Lead attribution: which ad or post gets credit — and which scenario the AI runs
Lead attribution: which ad or post gets credit — and which scenario the AI runs
One lead can arrive from an ad, a comment, a story, or a plain DM — here’s how Chatfuel pins the conversation to its origin and picks the scenario to run
Every lead comes from somewhere: an ad your agency is running, a comment under last week’s post, a story reply, a link in bio, or a plain DM to the account. Chatfuel pins each conversation to that exact origin and keeps it pinned for 24 hours after the lead’s last message — every new message from the lead restarts the clock. Two things follow: you always know which ad or post a lead belongs to, and the AI answers with the scenario you configured for that origin — the lake-house ad can qualify leads differently than the open-house post. This page explains the rules attribution follows, so conversations behave exactly the way you expect.

Where a lead can come from
Every incoming message is matched to one of these origins:
For most origins, attribution goes down to the specific object — not just “an Instagram comment” but a comment under that post, that ad, that story, that link. Plain direct messages and website chats have no object behind them, so they’re attributed at the channel level.
One origin, one scenario
Scenario settings live in automations, arranged in three levels:
- Main bot — the defaults for everything the bot does.
- Source — one kind of traffic on a channel: all Instagram comments, all story replies, all ads that click to WhatsApp.
- Object — one specific post, ad, story, or link inside a source.

A level only overrides what you set on it explicitly; everything you leave untouched is inherited from the parent. In practice that means you configure the Main bot once, and add overrides only where a campaign needs its own behavior — no duplicating the whole setup per post.
What can differ per level: the AI’s instructions (for comment origins that splits into the public reply, the private reply, and the DM conversation), follow-ups, message delay, when the AI replies — always or only after business hours, human handoff rules, booking autonomy, and whether the AI shares catalog photos.
Two ways to set it up
Open the Automations section to see the hierarchy and edit any level directly — or just tell the Co-Worker: “For the lake-house post, ask about budget and preferred viewing date, and hand off as soon as both are collected.” Both paths edit the same settings.

The attribution rules
- The first message opens the conversation, pinned to its origin. A lead comments under post A — the conversation is now post A’s, and post A’s scenario runs.
- The same origin continues it. Another comment under post A, or a DM reply inside that conversation, keeps everything as is.
- A different origin switches it. A story reply, a tap on another ad — or even a comment under post B. Two posts are two different origins: the moment the lead comments under post B, the AI drops post A’s scenario and runs post B’s.
- A plain DM never switches it. If a conversation is already open, a direct message continues it instead of hijacking it — more on why below.
- 24 hours of silence closes it. The clock counts from the lead’s last message. After it runs out, the next message starts a fresh conversation with fresh attribution.

The fine print
Only the lead’s own messages move attribution — follow-ups, broadcasts, and replies from the team never open or switch a conversation. And attribution only changes when the AI actually answers: if the AI is switched off for that origin, the chat is handed to a human, or it’s outside the answering hours you set, the conversation stays pinned where it was.
Why DMs don’t steal the lead
Here’s the case that makes rule 4 necessary. A lead comments under your client’s post; the AI replies publicly under the comment and continues privately in DM. From that moment, everything the lead types arrives as a direct message. If plain DMs switched attribution, every comment-lead would turn into a “direct lead” two messages in — the post’s scenario would be lost, and the post would lose credit for the lead it produced.
So a plain DM only opens a conversation when none is active. While one is open, the lead’s DM answers continue the scenario of the post, ad, or story that started it — right inside the DM thread.
One distinction to keep straight: ig.me links and ads that click into the inbox also arrive as direct messages, but they’re deliberate entry points carrying campaign intent — those do switch the conversation, like any other origin.
Four situations you’ll actually see
What this buys your campaigns
- Per-ad scripts. Each ad or post can run its own offer, its own qualification questions, its own follow-ups — matched to the creative the lead actually clicked.
- Ads keep their credit. The conversation moves into DM, but it stays attributed to the ad or post that produced it — DM traffic doesn’t blur which campaign a lead belongs to.
- A mental model for debugging. A lead is answering in DM but the bot keeps asking about post A? That’s attribution holding, by design. Want different behavior in that conversation? Change post A’s automation — not the direct-message one.
Where to next
The five modules every scenario is built from.
What the AI asks once the right scenario is running.
“When the AI replies” is one of the settings each automation controls.
Bot answering with the wrong scenario? Start here.
