---
title: "List roles"
method: GET
path: "/roles"
tags: ["Roles"]
---

# List roles

`GET /roles`

## Request

- Base URL: `https://public.escape.tech/v3`
- URL: `https://public.escape.tech/v3/roles`
- Auth: API key in header `X-ESCAPE-API-KEY`

List and search roles of the organization.

## Query parameters

- `cursor` string: The cursor to start the pagination from. Returned by the previous page response. If not provided, the first page will be returned.
- `size` integer: The number of items to return per page
- `search` string: Search term to filter roles by name

## Response `200`

OK

- object[]
  - `id` string, uuid, required: The id of the role
  - `name` string, required: The name of the role
  - `permissions` string[], required: The permissions of the role
  - `createdAt` string, date-time, required: The date and time the role was created
  - `bindings` object[], required: The bindings of the role
    - `id` string, uuid, required: The id of the role binding
    - `createdAt` string, date-time, required: The date and time the role binding was created
    - `roleId` string, uuid, required: The id of the role bound by the role binding
    - `projectId` string, uuid, nullable: The id of the project bound by the role binding
    - `userId` string, uuid, required: The id of the user bound by the role binding

## Other responses

- `400`: Pagination error

---

[API](https://skmtc.dev/escape/apis/escape-public-api.md) - [All operations](https://skmtc.dev/escape/apis/escape-public-api/llms.txt) - [OpenAPI document](https://skmtc.dev/escape/apis/escape-public-api/revisions/2eab35df40c7?raw)
