Skip to main content
POST
/
v1
/
templates
/
send
Enviar template
curl --request POST \
  --url https://api.notifique.dev/v1/templates/send \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "template": "boas_vindas_2024",
  "channels": [
    "whatsapp",
    "email"
  ],
  "to": [
    "5511999999999",
    "joao@email.com"
  ],
  "variables": {
    "1": "12345",
    "nome": "João"
  },
  "instanceId": "clqxyz...",
  "from": "contato@empresa.com",
  "fromName": "Empresa S.A."
}
'
{
  "success": true,
  "data": {
    "messageIds": [
      "<string>"
    ],
    "smsIds": [
      "<string>"
    ],
    "emailIds": [
      "<string>"
    ],
    "status": "QUEUED",
    "count": 3
  }
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
template
string
required

ID (cuid) ou nome exato do template.

Example:

"boas_vindas_2024"

channels
enum<string>[]
required

Canais para disparo.

Minimum array length: 1
Available options:
whatsapp,
sms,
email
Example:
["whatsapp", "email"]
to
string[]
required

Destinatários (telefones E.164 e/ou e-mails). Máximo 100.

Required array length: 1 - 100 elements
Example:
["5511999999999", "joao@email.com"]
variables
object

Valores para substituição no template (chave-valor).

Example:
{ "1": "12345", "nome": "João" }
instanceId
string

ID da instância WhatsApp. Obrigatório se canal whatsapp e workspace sem instância padrão.

Example:

"clqxyz..."

from
string

E-mail de remetente. Obrigatório se canal email e workspace sem domínio padrão.

Example:

"contato@empresa.com"

fromName
string

Nome de exibição do remetente (e-mail).

Example:

"Empresa S.A."

Response

Mensagens enfileiradas com sucesso.

success
boolean
Example:

true

data
object