Apariencia
Referencia: Conversaciones
Generada desde el contrato OpenAPI
Esta referencia se genera directamente del contrato de la API, por lo que sus descripciones están en inglés. Puedes descargarlo en openapi.json. Las guías explican cómo usar estos endpoints.
Conversations
Chats of your instances (a phone or a group) and what can be done to them.
Operaciones
GET/conversationsGET/conversations/{conversation}POST/conversations/{conversation}/readPOST/conversations/{conversation}/unreadPOST/conversations/{conversation}/archiveDELETE/conversations/{conversation}/archivePOST/conversations/{conversation}/pinDELETE/conversations/{conversation}/pinPOST/conversations/{conversation}/muteDELETE/conversations/{conversation}/mute
List conversations
GET
/conversations
One conversation per chat (a phone or a group) of your instances, most recent activity first, with cursor pagination (follow meta.next_cursor). Each one carries its last message, its unread counter and whether it is archived, pinned or muted. A conversation exists as soon as its chat has a message in ZAPPIO.
Autorizaciones
bearerAuth
An API key created in the dashboard (Authorization: Bearer
Tipo
HTTP (bearer)
Parámetros
Query Parameters
instance
Only conversations of this instance.
Tipo
string
Longitud máx.
40unread
true = with unread messages or marked as unread; false = read.
Tipo
string
Valores válidos
"true""false""1""0"archived
Tipo
string
Valores válidos
"true""false""1""0"pinned
Tipo
string
Valores válidos
"true""false""1""0"phone
The direct chat with this number. International format; for Mexican mobiles 52 + 10 digits and 521 + 10 digits are the same chat. Not with group.
Tipo
string
Longitud máx.
32group
The conversation of this group (grp_...). Not with phone.
Tipo
string
Longitud máx.
40limit
Page size (default 25).
Tipo
integer
Mínimo
1Máximo
100cursor
Opaque cursor from a previous page (meta.next_cursor).
Tipo
string
Longitud máx.
512Respuestas
A page of conversations.
application/json
JSON "data": [ { "id": "cnv_01JD8Z7Q0000000000000000CV", "instance_id": "string", "type": "string", "phone": "string", "group_id": "string", "name": "string", "unread_count": 0, "marked_unread": true, "archived": true, "pinned": true, "muted": true, "muted_until": "string", "last_message_at": "string", "last_message": { "id": "string", "instance_id": "string", "direction": "string", "from_me": true, "source": "string", "api_key_id": "string", "from_name": "string", "type": "string", "status": "string", "to": "string", "from": "string", "group_id": "string", "text": "string", "caption": "string", "media": { "mime_type": "string", "size": 0, "filename": "string", "available": true }, "location": { "latitude": 0, "longitude": 0, "name": "string", "address": "string", "url": "string", "live": true }, "contacts": [ ], "poll": { "question": "string", "multiple": true, "options": [ { "name": "string", "votes": 0 } ], "voters": 0, "votes": [ { "from": "string", "from_me": true, "options": [ "string" ], "voted_at": "string" } ], "votes_available": true }, "reply_to": "string", "forwarded": true, "reactions": [ { "emoji": "string", "from": "string", "from_me": true, "reacted_at": "string" } ], "error": { "code": "string", "message": "string" }, "created_at": "string", "queued_at": "string", "sent_at": "string", "delivered_at": "string", "read_at": "string", "failed_at": "string", "received_at": "string", "edited_at": "string", "deleted_at": "string" }, "created_at": "string", "updated_at": "string" } ], "links": { "additionalProperties": "string" }, "meta": { "per_page": 0, "next_cursor": "string", "prev_cursor": "string", "additionalProperties": "string" }
{
}
GET
/conversations
Ejemplos
Get a conversation
GET
/conversations/{conversation}
Autorizaciones
bearerAuth
An API key created in the dashboard (Authorization: Bearer
Tipo
HTTP (bearer)
Respuestas
The conversation.
application/json
JSON "data": { "id": "cnv_01JD8Z7Q0000000000000000CV", "instance_id": "string", "type": "string", "phone": "string", "group_id": "string", "name": "string", "unread_count": 0, "marked_unread": true, "archived": true, "pinned": true, "muted": true, "muted_until": "string", "last_message_at": "string", "last_message": { "id": "string", "instance_id": "string", "direction": "string", "from_me": true, "source": "string", "api_key_id": "string", "from_name": "string", "type": "string", "status": "string", "to": "string", "from": "string", "group_id": "string", "text": "string", "caption": "string", "media": { "mime_type": "string", "size": 0, "filename": "string", "available": true }, "location": { "latitude": 0, "longitude": 0, "name": "string", "address": "string", "url": "string", "live": true }, "contacts": [ ], "poll": { "question": "string", "multiple": true, "options": [ { "name": "string", "votes": 0 } ], "voters": 0, "votes": [ { "from": "string", "from_me": true, "options": [ "string" ], "voted_at": "string" } ], "votes_available": true }, "reply_to": "string", "forwarded": true, "reactions": [ { "emoji": "string", "from": "string", "from_me": true, "reacted_at": "string" } ], "error": { "code": "string", "message": "string" }, "created_at": "string", "queued_at": "string", "sent_at": "string", "delivered_at": "string", "read_at": "string", "failed_at": "string", "received_at": "string", "edited_at": "string", "deleted_at": "string" }, "created_at": "string", "updated_at": "string" }
{
}
GET
/conversations/{conversation}
Ejemplos
Mark a conversation as read
POST
/conversations/{conversation}/read
Gives blue ticks to the unread messages (the newest 100 at most; WhatsApp honours your read-receipt privacy setting) and marks the chat as read on every device of the number. unread_count becomes 0. Not billed.
Autorizaciones
bearerAuth
An API key created in the dashboard (Authorization: Bearer
Tipo
HTTP (bearer)
Respuestas
The conversation after the change.
application/json
JSON "data": { "id": "cnv_01JD8Z7Q0000000000000000CV", "instance_id": "string", "type": "string", "phone": "string", "group_id": "string", "name": "string", "unread_count": 0, "marked_unread": true, "archived": true, "pinned": true, "muted": true, "muted_until": "string", "last_message_at": "string", "last_message": { "id": "string", "instance_id": "string", "direction": "string", "from_me": true, "source": "string", "api_key_id": "string", "from_name": "string", "type": "string", "status": "string", "to": "string", "from": "string", "group_id": "string", "text": "string", "caption": "string", "media": { "mime_type": "string", "size": 0, "filename": "string", "available": true }, "location": { "latitude": 0, "longitude": 0, "name": "string", "address": "string", "url": "string", "live": true }, "contacts": [ ], "poll": { "question": "string", "multiple": true, "options": [ { "name": "string", "votes": 0 } ], "voters": 0, "votes": [ { "from": "string", "from_me": true, "options": [ "string" ], "voted_at": "string" } ], "votes_available": true }, "reply_to": "string", "forwarded": true, "reactions": [ { "emoji": "string", "from": "string", "from_me": true, "reacted_at": "string" } ], "error": { "code": "string", "message": "string" }, "created_at": "string", "queued_at": "string", "sent_at": "string", "delivered_at": "string", "read_at": "string", "failed_at": "string", "received_at": "string", "edited_at": "string", "deleted_at": "string" }, "created_at": "string", "updated_at": "string" }
{
}
POST
/conversations/{conversation}/read
Ejemplos
Mark a conversation as unread
POST
/conversations/{conversation}/unread
Like WhatsApp's "Mark as unread", the chat shows as unread on every device of the number (marked_unread). Not billed.
Autorizaciones
bearerAuth
An API key created in the dashboard (Authorization: Bearer
Tipo
HTTP (bearer)
Respuestas
The conversation after the change.
application/json
JSON "data": { "id": "cnv_01JD8Z7Q0000000000000000CV", "instance_id": "string", "type": "string", "phone": "string", "group_id": "string", "name": "string", "unread_count": 0, "marked_unread": true, "archived": true, "pinned": true, "muted": true, "muted_until": "string", "last_message_at": "string", "last_message": { "id": "string", "instance_id": "string", "direction": "string", "from_me": true, "source": "string", "api_key_id": "string", "from_name": "string", "type": "string", "status": "string", "to": "string", "from": "string", "group_id": "string", "text": "string", "caption": "string", "media": { "mime_type": "string", "size": 0, "filename": "string", "available": true }, "location": { "latitude": 0, "longitude": 0, "name": "string", "address": "string", "url": "string", "live": true }, "contacts": [ ], "poll": { "question": "string", "multiple": true, "options": [ { "name": "string", "votes": 0 } ], "voters": 0, "votes": [ { "from": "string", "from_me": true, "options": [ "string" ], "voted_at": "string" } ], "votes_available": true }, "reply_to": "string", "forwarded": true, "reactions": [ { "emoji": "string", "from": "string", "from_me": true, "reacted_at": "string" } ], "error": { "code": "string", "message": "string" }, "created_at": "string", "queued_at": "string", "sent_at": "string", "delivered_at": "string", "read_at": "string", "failed_at": "string", "received_at": "string", "edited_at": "string", "deleted_at": "string" }, "created_at": "string", "updated_at": "string" }
{
}
POST
/conversations/{conversation}/unread
Ejemplos
Archive a conversation
POST
/conversations/{conversation}/archive
Archives the chat on every device of the number. Not billed.
Autorizaciones
bearerAuth
An API key created in the dashboard (Authorization: Bearer
Tipo
HTTP (bearer)
Respuestas
The conversation after the change.
application/json
JSON "data": { "id": "cnv_01JD8Z7Q0000000000000000CV", "instance_id": "string", "type": "string", "phone": "string", "group_id": "string", "name": "string", "unread_count": 0, "marked_unread": true, "archived": true, "pinned": true, "muted": true, "muted_until": "string", "last_message_at": "string", "last_message": { "id": "string", "instance_id": "string", "direction": "string", "from_me": true, "source": "string", "api_key_id": "string", "from_name": "string", "type": "string", "status": "string", "to": "string", "from": "string", "group_id": "string", "text": "string", "caption": "string", "media": { "mime_type": "string", "size": 0, "filename": "string", "available": true }, "location": { "latitude": 0, "longitude": 0, "name": "string", "address": "string", "url": "string", "live": true }, "contacts": [ ], "poll": { "question": "string", "multiple": true, "options": [ { "name": "string", "votes": 0 } ], "voters": 0, "votes": [ { "from": "string", "from_me": true, "options": [ "string" ], "voted_at": "string" } ], "votes_available": true }, "reply_to": "string", "forwarded": true, "reactions": [ { "emoji": "string", "from": "string", "from_me": true, "reacted_at": "string" } ], "error": { "code": "string", "message": "string" }, "created_at": "string", "queued_at": "string", "sent_at": "string", "delivered_at": "string", "read_at": "string", "failed_at": "string", "received_at": "string", "edited_at": "string", "deleted_at": "string" }, "created_at": "string", "updated_at": "string" }
{
}
POST
/conversations/{conversation}/archive
Ejemplos
Unarchive a conversation
DELETE
/conversations/{conversation}/archive
Takes the chat out of the archive. Not billed.
Autorizaciones
bearerAuth
An API key created in the dashboard (Authorization: Bearer
Tipo
HTTP (bearer)
Respuestas
The conversation after the change.
application/json
JSON "data": { "id": "cnv_01JD8Z7Q0000000000000000CV", "instance_id": "string", "type": "string", "phone": "string", "group_id": "string", "name": "string", "unread_count": 0, "marked_unread": true, "archived": true, "pinned": true, "muted": true, "muted_until": "string", "last_message_at": "string", "last_message": { "id": "string", "instance_id": "string", "direction": "string", "from_me": true, "source": "string", "api_key_id": "string", "from_name": "string", "type": "string", "status": "string", "to": "string", "from": "string", "group_id": "string", "text": "string", "caption": "string", "media": { "mime_type": "string", "size": 0, "filename": "string", "available": true }, "location": { "latitude": 0, "longitude": 0, "name": "string", "address": "string", "url": "string", "live": true }, "contacts": [ ], "poll": { "question": "string", "multiple": true, "options": [ { "name": "string", "votes": 0 } ], "voters": 0, "votes": [ { "from": "string", "from_me": true, "options": [ "string" ], "voted_at": "string" } ], "votes_available": true }, "reply_to": "string", "forwarded": true, "reactions": [ { "emoji": "string", "from": "string", "from_me": true, "reacted_at": "string" } ], "error": { "code": "string", "message": "string" }, "created_at": "string", "queued_at": "string", "sent_at": "string", "delivered_at": "string", "read_at": "string", "failed_at": "string", "received_at": "string", "edited_at": "string", "deleted_at": "string" }, "created_at": "string", "updated_at": "string" }
{
}
DELETE
/conversations/{conversation}/archive
Ejemplos
Pin a conversation
POST
/conversations/{conversation}/pin
Pins the chat to the top on every device of the number (WhatsApp allows a few pinned chats). Not billed.
Autorizaciones
bearerAuth
An API key created in the dashboard (Authorization: Bearer
Tipo
HTTP (bearer)
Respuestas
The conversation after the change.
application/json
JSON "data": { "id": "cnv_01JD8Z7Q0000000000000000CV", "instance_id": "string", "type": "string", "phone": "string", "group_id": "string", "name": "string", "unread_count": 0, "marked_unread": true, "archived": true, "pinned": true, "muted": true, "muted_until": "string", "last_message_at": "string", "last_message": { "id": "string", "instance_id": "string", "direction": "string", "from_me": true, "source": "string", "api_key_id": "string", "from_name": "string", "type": "string", "status": "string", "to": "string", "from": "string", "group_id": "string", "text": "string", "caption": "string", "media": { "mime_type": "string", "size": 0, "filename": "string", "available": true }, "location": { "latitude": 0, "longitude": 0, "name": "string", "address": "string", "url": "string", "live": true }, "contacts": [ ], "poll": { "question": "string", "multiple": true, "options": [ { "name": "string", "votes": 0 } ], "voters": 0, "votes": [ { "from": "string", "from_me": true, "options": [ "string" ], "voted_at": "string" } ], "votes_available": true }, "reply_to": "string", "forwarded": true, "reactions": [ { "emoji": "string", "from": "string", "from_me": true, "reacted_at": "string" } ], "error": { "code": "string", "message": "string" }, "created_at": "string", "queued_at": "string", "sent_at": "string", "delivered_at": "string", "read_at": "string", "failed_at": "string", "received_at": "string", "edited_at": "string", "deleted_at": "string" }, "created_at": "string", "updated_at": "string" }
{
}
POST
/conversations/{conversation}/pin
Ejemplos
Unpin a conversation
DELETE
/conversations/{conversation}/pin
Unpins the chat. Not billed.
Autorizaciones
bearerAuth
An API key created in the dashboard (Authorization: Bearer
Tipo
HTTP (bearer)
Respuestas
The conversation after the change.
application/json
JSON "data": { "id": "cnv_01JD8Z7Q0000000000000000CV", "instance_id": "string", "type": "string", "phone": "string", "group_id": "string", "name": "string", "unread_count": 0, "marked_unread": true, "archived": true, "pinned": true, "muted": true, "muted_until": "string", "last_message_at": "string", "last_message": { "id": "string", "instance_id": "string", "direction": "string", "from_me": true, "source": "string", "api_key_id": "string", "from_name": "string", "type": "string", "status": "string", "to": "string", "from": "string", "group_id": "string", "text": "string", "caption": "string", "media": { "mime_type": "string", "size": 0, "filename": "string", "available": true }, "location": { "latitude": 0, "longitude": 0, "name": "string", "address": "string", "url": "string", "live": true }, "contacts": [ ], "poll": { "question": "string", "multiple": true, "options": [ { "name": "string", "votes": 0 } ], "voters": 0, "votes": [ { "from": "string", "from_me": true, "options": [ "string" ], "voted_at": "string" } ], "votes_available": true }, "reply_to": "string", "forwarded": true, "reactions": [ { "emoji": "string", "from": "string", "from_me": true, "reacted_at": "string" } ], "error": { "code": "string", "message": "string" }, "created_at": "string", "queued_at": "string", "sent_at": "string", "delivered_at": "string", "read_at": "string", "failed_at": "string", "received_at": "string", "edited_at": "string", "deleted_at": "string" }, "created_at": "string", "updated_at": "string" }
{
}
DELETE
/conversations/{conversation}/pin
Ejemplos
Mute a conversation
POST
/conversations/{conversation}/mute
Silences the chat's notifications on every device of the number until until, or forever without it. Not billed.
Autorizaciones
bearerAuth
An API key created in the dashboard (Authorization: Bearer
Tipo
HTTP (bearer)
Cuerpo de la petición
application/json
JSON "until": "string"
{
}
Respuestas
The conversation after the change.
application/json
JSON "data": { "id": "cnv_01JD8Z7Q0000000000000000CV", "instance_id": "string", "type": "string", "phone": "string", "group_id": "string", "name": "string", "unread_count": 0, "marked_unread": true, "archived": true, "pinned": true, "muted": true, "muted_until": "string", "last_message_at": "string", "last_message": { "id": "string", "instance_id": "string", "direction": "string", "from_me": true, "source": "string", "api_key_id": "string", "from_name": "string", "type": "string", "status": "string", "to": "string", "from": "string", "group_id": "string", "text": "string", "caption": "string", "media": { "mime_type": "string", "size": 0, "filename": "string", "available": true }, "location": { "latitude": 0, "longitude": 0, "name": "string", "address": "string", "url": "string", "live": true }, "contacts": [ ], "poll": { "question": "string", "multiple": true, "options": [ { "name": "string", "votes": 0 } ], "voters": 0, "votes": [ { "from": "string", "from_me": true, "options": [ "string" ], "voted_at": "string" } ], "votes_available": true }, "reply_to": "string", "forwarded": true, "reactions": [ { "emoji": "string", "from": "string", "from_me": true, "reacted_at": "string" } ], "error": { "code": "string", "message": "string" }, "created_at": "string", "queued_at": "string", "sent_at": "string", "delivered_at": "string", "read_at": "string", "failed_at": "string", "received_at": "string", "edited_at": "string", "deleted_at": "string" }, "created_at": "string", "updated_at": "string" }
{
}
POST
/conversations/{conversation}/mute
Ejemplos
Unmute a conversation
DELETE
/conversations/{conversation}/mute
Turns the chat's notifications back on. Not billed.
Autorizaciones
bearerAuth
An API key created in the dashboard (Authorization: Bearer
Tipo
HTTP (bearer)
Respuestas
The conversation after the change.
application/json
JSON "data": { "id": "cnv_01JD8Z7Q0000000000000000CV", "instance_id": "string", "type": "string", "phone": "string", "group_id": "string", "name": "string", "unread_count": 0, "marked_unread": true, "archived": true, "pinned": true, "muted": true, "muted_until": "string", "last_message_at": "string", "last_message": { "id": "string", "instance_id": "string", "direction": "string", "from_me": true, "source": "string", "api_key_id": "string", "from_name": "string", "type": "string", "status": "string", "to": "string", "from": "string", "group_id": "string", "text": "string", "caption": "string", "media": { "mime_type": "string", "size": 0, "filename": "string", "available": true }, "location": { "latitude": 0, "longitude": 0, "name": "string", "address": "string", "url": "string", "live": true }, "contacts": [ ], "poll": { "question": "string", "multiple": true, "options": [ { "name": "string", "votes": 0 } ], "voters": 0, "votes": [ { "from": "string", "from_me": true, "options": [ "string" ], "voted_at": "string" } ], "votes_available": true }, "reply_to": "string", "forwarded": true, "reactions": [ { "emoji": "string", "from": "string", "from_me": true, "reacted_at": "string" } ], "error": { "code": "string", "message": "string" }, "created_at": "string", "queued_at": "string", "sent_at": "string", "delivered_at": "string", "read_at": "string", "failed_at": "string", "received_at": "string", "edited_at": "string", "deleted_at": "string" }, "created_at": "string", "updated_at": "string" }
{
}
DELETE
/conversations/{conversation}/mute