Create a role
Authentication
AuthorizationBearer
API session token from POST /v1/admin/session (8 hours). Sign-in itself is Google Workspace; see research R2.
Headers
Idempotency-Key
One key per user attempt; retries reuse it and get the original result.
Request
This endpoint expects an object.
name
permissions
Permission ID to level, using the IDs defined in the portal UI code, e.g. {“sub_manage”: “edit”, “sub_create”: “yes”}.
description
version
Version you last read. Omit on create; required on update. A stale value returns 409 version_conflict.
Response
Created
name
permissions
Permission ID to level, using the IDs defined in the portal UI code, e.g. {“sub_manage”: “edit”, “sub_create”: “yes”}.
id
Server-generated.
description
userCount
version
Version you last read. Omit on create; required on update. A stale value returns 409 version_conflict.
Errors
401
Unauthorized Error
403
Forbidden Error
422
Unprocessable Entity Error
429
Too Many Requests Error
500
Internal Server Error
503
Service Unavailable Error