Getting identity information¶
You can get a list of identities and information for each. Or get information about a specific identity.
Method and URI¶
To get information about all identities, use a GET method and a URI:
GET https://{hostname|IP}/api/identity/user
To get information about a specific identity, use a GET method and a URI:
GET https://{hostname|IP}/api/identity/user/{identityUserId}
Tip
To get an {identityUserId}
value based on its name, follow the instructions in Getting an {identityUserId}.
Parameters¶
None.
Data¶
None.
Example 1: Get information about all identities¶
A Python snippet that is similar to the following example can be used to request a list of all identities and their information.
requests.get('https://' + spp_ipv4 + '/api/identity/user',
headers={...}, verify=...)

Figure 88 The same action can be taken in the IBM Spectrum Protect Plus web user interface: In the navigation pane, click Accounts > Identity.¶
The request prompts a response that is structured as shown, with the HTTP status of 200 (OK).
{
"links": {...},
"total": 3,
"users": [
{
"links": {...},
"resourceType": "user",
"id": "2101",
"name": "sarah-oracle1_10.4.4.1",
"username": "sarah-oracle1",
"type": "system",
"ostype": null,
"comment": null,
"keyid": null,
"realm": null,
"rbacPath": "root:0/identity:0/identitytype:credential/identitycreden
↪tial:2101",
"password": null
},
{
...
"id": "2102",
"name": "sarah.wiseman@bluemachines.com.invalid_10.0.0.10",
"username": "sarah.wiseman@bluemachines.com.invalid",
...
"realm": "@bluemachines.com.invalid",
"rbacPath": "root:0/identity:0/identitytype:credential/identitycreden
↪tial:2102",
...
},
{
...
"id": "2104",
"name": ".\\Administrator_hyperv.dallas.bluemachines.com.invalid",
"username": ".\\Administrator",
...
"realm": "\\ADMINISTRATOR",
"rbacPath": "root:0/identity:0/identitytype:credential/identitycreden
↪tial:2104",
...
},
{
...
"id": "2105",
"name": "serveradmin_localhost",
"username": "serveradmin",
...
"realm": null,
"rbacPath": "root:0/identity:0/identitytype:credential/identitycreden
↪tial:2105",
...
},
{...}, {...}, ..., {...}
]
}
Example 2: Get information about a specific identity¶
Assume that you added an identity, sarah-oracle1_10.4.4.1 ({identityUserId}
2101) to IBM Spectrum Protect Plus.
A Python snippet that is similar to the following example can be used to request information about this identity:
identity_user_id = "2101"
requests.get('https://' + spp_ipv4 + '/api/identity/user/' + identity_user_id,
headers={...}, verify=...)
The request prompts a response that is structured as shown, with the HTTP status of 200 (OK).
{
"links": {...},
"resourceType": "user",
"id": "2101",
"name": "sarah-oracle1_10.4.4.1",
"username": "sarah-oracle1",
"type": "system",
"ostype": null,
"comment": null,
"keyid": null,
"realm": null,
"rbacPath": "root:0/identity:0/identitytype:credential/identitycreden
01",
"password": null
},