Storyden
Roles

Role Update Order

Update the global ordering of custom roles. The request body must include every non-default role identifier exactly once in the desired order of precedence.

PATCH/roles/order

Update the global ordering of custom roles. The request body must include every non-default role identifier exactly once in the desired order of precedence.

storyden-session<token>

In: cookie

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

curl -X PATCH "https://example.com/roles/order" \  -H "Content-Type: application/json" \  -d '{    "role_ids": [      "cc5lnd2s1s4652adtu50"    ]  }'
{
  "roles": [
    {
      "id": "cc5lnd2s1s4652adtu50",
      "createdAt": "2019-08-24T14:15:22Z",
      "updatedAt": "2019-08-24T14:15:22Z",
      "deletedAt": "2019-08-24T14:15:22Z",
      "misc": {},
      "name": "string",
      "colour": "string",
      "permissions": [
        "CREATE_POST"
      ],
      "meta": {}
    }
  ]
}
Empty
Empty
{
  "error": "string",
  "message": "string",
  "suggested": "string",
  "metadata": {}
}