Documentation Index Fetch the complete documentation index at: https://docs.vectalk.com.br/llms.txt
Use this file to discover all available pages before exploring further.
Tipos de mensagem
Texto
Imagem
Documento
Áudio
Vídeo
Localização
Template
Botões
Lista
CTA / Link
Flow
Produto
Reação
Grupo
Marcar como lida
{
"messaging_product" : "whatsapp" ,
"to" : "5511999999999" ,
"type" : "text" ,
"text" : {
"preview_url" : false ,
"body" : "Olá! Como posso ajudar?"
}
}
{
"messaging_product" : "whatsapp" ,
"to" : "5511999999999" ,
"type" : "image" ,
"image" : {
"link" : "https://example.com/image.jpg" ,
"caption" : "Confira nosso produto!"
}
}
{
"messaging_product" : "whatsapp" ,
"to" : "5511999999999" ,
"type" : "document" ,
"document" : {
"link" : "https://example.com/relatorio.pdf" ,
"filename" : "relatorio.pdf" ,
"caption" : "Relatório mensal"
}
}
{
"messaging_product" : "whatsapp" ,
"to" : "5511999999999" ,
"type" : "audio" ,
"audio" : {
"link" : "https://example.com/audio.ogg"
}
}
{
"messaging_product" : "whatsapp" ,
"to" : "5511999999999" ,
"type" : "video" ,
"video" : {
"link" : "https://example.com/video.mp4" ,
"caption" : "Assista ao tutorial!"
}
}
{
"messaging_product" : "whatsapp" ,
"to" : "5511999999999" ,
"type" : "location" ,
"location" : {
"longitude" : -46.6333 ,
"latitude" : -23.5505 ,
"name" : "Av. Paulista" ,
"address" : "Av. Paulista, 1000 - São Paulo, SP"
}
}
{
"messaging_product" : "whatsapp" ,
"to" : "5511999999999" ,
"type" : "template" ,
"template" : {
"name" : "order_confirmation" ,
"language" : { "code" : "pt_BR" },
"components" : [
{
"type" : "body" ,
"parameters" : [
{ "type" : "text" , "text" : "João" },
{ "type" : "text" , "text" : "#12345" }
]
}
]
}
}
{
"messaging_product" : "whatsapp" ,
"to" : "5511999999999" ,
"type" : "interactive" ,
"interactive" : {
"type" : "button" ,
"header" : {
"type" : "text" ,
"text" : "Confirmação de pedido"
},
"body" : {
"text" : "Deseja confirmar seu pedido?"
},
"footer" : {
"text" : "Responda abaixo"
},
"action" : {
"buttons" : [
{ "type" : "reply" , "reply" : { "id" : "confirm_yes" , "title" : "Sim, confirmar" } },
{ "type" : "reply" , "reply" : { "id" : "confirm_no" , "title" : "Cancelar" } }
]
}
}
}
Máximo de 3 botões por mensagem.
{
"messaging_product" : "whatsapp" ,
"to" : "5511999999999" ,
"type" : "interactive" ,
"interactive" : {
"type" : "list" ,
"body" : { "text" : "Selecione um produto:" },
"footer" : { "text" : "Estoque disponível" },
"action" : {
"button" : "Ver produtos" ,
"sections" : [
{
"title" : "Eletrônicos" ,
"rows" : [
{ "id" : "prod_001" , "title" : "Smartphone X" , "description" : "R$ 1.999,00" },
{ "id" : "prod_002" , "title" : "Fone Bluetooth" , "description" : "R$ 299,00" }
]
}
]
}
}
}
{
"messaging_product" : "whatsapp" ,
"to" : "5511999999999" ,
"type" : "interactive" ,
"interactive" : {
"type" : "cta_url" ,
"body" : { "text" : "Acesse nosso portal para mais informações" },
"action" : {
"name" : "cta_url" ,
"parameters" : {
"display_text" : "Acessar Portal" ,
"url" : "https://vectax.com"
}
}
}
}
{
"recipient_type" : "individual" ,
"messaging_product" : "whatsapp" ,
"to" : "5511999999999" ,
"type" : "interactive" ,
"interactive" : {
"type" : "flow" ,
"header" : {
"type" : "text" ,
"text" : "Pesquisa de satisfação"
},
"body" : { "text" : "Preencha nossa pesquisa de satisfação:" },
"footer" : { "text" : "Leva menos de 1 minuto" },
"action" : {
"name" : "flow" ,
"parameters" : {
"flow_message_version" : "3" ,
"flow_token" : "unused" ,
"flow_id" : "FLOW_ID" ,
"flow_cta" : "Responder pesquisa" ,
"flow_action" : "navigate" ,
"flow_action_payload" : {
"screen" : "INTRO" ,
"data" : { "user_name" : "João" }
}
}
}
}
}
flow_message_version deve ser "3". flow_token é opcional (default "unused").
flow_action pode ser "navigate" (default) ou "data_exchange".
Quando flow_action é "navigate", o campo flow_action_payload.screen é obrigatório.
{
"messaging_product" : "whatsapp" ,
"to" : "5511999999999" ,
"type" : "interactive" ,
"interactive" : {
"type" : "product" ,
"body" : { "text" : "Confira este produto:" },
"action" : {
"catalog_id" : "CATALOG_ID" ,
"product_retailer_id" : "SKU_001"
}
}
}
{
"messaging_product" : "whatsapp" ,
"to" : "5511999999999" ,
"type" : "reaction" ,
"reaction" : {
"message_id" : "wamid.HBgLNTUxMTk5OTk5OTk5..." ,
"emoji" : "👍"
}
}
{
"messaging_product" : "whatsapp" ,
"recipient_type" : "group" ,
"to" : "GROUP_ID" ,
"type" : "text" ,
"text" : {
"body" : "Olá grupo!"
}
}
Para enviar mensagens a grupos, o campo recipient_type deve ser "group" e to deve conter o ID do grupo.
Todos os tipos de mensagem (texto, imagem, template, etc.) funcionam — basta adicionar "recipient_type": "group".
{
"messaging_product" : "whatsapp" ,
"status" : "read" ,
"message_id" : "wamid.HBgLNTUxMTk5OTk5OTk5..."
}
Parâmetros
messaging_product
string
default: "whatsapp"
required
Sempre "whatsapp".
recipient_type
string
default: "individual"
"individual" para mensagens diretas (default) ou "group" para mensagens em grupo. Obrigatório quando to é um ID de grupo.
Número do destinatário no formato E.164 sem o +, ou ID do grupo quando recipient_type é "group".
type
string
default: "text"
required
Tipo da mensagem: text, image, document, audio, video, sticker, location, contacts, template, interactive, reaction.
Obrigatório quando type é text. Conteúdo da mensagem (máx. 4096 caracteres).
Obrigatório quando type é image. Use link (URL pública) ou id (media_id do upload).
Obrigatório quando type é document. Use link ou id + filename.
Obrigatório quando type é audio. Use link ou id.
Obrigatório quando type é video. Use link ou id.
Obrigatório quando type é template. Veja exemplos nas abas acima.
Obrigatório quando type é interactive. Suporta button, list, cta_url, flow, product, product_list.
Obrigatório quando type é reaction. Campos: message_id, emoji.
Obrigatório apenas com token de organização . Com token de instância é resolvido automaticamente.
Resposta
{
"messaging_product" : "whatsapp" ,
"contacts" : [
{ "input" : "5511999999999" , "wa_id" : "5511999999999" }
],
"messages" : [
{ "id" : "wamid.HBgLNTUxMTk5OTk5OTk5..." }
]
}