POST /v1/conversations/start
const url = 'https://seu-endereco-da-api/v1/conversations/start';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"contactId":"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0","channelId":"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0","departmentId":"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0","templateId":"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0","variables":["example"],"headerMediaKey":"example","headerMediaMime":"example","type":"text","text":"example","mediaKey":"example","mediaMime":"example","asVoiceNote":true,"durationMs":1,"waveform":"example","fileName":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://seu-endereco-da-api/v1/conversations/start \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "contactId": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "channelId": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "departmentId": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "templateId": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "variables": [ "example" ], "headerMediaKey": "example", "headerMediaMime": "example", "type": "text", "text": "example", "mediaKey": "example", "mediaMime": "example", "asVoiceNote": true, "durationMs": 1, "waveform": "example", "fileName": "example" }'Permissão que a Chave de acesso precisa: Enviar mensagem e atender (conversations:write).
Authorizations
Seção intitulada “Authorizations”Request Bodyrequired
Seção intitulada “Request Bodyrequired”object
Responses
Seção intitulada “Responses”object
object
O nome que o cliente deu ao canal na plataforma
O numero ou @ da conta no provedor
O nome da conta no provedor: o verificado da Meta, ou o do aparelho no canal lite
O canal foi apagado; a conversa continua descrevendo por onde ela aconteceu
object
‘none’ when the channel has no session window
Whether this channel needs an approved template to reopen a closed window
The ad referral this conversation originated from, if any
Set when an unmerge left this thread with messages from two people
Set when an agent took this thread out of the inbox
Sobe a cada escrita na conversa; evento com revisao menor ou igual a esta ja esta contido neste estado
object
Null on a group, which is not a contact
‘person’ for a 1:1 contact, ‘group’ for a WhatsApp group
Presigned url for the contact’s whatsapp profile photo
True while the contact is blocked: inbound is stored silently and replies are refused
Se quem chama pode agir na conversa agora (responder, transferir, encerrar): conversations:write, a conversa visivel, livre, propria ou conversations:reassign, e ja aceita. false com mustAcceptFirst=false: so nota
A conversa esta na fila esperando aceite: aceitar antes de agir
Example
{ "window": { "kind": "none" }}