Users and Roles Management on the Anomali Platform
The endpoints described below can be used to establish and manage role-based access control on the Anomali platform.
Role Management
Use this endpoint to view, create, assign, update, and delete roles.
Request
/api/v1/user_role/
HTTP Methods: GET/PATCH/POST/DELETE
| Get a list of available permissions that can be assigned to a role | GET /api/v1/user_role/permissions |
| Get a list of all roles | GET /api/v1/user_role/Note: This request enables you to view details of all system and custom roles. |
| Get a list of custom roles | GET /api/v1/user_role/?type=user |
| Get a list of system roles (out-of-the-box roles) | GET /api/v1/user_role/?type=legacy |
|
Create a role (for Org Admins only) |
POST The request also requires you to specify values for the following properties in the payload:
For example, Copy
For the list of available permissions that can be added to a role, refer to Anomali Permissions. Note: The following permissions cannot be included in a custom role:
is_readonly, can_use_chat, can_see_api_key. To grant these permissions to users, the corresponding system roles must be assigned. To learn how to view the list of system roles, refer to Using System Roles. |
|
Assign roles to users (for Org Admins only) |
POST This request also requires you to specify values for the following parameters in the payload:
For example, Copy
|
| Update a custom role |
PATCH where The request also requires you to specify new values for the following role properties in the payload:
For the list of available permissions that can be added to a role, refer to Anomali Permissions. For example, Copy
|
|
Delete a role (for Org Admins only) |
DELETE where Note: System roles cannot be deleted.
|
Response
A response for the GET /api/v1/user_role/ request includes the objects properties that provide details about roles. The response sample below displays information about the rule_intel_creator role.
"objects": [
{
"created_ts": "2024-12-12T21:07:51.909567",
"id": 3011,
"match_filter": null,
"max_search_back": null,
"modified_ts": "2024-12-12T21:15:49.207885",
"name": "rule_intel_creator",
"permissions": [
"can_approve_intel",
"can_change_rules"
],
"resource_uri": "/api/v1/user_role/3011/",
"type": "user"
},
. ...
. ]
| Attribute | Description |
|---|---|
| created_ts | Time stamp of when the role was created. |
| id | ID of the role. |
| match_filter |
Eventlog filter applied to the role. Note: Requires a Security Analytics subscription. If you are a ThreatStream-only user, the parameter is always set to
null. |
| max_search_back |
Maximum search back range set for the role. Note: Requires a Security Analytics subscription. If you are a ThreatStream-only user, the parameter is always set to
null. |
| modified_ts | Time stamp of when the role was last modified. |
| name | Name of the role. |
| permissions | Permissions included in the role. |
User Management
Use this endpoint to view a list of users and their roles, add users to your organization and assign roles to them. For any other actions that you can take with this endpoint such as unlock a user account or delete a user, refer to User Administration.
Request
/api/v1/orgadmin/
HTTP Methods: GET/POST
|
Get a list of users and roles assigned to them (for Org Admins only) |
GET /api/v1/orgadmin/ |
|
Create a user and assign roles (for Org Admins only) |
POST /api/v1/orgadmin/This request also requires you to specify values for the following parameters in the payload:
For example, Copy |
Response
A response for the GET /api/v1/orgadmin/ request includes the objects properties that provide details about users and their roles.
The response sample below displays the details for the test@example.com user.
{
"objects": [
{
"avatar_s3_url": "",
"date_joined": "2020-10-27T21:03:25",
"date_password_changed": null
},
{
"avatar_s3_url": "",
"date_joined": "2025-05-22T19:23:50",
"date_password_changed": null,
"email": "test@example.com",
"is_active": true,
"is_locked": false,
"last_access_ts": "2025-06-25T05:57:31.215305",
"last_login": "2025-06-25T05:55:06.287563",
"must_change_password": false,
"name": "Test",
"next_password_change_ts": null,
"nickname": "",
"resource_uri": "/api/v1/orgadmin/999/",
"roles": [
{ "id": 12, "name": "Organization Administrator", "type": "legacy" },
{ "id": 7, "name": "API User", "type": "legacy" },
{ "id": 3155, "name": "test role again 2", "type": "user" },
{ "id": 3223, "name": "TopLogSources", "type": "user" },
{ "id": 14, "name": "MFA Exempt", "type": "legacy" }
],
"user_id": "725"
}
]
}
| Attribute | Description |
|---|---|
| avatar_s3_url | Path to the avatar. |
| date_joined | Time stamp of when the user was added to the organization. |
| date_password_changed | Time stamp of when the password was changed. |
| Email of the user. | |
| is_active | Whether the user account is active or not. If the user is active, the attribute is set to true. |
| is_locked | Whether the user account is locked or not. If the user account is locked, the attribute is set to true. |
| last_access_ts | Time stamp of when the user last accessed the Anomali platform. |
| last_login | Time stamp of when the user last logged in. |
| must_change_password |
Whether the user must change the password. If the user must change the password, the attribute is set to |
| next_password_change_ts | Time stamp of when the user will be forced to change their password. |
| nickname | Nickname of the user. |
| resource_uri | The endpoint for the user account. |
| roles | Roles assigned to the user. |
Managing SSO Security Group Mappings
Use this endpoint to view, create, update, and delete SSO security group mappings.
Request
/api/v1/ssopermission/
HTTP Methods: GET/POST/PATCH/DELETE
| Get a list of SSO security group mappings for a specific identity provider |
GET
|
| Create an SSO security group mapping | POST /api/v1/ssopermission/This request requires specifying values for following parameters in the payload:
For example, Copy |
| Update an SSO security group mapping |
PATCH where This request also requires specifying values for the following parameters in the payload:
For example, Copy
|
|
Delete an SSO security group mapping |
DELETE where |
Response
A response for the GET /api/v1/ssopermission/?identity_provider_id=<id> request includes the objects properties that provide details about SSO security groups and roles to which they are mapped.
The example below displays details for the 8x9x9f9t9w9sdf9pspdfg SSO security group and the roles mapped to it.
{
"objects": [
{
"group": "8x9x9f9t9w9sdf9pspdfg"
"id": 1692,
"identity_provider": "/api/v1/identity-provider/112/",
"idp_id": 159,
"resource_uri": "/api/v1/ssopermission/1692/",
"roles": [
{
"id": 4567,
"name": "Test",
"type": "user"
},
{
"id": 3238,
"name": "AnomaliRole_azure",
"type": "user"
}
]
}
]
}
| Attribute | Description |
|---|---|
| group | The UUID of the SSO security group. |
| id | ID of the SSO security group. |
| identity_provider | API of the identity provider to which the SSO security group belongs. |
| idp_id | ID of the identity provider. |
| resource_uri | URI to the SSO security group |
| roles | Roles mapped to the SSO security group. |
Anomali Permissions
Below is the list of permissions that can be added to a role. Permissions such as is_readonly, can_use_chat, can_see_api_key cannot be added to a role. To grant these permissions to users, the corresponding system roles must be assigned. To learn how to view the list of system roles, refer to Using System Roles.
| Permission | Type | Description |
|---|---|---|
| can_approve_intel | boolean | Enables a user to approve imported intelligence. |
| can_audit | boolean | Grants a user read-only access to all ThreatStream pages and settings. |
| can_change_rules | boolean | Enables a user to edit rules. |
| can_import_to_taxii_inbox | boolean | Enables a user to push data from TAXII clients to your ThreatStream TAXII server. |
| can_share_intelligence | boolean | Enables a user to create intelligence shared with the Anomali Community. This includes importing observables, creating Sandbox reports, as well as modifying tags and commenting on observables and Sandbox reports shared with the Anomali Community. |
| can_submit sandbox | boolean | Enables a user to submit malware to a sandbox for detonation. This privilege also applies to sandbox submissions made through phishing mailboxes. |
| can_use_match | boolean | Enables a user to access Anomali Security Analytics. |
| is_org_admin | boolean | Grant a user Org Admin privileges. |
| is_tfa_exempt | boolean | Makes a user exempt from multi-factor authentication. |
Examples
-
To get a list of users and roles assigned to them:
Copycurl 'https://api.threatstream.com/api/v1/orgadmin/' -H 'Authorization: apikey <username>:<api_key>' -
To get a list of roles:
Copycurl 'https://api.threatstream.com/api/v1/user_role/' -H 'Authorization: apikey <username>:<api_key>' -
To delete the role whose ID is 4:
Copycurl --request DELETE 'https://api.threatstream.com/api/v1/user_role/4/' -H 'Authorization: apikey <username>:<api_key>' -v -
Add a new user with the email johnhopkins@anomali.com and assign them the roles whose IDs are 7 and 9:
Copycurl --request POST --data '{"email": "johnhopkins@anomali.com", "roles": [7, 9]}' 'https://api.threatstream.com/api/v1/orgadmin/' -H 'Authorization: apikey <username>:<api_key>' -H 'Content-Type: application/json' -v -
Create the PlatformOrgAdmin role that includes the following permissions:
is_org_admin,is_tfa_exempt, andcan_use_match:Copycurl --request POST --data '{"name": "PlatformOrgAdmin", "permissions": ["is_org_admin", "is_tfa_exempt", "can_use_match"]}' 'https://api.threatstream.com/api/v1/orgadmin/' -H 'Authorization: apikey <username>:<api_key>' -H 'Content-Type: application/json' -v -
Map the SecAdminGroup SSO security group to the role whose ID is 6 and ID of the identity provider is 7:
Copycurl --request PATCH --data '{"group": "SecAdminGroup", "idp_id": 7, "roles": [6]}' 'https://api.threatstream.com/api/v1/orgadmin/' -H 'Authorization: apikey <username>:<api_key>' -H 'Content-Type: application/json' -v