Sequences

Draft Email

Draft one contact's email with an agent. SPENDS CREDITS per call.

Returns the subject and body; nothing is saved or sent. A 402 means the organisation is out of credits. Price it first with .../email/estimate.

post/sequencer/content/email/generate

Request

  • Base URL: https://be.graph8.com/api/v1
  • URL: https://be.graph8.com/api/v1/sequencer/content/email/generate
  • Auth: HTTP bearer

Headers

Authorizationstring nullable
X-Target-Org-Idstring nullable

Request body

contact_idinteger required
contact_work_emailstring required
first_namestring required
last_namestring required
instructionsstring required

What the email should do - the step's prompt.

lead_infostring required

What is known about the contact, as free text.

agent_namestring required

The textual agent whose voice and context are used.

sequence_idstring nullable

Draft in the context of this sequence's linked campaign.

studio_campaign_idstring nullable

Draft in this campaign's context; wins over sequence_id.

step_orderinteger nullable
provider'openai' | 'anthropic' | 'openrouter' nullable

Model provider, from GET /sequencer/content/email/models.

modelstring nullable

Model slug, from GET /sequencer/content/email/models.

Response

Successful Response

dataSequencerPayload required

An open envelope around one sequencer record.

Open because templates, schedules and channels carry nested step data and configuration that grows as channels are added.

Changes

No recorded changes to this operation across all 2 revisions of this API.