package example
import (
context "context"
management "github.com/auth0/go-auth0/management/management"
client "github.com/auth0/go-auth0/management/management/client"
option "github.com/auth0/go-auth0/management/management/option"
users "github.com/auth0/go-auth0/management/management/users"
)
func do() {
client := client.NewClient(
option.WithToken(
"<token>",
),
)
request := &users.ListUserRolesRequestParameters{
PerPage: management.Int(
1,
),
Page: management.Int(
1,
),
IncludeTotals: management.Bool(
true,
),
}
client.Users.Roles.List(
context.TODO(),
"id",
request,
)
}[
{
"id": "<string>",
"name": "<string>",
"description": "<string>"
}
]Retrieve detailed list of all user roles currently assigned to a user.
Note: This action retrieves all roles assigned to a user in the context of your whole tenant. To retrieve Organization-specific roles, use the following endpoint: Get user roles assigned to an Organization member.
package example
import (
context "context"
management "github.com/auth0/go-auth0/management/management"
client "github.com/auth0/go-auth0/management/management/client"
option "github.com/auth0/go-auth0/management/management/option"
users "github.com/auth0/go-auth0/management/management/users"
)
func do() {
client := client.NewClient(
option.WithToken(
"<token>",
),
)
request := &users.ListUserRolesRequestParameters{
PerPage: management.Int(
1,
),
Page: management.Int(
1,
),
IncludeTotals: management.Bool(
true,
),
}
client.Users.Roles.List(
context.TODO(),
"id",
request,
)
}[
{
"id": "<string>",
"name": "<string>",
"description": "<string>"
}
]Documentation Index
Fetch the complete documentation index at: https://auth0-feat-docs-5492.mintlify.app/llms.txt
Use this file to discover all available pages before exploring further.
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
ID of the user to list roles for.
Number of results per page.
1 <= x <= 100Page index of the results to return. First page is 0.
x >= 0Return results inside an object that contains the total result count (true) or as a direct array of results (false, default).
Cette page vous a-t-elle été utile ?