---
title: "Retrieve user count for role"
method: GET
path: "/api/v1/roles/{role_name}/users:count"
tags: ["Roles"]
---

# Retrieve user count for role

`GET /api/v1/roles/{role_name}/users:count`

Retrieves the total number of users currently assigned to the specified role within the environment. Use this endpoint to monitor role usage, enforce user limits, or understand the scope of role assignments. Provide the role's unique name as a path parameter, and the response will include the current user count for that role. This operation is read-only and does not modify any data or user assignments. The count reflects all users who have the role either directly assigned or inherited through organization membership. This information is useful for capacity planning, security auditing, or understanding the impact of role changes across your user base.

## Path parameters

- `role_name` string, required

## Response `200`

Successfully retrieved user count for the specified role. Returns the total number of users currently assigned to the role, including both direct assignments and inherited assignments.

- RolesGetRoleUsersCountResponse
  - `count` string, int64 — Number of users associated with the role

---

[API](https://skmtc.net/scalekit/apis/scalekit-api-reference.md) · [All operations](https://skmtc.net/scalekit/apis/scalekit-api-reference/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/scalekit/scalekit-api-reference/versions/a40d5d4650e5/schema)
