Skip to main content
POST
/
api
/
v1
/
roles
/
{role_name}
/
actions
Add action permission to a role
curl --request POST \
  --url https://services.pref.rio/heimdall-admin/api/v1/roles/{role_name}/actions \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "action_name": "user:read"
}'
{
  "status": "action_assigned",
  "role": "data_analyst:read",
  "action": "user:read"
}

Authorizations

Authorization
string
header
required

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

Path Parameters

role_name
string
required

Body

application/json

Request model for role-action operations.

action_name
string
required

Name of the action to assign/remove (lowercase letters, numbers, underscores, and colons only)

Example:

"user:read"

Response

Action permission added to role successfully

Response model for role-action operations.

status
string
required

Status of the operation

Example:

"action_assigned"

role
string
required

Role name

Example:

"data_analyst:read"

action
string
required

Action name

Example:

"user:read"