---
title: "Returns a list of AccessRole in the mesh."
method: GET
path: "/v1/mesh/control-planes/{cpId}/api/access-roles"
tags: ["AccessRole"]
---

# Returns a list of AccessRole in the mesh.

`GET /v1/mesh/control-planes/{cpId}/api/access-roles`

## Query parameters

- `offset` integer
- `size` integer
- `filter` object
  - `key` string
  - `value` string

## Response `200`

List

- object
  - `items` AccessRoleItem[], nullable
    - `creationTime` string, date-time — Time at which the resource was created
    - `labels` object
    - `modificationTime` string, date-time — Time at which the resource was updated
    - `name` string, required
    - `rules` object[], nullable
      - `access` union[], nullable
        - union
          - string
          - integer
      - `mesh` string
      - `names` string[], nullable
      - `types` string[], nullable
      - `when` object[], nullable
        - `destinations` object
          - `match` object — Tags to match, can be used for both source and destinations
        - `dpToken` object
          - `tags` object[], nullable
            - `name` string
            - `value` string
        - `from` object
          - `targetRef` object
            - `kind` string
            - `mesh` string
            - `name` string
            - `tags` object
        - `selectors` object
          - `match` object — Tags to match, can be used for both source and destinations
        - `sources` object
          - `match` object — Tags to match, can be used for both source and destinations
        - `targetRef` object
          - `kind` string
          - `mesh` string
          - `name` string
          - `tags` object
        - `to` object
          - `targetRef` object
            - `kind` string
            - `mesh` string
            - `name` string
            - `tags` object
    - `type` string, required
  - `next` string, nullable — URL to the next page
  - `total` number, nullable — The total number of entities

---

[API](https://skmtc.net/kong/apis/konnect-api-beta.md) · [All operations](https://skmtc.net/kong/apis/konnect-api-beta/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/kong/konnect-api-beta/revisions/658ffb748f95/schema)
