Workspaces
Workspaces group and organize grants in a Nylas application by a common attribute, such as the email address domain (for example, nylas.com).
Assign grants to workspaces
Nylas offers two endpoints to manage workspaces and the grants they contain:
- Automatically Group Grants into Workspaces: Starts a background job that, based on your filters, processes existing grants in your Nylas application and automatically sorts them to existing workspaces. If necessary, Nylas automatically creates new workspaces.
- Update Workspace Assignments: Manually specify a workspace ID and up to 500 grants to add or remove from that workspace.
Workspace limitations
- Workspaces are designed to group grants by the top-level domain (TLD) of users' email addresses. Nylas allows you to manually assign grants to any workspace, but that workspace must have
auto_groupset tofalse. - When
auto_groupis set tofalse, Nylas doesn't automatically assign grants to that workspace. You'll need to manually assign grants to the workspace using the Update Workspace Assignments endpoint. - When
auto_groupistrue, Nylas automatically assigns new grants to the workspace. You can move grants to a different workspace by making an Update Workspace Assignments request.
GET /v3/workspacesReturns all workspaces in your Nylas application. The application queried is determined based on the API key you use to authorize your request.
POST /v3/workspacesCreates a workspace.
GET /v3/workspaces/{workspace_id}Returns the specified workspace.
PATCH /v3/workspaces/{workspace_id}Updates the specified workspace.
DELETE /v3/workspaces/{workspace_id}Deletes the specified workspace.
POST /v3/workspaces/auto-groupConfigures automatic grouping settings for new or existing workspaces, depending on the filters set. If you don't set any filters, Nylas considers all grants.
POST /v3/workspaces/{workspace_id}/manual-assignManually assigns or removes specified grants to or from a specific workspace. You must specify at least one grant ID in either assign grants or remove grants. You can include up to 500 grants per list...