Docs Home Log in

Campaigns

A campaign is one offer sent to one audience: a brief, a sequence of steps, and the angles of each step.

Status: the top switch

StatusWhat happens
draftNothing is planned. New campaigns start here.
activeIts emails are planned on the next scheduler run (every minute), only from mailboxes that are active too.
pausedNothing new is planned.

Kata never activates a campaign by itself. Only you, or the agent with your approval, do. set_sending is a shortcut over every campaign: off pauses all active campaigns and cancels the emails already planned; on sets the paused ones back to active. Drafts stay drafts.

An active campaign also has a state, computed on each read: error when it cannot send (no active mailbox it may use, {{link}} in the emails but no Link: line, a brief check that failed, no live angle for the first email, no lead at all), shown as a red badge with the reason; completed when every lead went through the sequence (not an error). status and campaign_report return it. The campaign page has a Diagnose button: the agent reads the numbers and lists the 3 to 5 biggest problems, each with one action.

brief.md and company.md

Two memory files guide the AI that writes the emails:

The campaign link is the line Link: https://… in brief.md, and only that line. It is where {{link}} points. update_campaign with target_url is a shortcut that rewrites that line.

check_campaign_brief checks five essentials: target, offer, why care, action, link. It also lists sending checks that do not block: link variables present on the leads, a live angle on each step, and hand-written URLs that will not be tracked.

Need more context? save_context adds files with scope company (used everywhere) or campaign (used for that campaign's emails).

The sequence

Step 0 is the first email. Each follow-up waits a number of days after the previous email. set_steps with [3, 5] means: first email, follow-up 1 three days later, follow-up 2 five days after that. [] means no follow-up. A new campaign gets one follow-up after 3 days unless you say otherwise.

  • Follow-ups stay in the same thread and go out from the same mailbox as the first email.
  • A first email with no live angle waits. A follow-up step with no live angle ends the sequence there.

Variables

VariableValue
{{first_name}}, {{company}}, {{email}}The lead's fields.
{{country}}, {{phone}}…Any other field of the lead (any CSV column or webhook field).
{{sender_name}}, {{sender_first}}The sending mailbox's display name, and its first word.
{{link}}The campaign link, with the lead's variables filled in and kata=<token> added. Tracked when the mailbox's domain has a link domain.
{{unsubscribe_url}}The lead's unsubscribe link (a mailto when there is no link domain).

A variable inside a URL is URL-encoded: sean+ie@x.com becomes sean%2Bie%40x.com. {{x|url}} encodes anywhere; {{x|raw}} never encodes. A URL you write by hand in the body goes out as written: not tracked, no token. Use {{link}} for anything you want measured.

Plain text only

Kata sends plain text for now, like a personal note: no HTML, no images, no tracking pixel. The sender name and the signature of the sending mailbox go below (Mailboxes, the ⋯ menu of a mailbox, Email signature). When the body has no unsubscribe link, Kata adds this line:

text
If this isn't relevant, just let me know and I won't write again.

What stops a sequence

  • A reply. Out-of-office replies do not stop it.
  • A hard bounce, an unsubscribe, or a conversion. A soft bounce only delays the email by 24 hours.
  • stop_sequence, suppress, or removing the lead from the list that feeds the campaign.

A person is never live in two sequences at once.

Which mailboxes send

By default a campaign sends from every active mailbox. set_campaign_mailboxes limits it to some. Only new first emails follow the choice: follow-ups stay in the mailbox of their thread.

Deleting

delete_campaign only works on a campaign that never sent. A campaign that sent can be paused, not deleted. Contacts always stay.