Sends a real message to a real person. There is no test mode. The send is queued and the response is data.messageId with data.status "queued"; delivery outcome arrives later on the message itself. message is the channel payload — a text message is { "type": "text", "text": "Hello" }. connectionId must be a connection on this account, and channel rules still apply (for example the WhatsApp 24-hour window and Instagram not being able to open a conversation).
Optional. A unique value of your own, up to 255 printable characters without spaces — a UUID is ideal. The first request carrying it is processed; any later request with the same key returns that first response instead of repeating the work, for 24 hours. A replayed response carries Idempotency-Replayed: true. Reuse the key when you retry after a timeout, and change it when you mean to send again.
Channel message payload. A text message is { "type": "text", "text": "Hello" }.
{ "type": "text", "text": "Hello" }
- Mock serverhttps://developer.iclosed.io/_mock/openapi/uinbox/v1/modules/messages/v1/messages/send
- Productionhttps://uinboxpub.api.iclosed.io/v1/messages/send
curl -i -X POST \
https://developer.iclosed.io/_mock/openapi/uinbox/v1/modules/messages/v1/messages/send \
-H 'Authorization: Bearer <YOUR_API key_HERE>' \
-H 'Content-Type: application/json' \
-H 'Idempotency-Key: string' \
-d '{
"chatId": "507f1f77bcf86cd799439011",
"connectionId": "507f191e810c19729de860ea",
"message": {
"type": "text",
"text": "Hello"
}
}'{ "data": { "messageId": "string", "status": "queued" } }