> ## Documentation Index
> Fetch the complete documentation index at: https://docs.useinvent.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Tracking

> Track where conversations originate from across ads, products, and web widget UTM parameters

Referral Tracking lets you see exactly where each conversation originates from. Whether a customer clicks a WhatsApp ad, browses an Instagram product, or lands on your web widget from a Google campaign, Invent captures the source and displays it directly in the conversation.

This gives your assistants the perfect context to know what the customer is interested in and how to respond.

## Supported Sources

Tracking works across native ad platforms and web widget UTM URLs:

### Native Ads

| Source | Description |
| - | - |
| **Messenger Ad** | Conversations initiated from Facebook Messenger ads |
| **WhatsApp Ad** | Conversations initiated from WhatsApp click-to-chat ads |
| **Instagram Ad** | Conversations initiated from Instagram ads |
| **TikTok Ad** | Conversations initiated from TikTok ads |

### Organic Content

| Source | Description |
| - | - |
| **Instagram Post / Reel / Story** | Conversations started from an Instagram post, reel, story, or story mention |
| **Facebook Post / Reel** | Conversations started from a Facebook post or reel |
| **Facebook Comment** | Conversations started from a comment on one of your Page posts, through the Messenger **Reply to comments** setting. The card reads "Commented on a post", quotes the comment, and links to the post. Instagram comments are pending Meta review. See [Comment Replies](/assistants/channels/comment-replies) |
| **TikTok Post / Short Link** | Conversations started from a shared TikTok post or short link |

### Native Products

| Source | Description |
| - | - |
| **Messenger Product** | Conversations initiated from products shared in Messenger |
| **Facebook / Instagram Product Catalog** | Conversations initiated from a shared multi-product catalog template |
| **WhatsApp Product (Catalogs)** | Conversations initiated from WhatsApp product catalogs |
| **WhatsApp Order (Catalogs)** | Conversations initiated from WhatsApp catalog orders |
| **Instagram Product** | Conversations initiated from Instagram product listings |

<Note>
  These tables are representative, not exhaustive. Invent recognizes many referral types across each channel and displays whichever one applies.
</Note>

### Web Widget

| Source | Description |
| - | - |
| **Web Widget (UTM Support)** | Conversations from your website widget with full UTM parameter tracking |

## How It Works

When a customer starts a conversation from any supported source, Invent automatically captures the referral information and displays it in three places:

1. **Conversation timeline**: A referral card shows where the conversation came from. Its heading is a short phrase next to the platform icon, such as "From an ad", "Shared a post", "Asked about a product", "Placed an order", or "Came from a page", with a thumbnail or the product or order details below. Posts, products, and orders appear as a message on the side of whoever shared them. Ads and web widget origins are centered, since nobody sent them
2. **Contact panel**: The **Referral** section in the [Contact Panel](/guides/inbox#referral) shows the same card for quick reference
3. **Inbox list**: The conversation preview reads the same phrase when the referral is the latest message

No additional setup is required for native ad and product tracking. For web widget tracking, UTM parameters are captured automatically from the page URL where the widget is embedded.

## Viewing Referral Data

### Ad and Product Referrals

For conversations originating from ads or product listings, the card shows:

* **What happened**: "From an ad", "Asked about a product", "Shared a catalog", or "Placed an order", next to the platform icon
* **Preview**: The ad creative or the product image, with the ad headline or the product name and price. An order lists each product with its quantity and price, and the total
* **Details**: Hover over the info icon on the card to see the identifiers (ad ID, post ID, SKU, catalog) and the product description. The arrow icon opens the source on the platform when a link is available

For example, someone who tapped a product on Instagram shows up as an "Asked about a product" card with the product image, name, and price, on their side of the conversation.

### Web Widget UTM Referrals

For conversations originating from your web widget with UTM parameters, the referral section captures:

* **Source**: The traffic source (e.g., `google`, `facebook`, `newsletter`)
* **Medium**: The marketing medium (e.g., `cpc`, `email`, `social`)
* **Campaign**: The campaign name (e.g., `spring_sale_2026`)
* **Term**: The paid search keyword (e.g., `ai chatbot`)
* **Content**: The ad variation or content identifier (e.g., `headline_v2`)
* **Ad**: The ad identifier (`utm_ad`)
* **Google Click ID**: The GCLID for Google Ads attribution
* **Facebook Click ID**: The FBCLID for Meta Ads attribution
* **Page**: The full URL the customer visited

In the conversation timeline, the card reads "Came from a page" and lists these fields inline, with the page as a link. It sits centered in the conversation.

## Using Tracking with Assistants

Referral data is available to your assistants, enabling them to tailor responses based on context. For example:

* A customer coming from a **product listing** can be greeted with information about that specific product
* A customer from a **paid ad campaign** can receive messaging aligned with the campaign's offer
* A customer browsing your **catalog** can get personalized product recommendations based on the item they viewed

This context helps your assistants deliver relevant, personalized conversations from the very first message. You can add rules in your [Instructions](/guides/practical/writing-instructions) to guide how your assistant uses referral data (e.g., "If the customer came from a product listing, greet them with information about that product").

## Next Steps

<CardGroup cols={2}>
  <Card title="Inbox" icon="inbox" href="/guides/inbox">
    View referral data in the contact panel alongside conversations
  </Card>

  <Card title="Channels" icon="tower-broadcast" href="/assistants/channels">
    Connect the channels that support referral tracking
  </Card>
</CardGroup>


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.