permissions
Set role permissions
Atomically replaces all permissions directly assigned to a role. An empty permissions array removes every permission from the role. Permissions that do not exist are created when the caller has permission to create them.
Required Permissions
Your root key must have:
- rbac.*.add_permission_to_role
- rbac.*.remove_permission_from_role
When any requested permission slug does not exist, it must also have:
- rbac.*.create_permission
post/v2/permissions.setRolePermissions
Request body
Example request
{
"roleId": "proj_1234abcd"
}Response
Permissions set successfully.
Example response
{
"meta": {
"requestId": "req_123"
},
"data": [
{
"id": "perm_1234567890abcdef",
"name": "users.read",
"slug": "users-read",
"description": "Allows reading user profile information and account details"
}
]
}