Marketing
Sequences
Automated, multi-step drips that stop when someone replies.
A sequence emails a contact over time — a welcome series, an onboarding drip — with waits between steps. It exits automatically the moment the contact replies.
GET
/v1/sequencesPOST
/v1/sequencesGET
/v1/sequences/:idPATCH
/v1/sequences/:idPOST
/v1/sequences/:id/enrollGET
/v1/sequences/:id/enrollmentsPOST
/v1/sequences/:id/enrollments/:enrollmentId/cancelGET
/v1/sequences/:id/analyticssequence.ts
const seq = await mail.sequences.create({
name: "Onboarding",
steps: [
{ template: "welcome", delayHours: 0 },
{ template: "tips", delayHours: 48 },
{ template: "upgrade", delayHours: 120 },
],
});
await mail.sequences.enroll(seq.id, "ada@example.com");noteSequences and campaigns are Marketing-wing features — enrolling or sending checks your plan and returns a
feature_locked error if it isn't enabled.