Skip to content
Docs
Open Escouade
Documentation contents

Docs › Mail › Tools

save_campaign

View as .md

Prepare a campaign.

Creates or updates a draft: one inbox, one audience and a sequence of 1 to 4 steps, with 1 to 3 variants per step. Fields such as {{prenom}} and {{societe}} come from the contacts. An empty field blocks the send. Only {{unsubscribe_url}} is filled in when the message leaves.

Access

  • Key: an Escouade Mail key with send.
  • Space: a verified space.
  • Changes nothing: no, it acts.
  • Safe to replay: use an idempotency_key where the tool offers one.

Parameters

ParameterTypeRequiredDescription
campaign_idstringnoDraft to update, optional.
namestringyesName.
inbox_idstringyesSending inbox.
from_addressstringnoThis inbox’s main address or an alias.
audience_idstringnoAudience.
reply_tostringnoOptional reply-to address.
stepslist of objectyesThe sequence: 1 to 4 steps, each with its delay and 1 to 3 variants (subject, text, optional HTML).

Call it

Terminal
curl -s https://api.subagent.fr/v1/save_campaign \
  -H 'Content-Type: application/json' \
  -H 'Authorization: Bearer sak_…' \
  -d '{"name": "…", "inbox_id": "…", "steps": "…"}'

The full page in French, with the response fields and every refusal the tool can return: /mail/docs/reference/save_campaign.