Receiving and Processing Reports Sent on Twilio
Function
This interface is invoked to receive and process reports sent on Twilio.
Usage Description
Interface Authentication
This authentication mode is used for WhatsApp access through the Twilio integrator.
Instructions:
In the AICC, the webhook user and password are configured on the Channel Configuration page.
After the WhatsAppAdapter interface is invoked, the request header generates a signature based on the webhook user and password and adds the signature to the Authorization attribute.
Request Header Parameters
|
Parameter |
Mandatory or Not |
Type |
Default Value |
Description |
|---|---|---|---|---|
|
Content-Type |
Yes |
String |
None |
The value is fixed at application/x-www-form-urlencoded. |
|
Authorization |
Yes |
String |
None |
Twilio generates Authorization based on the webhook user and password, which is carried in a request sent to the AICC. |
Interface Prototype
|
Method |
POST |
|
|---|---|---|
|
URL |
https://IP address:Port number/social/on/whatsapp/{whatsAppBsp}/report/{channelConfigId} |
IP address:Port number indicates the IP address and port number of the NSLB exposed externally. {whatsAppBsp} indicates the integrator and is fixed at twilio in the twilio provider scenario. {channelConfigId} indicates the channel ID. |
Request Body Parameters
|
Parameter |
Mandatory or Not |
Type |
Description |
|---|---|---|---|
|
MessageSid |
Yes |
String |
Message ID identifier. |
|
MessageStatus |
Yes |
String |
Status: delivered or read. |
|
To |
Yes |
String |
Receiver. |
|
From |
Yes |
String |
Sender. |
Response Parameters
No response is returned when this interface is invoked.
Example
- Request
POST /social/on/whatsapp/twilio/report/****' --header 'Authorization: basic ****' --header 'Content-Type: application/x-www-form-urlencoded' --data-urlencode 'From=whatsapp:+****' --data-urlencode 'To=whatsapp:+****' --data-urlencode 'MessageStatus=delivered' --data-urlencode 'MessageSid=****'
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot