cURL
curl --request GET \
--url https://cockroachlabs.cloud/api/v1/roles/{user_id} \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN'{
"group_roles": [
{
"group_names": [
"<string>"
],
"role": {
"name": "BILLING_COORDINATOR",
"resource": {
"type": "ORGANIZATION",
"id": "<string>"
}
}
}
],
"roles": [
{
"name": "BILLING_COORDINATOR",
"resource": {
"type": "ORGANIZATION",
"id": "<string>"
}
}
]
}{
"code": 123,
"details": [
{
"@type": "<string>"
}
],
"message": "<string>"
}Get all role grants for a user, service account, or group
Get all role grants for a user, service account, or group by providing its ID in the user_id path parameter.
Can be used by the following roles assigned at the organization scope:
- ORG_ADMIN
- CLUSTER_ADMIN
- FOLDER_ADMIN
- AUDITOR
GET
/
api
/
v1
/
roles
/
{user_id}
cURL
curl --request GET \
--url https://cockroachlabs.cloud/api/v1/roles/{user_id} \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN'{
"group_roles": [
{
"group_names": [
"<string>"
],
"role": {
"name": "BILLING_COORDINATOR",
"resource": {
"type": "ORGANIZATION",
"id": "<string>"
}
}
}
],
"roles": [
{
"name": "BILLING_COORDINATOR",
"resource": {
"type": "ORGANIZATION",
"id": "<string>"
}
}
]
}{
"code": 123,
"details": [
{
"@type": "<string>"
}
],
"message": "<string>"
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
user_id is the ID of the user, service account, or group whose roles are being retrieved.

