Create New Message
Create a new message in the conversation.
Use application/json for text messages and multipart/form-data when the
message includes file attachments.
Multipart attachment request
Send files with the attachments[] form field. curl -F sets the
multipart/form-data content type and boundary automatically.
curl -X POST "https://app.chatwoot.com/api/v1/accounts/{account_id}/conversations/{conversation_id}/messages" \ -H "Authorization: Bearer <your-api-token>" \ -F "content=Here is the screenshot" \ -F "message_type=outgoing" \ -F "private=false" \ -F "attachments[]=@/path/to/screenshot.png"WhatsApp Template Messages
For WhatsApp channels, you can send structured template messages using the template_params field.
Templates must be pre-approved in WhatsApp Business Manager.
By default, content is treated as the already-rendered transcript text for
compatibility with existing API and mobile clients. To submit the original
template body instead, set template_params.content_mode to raw_template;
Chatwoot will substitute processed_params.body before saving the transcript.
Example Templates
Text with Image Header:
{ "content": "Hi your order 121212 is confirmed. Please wait for further updates", "template_params": { "name": "order_confirmation", "category": "MARKETING", "language": "en", "processed_params": { "body": { "1": "121212" }, "header": { "media_url": "https://picsum.photos/200/300", "media_type": "image" } } }}Text with Copy Code Button:
{ "content": "Special offer! Get 30% off your next purchase. Use the code below", "template_params": { "name": "discount_coupon", "category": "MARKETING", "language": "en", "processed_params": { "body": { "discount_percentage": "30" }, "buttons": [{ "type": "copy_code", "parameter": "SAVE20" }] } }}AuthorizationBearer <token>Authenticate with Authorization: Bearer <token> using a user API token from Profile Settings. Available in Chatwoot v4.19.0 and later.
account_id*integerThe numeric ID of the account
conversation_id*integerThe numeric ID of the conversation
- body
content*stringThe content of the message
message_type?stringThe type of the message
"outgoing""incoming"private?booleanFlag to identify if it is a private note
content_type?stringContent type of the message
"text""input_email""cards""input_select""form""article"content_attributes?Attributes based on the content type. For input_select, provide an items array with
title, value, and optional description. WhatsApp list messages use description
as the row subtitle when present.
campaign_id?integerThe campaign id to which the message belongs
template_params?WhatsApp template parameters for sending structured messages
Success
application/json- response
id?numberThe ID of the message
content?stringThe text content of the message
account_id?numberThe ID of the account
inbox_id?numberThe ID of the inbox
conversation_id?numberThe ID of the conversation
message_type?integerThe type of the message
0123created_at?integerThe time at which message was created
updated_at?|The time at which message was updated
private?booleanThe flags which shows whether the message is private or not
status?|The status of the message
"sent""delivered""read""failed"nullsource_id?|The source ID of the message
content_type?|The type of the template message
"text""input_text""input_textarea""input_email""input_select""cards""form""article""incoming_email""input_csat""integrations""sticker""voice_call"nullcontent_attributes?The content attributes for each content_type
sender_type?|The type of the sender
"Contact""User""AgentBot""Captain::Assistant"nullsender_id?|The ID of the sender
external_source_ids?The external source IDs of the message
additional_attributes?The additional attributes of the message
processed_message_content?|The processed message content
sentiment?|The sentiment of the message
conversation?|The conversation object
attachment?|The file object attached to the image
sender?User/Agent/AgentBot object
curl -X POST 'https://helpdesk.inclamo.com/api/v1/accounts/0/conversations/0/messages' \ -H 'Content-Type: application/json' \ -d '{ "content": "string"}'{ "id": 0, "content": "string", "account_id": 0, "inbox_id": 0, "conversation_id": 0, "message_type": 0, "created_at": 0, "updated_at": 0, "private": true, "status": "sent", "source_id": "string", "content_type": "text", "content_attributes": {}, "sender_type": "Contact", "sender_id": 0, "external_source_ids": {}, "additional_attributes": {}, "processed_message_content": "string", "sentiment": {}, "conversation": {}, "attachment": {}, "sender": {}}