Create Role
POST/roles/
Request
- application/json
- application/x-www-form-urlencoded
- multipart/form-data
Body
required
Array [
]
name stringrequired
Possible values: <= 255 characters
Role's name.
permissions
object[]
id stringrequired
Possible values: <= 255 characters
Textual identifier.
description stringnullable
Short description.
Body
required
Array [
]
name stringrequired
Possible values: <= 255 characters
Role's name.
permissions
object[]
id stringrequired
Possible values: <= 255 characters
Textual identifier.
description stringnullable
Short description.
Body
required
Array [
]
name stringrequired
Possible values: <= 255 characters
Role's name.
permissions
object[]
id stringrequired
Possible values: <= 255 characters
Textual identifier.
description stringnullable
Short description.
Responses
- 201
- 400
- 401
- 500
- application/json
- Schema
- Example (from schema)
Schema
Array [
]
id stringrequired
A unique Base58 value identifying this object.
name stringrequired
Possible values: <= 255 characters
Role's name.
permissions
object[]
id stringrequired
Possible values: <= 255 characters
Textual identifier.
name stringrequired
Possible values: <= 255 characters
Permission name.
custom booleanrequired
description stringnullable
Short description.
{
"id": "string",
"name": "string",
"permissions": [
{
"id": "string",
"name": "string"
}
],
"custom": true,
"description": "string"
}
- application/json
- Schema
- Example (from schema)
Schema
<field name> string[]
non_field_errors string[]
{
"<field name>": [
"Errors related to field <field name>."
],
"non_field_errors": [
"Errors not related to any field specific field."
]
}
- application/json
- Schema
- Example (from schema)
Schema
detail string
{
"detail": "Incorrect authentication credentials."
}
- application/json
- Schema
- Example (from schema)
Schema
detail string
{
"detail": "Unexpected error while handling your request."
}
Loading...