Twitter Direct Message Integration
The Omnichannel strategy concerns the ability of a product to be present and usable for the customer anywhere and through various platforms, applications, social networks, among others. 4biz makes available the integration of the tool through various channels and social networks that we will know through this and other documents about Omnichannel. We will discuss how 4biz integration is done with the social network Twitter.
It is necessary to have permission to access the System;
Have a registered group that will receive all Twitter Direct Message users/requesters;
Have a registered portfolio that has the "Activity" to be made available by Twitter Direct Message;
Configure the Smartchat parameters (parameter 118, 315, 317, 390, 447);
Configure the Helper parameters(parameters 402, 423, 441, 442, 450, 453);
Have permission to create and/or edit an Omnichannel interaction;
Have performed all the necessary configurations on the Twitter developer (which will be presented later in the document).
To access Omnichannel functionality in 4biz, go to Menu > System > Settings > Omnichannel Interactions. The screen with the filters will be shown to search for the interactions and the list of interactions already present in the tool. Before filling in the data to create an Omnichannel interaction in 4biz, it is necessary to perform the configuration in Twitter Developer itself.
To achieve the integration through a direct message from Twitter, you need to use the Twitter Developer website (developer.twitter.com), because it will present the information that we will use in the configuration of 4biz. To create a Twitter Developer account, you must first have a Twitter registered account (twitter.com). After creating the accounts, follow the following steps:
-
- Twitter Developer even asks you to answer in English how you intend to use their API. We recommend setting it to "yes" and filling in only the options: "In English, please describe how you plan to use Twitter data and/or APIs. The more detailed the response, the easier it is to review and approve." and "Will you app use Tweet, Retweet, like, follow or Direct Message functionality?"
- Apps".
- Create New App" to create a new app.
-
Fields | Description |
---|---|
App name (mandatory) | Give a name to the application |
Application description (mandatory) | Describe the application that is being created
|
Website URL (mandatory) | Enter the URL of your domain |
Enable sign in with Twitter | Click if you want to allow this app to be used to log in with Twitter. Recommended not to check |
Tell us how this app will be used | Describe to the Twitter Developer itself the purpose of this application and how it will be used by the client |
- App Details" tab shows the fields that were filled in when creating the app.
- In the "Keys and tokens" tab, you can manage the keys, secret keys, and app access tokens.
- In "Consumer API Keys", will be presented the key and secret key of the API, keys that will be used to configure Omnichannel in 4biz.
- To generate access tokens and secret access tokens, click on "Generate" in "Access token & access token secret". These tokens will be used to configure the Omnichannel in 4biz.
🖊 Note: Note that a pop-up will appear with the access tokens to be copied, as once this window is closed, the access token data can no longer be viewed for security reasons. However, it is possible to generate new tokens by clicking on "Regenerate", except that the old tokens will be invalidated.
- In the "Permissions" tab, click on edit to give the type of access permission for the platform. In our case we will mark the option "Read, Write and Direct Message", in which the application will be allowed to read, write and perform direct message from Twitter.
- click on your avatar and go to "Dev Environments".
🖊 Note: To use one of the Twitter API subscriptions, you need to set up a development environment for the endpoint. All API subscription packages support at least 1 development environment (the number will depend on the details of your package), which can be used to isolate usage, rules, fee limits, or otherwise within your systems.
Field | Description |
---|---|
Dev environment label | Put an identifier for the application |
App | Select the application that was created earlier |
After filling in the fields, the description of the application we have just set up will be shown on the environments screen, and it is also possible to delete this environment.
To access Omnichannel functionality in 4biz, go to Menu > System > Settings > Omnichannel Interactions. Click on "New".
Fill in the fields that will appear:
Fields | Description |
---|---|
Identifier | 4biz already has this code filled in, and it cannot be changed |
Name | The user who is going to register can put any desired Name |
Interaction Channel
| Select the desired interaction channel. In this case, the "Twitter Direct Message" option |
Default Unit | The unit used in the creation of the collaborator/requester of the Twitter Direct Message |
Default Group | The group that will be configured for the collaborator/requester of the Twitter Direct Message |
Default Activity | Activity to be made available for creating tickets related to Twitter Direct Message |
Contact Origin | Configure where the contact will come from. In this case, Twitter |
Enable Interception with Helper | Enable this option only when you want the Twitter Direct Message user/requester to interact with the chatbot |
Development Environment | Is the name of the environment that was set up in the "Dev environment label" field in Twitter Developer |
API Key | The key generated in Twitter Developer itself in the "Keys and tokens" tab, the "API key" field |
API Secret Key | The secret key generated in Twitter Developer itself in the "Keys and tokens" tab, the "API secret key" field |
Access Token | The token generated in Twitter Developer itself in the "Keys and tokens" tab, the "Access token" field |
Access Token Secret | The secret token generated in Twitter Developer itself in the "Keys and tokens" tab, the "Access token secret" field |
Callback URL
| The domain of the application that will receive the calls coming from Twitter |
If you want to edit or delete an interaction, go to the home page of the Omnichannel Interactions, select one of the existing interactions to edit, or click on "Actions" and select the "Delete" option.