Compose Inbox Email
POST /inbox/emails/compose
COMPOSE AN EMAIL. WITH save_as_draft FALSE THIS REACHES A REAL PERSON.
The one call that does everything the compose window does:
- new thread, sent now -
to,from_mailbox,subject,content - new thread, saved as a draft - the same plus
save_as_draft: true - reply into a thread - add
reply_to_email_id - edit an existing draft - add
draft_id - send a draft you saved -
draft_idplussave_as_draft: false
save_as_draft DEFAULTS TO FALSE, which means SEND. That is the app’s own
default and it is kept rather than made safer here, because two ends
disagreeing about what an omitted field does is worse than a default you
can read.
Classified external (inbox:run) because it can deliver. Sending as a
mailbox the caller is not authorised for is a 403 from the sender
authorisation gate, not a silent success - check first with
POST /inbox/emails/validate-mailbox.
Distinct from POST /inbox/emails/{email_id}/send, which can only reply
into a thread that already exists.
Authorizations
Parameters
Header Parameters
Request Body required
Compose an email: save it as a draft, or SEND IT TO A REAL PERSON.
save_as_draft decides which. It defaults to FALSE, which means SEND -
the app’s default, kept rather than made safer here so the two ends cannot
disagree about what an omitted field does.
object
Emails to assign the resulting thread to.
Already-uploaded attachment references. The server re-validates each one.
object
Body, HTML.
The mailbox to send AS. Must already be syncing - check with POST /inbox/emails/validate-mailbox first.
FALSE SENDS THE MESSAGE. True stores a draft and contacts nobody.
Tags to attach to the thread.
Recipients. These are real addresses.
Responses
200
Successful Response
object
An open envelope for a comment, an assignment or a workspace.
Open because a comment carries attachment refs and mention metadata that grow, and because an assignment result reports per-assignee outcomes.
object
object
Whether there are more pages
Items per page
Current page number (1-indexed)
Total number of items
422
Validation Error