Skip to main content
PATCH
Update a custom agent's sharing permissions
The organization bot token must have the following scopes:
  • workflows:write

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Headers

Notion-Version
enum<string>
required

The Admin API version to use for this request.

Available options:
2026-06-01

Path Parameters

agent_id
string<uuid>
required
space_id
string<uuid>
required

Body

application/json

'set' upserts (grants or updates the level for) each principal; 'remove' revokes access for each principal. A single request may do both, applied atomically — invalid batches write nothing. At most 100 combined 'set' + 'remove' entries per request, and a principal must not appear in both lists.

remove
object[]

Principals to revoke permissions for.

A recipient of a permission grant. 'workspace' maps to a space-wide permission granting all workspace members the given role; guests are never covered by it.

set
object[]

Principals to grant permissions to, or update the level for.

Response

permissions
object[]
required

The updated permission list, in the same shape as the read endpoint. This is a pre-commit projection truncated at 250 entries with no cursor; treat the paginated read endpoint as the source of truth.