POST /ai/draft
Write an email in the team's brand voice from a web page, a brief, or both. Returns subject, preview text and editor blocks. With target, writes it straight into a template or draft broadcast, and anyone with it open sees it arrive.
| Field | Type | Description | |
|---|---|---|---|
url | string | A page to write from: a blog post, changelog, product or event page. | |
brief | string | What the email is for. Provide url, brief or both. | |
kind | string | broadcast or template. | |
length | string | short, medium or long. | |
tone | string | A tone for this email, on top of the brand voice. | |
variables | string[] | Variables the email may use, like first_name. | |
target | object | { type: "template" | "broadcast", id } to write into. |