Webhook tool

WhatsApp AI voice agents that send the link while you talk

The conversation stays on the phone call. When the caller needs something in writing, the agent sends an approved WhatsApp template to their number.

Phone agent with WhatsApp follow-up

Talks on the call and sends a WhatsApp message when asked.

Instructions

Answer questions about hours, the menu and reservations on the call. When they need the booking link, ask if they want it on WhatsApp from your business. Send it only after a clear yes, then tell them it is on its way. Do not promise to answer replies on WhatsApp.

Connected tools

  • Send WhatsApp linkWebhook

What a WhatsApp AI voice agent can do

Open one to watch a call. The grey lines are the tools the agent calls mid-sentence.

The booking link arrives on WhatsApp during the call, so nobody has to spell out a URL or write it down.

Tool definitions

Webhook tools go to POST /v1/agents/tools. Transfers are a system tool on the agent. Replace the placeholder values in capitals with your own.

Webhook

Send WhatsApp link

Sends an approved template to the caller's number.

Show the JSON definition
send_whatsapp_link
{
  "type": "webhook",
  "name": "send_whatsapp_link",
  "description": "Sends the booking link to the caller on WhatsApp. Use it only after the caller says yes to receiving it.",
  "pre_tool_speech": "auto",
  "execution_mode": "async",
  "response_timeout_secs": 20,
  "api_schema": {
    "url": "https://graph.facebook.com/v26.0/YOUR_PHONE_NUMBER_ID/messages",
    "method": "POST",
    "request_body_schema": {
      "type": "object",
      "properties": {
        "messaging_product": {
          "type": "string",
          "constant_value": "whatsapp"
        },
        "recipient_type": {
          "type": "string",
          "constant_value": "individual"
        },
        "to": {
          "type": "string",
          "dynamic_variable": "system__caller_id"
        },
        "type": {
          "type": "string",
          "constant_value": "template"
        },
        "template": {
          "type": "object",
          "properties": {
            "name": {
              "type": "string",
              "constant_value": "booking_link"
            },
            "language": {
              "type": "object",
              "properties": {
                "code": {
                  "type": "string",
                  "constant_value": "en_US"
                }
              }
            }
          }
        }
      },
      "required": []
    },
    "authentication": {
      "mode": "bearer",
      "token": {
        "type": "secret",
        "secret_value": "YOUR_SYSTEM_USER_TOKEN"
      }
    }
  }
}

Set it up

No native connector. The tool calls the WhatsApp Cloud API with a system user access token you store as a secret. It sends; it does not chat. Vendor details read in November 2026.

  1. Set up the Cloud API

    Register the business phone number the messages come from with the WhatsApp Cloud API, and put its phone number ID in the tool URL.

  2. Create and submit the template

    Write a template with the link in its text, such as booking_link, and submit it. Meta reviews templates automatically, which can take up to 24 hours, and only an APPROVED template can be sent.

  3. Generate a system user token

    In Business settings, add a system user, give it control of your app, and generate a token with business_management, whatsapp_business_management and whatsapp_business_messaging. Store it as the bearer secret.

  4. Test from your own phone

    Call the agent from a phone with WhatsApp, ask for the link, and check that the template arrives.

Before you build

Why a template

A customer service window opens only when the person messages or calls your WhatsApp number, and lasts 24 hours. A phone caller usually has done neither, so only approved templates go through.

This tool sends fixed text

A template that fills in a name, date or order number nests its values deeper than the five levels a webhook tool body allows. The tool on this page sends fixed text.

Templates with variables need a service

For a template with variables, point the tool at a service of yours with flat fields, and let it build the Cloud API request.

Check the caller ID format

The tool sends the caller ID as the recipient. Test with a real inbound call that it arrives with the country code, as in +16505551234, or reformat it in a service before sending.

Enterprise-grade security

  • HIPAA compliant badge

    HIPAA compliant

  • SOC 2 Type 2 badge

    SOC 2 Type 2

  • GDPR badge

    GDPR

WhatsApp AI voice agent FAQs

Can an AI voice agent send a WhatsApp message?

Yes. During a phone call, the agent on this page sends an approved WhatsApp template to the caller's number through the WhatsApp Cloud API, using a system user token you store as a secret. The conversation itself stays on the phone call.

Can this agent answer WhatsApp calls?

No. Meta's Cloud API supports WhatsApp calls, but this page covers regular phone calls. The agent talks to the caller by phone and only sends a template to WhatsApp. It doesn't take WhatsApp calls or hold WhatsApp chats.

Why does the agent have to use a WhatsApp template?

A customer service window opens only when the person messages or calls your WhatsApp number, and lasts 24 hours. A phone caller usually has done neither, so only approved templates go through.

Can callers reply to the agent's WhatsApp message?

They can, and the reply goes to your WhatsApp business number, not to the voice agent. Have someone, or another system, answer replies there.

How much does sending WhatsApp messages from a voice agent cost?

Cartesia bills the agent at $0.03/min, plus LLM usage and telephony. Meta prices WhatsApp templates separately, by category, so each template the agent sends shows up on your Meta bill.

Get started today

Talk to an expert.

Connect with a member of our team and learn how Cartesia can help you build world-class voice experiences.

Contact Sales

Start building.

Access our models via API and bring a voice agent into production in minutes.

Try Cartesia