Skip to content

RCS Webhooks

RCS Webhooks allow your application to receive real-time callbacks whenever a user interacts with your RCS Business Agent or when the status of an outbound message changes.

To register a new webhook, configure a new webhook from the dashboard under RCS → Utility → Webhook. Give your webhook a name, choose the events you want to receive, and provide your callback URL.


How To Add An RCS Webhook

  1. Click on RCS, then select Utility, and choose Webhook from the Dashboard.
RCS webhook list in the dashboard
  1. Click Add Webhook.
Add an RCS webhook callback URL
  1. Enter the following details:
  • Name – A unique name for the webhook.
  • Method – HTTP Method (POST).
  • End Point – Your publicly accessible webhook URL.
  • Events – Select the RCS events that you want to receive.
  1. Click Add Webhook to save the configuration.

Sample Webhook Requests

The following examples show the webhook payloads that your application may receive.

Replace the webhook URL with your own endpoint.


User Text Message

curl -X POST "https://your-domain.com/rcs/webhook" \
-H "Content-Type: application/json" \
-d '{
  "botId":"Brand BotId",
  "channel":"rcs",
  "event":"user_message",
  "message":{
    "suggestionResponse":null,
    "text":"Reply",
    "userFile":null
  },
  "messageId":"880be396-0b83-4cc0-8b79-0a259daff1e5:1",
  "timestamp":1782471254312,
  "userPhoneNumber":"+919999999999"
}'

Action URL Callback

curl -X POST "https://your-domain.com/rcs/webhook" \
-H "Content-Type: application/json" \
-d '{
  "botId":"Brand BotId",
  "channel":"rcs",
  "event":"user_message",
  "message":{
    "suggestionResponse":{
      "plainText":"Button Label",
      "postBack":{
        "data":"Your postdata"
      },
      "type":"ACTION"
    },
    "text":"",
    "userFile":null
  },
  "messageId":"53282600-4563-4cf4-94c0-680895481b2b:1",
  "timestamp":1782471183264,
  "userPhoneNumber":"+919999999999"
}'

Reply Button Callback

curl -X POST "https://your-domain.com/rcs/webhook" \
-H "Content-Type: application/json" \
-d '{
  "botId":"Brand BotId",
  "channel":"rcs",
  "event":"user_message",
  "message":{
    "suggestionResponse":{
      "plainText":"Yes",
      "postBack":{
        "data":"YES_CLICKED"
      },
      "type":"REPLY"
    },
    "text":"",
    "userFile":null
  },
  "messageId":"6b4e01d2-5b26-48c9-b879-1efaf08c4b01:1",
  "timestamp":1782471254312,
  "userPhoneNumber":"+919999999999"
}'

Dialer Callback

curl -X POST "https://your-domain.com/rcs/webhook" \
-H "Content-Type: application/json" \
-d '{
  "botId":"Brand BotId",
  "channel":"rcs",
  "event":"user_message",
  "message":{
    "suggestionResponse":{
      "plainText":"Call Now",
      "postBack":{
        "data":"+911234567890"
      },
      "type":"DIALER"
    },
    "text":"",
    "userFile":null
  },
  "messageId":"f0a6f7b4-c7a4-4709-b9f8-04e46bcfd911:1",
  "timestamp":1782471254312,
  "userPhoneNumber":"+919999999999"
}'

Message Sent

curl -X POST "https://your-domain.com/rcs/webhook" \
  -H "Content-Type: application/json" \
  -d '{
    "botId": "Brand BotId",
    "channel": "rcs",
    "event": "message_status",
    "messageId": "d8f513e9-7a5d-4356-99cd-a3a54660691a:1",
    "statuses": {
      "eventId": "MxV08D0IpdSJe7w207IxOEOQ",
      "status": "sent",
      "timestamp": 1782471167
    }
  }'

Message Delivered

curl -X POST "https://your-domain.com/rcs/webhook" \
-H "Content-Type: application/json" \
-d '{
   "botId": "Brand BotId",
  "channel": "rcs",
  "event": "message_status",
  "messageId": "d8f513e9-7a5d-4356-99cd-a3a54660691a:1",
  "statuses": {
    "eventId": "MxV08D0IpdSJe7w207IxOEOQ",
    "status": "delivered",
    "timestamp": 1782471167
  }
}'

Message Read

curl -X POST "https://your-domain.com/rcs/webhook" \
-H "Content-Type: application/json" \
-d '{
 "botId": "Brand BotId",
  "channel": "rcs",
  "event": "message_status",
  "messageId": "d8f513e9-7a5d-4356-99cd-a3a54660691a:1",
  "statuses": {
    "eventId": "MxV08D0IpdSJe7w207IxOEOQ",
    "status": "read",
    "timestamp": 1782471167
  }
}'

Message Failed

curl -X POST "https://your-domain.com/rcs/webhook" \
  -H "Content-Type: application/json" \
  -d '{
     "botId": "Brand BotId",
  "channel": "rcs",
  "event": "message_status",
  "messageId": "d8f513e9-7a5d-4356-99cd-a3a54660691a:1",
  "statuses": {
    "eventId": "MxV08D0IpdSJe7w207IxOEOQ",
    "status": "failed",
    "timestamp": 1782471167
  }
  }'

Message Status Event

StatusDescription
sentThe message has been accepted by the RCS platform and sent for delivery.
deliveredThe message has been successfully delivered to the recipient's device.
readThe recipient has opened and read the message.
failedThe message could not be delivered to the recipient.

Event Descriptions

EventDescription
user_messageTriggered whenever a user sends a message or interacts with your RCS Business Agent.
ACTIONUser tapped an Action URL suggestion.
REPLYUser selected a Reply Button suggestion.
DIALERUser tapped a Call Button suggestion.
textUser sent a text message.
suggestionResponseContains the information about the suggestion button selected by the user.
locationUser shared their location.
userFileUser uploaded a file, image, video, or audio attachment.

Was this page helpful?