Drafts

Create a draft

labels are applied to the message when the draft is sent. Set sendAt to schedule the send: Anjal sends it at that time, no cron needed.

post/v1/inboxes/{id}/drafts

Request

  • Base URL: https://anjal.app
  • URL: https://anjal.app/v1/inboxes/{id}/drafts
  • Auth: API key in header X-API-Key

Request body

subjectstring
plainBodystring
htmlBodystring
replyToMessageIdstring uuid
sendAtstring date-time nullable

Schedule the send: ISO 8601 with an offset, e.g. 2026-10-01T09:00:00-04:00. Must be in the future and at most 90 days ahead. A scheduled draft needs at least one recipient and a body. On update, null cancels the schedule. Anjal checks for due drafts about every 20 seconds. If the send fails, the draft is kept, sendError is set, sendAt is cleared and draft.send_failed fires.

Example request

{
  "sendAt": "2026-10-01T09:00:00-04:00"
}

Response

Created

idstring uuid
inboxIdstring uuid
tostring[]
ccstring[]
bccstring[]
subjectstring
plainBodystring nullable
htmlBodystring nullable
replyToMessageIdstring uuid nullable
labelsstring[]

Applied to the message when the draft is sent.

sendAtstring date-time nullable

When Anjal will send this draft. Null if not scheduled.

sendErrorstring nullable

Why the last scheduled send failed. The draft is kept and sendAt is cleared.

createdAtstring date-time
updatedAtstring date-time

Changes

No recorded changes to this operation across all 1 revision of this API.