On Workplace, bots are represented as pages. A page is automatically created when you create a custom integration app. Only System Administrators of a Workplace community can create apps and generate access tokens in that community.
- Each YM Bot is considered as a custom integration for the workplace (page).
- The workplace custom integration interacts with the YM Bot through webhooks which can be configured from within the workplace settings.
- The YM Bot consumes workplace APIs to send messages across.
Creating Custom Integrations
You will be needing a Super Administrator role. To create an app for Workplace, follow the steps below:
- In the Admin Panel, open the Integrations tab.
- Click on the Create Custom Integration button.
- Choose a relevant name and description for the app.
- Add a profile picture for the app. This will be used any time the app is visually represented, for instance if it makes a post to a group.
- Choose the required permissions for the app, based on the integration functionality you require.
- Create Access Token once you are landed to the Integration details page
- Copy and safely store the access token that is shown to you. You will need this when making API calls and configuring in the YM Portal.
General List of permissions required
Message any member - This permission is used to send a message to any member in the workplace team. Real all messages - See messages sent to anyone in the workplace team.
Configuring workplace as a channel in the Portal
- In the portal, go to Configuration and then select Channels.
- Now select Facebook workplace form the list of channels, there paste the App ID from the workplace integration page, and the access token which was generated earlier, and click on connect.
- Now, post successful connection, copy the Webhook configuration, both callback URL and the verify token and paste under the “Page” tab of the “Configure Webhooks” section in the workplace integrations page.
Making sure that all the checkboxes are selected under the Page tab, click on save. Now the created workplace integration is successfully configured with the YM Bot as a channel, and all the messages can be exchanged between.