Space teams

Integrate team-based permissions for better collaboration in a space.

Assign entire teams to your spaces and streamline the process of granting or revoking access at scale, without dealing with individual user roles.

Remove a space team

delete
Authorizations
Path parameters
spaceIdstringrequired

The unique id of the space

teamIdstringrequired

The unique ID of the Team

Responses
curl -L \
  --request DELETE \
  --url 'https://api.gitbook.com/v1/spaces/{spaceId}/permissions/teams/{teamId}' \
  --header 'Authorization: Bearer YOUR_SECRET_TOKEN'

No Content

Update a space team permission

patch
Authorizations
Path parameters
spaceIdstringrequired

The unique id of the space

teamIdstringrequired

The unique ID of the Team

Body
roleone ofoptional

The role of a member in an organization, null for guests

"The role of a member in an organization. "admin": Can administrate the content: create, delete spaces, ... "create": Can create content. "review": Can review content. "edit": Can edit the content (live or change requests). "comment": Can access the content and its discussions. "read": Can access the content, but cannot update it in any way.

Responses
curl -L \
  --request PATCH \
  --url 'https://api.gitbook.com/v1/spaces/{spaceId}/permissions/teams/{teamId}' \
  --header 'Authorization: Bearer YOUR_SECRET_TOKEN' \
  --header 'Content-Type: application/json' \
  --data '{
    "role": "admin"
  }'

No Content

List space team persmissions

get
Authorizations
Path parameters
spaceIdstringrequired

The unique id of the space

Query parameters
pagestringoptional

Identifier of the page results to fetch.

limitnumber · max: 1000optional

The number of results per page

Responses
curl -L \
  --url 'https://api.gitbook.com/v1/spaces/{spaceId}/permissions/teams' \
  --header 'Authorization: Bearer YOUR_SECRET_TOKEN'
{
  "next": {
    "page": "text"
  },
  "count": 1,
  "items": [
    {
      "permission": "admin",
      "team": {
        "object": "team",
        "id": "text",
        "title": "text",
        "members": 1,
        "spaces": 1,
        "createdAt": "2025-04-12T21:04:01.285Z"
      }
    }
  ]
}

Was this helpful?