API reference / Outreach
Edit a campaign's email
A person's own words for a draft, or for an approved email not yet sent. What a person writes carries no flags.
/api/v1/campaigns/{id}/emails/{email}Other ways to call it
troopy campaigns edit-emailtroopy_update_campaign_emailIdempotency-Key header. A retry with the same key gets the first answer back, and the operation runs one time.Path parameters
id*stringA 24-character id
email*stringA 24-character id
Body
application/jsonsubjectstringAt least 1 characters · At most 200 characters
bodystringAt least 1 characters · At most 5000 characters
Response
200 · application/jsondata*object17 properties
id*stringA 24-character id
lead*object4 properties
enrollment*stringA 24-character id
email*stringname*string | nullstatus*enum<string>activepausedrepliedbouncedunsubscribeddonestopped
step*integerIts step, from 0
subject*stringbody*stringflags*array<string>What a person should look at first: a flagged email always waits for one
status*enum<string>draftapprovedsendingsentunknownfailedskippedcanceledreceived
dueAt*string | nullsentAt*string | nullwrittenBy*enum<string>templatepersonteammate
teammate*object | nullThe teammate that wrote it
2 properties
name*stringhandle*stringnote*string | nullThe line of the teammate for the person who reviews it: the detail it starts with, and where that comes from
used*array<object>What the teammate took from the lead's material, each with the words it took. Troopy checked each quote against its source
3 properties
source*stringurl*string | nullquote*stringrewriting*booleanA teammate writes it again now, as a person asked
approvedBy*object | null3 properties
type*enum<string>personagentapi
id*stringname*stringautopilot*booleanApproved by the campaign's Autopilot, in the name of whoever granted it
error*string | nullWhy it hasn't gone, or may not have, or why it couldn't be rewritten