List the person's sessions your application signed in through
The person's signed-in devices that your application's live tokens were authorized in: device name and kind, approximate city, when each was last active, whether it is the one this token was authorized in, and whether the account has two-factor authentication on. Never an IP address or a user agent. Needs sessions; profile_section_hidden when your configuration hides the sessions section.
Authorization
oauth2 An OAuth2 access token issued through the authorization flow. Acts on a user's behalf, and reads only what that user's granted scopes disclose. A token whose user has since been deactivated or soft-deleted is rejected.
In: header
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
Error codes
Every error response carries one of these in its code field. Branch on the code, never on the detail text.
| Status | code |
|---|---|
| 401 | not_authenticated, authentication_failed |
| 403 | permission_denied |
| 404 | not_found, profile_section_hidden |
| 429 | rate_limited |
Before you run the sample
- Replace
ACCESS_TOKENwith your user's access token.
curl -X GET "https://example.com/api/v1/userinfo/sessions/"{ "sessions": [ { "city": "string", "device_kind": "string", "device_name": "string", "id": "1400000000000000000", "is_current": true, "last_active_at": "2019-08-24T14:15:22Z", "mfa_enabled": true } ]}The claims this access token discloses GET
Scoped to exactly what the user granted: `identity` unlocks email, the person's username in your organization and verification status; `profile` unlocks the consented profile claims, read from the person's profile with your organization. `sub` and `id` (the same value) are always present. Mirrors an OIDC userinfo endpoint and shares one implementation with `/o/userinfo/`, so the two can never answer differently for the same token.
Read one of the person's sessions GET
One session from the list, with its browser and operating system families, when it first signed in, its region and country, and your application on it. `session_not_found` for a session that is not one of the list's.