Skip to main content
POST
Assign Service Account Workspace Role

Authorizations

Authorization
string
header
required

OAuth 2.0 client credentials. Alternatively, you can authenticate with a personal access token (PAT) by sending Authorization: Basic base64(email:PAT).

Scopes

management:service-accounts:write

Write access to service account resources.

Path Parameters

id
string<uuid>
required

Service account identifier (UUID).

workspace_id
string<uuid>
required

Workspace identifier (UUID).

Body

application/json
role_id
string<uuid>
required

Role to assign. Must exist in the organization.

Response

Created. Returns the new workspace role assignment.

A workspace-scoped role assignment for a service account.

id
string<uuid>

Assignment identifier.

service_account_id
string<uuid>

The service account this workspace role is assigned to.

workspace_id
string<uuid>

The workspace this role is assigned to.

role_id
string<uuid>

The role identifier.

role_name
string

The name of the role.

role_type
enum<string>

The type of the role.

Available options:
system_role,
access_role
granted_at
string<date-time>

ISO 8601 UTC.

granted_by
string<uuid>

The user who granted the workspace role.

Last modified on November 12, 2026