v2

latestOpenAPI 3.0.3Apache-2.02026-08-07119359591.9 KB
Role Bindings

Update a role binding

Update an existing role binding by changing its assigned role.

Payload Requirements

  • role_id is required and replaces the currently assigned role.
  • Only role_id is mutable. The binding identity, principal, resource, and timestamps stay the same.
  • System-managed fields (id, user_id, resource_type, resource_id, created_at, updated_at) are not accepted in the request body.

Valid example

{
  "role_id": "Um9sZToyOmRLMjQ="
}

Invalid example

{
  "role_id": "Um9sZToyOmRLMjQ=",
  "user_id": "VXNlcjoxOmxQZzI="
}

This fails because only role_id can be updated on an existing binding.

<Note>This endpoint is in beta, read more here.</Note>

patch/v2/role-bindings/{binding_id}

Path parameters

binding_idstring required

A universally unique identifier (base64-encoded opaque string).

Example:RW50aXR5OjEyMzQ1

The unique role binding identifier (base64)

Request body

role_idstring required

A universally unique identifier (base64-encoded opaque string).

Example request

{
  "role_id": "RW50aXR5OjEyMzQ1"
}

Response

A role binding object.

idstring required

Unique identifier for the role binding.

role_idstring required

A universally unique identifier (base64-encoded opaque string).

user_idstring required

A universally unique identifier (base64-encoded opaque string).

resource_type'SPACE' | 'PROJECT' required

Resource type for the binding. Only SPACE and PROJECT are supported for single-binding CRUD. resource_id must encode the same resource type.

resource_idstring required

A universally unique identifier (base64-encoded opaque string).

created_atstring date-time required

Timestamp when the binding was created.

updated_atstring date-time required

Timestamp when the binding was last updated.

Example response

{
  "role_id": "RW50aXR5OjEyMzQ1",
  "user_id": "RW50aXR5OjEyMzQ1",
  "resource_id": "RW50aXR5OjEyMzQ1"
}