List messages
One conversation's messages, newest first. Poll forward with after (the id of the newest message you already have) to get only new ones. Page backward through history with cursor. Do not pass both.
Set up WhatsApp first. Connect a WhatsApp number in the dashboard or with Connect numbers. Included on every paid plan. See plans.
conversation_idstringrequiredThe conversation to read.
afterintegerReturn messages newer than this message id. next_cursor is null in this mode.
limitintegerRows per page.
cursorstringThe next_cursor from the previous page. Do not combine it with after.
curl -X GET 'https://omnidim.io/api/v1/whatsapp/messages?limit=20' \ -H 'Authorization: Bearer YOUR_API_KEY'
{ "data": [ { "id": 0, "conversation_id": "string", "wa_message_id": "string", "sender": "customer", "type": "string", "text": "string", "caption": "string", "profile_name": "string", "sent_by_workflow": "string", "timestamp": "string", "status": "pending", "reply_to": { "wa_message_id": "string", "preview": "string", "sender": "customer" }, "reactions": [ { "emoji": "string", "sender": "customer", "timestamp": "string" } ], "media": { "mime": "string", "filename": "string", "size": 0, "fetch_status": "done" }, "voice": { "duration_seconds": 0, "transcript": "string" }, "location": { "lat": 0, "lng": 0, "name": "string", "address": "string", "map_url": "string" }, "contacts": [ { "name": "string", "phones": [ "string" ] } ], "interactive": { "title": "string" }, "template": { "id": 0, "name": "string" }, "failure": { "code": "string", "reason": "string", "retryable": false }, "charged": { "amount": 0, "currency": "string" } } ], "has_more": false, "next_cursor": "string" }
BearerAuthAuthorizationBearer <token>Bearer token authentication. Obtain your API key from the OmniDimension dashboard.
conversation_id*stringThe conversation to read.
after?integerReturn messages newer than this message id. next_cursor is null in this mode.
limit?integerRows per page.
1 <= value <= 10020cursor?stringThe next_cursor from the previous page. Do not combine it with after.
Response body
application/jsonOne page of messages.
application/jsondata?has_more?booleannext_cursor?stringHand a conversation back
Give the conversation back to the agent, and clear a pause. The agent answers the customer's next message. Repeating it changes nothing.
Send a message
Send one message through phone_number_id to a customer, in a text, a template, an image or a document. Set type and the matching field.
