Send a WhatsApp message from an Attio workflow

A deal moves, an invoice falls due, a booking is confirmed, and the customer hears from you on WhatsApp with nobody pressing send. This runs on the WhatsApp Business API, so it needs your number connected through Meta and wording Meta approved in advance.

What you need first

Sending is the one part of WhatSync with prerequisites. Check this list before you write the workflow.
Templates need your number connected through Meta. If you linked your own WhatsApp by QR code instead, the same API sends plain text from it: use "channel": "qr" and text instead of a template. API quickstart
  1. A Meta Business portfolio you are an admin on.
  2. Your number connected through Meta, not linked as personal WhatsApp.
  3. A WhatSync API key. API keys are part of the Max plan and up.
  4. At least one message template Meta has approved.
  5. Somewhere to send an HTTP request from: Attio workflows, Zapier, Make, n8n or your own backend.

Connect your number

On the Business page of your WhatSync dashboard.
  1. Open the Business page and sign in with Meta.
  2. Pick your number from your Meta Business portfolio. You need admin access to it.
  3. Wait until it says Connected.

You keep your own number; Meta does not give you one. Every message that starts a conversation must be a template Meta approved, and Meta charges per message at your country's rate. Meta also reviews your business before sending turns on, so allow more than an afternoon.

Connecting your number through Meta, step by step.

Create an API key

One key proves the request is yours. It already knows which account it belongs to, so there is no connection ID to copy.
  1. Open Developers in your WhatSync dashboard.
  2. Create a key and keep Send messages ticked.
  3. Copy it once and store it in your workflow tool's secrets, never in the workflow text.
  4. Send it as Authorization: Bearer YOUR_API_KEY on every request.
  5. If a key ever leaks, revoke it in the same place and create a new one.
Open Developers

Get a template approved

A template is the message with blanks in it. Meta reviews it once, then your workflow can fill the blanks and send it as often as you like.
  1. Open WhatsApp Manager and the WhatsApp account you connected to WhatSync.
  2. Open Message templates and create one.
  3. Choose a category: marketing, utility or authentication.
  4. Name it in lowercase, like appointment_reminder, and pick the language.
  5. Write the message with a variable wherever a value changes.
  6. Add a sample value for every variable. Meta reads them during review.
  7. Submit it and wait for approval.

Name

appointment_reminder

Message

Hi {{1}}, this is a reminder that your appointment with {{2}} is on {{3}}. Reply here if you need to change it.

{{1}}

Customer name

{{2}}

Team member

{{3}}

Date and time

  • Templates are only needed to start a conversation. Once someone replies, you can answer without a template for 24 hours.
  • Write it the way the customer should read it, and say why they are hearing from you.
  • Use variables only for what changes: a name, a time, an invoice number, a link.
  • One template per purpose.

Check yours first with the free template builder.

Build the workflow

The workflow decides when someone should hear from you, then calls WhatSync. Six things to get right.
  1. 01

    Pick the trigger

    Start from something your team already tracks: a new lead, a booking confirmed, an invoice due, a renewal coming up.

  2. 02

    Choose the template

    The template name and language in your request must match the approved template in Meta exactly.

  3. 03

    Map the phone number

    International format with the country code. No spaces, brackets or local-only numbers.

  4. 04

    Fill the variables

    They go in order: the first value in templateParameters fills {{1}}, the second fills {{2}}, and so on.

  5. 05

    Send the request

    Your workflow posts to WhatSync with your API key. We check the template and the number, then pass it to Meta.

  6. 06

    Catch the updates

    Meta reports what happened to the message. WhatSync saves it and can call your workflow back with a webhook.

The request you send

One POST to WhatSync with the template name, the number and the values. We check the template against Meta and send it.
POST https://whatsync.app/api/v1/tools/send_message

JSON body, with your key in an Authorization: Bearer header. Confirm the person agreed to hear from you with recipientOptInConfirmed, and give each send a fresh idempotencyKey (a random UUID) so a retry never sends it twice.

curl -X POST "https://whatsync.app/api/v1/tools/send_message" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "idempotencyKey": "6f1c2a9e-3b7d-4e1a-9c55-0d2f8b7a4e10",
    "channel": "business",
    "phoneNumber": "14155550123",
    "templateName": "appointment_reminder",
    "templateLanguage": "en",
    "templateParameters": ["Ava", "Maya from Sales", "Tuesday at 2:00 PM"],
    "recipientOptInConfirmed": true
  }'
  • The template name and language must match the approved template in Meta exactly. The language defaults to en_US.
  • Templates with an image, video or document header, or a button that needs a value, cannot be sent this way yet.
  • The same message to the same person within an hour is refused, so a looping workflow cannot spam someone.
  • A success means Meta accepted the message. Delivery is confirmed later.

Every field and error: API quickstart.

After it goes out

Meta reports each stage, and WhatSync saves what it says.
  1. Stage 1

    Accepted

    Meta took the request

  2. Stage 2

    Sent

    It left Meta

  3. Stage 3

    Delivered

    It reached the phone

  4. Stage 4

    Read

    They opened it

When a message fails, Meta sends a reason with it. We store both, so you can see whether the number was unreachable or the template broke a rule. To update Attio when the status changes, add a webhook for message.status in Developers and point it at your workflow.

Fixing common problems

Sends fail for a short list of reasons: the template, the parameter order, a template type the API cannot send yet, or a number that is not connected.
It says the connection is not ready
Your number is not fully connected through Meta. Check the Business page in your WhatSync dashboard says Connected.
Meta rejects the send
Nearly always the template. Check it is approved, the name matches character for character, the language code is right, and the number is in international format.
It says the template is not supported
Templates with an image, video or document header, or a button that needs a value, cannot be sent through the API yet. Use a template without them.
The customer never got it
Check the status in WhatSync, or listen for the message.status webhook. Meta sends a failed update when someone is unreachable or the template breaks policy, and we store the reason.
The wrong value shows up in the message
Parameter order. The first value in templateParameters fills {{1}}, the second fills {{2}}, the third fills {{3}}. One off and the name lands where the date should be.
It says the request was sent before
Every send needs its own idempotencyKey. Reusing one tells WhatSync it is the same send, so nothing goes out twice. Generate a fresh UUID for each message.

Still stuck? Email hello@whatsync.app with the template name and the error you got.

Meta's documentation

For templates, policy and pricing, Meta is the source.