Create a draft email
client.email.draft(EmailDraftParams { from, attachments, bcc, 4 more } body, RequestOptionsoptions?): EmailDraftResponse { draftedAt }
POST/v1/emails/draft
Creates a draft in the connected email account that owns the from address. Mirrors native email-client behavior: only from is required — to, cc, bcc, subject, messageBody, and attachments are all optional. At least one of those optional fields must be populated; sending only from returns a 400.
Supports idempotency via the Idempotency-Key header.
Required scope: emails:create
Rate limit category: Write
Create a draft email
import Lightfield from 'lightfield';
const client = new Lightfield({
apiKey: 'My API Key',
});
const emailDraftResponse = await client.email.draft({ from: 'sales@acme.com' });
console.log(emailDraftResponse.draftedAt);{
"draftedAt": "draftedAt"
}Returns Examples
{
"draftedAt": "draftedAt"
}