Documentation
Sign inGet started

bird whatsapp send

Usage

कोड उदाहरण
bird whatsapp send [flags]

Description

Send a WhatsApp template message to one recipient.
Sending is outbound and irreversible: it reports "accepted", not "delivered" — read the message back with "bird whatsapp get" to confirm delivery. Bird selects the sender number from the template's category. Templates are currently the only supported content type, so every send needs one (browse them with "bird whatsapp templates list").
Build the request from flags, a JSON WhatsAppMessageSendRequest body via --body-file ("-" reads stdin), or both — a flag overrides the matching body field. Run --example to print a ready-to-edit body, or --dry-run to print the resolved request without sending it.

Examples

कोड उदाहरण
# print the body shape (no credentials needed)
bird whatsapp send --example

# the body it prints:
कोड उदाहरण
{
  "template": {
    "components": [
      {
        "parameters": [
          {
            "text": "1234",
            "type": "text"
          }
        ],
        "type": "body"
      },
      {
        "parameters": [
          {
            "text": "1234",
            "type": "text"
          }
        ],
        "type": "button"
      }
    ],
    "language": "en",
    "name": "bird_otp"
  },
  "to": "+31612345678"
}
कोड उदाहरण
# send a template with body placeholders
bird whatsapp send --to +15551234567 --template bird_order_confirmation --language en --components '[{"type":"body","parameters":[{"type":"text","text":"A1B2C3D4"}]}]'

# preview the resolved request without sending
bird whatsapp send --body-file body.json --dry-run

Options

Routing

NameDescription
--toRecipient phone number in E.164 format (e.g. +15551234567)

Template

NameDescription
--templateThe template to send, by its name (e.g. bird_otp)
--languageLanguage code of the template variant to send (e.g. en or pt_BR); omit when the template has a single language
--componentsThe values that fill the template's placeholders, as a JSON array (e.g. body/header/button component objects)

Request

NameDescription
--body-fileRead the JSON request body from this file; "-" reads stdin
--examplePrint a complete example request body, then exit
--dry-runPrint the resolved request without sending it, then exit
--idempotency-keyDeduplication key; a retry with the same key won't act twice

Options

NameDescription
--response-schemaPrint the fields this command returns, then exit
NameDescription
bird whatsapp getGet a WhatsApp message
bird whatsapp listList WhatsApp messages
bird whatsapp list-eventsList events for a WhatsApp message