Skip to content
Skip to main content
POST
/v3/grants/{grant_id}/folders

Create a Folder

Creates a folder.

NYLAS API KEYACCESS TOKEN

Parameters

Path parameters

grant_id*string

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

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.

shared_fromstring

(Microsoft only) When provided, Nylas returns items that were shared from the specified email address. It also accepts grant ID. This parameter only accepts single email address or grant ID. Check out the Shared folders guide for more information.

Request body

name*string

Creates a folder with the specified display name.

minLength: 1maxLength: 1024
parent_idstring

(Microsoft and EWS only) The ID of the parent folder.

text_colorstring

(Google only) The text color of the folder, in hexadecimal format (for example, #0099EE). See the list of Google-defined values for more information.

background_colorstring

(Google only) The background color of the folder, in hexadecimal format (for example, #0099EE). See the list of Google-defined values for more information.

Responses

request_idstring

The request ID.

dataobject

An email folder or label.

POSThttps://api.us.nylas.com/v3/grants/{grant_id}/folders

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.

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.

shared_fromstring

(Microsoft only) When provided, Nylas returns items that were shared from the specified email address. It also accepts grant ID. This parameter only accepts single email address or grant ID. Check out the Shared folders guide for more information.

Loading editor...

Autocomplete and validation come from this endpoint's request schema.