Skip to content

Change a member of staff's console role

POST
/console/users/{id}/staff-role
curl --request POST \
--url https://example.com/console/users/example/staff-role \
--header 'Content-Type: application/json' \
--cookie bottle.session_token=<bottle.session_token> \
--data '{ "role": "support", "reason": "example" }'

Support, billing or owner, for somebody who is already staff, with the reason recorded. Console owners only, never on yourself, and never leaving the console without an owner. Making somebody staff, or taking it away, is still done on the box.

id
required
string
>= 1 characters
Media typeapplication/json
object
role
required
string
Allowed values: support billing owner
reason
required
string
>= 5 characters <= 500 characters

The person afterwards

Media typeapplication/json
object
id
required
string
email
required
string
name
required
string
emailVerified
required
boolean
twoFactorEnabled
required
boolean
createdAt
required
string format: date-time
lockedAt
required
string | null format: date-time
lockedReason
required
string | null
staffRole
required
string | null
Allowed values: support billing owner
memberships
required
Array<object>
object
tenantId
required

UUID v7

string format: uuid
tenantName
required
string
role
required

Owner: billing, deleting the tenant, full control of members. admin: all operational work and may manage drivers and admins. driver: their own round only.

string
Allowed values: owner admin driver
joinedAt
required
string format: date-time
lastSignInAt
required
string | null format: date-time
Example
{
"staffRole": "support",
"memberships": [
{
"tenantId": "019205d1-6e7a-7c3b-9f6e-3a2b1c0d9e8f",
"role": "owner"
}
]
}

Not signed in

Media typeapplication/json
object
error
required
string
message
required
string
Example
{
"error": "not_found",
"message": "Customer not found"
}

Not Bottle staff, no two-step sign-in, or a console role too low for this

Media typeapplication/json
object
error
required
string
message
required
string
Example
{
"error": "not_found",
"message": "Customer not found"
}

No such person

Media typeapplication/json
object
error
required
string
message
required
string
Example
{
"error": "not_found",
"message": "Customer not found"
}

Not on yourself, or not on staff without a console owner

Media typeapplication/json
object
error
required
string
message
required
string
Example
{
"error": "not_found",
"message": "Customer not found"
}

Validation failed

Media typeapplication/json
object
error
required
string
Allowed values: validation
message
required
string
issues
required
Array<object>
object
path
required
string
message
required
string
Example
{
"error": "validation",
"issues": [
{
"path": "email",
"message": "Invalid email"
}
]
}