---
title: "Creates AccessRole entity"
method: POST
path: "/v3/mesh/control-planes/{cpId}/access-roles"
tags: ["AccessRole"]
---

# Creates AccessRole entity

`POST /v3/mesh/control-planes/{cpId}/access-roles`

## Request

- Base URL: `https://global.api.konghq.com`
- URL: `https://global.api.konghq.com/v3/mesh/control-planes/{cpId}/access-roles`
- Auth: one of:
  - HTTP bearer
  - HTTP bearer
  - HTTP bearer
  - HTTP bearer

Creates a resource using the name in the body. An existing resource is never modified. Requires Kuma 3.0 or later.

## Path parameters

- `cpId` string, uuid, required

## Request body

- AccessRoleItem
  - `creationTime` string, date-time: Time at which the resource was created
  - `kri` string: Kuma Resource Identifier (KRI) of the given resource
  - `labels` object
  - `modificationTime` string, date-time: Time at which the resource was updated
  - `name` string, required
  - `rules` object[], nullable
    - `access` string[], nullable
    - `mesh` string
    - `names` string[], nullable
    - `types` string[], nullable
    - `when` object[], nullable
      - `dpToken` object
        - `tags` object[], nullable
          - `name` string
          - `value` string
      - `from` object
        - `targetRef` object
          - `kind` string
          - `labels` object
          - `name` string
      - `targetRef` object
        - `kind` string
        - `labels` object
        - `name` string
      - `to` object
        - `targetRef` object
          - `kind` string
          - `labels` object
          - `name` string
  - `type` string, required

## Response `201`

Successful response

- object
  - `warnings` string[]: warnings is a list of warning messages to return to the requesting Kuma API clients. Warning messages describe a problem the client making the API request should correct or be aware of.

## Other responses

- `400`: Invalid resource
- `409`: A resource with this identity already exists

## Changes

- **2026-12-03** `9c8d300657bd`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/kong/apis/konnect-api-beta/changes/v3/mesh/control-planes/:cpId/access-roles/post.md)

---

[API](https://skmtc.dev/kong/apis/konnect-api-beta.md) - [All operations](https://skmtc.dev/kong/apis/konnect-api-beta/llms.txt) - [OpenAPI document](https://skmtc.dev/kong/apis/konnect-api-beta/revisions/9c8d300657bd?raw)
