Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

adding details to rest API calls for role updates #7234 #7254

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 8 additions & 2 deletions _security/access-control/api.md
Original file line number Diff line number Diff line change
Expand Up @@ -815,18 +815,24 @@ Creates, updates, or deletes multiple roles in a single call.
PATCH _plugins/_security/api/roles
[
{
"op": "replace", "path": "/role1/index_permissions/0/fls", "value": ["test1", "test2"]
"op": "replace", "path": "/role1/index_permissions/0/fls", "value": ["myfield*", "~myfield1"]
},
{
"op": "remove", "path": "/role1/index_permissions/0/dls"
},
{
"op": "add", "path": "/role2/cluster_permissions", "value": ["manage_snapshots"]
"op": "add", "path": "/role2/cluster_permissions/-", "value": {
"index_patterns": ["test_index"],
"allowed_actions": ["indices:data/read/scroll/clear"]
}
}
]
```
{% include copy-curl.html %}

You can use `-` to insert a new permission to the end of the array of permissions.
{: .note}

#### Example response

```json
Expand Down
Loading