Skip to Content
Technical Articles

Facebook Page and SAP Cloud for Service Integration Requires Facebook App Review

Disclaimer: The aim of this blog post is to provide a better understanding of the Facebook App Review procedure with regard to the integration between Facebook and SAP Cloud for Service (C4S), a solution of SAP Service Cloud portfolio, it is not the product documentation.

As the required Facebook permissions as well as review process might be changed overtime per Facebook’s policy, so if there is any change, I will publish a new blog post with updated information.

In order to be aware of any possible updates, I recommend to follow my profile  and update your notification settings to receive updates regarding this topic.

Meanwhile, be noticed, the information provided does not guaranty the app review approval from Facebook reivew. You are responsible for the continuity of apps and its contract with Facebook.

1. Overview

SAP Cloud for Service (C4S) supports a company’s service agent to directly reply from C4S to the Facebook user who makes posts, comments or direct Messenger conversation to the company’s Facebook page. A Facebook page is owned by a Facebook account. A page owner can grant access to a 3rd party Facebook app, allowing it to interact with that page on the owner’s behalf. This is how the C4S and Facebook integration works.

While in Development mode, apps are automatically approved for all login permissions, features, and product-specific features. You can test your integration with C4S.  But before you go live with your app, you will need to request some special Facebook permissions in order to integrate with C4S. These additional permissions will require your Facebook app to pass an App Review.

Before the Facebook Graph API was changed from V3.2 to V3.3 in April 30, 2019,  you would have to request for the following permissions – manage_pages, read_page_mailboxes, publish_pages for your Facebook app.

With the Graph API change, the Conversation API and Private Reply endpoints now require the pages_messaging permission, as the read_page_mailboxes permission is deprecated. Apps previously approved for read_page_mailboxes need to go through App Review for pages_messaging permissions approval.

So, for any new app to be integrated with SAP Cloud for Service after V3.3, The following permissions are subject to review:

  • manage_pages: Required for listing a user’s pages and obtaining page access tokens. Apps that allow users to publish as a Page must also have the publish_pages permission. To add review submission, from the Facebook dashboard, navigate to the App Review section, then click Start Submission.
  • publish_pages: Required for publishing posts, comments, and like Pages managed by the app user. Also requires the manage_pages permission. To add review submission, from the Facebook dashboard, navigate to the App Review section, then click Start Submission.
  • pages_messaging: Required for sending and receiving Facebook Messenger messages. First, add the Messenger product to your app, and then add this permission to your review request from the Messenger section of the Facebook dashboard.

Note: we do not request for any of the following permissions – “user_friends”, “user_link”, “user_gender”, “user_age_range” that are mentioned in their alert.

Please refer to this link from Facebook for the app review process.

2. Prerequisites

As the reviewer needs to log into your C4S  tenant to test the integration, so before you make the app review submission, you should follow this help center document to set up your Facebook app, and the integration with C4S tenant. Note: This is only possible when you Facebook app is not in live mode. Your app can only use permissions and features that it has been approved for. This means you will be unable to test usage of any unapproved permissions or features.

While creating your Facebook App, you should pay special attention to the following points:

1.Maintain the App Domains and Website:

2.

2.You have to make sure the valid OAuth Redirect URIs is maintained, the url is like this: https//myXYZ.crm.ondemand.com/sap/byd/oauth/facebook

If this is not correctly maintained, when the reviewer test your integration, they will receive the following error message:

3. Request Permissions

3.1 Manage_pages, publish_pages

3.1.1 Where to submit the app review request:

  1. You sign into your app’s dashboard, click App Review then click Permissions and Features.
  2. Search for manage_pages, publish_pages, request both of them.
  3. Both of the requests will be displayed in the Current Request section.

3.1.2  Complete verification

Under App Review, click Current Request section, then provide verification details by clicking the blue arrow icon in the Provide Verification details row. In the opened dialog window, make the selection per the sceenshot below.

Meanwhile, in the provide detailed step-by-step instructions input box of the screenshot above, try entering the following (Note: the URL and XXX needs to be replaced with your tenant and app specific value) :

“The permission is needed to integrate with SAP system SAP Cloud for Service. In order to test the integration, follow the steps covered in the screencast provided. Please use the following url and credentials for the test:

1.Log on to SAP C4S vial this URL using user: XXX and pwd:XXX

2. For the App ID and App secret to be entered for the first step: App ID: XXX App Secret: XXX

Note(To be deleted when submitting request): As Facebook App in development mode are automatically approved for all login permissions, and product-specific features. If the app to be reviewed is still in development mode, you can submit its app ID and secret to reviewer, they should be able to test the integration. If the app to be reviewed is already live, and you are just requesting for additional permission, Facebook suggest you use a test app for test

3. The Facebook developer account for this app to retrieve Facebook pages are : User Name: XXX Pwd:XXX ”  Note:  the system needs the manage_pages, Publish_Pages permissions, in order to retrieve a list of Facebook pages. Otherwise the system gives the error message.”

