Campaigns
Campaigns are outbound initiatives — proactive messaging to a defined audience, scheduled or one-shot. Distinct from the inbox (reactive, one-on-one) and from recipes (which run when a customer triggers them), campaigns push first.
What campaigns do
- Audience selection — pick contacts via a filter tree (operators like
eq,in,contains,tag_has,attr_eq,last_inbound_within_days), or reuse a saved audience segment. - Templated messaging — send pre-approved WhatsApp HSM templates (required outside the 24-hour customer-service window). Templates configure their own variable strategies (mapped field, fallback value, etc.) at the template level; the campaign just picks an approved template.
- Scheduling — fire immediately (
Send now), schedule for a future moment, or recur on a cadence using an RRULE string (RFC 5545 —FREQ=DAILY,FREQ=WEEKLY;BYDAY=MO,WE,FR, etc.). - Approval workflow — every campaign must be reviewed before it ships. Drafters submit; an admin approves or rejects with a reason; only approved campaigns can launch.
- Drift hold — if the resolved audience differs from the creation-time estimate by more than the configured threshold (default 25%), the campaign pauses and waits for an admin to confirm before sending.
- Reply handling — pick how recipient replies are routed: no action, opt-out keywords only, trigger a specific recipe, or route directly to an agent queue.
- Delivery tracking — every send is logged. Per-campaign analytics (sent / delivered / read / replied / failed funnel) ride on top of the channel adapter as it accumulates verified production traffic.
How campaigns relate to recipes
A campaign sends the first message; the recipient’s reply (if any) re-enters the platform as a normal inbound message. From there, the campaign’s reply-handling mode decides what happens — the reply can hit the standard trigger pipeline, fire a specific recipe with campaign context, route directly to a team queue, or be silently dropped (with opt-out keywords still respected).
This separation is intentional: campaigns own the outbound side; recipes own the conversational logic afterwards.
Compliance and consent
- Campaigns can only target opted-in contacts (PDPL + WhatsApp commerce policy). The audience preview filters non-consenting contacts out of the count automatically.
- Templates must be pre-approved by Meta — the wizard only lists approved templates.
- Opt-out keywords (
STOP,CANCEL,UNSUBSCRIBE, plus the Arabic equivalentsلاandإيقاف) are checked first on every reply, in every reply-handling mode — includingNo action. Opted-out contacts are excluded from future sends platform-wide.
Working with campaigns
The Campaigns surface lives in the main left-rail nav. From there:
- Campaigns list — every campaign in the workspace, with status pill, schedule mode, audience size, and next run. Status filter chips along the top: All, Drafts, Pending, Approved, Scheduled, Running, Paused, Drift hold, Completed, Cancelled.
- New campaign — six-step wizard: Basics → Audience → Template + variables → Schedule → Reply handling → Review + submit. Save as a draft at any point; resubmit for approval when ready.
- Audiences — saved audience definitions reusable across campaigns. Each campaign snapshots its filter at creation, so later edits to a saved audience do not affect campaigns already pointing at it.
- Campaign detail — shows the status pill, lifecycle action buttons (Submit / Approve / Reject / Launch / Pause / Resume / Cancel / Approve drift / Edit, gated by current status), a KPI strip (estimate, resolved size, drift threshold, reply mode, next run), and a configuration panel with the template ID, audience binding, schedule, and the frozen filter snapshot.
The campaign lifecycle
Campaigns walk through a strict status flow. The list filter chips mirror it:
- Draft — created, editable, not yet submitted. Drafter can edit freely.
- Pending approval — drafter clicked Submit for approval. An admin sees Approve / Reject buttons on the detail page.
- Approved — admin approved. The Launch button is now available.
- Scheduled — launched, but the start time hasn’t arrived yet.
- Running — actively sending.
- Paused — operator paused mid-flight. Resume button re-enters the previous state.
- Drift hold — automatic pause: the resolved audience drifted past the threshold versus the creation-time estimate. Banner explains the gap (e.g. “estimate 8,200 → resolved 12,400”). Admin clicks Approve drift to release.
- Completed — finished sending.
- Cancelled — operator cancelled. Irreversible; pending sends do not fire.
Rejection sends the campaign back to Draft with the rejection reason shown in a banner. The drafter can revise and resubmit.
Audiences
A campaign needs an audience — either a saved segment selected from a dropdown, or an ad-hoc filter tree authored inline.
- Filter tree is JSON with up to 3 levels of nesting. Top-level shape:
{"op":"AND","children":[ ... ]}or{"op":"OR","children":[ ... ]}. - Available operators:
eq,neq,in,contains,gt,lt,between,is_null,is_not_null,tag_has,attr_eq,attr_contains,last_inbound_within_days. - Click Preview audience size in the wizard to count how many opted-in contacts currently match. Counts may be capped — the preview tells you when capping kicks in.
- Saved audiences live at Campaigns → Audiences. Each row shows last resolved size, when it was resolved, and when it was last used by a campaign.
- The filter is snapshotted at campaign creation. Editing a saved audience does not retroactively change campaigns that already point at it.
Scheduling and runtime guards
The Schedule step has three modes:
- Send now — fires when the campaign launches.
- Scheduled — runs once at a future
DTSTART. - Recurring — runs on the RRULE cadence starting at
DTSTART. Examples:FREQ=DAILY,FREQ=WEEKLY;BYDAY=MO,FREQ=MONTHLY;BYMONTHDAY=1.
Timezone defaults to Asia/Dubai; change it to any IANA zone.
Two workspace-wide guards override the schedule at runtime:
- Quiet hours (Settings → Quiet hours) — outbound sends inside the window are deferred. Default is 22:00–08:00
Asia/Dubai. - Blackout dates (Settings → Blackout dates) — days on which sends are skipped or blocked entirely.
If the recipient is in a window that crosses these guards, the platform defers or drops the send rather than firing it.
Reply-handling modes
The Reply step picks how recipient responses are routed. Opt-out keywords are checked first in every mode.
- No action — replies hit the standard inbound pipeline (recipe triggers, agent inbox).
- Opt-out only — listen for STOP / CANCEL / UNSUBSCRIBE / لا / إيقاف keywords; ignore other replies.
- Trigger recipe — replies start the configured bot recipe with campaign context attached. Requires a recipe ID.
- Route to queue — replies go directly to the configured agent team queue. Requires a team ID.
Related admin surfaces
- Healthcare compliance blocklist (Settings → Compliance → Blocklist) — patterns automatically blocked from HSM template bodies (PDPL safeguard for the MENA healthcare deployment).
- Blackout dates (Settings → Blackout dates) — workspace-wide non-send days.
- Quiet hours (Settings → Quiet hours) — workspace-wide non-send window.
- Templates (Settings → Integrations → Templates) — where HSM templates are authored, submitted to Meta for approval, and configured with variable strategies. The wizard’s Template step only lists templates whose status is
approved.