Skip to main content
GET
/
roles
/
{id}
/
users
TypeScript
import { ManagementClient } from "auth0";

async function main() {
    const client = new ManagementClient({
        token: "<token>",
    });
    await client.roles.users.list("id", {
        from: "from",
        take: 1,
    });
}
main();
[
  {
    "user_id": "<string>",
    "picture": "<string>",
    "name": "<string>",
    "email": "john.doe@gmail.com"
  }
]

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

id
string
required

ID of the role to retrieve a list of users associated with.

Query Parameters

per_page
integer

Number of results per page. Defaults to 50.

Required range: 1 <= x <= 100
page
integer

Page index of the results to return. First page is 0.

Required range: x >= 0
include_totals
boolean

Return results inside an object that contains the total result count (true) or as a direct array of results (false, default).

from
string

Optional Id from which to start selection.

take
integer

Number of results per page. Defaults to 50.

Required range: 1 <= x <= 100

Response

Role users successfully retrieved.

user_id
string

ID of this user.

picture
string

URL to a picture for this user.

name
string

Name of this user.

email
string<email>
default:john.doe@gmail.com

Email address of this user.