# What Click-to-WhatsApp fields appear on Whatsable webhooks?

> Map Click-to-WhatsApp referral on Whatsable webhooks: source_type, source_id, source_url, headline, body, media, ctwa_clid, and first-message context fields.

When someone taps **Send message** on a Click-to-WhatsApp ad (Facebook, Instagram, or WhatsApp Status) and writes to your number, Meta attaches a `referral` object to that inbound event. Whatsable forwards it on your custom webhook and on n8n, Make, and Zapier triggers — so you can see which creative, platform, and click produced the lead.

This page is the **dedicated field dictionary** for that `referral` object (and the first-message fields that ride alongside it). For the full incoming and outgoing webhook payload and signature verification, use [Message webhooks](/api-reference/legacy/incoming-message) — including the live [Click-to-WhatsApp ads](/api-reference/legacy/incoming-message#click-to-whatsapp-ads) section.

## Prerequisites

- **Whatsable account** with a connected WhatsApp Business number (Embedded Signup / Coexistence supported — keep the WhatsApp Business app; do not uninstall it after connect).
- **Incoming messages** sent to your endpoint: an endpoint in **Settings → Webhooks** with **Incoming messages** ticked, or an [n8n](/integration/n8n), [Make](/integration/make) or [Zapier](/integration/zapier) trigger.
- **HTTPS endpoint** that accepts `POST` JSON and answers `2xx` quickly (same requirements as [Message webhooks](/api-reference/legacy/incoming-message)).
- Optional: a CRM or Conversions API destination ready to store `ctwa_clid` and `source_id` as soon as they arrive (they usually appear **once**).

> [!NOTE]
>
> Make, Zapier, n8n and outgoing webhooks are part of the **Pro** and **Agency** plans. See [plans](/features/plans-bulk-message-pro-agency).

---

## What `referral` is for

| Goal | Fields to use |
|------|----------------|
| Group leads by campaign or creative | `source_id`, `headline` |
| See Facebook vs Instagram vs other | `source_url` (host is `instagram.com`, `facebook.com`, `fb.me`, …) |
| Show agents the ad the lead saw | `headline`, `body`, `image_url` / `video_url`, `media_type` |
| Send conversions back to Meta | `ctwa_clid` |

> [!NOTE]
>
> `referral` is typically present only on the **first inbound message** after the ad click. Later messages in the same chat usually omit it. Persist `ctwa_clid` and `source_id` (keyed on the contact's phone) as soon as they arrive.

> [!NOTE]
>
> WhatsApp Status ad placements may omit `ctwa_clid`. Organic posts use `source_type: "post"` instead of `"ad"`.

---

## Referral object — field dictionary

Look for `referral` as a **top-level** field on the Whatsable webhook payload. On an endpoint that uses the **Native payload** format, it is at `message.referral`. Whatsable never sends Meta's Cloud API envelope.

| Exact key | Type | Meaning |
|-----------|------|---------|
| `referral` | object | Present on incoming CTWA / post events; omitted on ordinary chats and most follow-ups |
| `referral.source_type` | string | `"ad"` or `"post"` |
| `referral.source_id` | string | Meta ad or post ID |
| `referral.source_url` | string | URL of the ad or post (platform is in the host) |
| `referral.headline` | string | Ad or post headline |
| `referral.body` | string | Ad or post body copy (may include emoji shortcodes such as `:fire:`) |
| `referral.media_type` | string | `"image"` or `"video"` |
| `referral.image_url` | string | Image creative URL when `media_type` is `"image"` (URLs can expire — copy assets you need to keep) |
| `referral.video_url` | string | Video creative URL when `media_type` is `"video"` |
| `referral.thumbnail_url` | string | Thumbnail URL for video creatives |
| `referral.ctwa_clid` | string | Click ID for Meta Conversions API attribution (`action_source: "business_messaging"`, `messaging_channel: "whatsapp"`) |
| `referral.welcome_message` | object | Optional. Welcome message configured on the ad, when Meta includes it. Whatsable passes it on as Meta sends it |

> [!WARNING]
>
> Only the keys above are documented. A Facebook Lead Ads form submission is a different Meta product and does not produce a `referral`.

---

## First-message fields on the same event

Creative and attribution live under `referral.*`. The contact's first text rides on the **same** inbound payload in the usual message fields — useful for CRM notes and routing.

| Exact key | Role alongside `referral` |
|-----------|---------------------------|
| `incoming_message` | `true` on a **Your own server** endpoint; missing on a **Make, Zapier or n8n** endpoint |
| `last_message_of_user` | Latest user text (sample: `"Quiero información"`) |
| `last_messages` | Recent thread as a JSON string — parse before iterating |
| `message_type` | `referral` for a text message that came from an ad; the real type, such as `image`, otherwise |
| `phone_number` | Contact digits, as a string |
| `recipient_name` | Display name if available |
| `conversation_paragraph` | Human-readable summary |

---

## Sample payload (Whatsable flattened shape)

```json
{
  "last_messages": "[{\"type\":\"user\",\"content\":\"Quiero información\",\"timestamp\":\"2026-08-15T18:18:36.000Z\",\"content_type\":\"text\"}]",
  "conversation_paragraph": "User (6:18:36 PM): Quiero información",
  "phone_number": "50655550100",
  "recipient_name": "Maria Lopez",
  "user_id": "9232fcef-a570-4a2c-b46b-6cab53aec304",
  "last_message_of_user": "Quiero información",
  "last_message_of_bot": "",
  "message_type": "referral",
  "incoming_message": true,
  "is_scheduled": false,
  "referral": {
    "source_type": "ad",
    "source_id": "52540693396957",
    "source_url": "https://www.instagram.com/p/DZiVBz7gAF9/",
    "headline": "Expo Nissan",
    "body": "Aprovechá la EXPONISSAN y llevate tu nuevo Nissan Kicks Play Sense MT con condiciones que juegan a tu favor.",
    "media_type": "image",
    "image_url": "https://scontent.xx.fbcdn.net/v/t45.1600-4/example.jpg",
    "ctwa_clid": "AfhN-JKvx8HeFTmfB-Tu11zktQRJ-MNdMV1mwvDNxHnpYrGl-jVf3OEFhLva_MP41zYRe5ErUteWFn3v4gkkjzfIEVr9J_u8GAo3-o6DqShykM4Zsl14FcU5MyThsCoQ"
  }
}
```

This sample comes from a **Your own server** endpoint and leaves out some fields. `video_url`, `thumbnail_url` and `welcome_message` appear only when Meta sends them.

---

## Delivery paths

| Destination | How `referral` arrives |
|-------------|------------------------|
| Your own endpoint (**Settings → Webhooks**) | Whatsable POSTs the payload including `referral` when present |
| n8n / Make / Zapier triggers | Same object on the trigger; filter when `referral` exists |

Field companions when mapping in each tool: [Zapier fields](/integration/zapier/fields) · [Make fields](/integration/make/fields) · [n8n fields](/integration/n8n/fields).

> [!TIP]
>
> In n8n, Make, or Zapier, add a filter or router: only treat the event as ad-attributed when `referral` exists (or `referral.source_type` is `"ad"`). Map `referral.headline`, `referral.source_url`, and `referral.source_id` into your CRM so reporting matches Meta Ads Manager.

---

## Limits and what this does NOT do

> [!WARNING]
>
> **First inbound only (typical).** Do not expect `referral` on every message in the thread. Store `ctwa_clid` and `source_id` immediately.

> [!WARNING]
>
> **Status ads may omit `ctwa_clid`.** Other referral fields can still be present. Organic posts use `source_type: "post"`.

- A Facebook Lead Ads form submission is a different Meta product and does not produce a `referral`.
- `ctwa_clid` is the only attribution field meant for Meta's Conversions API.

---

## Related features and next steps

- [Message webhooks](/api-reference/legacy/incoming-message): 
Full inbound/outbound payload, signatures, and CTWA section

- [Zapier fields](/integration/zapier/fields): 
Trigger output dictionary including nested `referral`

- [Make fields](/integration/make/fields): 
Module field dictionary for Make

- [n8n fields](/integration/n8n/fields): 
Node field dictionary for n8n

Also: [n8n overview](/integration/n8n) · [Make overview](/integration/make) · [Zapier overview](/integration/zapier) · [Click-to-WhatsApp ads (anchor)](/api-reference/legacy/incoming-message#click-to-whatsapp-ads).

---

## FAQ

### Do Whatsable webhooks include Click-to-WhatsApp ad details?

Yes. When the contact's message comes from a Click-to-WhatsApp ad (or organic post with referral), the payload includes a `referral` object (`source_id`, `source_url`, `source_type`, `headline`, `body`, `media_type`, creative URLs, and usually `ctwa_clid`). Full field list is on this page; parent payload reference: [Message webhooks](/api-reference/legacy/incoming-message#click-to-whatsapp-ads).

### Why is `referral` missing on later messages?

Meta / Whatsable typically attach `referral` only on the **first** inbound after the tap. Persist `ctwa_clid` and `source_id` keyed on `phone_number` when you first see them.

### Where do I look in a Cloud API–shaped delivery?

Whatsable never sends Meta's Cloud API envelope. On the Whatsable webhook body, look for top-level `referral`. On an endpoint that uses the **Native payload** format, look at `message.referral`.

### Can I send `ctwa_clid` to Meta Conversions API?

Yes — that is the documented purpose of `ctwa_clid` (Business Messaging / WhatsApp). Status placements may omit the click ID; do not invent other pixel fields on this webhook.