POST/api/v1/projects/{project_id}/campaigns/{campaign_id}/pause
pause_campaign
Pauses a sending campaign: no new letter of it goes out until resume_campaign; the letters under way finish.
- Call it
- to hold a campaign that is going out (a mistake in it, a complaint wave).
- Needs
- an admin key with
project_id, or a project key with scopesend(its own project; the argument is ignored), and a campaign insending(a paused one is answered as it is; otherwiseconflict). - Returns
- the campaign after the call, the same as
POST /api/v1/projects/{project_id}/campaigns/{campaign_id}/pause.
Arguments
- object
-
campaign_idstring · uuidrequiredThe campaign’s id, as
create_campaignorlist_campaignsgave it. -
project_idstring · uuid | nullThe campaign’s project. An admin key must pass it; a project key’s own project is used and this is ignored.
No other arguments are accepted.
Result
The result comes back as structuredContent, with the same JSON as a text block.
- object · all fields required
-
completed_atstring · date-time | null -
created_atstring · date-time -
from_emailstring | nullnull: the project’ssettings.from_email. -
from_namestring | nullnull: the project’ssettings.from_name. -
idstring · uuid -
last_errorstring | nullWhy the launch failed;
nullunlessfailed. -
launched_atstring · date-time | null -
list_idsarray of stringThe lists it goes to, in the order given.
-
namestring -
partial_versionsmap of string → integer · uint32The versions of the partials fixed at launch, by name;
{}before. -
project_idstring · uuid -
reply_tostring | nullnull: the project’ssettings.reply_to. -
scheduled_atstring · date-time | nullWhen a scheduled campaign launches;
nullunless scheduled. -
shard_countinteger · uint32 | nullFixed at launch;
nullbefore.≥ 0
-
statusstringdraft,scheduled,launching,sending,paused,completed,cancelledorfailed. -
subject_overridestring | nullnull: the template’s subject. -
template_idstring · uuid -
template_versioninteger · uint32 | nullThe template’s version fixed at launch;
nullbefore.≥ 0
-
throttle_per_hourinteger · uint32 | nullnull: the project’sdefault_throttle_per_hour, or no limit.≥ 0
-
total_recipientsinteger · uint64 | nullRecipients of the launch’s snapshot;
nullbefore.≥ 0
-
tracking_overrideTrackingOverride | nullnull: the project’ssettings.tracking.2 fields
- TrackingOverride object · all fields required
-
clicksboolean -
opensboolean
-
transport_overridestring | nullnull: the project’s transport, then the node’s default. -
updated_atstring · date-timeThe latest change: creation, fields, status.
Definitions
TrackingOverride
What a campaign tracks in place of the project’s.
- object · all fields required
-
clicksboolean -
opensboolean
Errors
A failed call answers isError: true with a code from the same table as the HTTP API, and detail. How tools report errors
HTTP API
The same operation over HTTP: POST /api/v1/projects/{project_id}/campaigns/{campaign_id}/pause