Skip to main content
The Conversations API lets you read and manage conversation threads in your Sahut inbox programmatically. Use it to pull conversation data into your reporting tools, create conversations from external triggers, or update conversation status and assignments.

List conversations

Retrieve a paginated list of conversations in your workspace.

Query parameters

string
Filter by status. One of: open, pending, resolved, snoozed. Omit to return all statuses.
string
Filter by channel ID. Returns only conversations from that channel.
string
Filter by assigned agent ID. Use unassigned to get conversations with no assignee.
integer
Page number for pagination. Default: 1.
integer
Number of results per page. Default: 25. Max: 100.

Example request

Example response

Get a conversation

Retrieve a single conversation by its ID.

Path parameters

string
required
The conversation ID (e.g., conv_01HX2B9K3M5N7P).

Example request

Create a conversation

Start a new conversation. This creates an outbound conversation — useful for proactive outreach.

Request body

string
required
ID of the contact to start the conversation with.
string
required
ID of the channel to use for this conversation.
object
Optional initial message to send. Include content (string) for a text message, or template_id for a WhatsApp template message.
string
Agent ID to assign the conversation to immediately.

Example request

Update a conversation

Change a conversation’s status, assignee, or labels.

Request body

string
New status. One of: open, pending, resolved, snoozed.
string
Agent ID to assign to. Pass null to unassign.
string
Team ID to assign to.
array
Array of label names to set on the conversation. Replaces existing labels.

Example request