Note (To be deleted when submitting request): The reviewer might log in with their own developer account, and create a test page, but you might as well provide a test developer account just in case.

3.1.3 Explain how you’ll use the publish_pages and manage_pages permission

In the Requested Permission and Features section, click the blue arrow of publish pages and manage_pages, see the screenshot below

It opens up a screen as shown below:

For the first input box for both publish_pages and manage_pages, I’d recommend you try with the following:

The permission is requested to integrate with our CRM system, SAP Cloud for Service (C4S) system. C4S app allows our service team to send customer support messages to the Facebook user who makes posts, comments or direct Messenger conversation to our Facebook page (mainly for customer service). For the manage_pages permission, our app requires access to this permission to retrieve Page Access Tokens, and also due to the need of publish_pages permission that also requires manage_pages. The publish_pages and manage_pages permission allows the app to retrieve the public posts and comments on our Facebook page, which will be created as service tickets, and then our service team can publish content to our Facebook page.
Be noticed that the SAP C4S programmatically retrieves the public posts to Facebook page:
• A batch job is scheduled on a regular basis to pull messages from Facebook page.
• If there are new messages, a call is made to the Graph API using manage_pages, publish_pages  to pull messages from Facebook page.”

For the screencast, you can make a screencast in a C4S system that integrates with a Facebook app that is stil in development mode, it’s better that your screencast can cover the following parts as shown in this video. You can try directly upload this video, however, as the C4S tenant is different, not sure if reviewer will accept it.

3.1.4 Complete app setting

Before you can sumbit the request, you should review your app settings.

3.2 Page_Messaging

The page_messaging permission is needed if you will respond to Facebook Messenger message directly from SAP Cloud for Service.

3.2.1 Prequisites

Doublecheck if the valid OAuth Redirect URIs is maintained, the url is like this: https//myXYZ.crm.ondemand.com/sap/byd/oauth/facebook

3.2.3 Request the permission

For page_messaging, you should add Messenger to Products first, then follow the steps below to request the permission for page_messaging:

1.Go to Messenger and click Settings, navigate to the App Review for Messenger section as shown below:

2. Add Pages_Messaging to submission.

3. Open the submission form details. Check the “I agree to Facebook’s permission and feature usage guidelines.”

4. In the Tell us about the Use case(s) for your app will use the permission for section. Check the last one Others. Then I’d recommend you try with the following input:

The integration is for business integration with CRM system, there is no chatbot involved, the service agent can only manually reply to the messenger message when the message is imported to the CRM system, in the CRM system, the Messenger conversation is retrieved via scheduled batch job, and the message will be created as a service ticket, in the service ticket, the service agent can manually reply to the messenger conversation which will be shown to the Facebook user.”

4. Additional info

When you get the approval of the requested permissions, you should set the App to live mode in order to access live data. Meanwhile, business verification shall be done, also related contracts shall be signed per Facebook’s request.

9 Comments
You must be Logged on to comment or reply to a post.
  • Thank you, it’s a very good post!
    Wendy, maybe you know, I’ve all permissions and contract on FB side. Screenshot
    But when change App status in “Live” in C4C have next error ” 403 :message#Application request limit reached#type#”OAuthException”,”is_transient”false,”code”4,”error_subcode”1349193,”error_user_title””Exceeded asset access limit”,”error_user_msg””You h’ ”

    Thank for all answer

  • Hello Wendy

    That was an excellent post. I could  configurate my integration perfectly.

    Nevertheless im stuck at the point when i need to send a message from C4C to facebook, related to a ticket. I already have the  page_messaging permission from facebook. But i can’t find the way to write that messages from my c4c platform. Could you please give me a hand with that?

    Thank you!

    Rgs

    • Hi Carles,

      The issue description is too general for me to understand the real issue here.

      At the same time, please confirm the following:

      1. Did you try to reply the social user via the Social Interaction tab of the Ticket?
      2. Or you did try to reply from Social interaction tab, but there is no reply button?
      3. Or when you reply, the message is not reached to Facebook?

      Would be great if you could report an incident is the issue is not resolved.

      Regards,

      Wendy

      •  

        Hi Wendy,

        I can’t see the Social Media interactions Facet from my Fiori Client view.

        Also, i have tried to create a Social Media Message through my Facebook Channel to my facebook account, and this error appears:

        “The external service provider ‘C4Cproducts’ reported the following error: :message#(#200) If posting to a group, requires app being installed in the group, and \\n either publish_to_groups permission with user token, or both manage_pages \\n and publish_pages permission with page token; If posting to a page,”

        I already have the Manage_pages, Publish_pages and Page_messaging permissions from facebook on my app.

        Do you have an idea of what could be the problem?

        Thank you so much for your help

        Rgds

         

        Carles.

  • Hello,

    Experts, can you send more info about How end-users must send answers from ticket to Facebook client.

    Use tab Interactions or SocialInteractions in the FIORI?

    I can’t find any user guide

    Thanks