---
title: "Create a new RBAC Role Entity"
method: POST
path: "/{workspace}/rbac/roles/{RBACRoleIdForNestedEntities}/entities"
tags: ["RBACRoleEntities"]
---

# Create a new RBAC Role Entity

`POST /{workspace}/rbac/roles/{RBACRoleIdForNestedEntities}/entities`

Create a new RBAC Role Entity

## Path parameters

- `workspace` string, required

## Request body

- RBACRoleEntity
  - `actions` string[], required
  - `comment` string, nullable — Additional comment or description for the RBAC role entity.
  - `created_at` integer, nullable — Unix epoch when the resource was created.
  - `entity_id` string, nullable, required — The ID of the entity associated with the RBAC role.
  - `entity_type` string, nullable, required — The type of the entity associated with the RBAC role.
  - `negative` boolean, nullable — Indicates whether the RBAC role has negative permissions for the entity.
  - `role` object, nullable — The RBAC role associated with the entity.
    - `id` string
  - `updated_at` integer, nullable — Unix epoch when the resource was last updated.
  - `role_id` string, nullable

## Response `201`

Successfully created RBAC Role Entity

- RBACRoleEntity
  - `actions` string[], required
  - `comment` string, nullable — Additional comment or description for the RBAC role entity.
  - `created_at` integer, nullable — Unix epoch when the resource was created.
  - `entity_id` string, nullable, required — The ID of the entity associated with the RBAC role.
  - `entity_type` string, nullable, required — The type of the entity associated with the RBAC role.
  - `negative` boolean, nullable — Indicates whether the RBAC role has negative permissions for the entity.
  - `role` object, nullable — The RBAC role associated with the entity.
    - `id` string
  - `updated_at` integer, nullable — Unix epoch when the resource was last updated.
  - `role_id` string, nullable

## Other responses

- `401` — Unauthorized

---

[API](https://skmtc.net/kong/apis/kong-enterprise-admin-api.md) · [All operations](https://skmtc.net/kong/apis/kong-enterprise-admin-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/kong/kong-enterprise-admin-api/revisions/28b1f8a59cdc/schema)
