Skip to content
ChatVendor ChatVendor

Messenger API

Everything the panel can do with a connected Telegram, WhatsApp or Instagram account, over REST — one key, one response shape, chapter by chapter.

WhatsApp

Chats, messages, files and templates of a WhatsApp Business number (wa_{id}).

WhatsApp numbers appear in GET /channels with ids like wa_12; {peer} is the customer phone in international format. Free-form text is allowed only within 24 hours after the customer’s last message — outside the window send an approved template.

Base URL: https://chatvendor.net/api/v1 · every response is {"success": true, "data": …}

GET /channels/wa_{id}/dialogs WhatsApp: chats of a number

Scope: channels:read

Parameters

idpath · integerrequired

Channel id (from GET /channels)

qquery · string
unreadquery · integer

Response 200 · Dialog[]

peer_id integertype stringtitle stringusername stringunread_count integerlast_message_at string (date-time)last_message_text string

curl https://chatvendor.net/api/v1/channels/wa_1/dialogs \
  -H "Authorization: Bearer cv_live_xxxxxxxxxxxx"
GET /channels/wa_{id}/dialogs/{peer}/messages WhatsApp: messages of a chat (peer = phone in international format)

Scope: channels:read

Parameters

idpath · integerrequired

Channel id (from GET /channels)

peerpath · stringrequired

Telegram peer: numeric id (channels/groups negative, e.g. -1001234567890), @username or phone

Response 200 · ChatMessage[]

id integerchat_id integersender_id integersender_name stringout booleandate string (date-time)text stringmedia objectreply_to integertopic_id integerbuttons object[][]

curl https://chatvendor.net/api/v1/channels/wa_1/dialogs/@username/messages \
  -H "Authorization: Bearer cv_live_xxxxxxxxxxxx"
POST /channels/wa_{id}/dialogs/{peer}/messages WhatsApp: send text, an approved template, or reply buttons

Scope: channels:write

Parameters

idpath · integerrequired

Channel id (from GET /channels)

peerpath · stringrequired

Telegram peer: numeric id (channels/groups negative, e.g. -1001234567890), @username or phone

Body (application/json)

textstring
reply_tointeger
templatestring
languagestring
componentsobject[]
buttonsobject[]
buttons[].idstring
buttons[].titlestring

Response 200 · ChatMessage

id integerchat_id integersender_id integersender_name stringout booleandate string (date-time)text stringmedia objectreply_to integertopic_id integerbuttons object[][]

curl -X POST https://chatvendor.net/api/v1/channels/wa_1/dialogs/@username/messages \
  -H "Authorization: Bearer cv_live_xxxxxxxxxxxx"
  -H "Content-Type: application/json" \
  -d '[]'
POST /channels/wa_{id}/dialogs/{peer}/file WhatsApp: send a file (multipart: file, caption, as=auto|document|voice)

Scope: channels:write

Parameters

idpath · integerrequired

Channel id (from GET /channels)

peerpath · stringrequired

Telegram peer: numeric id (channels/groups negative, e.g. -1001234567890), @username or phone

multipart/form-data — fields are listed in the summary above.

Response 200 · ChatMessage

id integerchat_id integersender_id integersender_name stringout booleandate string (date-time)text stringmedia objectreply_to integertopic_id integerbuttons object[][]

curl -X POST https://chatvendor.net/api/v1/channels/wa_1/dialogs/@username/file \
  -H "Authorization: Bearer cv_live_xxxxxxxxxxxx"
  -F "file=@photo.jpg" -F "caption=…"
POST /channels/wa_{id}/dialogs/{peer}/read WhatsApp: mark the chat as read

Scope: channels:write

Parameters

idpath · integerrequired

Channel id (from GET /channels)

peerpath · stringrequired

Telegram peer: numeric id (channels/groups negative, e.g. -1001234567890), @username or phone

Response 200

OK

curl -X POST https://chatvendor.net/api/v1/channels/wa_1/dialogs/@username/read \
  -H "Authorization: Bearer cv_live_xxxxxxxxxxxx"
GET /channels/wa_{id}/dialogs/{peer}/messages/{message}/media WhatsApp: download media

Scope: channels:read

Parameters

idpath · integerrequired

Channel id (from GET /channels)

peerpath · stringrequired

Telegram peer: numeric id (channels/groups negative, e.g. -1001234567890), @username or phone

messagepath · integerrequired

Message id

Response 200

The file

curl https://chatvendor.net/api/v1/channels/wa_1/dialogs/@username/messages/123/media \
  -H "Authorization: Bearer cv_live_xxxxxxxxxxxx"
GET /channels/wa_{id}/templates WhatsApp: message templates of the number

Scope: channels:read

Parameters

idpath · integerrequired

Channel id (from GET /channels)

Response 200 · Template[]

name stringstatus stringcategory stringlanguage stringbody string

curl https://chatvendor.net/api/v1/channels/wa_1/templates \
  -H "Authorization: Bearer cv_live_xxxxxxxxxxxx"