Menu
Create Access Rule
Create an Access Rule
POST
/accessUse it in a workflow
- Add a step and choose the Directus connector.
- Pick the Create Access Rule action (under Access).
- Fill in the fields below, then reference the result from later steps as
{{createAccessRule.response.data}}.
Request
Query parameters
Request body
Enter the body as JSON in the step's Body field.
{
"role": "00000000-0000-0000-0000-000000000000",
"user": "00000000-0000-0000-0000-000000000000",
"policy": "00000000-0000-0000-0000-000000000000",
"sort": 0
}
Response
Returns 200 with an object. Read it in later steps with {{createAccessRule.response.data.<field>}}.
{
"data": {
"id": "8cbb43fe-4cdf-4991-8352-c461779cec02",
"role": "8b4474c0-288d-4bb8-b62e-8330646bb6aa",
"user": "0bc7b36a-9ba9-4ce0-83f0-0a526f354e07",
"policy": "22640672-eef0-4ee9-ab04-591f3afb2886",
"sort": 1
}
}
Need more? See the Directus guide for connection setup and behaviour shared by every action.
Was this page helpful?