Get User Session Info using Bearer Token
This request gets information about the user session for the Bearer authToken included in the request headers, which was obtained using Initiate User Session using Key and Secret.
Authorizations: All
Requests
GET /apis/authentication/login/key
Response
Example:
{
"data": {
"admin": true,
"assets": {},
"authToken": "<auth token>",
"displayName": "User0Groups TheUser",
"groups": [],
"id": "d2be5490-f70e-4132-9570-d8a45d94204f",
"lastAction": "2025-03-21T19:20:01.099Z",
"lastLoginDate": "2025-03-21T17:29:07.272Z",
"provisionType": "jit",
"numLoginFailures": null,
"preferredUsername": "43ab703c-9a65-4c89-b005-daebc663590f",
"roleIds": ["912cf463-409a-4df0-89ff-68016b213c77"],
"roles": [
{
"id": "912cf463-409a-4df0-89ff-68016b213c77",
"name": "Administrator",
"admin": true,
"permissions": {}
}
],
"sections": {},
"sessionId": "2167935c-5633-4aad-a814-2279bc928944",
"sessions": {},
"sharePermissions": {},
"sources": {},
"username": "43ab703c-9a65-4c89-b005-daebc663590f",
"serviceMessages": [
"Password change required for built-in user account (operator)"
]
}
}
Caution
This data is informational only and subject to change in future HMP releases.
REST API developers are encouraged to check for a
200 OKstatus to verify that a session is valid, but otherwise ignore this response except for theauthTokenfield. REST API applications that use the data from this response may stop functioning and break user logins if this response is changed.
Error
Code | Payload | Description |
|---|---|---|
|
| User has no role assigned. |
|
| An internal error occurred. |
|
| Authentication service is unavailable. Please try again later. |