post
/public_api/v1/rbac/set_user_role/
Required license: **Cortex Xpanse Expander**
Add or remove one or more users from a role.
CURL
curl -X POST \
-H "Accept: application/json" \
-H "Content-Type: application/json" -H "authorization: {{api_key}}" -H "x-xdr-auth-id: {{api_key_id}}" \
"https://api-}/public_api/v1/rbac/set_user_role/" \
-d '{
"request_data" : {
"role_name" : "role_name",
"user_emails" : [ "user_emails", "user_emails" ]
}
}'
Request headers
authorization
required
String
api-key
Example:
{{api_key}}
x-xdr-auth-id
required
String
api-key-id
Example:
{{api_key_id}}
Request
Body
required
request_data
required
Object
A dictionary containing the API request fields.
user_emails
optional
Array
of strings
List of one or more user emails of users you want to add to or remove from a role.
role_name
required
String
Name of the role you want to add a user to. Send an empty field to remove the user.
Responses