Skip to Content
Omnibase

Create a role

POST
/api/v1/tenants/roles

Authorization

headerX-Session-Token<token>

Kratos session JWT token. Alternative to cookie authentication for non-browser clients.

Request Body

application/json
  1. body
permissions*array<>|null
role_name*string
Length1 <= length

Response Body

OK

application/json
  1. response
created_at*string
Formatdate-time
id*string
permissions*array<string>|null
role_name*string
template_id*string
tenant_id*string
updated_at*string
Formatdate-time
user_ids*array<string>|null
Example Request
curl -X POST 'https://api.omnibase.tech/api/v1/tenants/roles' \  -H 'Content-Type: application/json' \  -d '{  "permissions": [    "project:*#view",    "tenant#read"  ],  "role_name": "test_project_viewer"}'
Example Response
{  "created_at": "2019-08-24T14:15:22Z",  "id": "string",  "permissions": [    "string"  ],  "role_name": "string",  "template_id": "string",  "tenant_id": "string",  "updated_at": "2019-08-24T14:15:22Z",  "user_ids": [    "string"  ]}