Echo/Docs

CLI command

email brand

The product a CRM campaign speaks for: whose approved messaging its crafted drafts are written from, and whose banned phrases every message of the campaign is checked against before it is sent.

Invocation#

Shell
echo-cli email brand read --campaign <campaign-id>
echo-cli email brand set --campaign <campaign-id> --product <product-id> --by <name>
echo-cli email brand clear --campaign <campaign-id>

Inputs and output#

read writes the campaign's product — campaign_id, product_id, set_by, set_at — or null when it names none; set writes the product it now names; clear writes the one it named.

State effect#

Every verb calls Echo Web's authenticated /api/crm/campaigns/<id>/brand with ECHO_INTERNAL_BEARER at ECHO_WEB_BASE_URL; the /campaigns/variants screen and the Campaign A/B variants section of Echo Desktop read, name and clear it the same way, and echo-mcp reads it as echo_campaign_brand. The product is kept in crm_campaign_brands, one per campaign. A draft crafted from an AI: brief for a campaign that names a product is written from that product's approved messaging house (echo-cli messaging): the model is given the brief, the house's umbrella message and pillars with their proof points and version, and the prospect's facts. While the product has no approved version, nothing is crafted: the recipient is marked failed with error "compose_failed: campaign <id> speaks for product <id>, which has no approved messaging; echo-cli messaging approve approves a version", and email preview answers the same sentence. When the campaign worker (or a reviewer's approval of a held send) composes a message for a campaign that names a product — a filled template or a crafted draft, at any step or variant — it checks the subject and body against that product's banned phrases (echo-cli glossary), matched as whole words without regard to case, before anything is claimed or sent. A message holding any is not sent: the recipient is marked failed with error "banned_phrases: \"<phrase>\" in <subject|body> at line <n>, column <n>[; write \"<use instead>\" instead]", every occurrence named, the campaign is recounted and the audit trail records the failure. email preview answers the same occurrences as banned. A campaign naming no product has no messaging or glossary to answer to; its crafted drafts are written from the brief alone.

Refusals#

  • A wrong invocation is refused before anything is sent: "email brand takes <every brand usage>; got <word>", "email brand <verb> does not take <flag>; it takes …", "<flag> needs a value" and "email brand <verb> needs <flag>".
  • Echo Web answers a bad request with "product_id is required: the product whose brand glossary the campaign's messages answer to" or "set_by is required: an internal caller has no signed-in user, so it names who is acting"; not found with "no campaign has id <id>; echo-cli outreach lists the campaigns", "no product has id <id>; echo-cli products lists the ones that exist" or, for clear, "campaign <id> names no product". The command prints Echo Web's sentence and exits 1.