---
title: "List roles with pagination"
method: GET
path: "/os/v1/roles"
tags: ["Role"]
---

# List roles with pagination

`GET /os/v1/roles`

Returns a paginated list of roles for the company. Use `expand=company,positions` to load relations. When `externalCode` is set, the list is filtered to matching roles (case-insensitive). If none match, `data` is empty and `total` is 0.

## Query parameters

- `externalCode` string
- `page` number
- `maxPageSize` number
- `expand` string

## Response `200`

Roles retrieved successfully

## Other responses

- `400` — Bad Request - Invalid query parameters
- `401` — Unauthorized - Invalid or missing token
- `500` — Internal Server Error - Unexpected failure

---

[API](https://skmtc.net/gupy/apis/gupy-public-api.md) · [All operations](https://skmtc.net/gupy/apis/gupy-public-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/gupy/gupy-public-api/revisions/3f26defa2a42/schema)
