A user must be registered as a contact on your account before their messages will be routed to you. This can be done by sending them a message or adding them as a contact.
Need receive-first texting? Talk to us about our dedicated plans.
In order to enable receiving messages, you have to specify the webhooks that you want to use in your api dashboard.
Received Messages will be sent as a POST request to the webhook which you define. These messages will be delivered in the JSON of a POST body which looks like this:
"accountEmail": "[email protected]",
"content": "Ahoy Developer!",
You must send a response to our server in order to avoid receiving multiple webhook calls.
Webhook Body Parsing
|Callback Body Field||Type||Description|
|accountEmail||Associated account email|
|media_url||A CDN link to the image that was sent to your sendblue number from an end-user. This link expires after 30 days|
|is_outbound||True if message is sent, false if message is received|
|status||The current status of the message|
|error_code||error code (null if no error)|
|error_message||descriptive error message (null if no error)|
|message_handle||Sendblue message handle|
|date_sent||ISO 8601 formatted date string of the date this message was created|
|date_updated||ISO 8601 formatted date string of the date this message was last updated|
|from_number||E.164 formatted phone number string of the message dispatcher|
|number||E.164 formatted phone number string of your end-user (not the Sendblue-provided phone number)|
|to_number||E.164 formatted phone number string of the message recipient|
|was_downgraded||true if the end user does not support iMessage, false otherwise|
|plan||Value of the Sendblue account plan|