Skip to main content
GET
/
v2
/
requestable-roles
List Requestable Roles
curl --request GET \
  --url https://public.api.serval.com/v2/requestable-roles \
  --header 'Authorization: Bearer <token>'
{
  "data": [
    {
      "role": {
        "id": "<string>",
        "resourceId": "<string>",
        "name": "<string>",
        "description": "<string>",
        "requestsEnabled": true,
        "accessPolicyId": "<string>",
        "provisioningMethod": {
          "builtinWorkflow": {}
        },
        "externalId": "<string>",
        "externalData": "<string>"
      },
      "accessPolicy": {
        "id": "<string>",
        "teamId": "<string>",
        "name": "<string>",
        "description": "<string>",
        "maxAccessMinutes": 123,
        "requireBusinessJustification": true,
        "recommendedAccessMinutes": 123
      }
    }
  ],
  "nextPageToken": "<string>"
}

Documentation Index

Fetch the complete documentation index at: https://docs.serval.com/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Query Parameters

teamId
string
required

The ID of the team. Required.

targetUserId
string

The ID of the user to check requestable roles for. Defaults to the authenticated user if omitted.

pageSize
integer<int32>

Maximum number of results to return. Default is 100, maximum is 1000.

pageToken
string

Token for pagination. Leave empty for the first request.

Response

Success

data
RequestableRole · object[]

The list of requestable roles with their access policies.

nextPageToken
string | null

Token for retrieving the next page of results. Empty if no more results.