Skip to content
Skip to main content
POST
https://api.us.nylas.com/v3/grants/{grant_id}/drafts/{draft_id}

Send a Draft

Sends the specified draft as a message and returns the sent message object. This request has no body. To add a signature, set signature_id when you create or update the draft.

Queued sends on Agent Accounts

When an Agent Account sends faster than its per-second rate limit, Nylas can queue the draft instead of rejecting it, and returns 202 Accepted with the message object. Queued drafts are sent in order, usually within seconds. A draft at the back of a full queue can take up to 90 seconds. Subscribe to message.delivered to confirm that a queued draft went out, and to message.send_failed to learn if it couldn't be sent. A draft that fails to send stays in the Drafts folder. See Send queueing.

Works with an API key, an access token (use /v3/grants/me/ in place of the grant ID), or an IAM API key with the drafts.send permission.

Parameters

Path parameters

grant_id*string

ID of the grant to access. Use /me/ to refer to the grant associated with an access token.

draft_id*string

ID of the draft to access. Nylas recommends you URL-encode this field, or you might receive a 404 error if the ID contains special characters (for example, #).

Query parameters

selectstring

Specify fields that you want Nylas to return, as a comma-separated list (for example, select=id,updated_at). This allows you to receive only the portion of object data that you're interested in. You can use select to optimize response size and reduce latency by limiting queries to only the information that you need.

Responses

request_idstring

The request ID.

dataobject
POSThttps://api.us.nylas.com/v3/grants/{grant_id}/drafts/{draft_id}

Find your API key in the Nylas Dashboard under API Keys in your application settings.

grant_idrequiredstring

ID of the grant to access. Use /me/ to refer to the grant associated with an access token.

draft_idrequiredstring

ID of the draft to access. Nylas recommends you URL-encode this field, or you might receive a `404` error if the ID contains special characters (for example, #).

selectstring

Specify fields that you want Nylas to return, as a comma-separated list (for example, select=id,updated_at). This allows you to receive only the portion of object data that you're interested in. You can use select to optimize response size and reduce latency by limiting queries to only the information that you need.