query · Module: Accounts · Requires accounts:read
Arguments
Returns
Role!
Errors
Errors are returned inerrors[], with the REST error object in extensions (type, code, param, request_id), using the codes in Conventions §9.
Documentation Index
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
query Role($id: ID!) {
role(id: $id) {
id
object
name
livemode
created
updated
scopes
built_in
}
}
{
"id": "role_1a2B3c"
}
{
"data": {
"role": {
"id": "role_1a2B3c",
"object": "role",
"name": "Example",
"livemode": true,
"created": 1791302400,
"updated": 1791302400,
"scopes": [
"example"
],
"built_in": true
}
}
}
Retrieve a Role
query Role($id: ID!) {
role(id: $id) {
id
object
name
livemode
created
updated
scopes
built_in
}
}
{
"id": "role_1a2B3c"
}
{
"data": {
"role": {
"id": "role_1a2B3c",
"object": "role",
"name": "Example",
"livemode": true,
"created": 1791302400,
"updated": 1791302400,
"scopes": [
"example"
],
"built_in": true
}
}
}
query · Module: Accounts · Requires accounts:read
| Argument | Type | Description |
|---|---|---|
id | ID! | The object’s ID. |
Role!
| Field | Type |
|---|---|
id | String! |
object | RoleObject! |
livemode | Boolean! |
created | Int! |
updated | Int |
name | String! |
scopes | [String!]! |
built_in | Boolean |
user_metadata | UserMetadata |
carrier_metadata | CarrierMetadata |
system_metadata | SystemMetadata |
errors[], with the REST error object in extensions (type, code, param, request_id), using the codes in Conventions §9.
query Role($id: ID!) {
role(id: $id) {
id
object
name
livemode
created
updated
scopes
built_in
}
}
{
"id": "role_1a2B3c"
}
{
"data": {
"role": {
"id": "role_1a2B3c",
"object": "role",
"name": "Example",
"livemode": true,
"created": 1791302400,
"updated": 1791302400,
"scopes": [
"example"
],
"built_in": true
}
}
}