Conversations
A conversation is the chat with one contact on one channel: WhatsApp, website chat, Instagram, Messenger, Telegram or SMS. Assign it to a team member, close it, or read its messages.
List conversations #
GET/api/v1/conversations
Newest first. Every filter is optional and they combine.
Query parameters
statusstring- open or closed.
channelstring- whatsapp, widget, instagram, messenger, telegram or sms.
contact_idinteger- Only this contact’s conversations.
phonestring- Only conversations with the contact who has this phone number.
assigned_tostring- A team member’s id, or “none” for conversations nobody has taken.
active_sincedate-time- Only conversations with a message at or after this time.
pageinteger- Which page, starting at 1. A page past the end is an empty list.
limitinteger- How many per page: 1 to 100. 50 when left out.
Returns HTTP 200
okboolean- Always true on success.
conversationslist of Conversation- The conversations on this page.
pageinteger- The page you asked for.
pagesinteger- How many pages there are at this limit.
totalinteger- How many items match in all.
limitinteger- Items per page.
has_moreboolean- True while there is a next page.
Errors
- 401
unauthorized - The Authorization header is missing, or the key is wrong or deleted.
- 422
invalid_date - A date filter isn’t a date and time like 2026-01-31T09:30:00Z.
- 422
invalid_filter - assigned_to isn’t an id or “none”.
- 429
rate_limited - More than 120 requests in a minute with this key. Wait for the seconds in Retry-After.
Plus the errors any request can get.
curl "https://chatilo.me/api/v1/conversations?status=open&assigned_to=none" \
-H "Authorization: Bearer YOUR_API_KEY"<?php
$apiKey = 'YOUR_API_KEY';
$ch = curl_init('https://chatilo.me/api/v1/conversations?status=open&assigned_to=none');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Authorization: Bearer ' . $apiKey],
]);
$result = json_decode((string) curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_RESPONSE_CODE);
if ($status >= 400) {
throw new RuntimeException($result['error']['code'] . ': ' . $result['error']['message']);
}
print_r($result);const apiKey = 'YOUR_API_KEY';
const response = await fetch("https://chatilo.me/api/v1/conversations?status=open&assigned_to=none", {
headers: {
Authorization: `Bearer ${apiKey}`,
},
});
const result = await response.json();
if (!response.ok) {
throw new Error(`${result.error.code}: ${result.error.message}`);
}
console.log(result);import requests
api_key = "YOUR_API_KEY"
response = requests.get(
"https://chatilo.me/api/v1/conversations?status=open&assigned_to=none",
headers={"Authorization": f"Bearer {api_key}"},
timeout=30,
)
result = response.json()
if not response.ok:
raise RuntimeError(f"{result['error']['code']}: {result['error']['message']}")
print(result){
"ok": true,
"conversations": [
{
"id": 2001,
"contact_id": 1001,
"channel": "whatsapp",
"status": "open",
"assigned_to": null,
"last_message_preview": "Hi, is the blue kurta available in medium?",
"last_message_at": "2026-01-31T09:30:00Z",
"window_open": true,
"created_at": "2026-01-31T09:30:00Z",
"url": "https://chatilo.me/inbox?c=2001"
}
],
"page": 1,
"pages": 1,
"total": 1,
"limit": 50,
"has_more": false
}Get a conversation #
GET/api/v1/conversations/{id}
One conversation with its contact.
Path
idintegerrequired- The conversation’s id.
Returns HTTP 200
okboolean- Always true on success.
conversationConversation- The conversation.
contactContact or null- Who it is with.
Errors
- 401
unauthorized - The Authorization header is missing, or the key is wrong or deleted.
- 404
conversation_not_found - No conversation with that id in this workspace.
- 429
rate_limited - More than 120 requests in a minute with this key. Wait for the seconds in Retry-After.
Plus the errors any request can get.
curl "https://chatilo.me/api/v1/conversations/2001" \
-H "Authorization: Bearer YOUR_API_KEY"<?php
$apiKey = 'YOUR_API_KEY';
$ch = curl_init('https://chatilo.me/api/v1/conversations/2001');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Authorization: Bearer ' . $apiKey],
]);
$result = json_decode((string) curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_RESPONSE_CODE);
if ($status >= 400) {
throw new RuntimeException($result['error']['code'] . ': ' . $result['error']['message']);
}
print_r($result);const apiKey = 'YOUR_API_KEY';
const response = await fetch("https://chatilo.me/api/v1/conversations/2001", {
headers: {
Authorization: `Bearer ${apiKey}`,
},
});
const result = await response.json();
if (!response.ok) {
throw new Error(`${result.error.code}: ${result.error.message}`);
}
console.log(result);import requests
api_key = "YOUR_API_KEY"
response = requests.get(
"https://chatilo.me/api/v1/conversations/2001",
headers={"Authorization": f"Bearer {api_key}"},
timeout=30,
)
result = response.json()
if not response.ok:
raise RuntimeError(f"{result['error']['code']}: {result['error']['message']}")
print(result){
"ok": true,
"conversation": {
"id": 2001,
"contact_id": 1001,
"channel": "whatsapp",
"status": "open",
"assigned_to": {
"id": 4,
"name": "Emily"
},
"last_message_preview": "Hi, is the blue kurta available in medium?",
"last_message_at": "2026-01-31T09:30:00Z",
"window_open": true,
"created_at": "2026-01-31T09:30:00Z",
"url": "https://chatilo.me/inbox?c=2001"
},
"contact": {
"id": 1001,
"name": "Grace Miller",
"phone": "919876543210",
"email": "[email protected]",
"source": "api",
"opted_in": true,
"tags": [
"VIP"
],
"created_at": "2026-01-31T09:30:00Z",
"attributes": {
"city": "Denver"
},
"notes": "",
"opted_out_at": null,
"last_seen_at": "2026-01-31T09:30:00Z",
"updated_at": "2026-01-31T09:30:00Z"
}
}Assign, close or reopen a conversation #
PUT/api/v1/conversations/{id}
Send status, assigned_to, or both. Closing also hands the chat back to your chatbot and flows for next time, exactly as closing it in the inbox does. Hooks hear conversation.closed and conversation.opened within about a minute.
Path
idintegerrequired- The conversation’s id.
Body JSON
statusstring- closed to close it, open to reopen it.
assigned_tointeger or null- The id of an active team member (see “List the team”), or null to unassign.
Returns HTTP 200
okboolean- Always true on success.
conversationConversation- The conversation as it now is.
contactContact or null- Who it is with.
Errors
- 401
unauthorized - The Authorization header is missing, or the key is wrong or deleted.
- 403
read_only_key - A read-only key was used for a request that changes something.
- 404
conversation_not_found - No conversation with that id in this workspace.
- 422
invalid_assignee - assigned_to isn’t an active team member of this workspace.
- 422
invalid_status - status isn’t open or closed.
- 422
nothing_to_update - Neither status nor assigned_to was sent.
- 429
rate_limited - More than 120 requests in a minute with this key. Wait for the seconds in Retry-After.
Plus the errors any request can get.
curl -X PUT "https://chatilo.me/api/v1/conversations/2001" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"status": "closed",
"assigned_to": 4
}'<?php
$apiKey = 'YOUR_API_KEY';
$ch = curl_init('https://chatilo.me/api/v1/conversations/2001');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_CUSTOMREQUEST => 'PUT',
CURLOPT_HTTPHEADER => ['Authorization: Bearer ' . $apiKey, 'Content-Type: application/json'],
CURLOPT_POSTFIELDS => json_encode([
'status' => 'closed',
'assigned_to' => 4,
]),
]);
$result = json_decode((string) curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_RESPONSE_CODE);
if ($status >= 400) {
throw new RuntimeException($result['error']['code'] . ': ' . $result['error']['message']);
}
print_r($result);const apiKey = 'YOUR_API_KEY';
const response = await fetch("https://chatilo.me/api/v1/conversations/2001", {
method: 'PUT',
headers: {
Authorization: `Bearer ${apiKey}`,
'Content-Type': 'application/json',
},
body: JSON.stringify({
"status": "closed",
"assigned_to": 4
}),
});
const result = await response.json();
if (!response.ok) {
throw new Error(`${result.error.code}: ${result.error.message}`);
}
console.log(result);import requests
api_key = "YOUR_API_KEY"
response = requests.put(
"https://chatilo.me/api/v1/conversations/2001",
headers={"Authorization": f"Bearer {api_key}"},
json={
"status": "closed",
"assigned_to": 4,
},
timeout=30,
)
result = response.json()
if not response.ok:
raise RuntimeError(f"{result['error']['code']}: {result['error']['message']}")
print(result){
"ok": true,
"conversation": {
"id": 2001,
"contact_id": 1001,
"channel": "whatsapp",
"status": "closed",
"assigned_to": {
"id": 4,
"name": "Emily"
},
"last_message_preview": "Hi, is the blue kurta available in medium?",
"last_message_at": "2026-01-31T09:30:00Z",
"window_open": true,
"created_at": "2026-01-31T09:30:00Z",
"url": "https://chatilo.me/inbox?c=2001"
},
"contact": {
"id": 1001,
"name": "Grace Miller",
"phone": "919876543210",
"email": "[email protected]",
"source": "api",
"opted_in": true,
"tags": [
"VIP"
],
"created_at": "2026-01-31T09:30:00Z",
"attributes": {
"city": "Denver"
},
"notes": "",
"opted_out_at": null,
"last_seen_at": "2026-01-31T09:30:00Z",
"updated_at": "2026-01-31T09:30:00Z"
}
}List a conversation’s messages #
GET/api/v1/conversations/{id}/messages
The messages and internal notes in one conversation, newest first.
Path
idintegerrequired- The conversation’s id.
Query parameters
directionstring- in for the customer’s messages, out for yours.
sincedate-time- Only messages at or after this time.
pageinteger- Which page, starting at 1. A page past the end is an empty list.
limitinteger- How many per page: 1 to 100. 50 when left out.
Returns HTTP 200
okboolean- Always true on success.
messageslist of Message- The messages on this page.
pageinteger- The page you asked for.
pagesinteger- How many pages there are at this limit.
totalinteger- How many items match in all.
limitinteger- Items per page.
has_moreboolean- True while there is a next page.
Errors
- 401
unauthorized - The Authorization header is missing, or the key is wrong or deleted.
- 404
conversation_not_found - No conversation with that id in this workspace.
- 422
invalid_date - A date filter isn’t a date and time like 2026-01-31T09:30:00Z.
- 429
rate_limited - More than 120 requests in a minute with this key. Wait for the seconds in Retry-After.
Plus the errors any request can get.
curl "https://chatilo.me/api/v1/conversations/2001/messages?limit=20" \
-H "Authorization: Bearer YOUR_API_KEY"<?php
$apiKey = 'YOUR_API_KEY';
$ch = curl_init('https://chatilo.me/api/v1/conversations/2001/messages?limit=20');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Authorization: Bearer ' . $apiKey],
]);
$result = json_decode((string) curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_RESPONSE_CODE);
if ($status >= 400) {
throw new RuntimeException($result['error']['code'] . ': ' . $result['error']['message']);
}
print_r($result);const apiKey = 'YOUR_API_KEY';
const response = await fetch("https://chatilo.me/api/v1/conversations/2001/messages?limit=20", {
headers: {
Authorization: `Bearer ${apiKey}`,
},
});
const result = await response.json();
if (!response.ok) {
throw new Error(`${result.error.code}: ${result.error.message}`);
}
console.log(result);import requests
api_key = "YOUR_API_KEY"
response = requests.get(
"https://chatilo.me/api/v1/conversations/2001/messages?limit=20",
headers={"Authorization": f"Bearer {api_key}"},
timeout=30,
)
result = response.json()
if not response.ok:
raise RuntimeError(f"{result['error']['code']}: {result['error']['message']}")
print(result){
"ok": true,
"messages": [
{
"id": 3001,
"conversation_id": 2001,
"direction": "out",
"kind": "template",
"body": "Hi Grace, your order #1042 has shipped.",
"status": "delivered",
"error": null,
"sender": "API",
"created_at": "2026-01-31T09:30:00Z",
"media": null,
"contact_id": 1001
}
],
"page": 1,
"pages": 1,
"total": 1,
"limit": 20,
"has_more": false
}List the team #
GET/api/v1/team
The workspace’s team members, so you know whose id to assign a conversation to.
Returns HTTP 200
okboolean- Always true on success.
teamlist of TeamMember- The team, by name.
Errors
- 401
unauthorized - The Authorization header is missing, or the key is wrong or deleted.
- 429
rate_limited - More than 120 requests in a minute with this key. Wait for the seconds in Retry-After.
Plus the errors any request can get.
curl "https://chatilo.me/api/v1/team" \
-H "Authorization: Bearer YOUR_API_KEY"<?php
$apiKey = 'YOUR_API_KEY';
$ch = curl_init('https://chatilo.me/api/v1/team');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Authorization: Bearer ' . $apiKey],
]);
$result = json_decode((string) curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_RESPONSE_CODE);
if ($status >= 400) {
throw new RuntimeException($result['error']['code'] . ': ' . $result['error']['message']);
}
print_r($result);const apiKey = 'YOUR_API_KEY';
const response = await fetch("https://chatilo.me/api/v1/team", {
headers: {
Authorization: `Bearer ${apiKey}`,
},
});
const result = await response.json();
if (!response.ok) {
throw new Error(`${result.error.code}: ${result.error.message}`);
}
console.log(result);import requests
api_key = "YOUR_API_KEY"
response = requests.get(
"https://chatilo.me/api/v1/team",
headers={"Authorization": f"Bearer {api_key}"},
timeout=30,
)
result = response.json()
if not response.ok:
raise RuntimeError(f"{result['error']['code']}: {result['error']['message']}")
print(result){
"ok": true,
"team": [
{
"id": 4,
"name": "Emily",
"email": "[email protected]",
"role": "agent",
"status": "active"
}
]
}