Skip to main content
POST
Create role

Authorizations

Authorization
string
header
required

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

Body

application/json

Request body schema.

name
string
required

Display name for the role.

Required string length: 1 - 255
slug
string
required

Unique snake_case identifier for the role.

Required string length: 1 - 63
Pattern: ^[a-z0-9]+(_[a-z0-9]+)*$
color
enum<string>
required

Color shown as a dot next to the role name.

Available options:
orange,
red,
purple,
green,
yellow,
grey
permissions
Permissions · object[]
required

Permission grants for the role.

description
string

Optional description shown next to the role name.

Required string length: 1 - 1000

Response

Successful response

role
object
required