Login to your TextIt account to use the following links to access specific pages in your account.
For this integration, you’ll need:
- a Facebook App: Your Facebook App will contain your Bot’s Messenger settings. This is where you'll setup your Webhook, retrieve your page access token and submit your app for approval.
- a Facebook Page: A Facebook Page will be act as your Bot’s identity. When people chat with your Bot, they’ll see the Page’s name and profile pic.
- a WebHook URL: Facebook uses secure callbacks to send messaging events to your TextIt account.
Creating your Bot
First, create an account on Facebook's Developer Platform. Once logged in, use the ‘My Apps’ menu in the top righthand corner to select ‘Add a New App’.
An ‘Add a New App’ dialogue will appear, asking you to select a platform. Click the ‘basic setup’ link near the bottom; you can add your platform at a later step.
Next, you’ll be prompted to create an App ID for your new app.
Once you've registered your app, navigate to the ‘Messenger’ tab and click ‘Get Started’.
Once you’ve received your Page Access Token, navigate to your TextIt account in a separate tab and claim a Facebook channel. Enter your Page Access Token to receive your callback URL.
Back in the 'Messenger' tab, within the 'Webhooks' section, click ‘Setup Webhooks’ to enter your callback URL and check all boxes to subscribe to all incoming Facebook events.
- ‘messaging_optins’ subscribes your app to authentication callbacks via the Send-to-Messenger Plugin.
- ‘messages’ allows your app receive text messages or messages with attachments (image, video, audio).
- ‘message_deliveries’ subscribes your app to message delivery receipts.
- ‘messaging_postbacks’ subscribes to post back callbacks, in case your app incorporates buttons.
Next, navigate to the ‘Settings’ tab and click ‘Add Platform’.
There, you can add the URL of your website as your platform. Once added, click ‘Save Changes’ to continue.
Prior to submission, navigate to the ‘App Details’ tab and complete it.
Submitting your Bot
Now you’re ready to submit your app. Note that each new Messenger Bot is subject to an internal review process; use the information in this link to ensure your content is acceptable per Facebook's approval criteria.
Navigate to the ‘App Review’ tab and click ‘Start a Submission’. Select ‘pages_messaging’ from the list on the lefthand side of the dialog and continue.
Once you've selected the 'items' you'd like to add, click the 'edit' links next to them to fill out their corresponding forms.
Finally, click 'Submit for Review' to complete the submission process.
- The Messenger Platform is intended for customer-initiated interactions. As such, Facebook Messenger doesn't allow you to reach Facebook contacts without them contacting you first. Your contacts can reach you via your Page, or search for your Bot via the Messenger app.
Facebook uses unique contact ids per page, so you won't be able to access contacts you talked to previously on a Facebook page with a new page. For this reason, we recommend assigning one Facebook page to each Messenger app (Facebook channel) connected to your TextIt account.
Until your app is approved by Facebook, only admins will be allowed to message your app (even if you've made it 'public' prior to approval).