Get passkeys
The endpoint provides functionality to get all passkeys for an existing user.
HTTP request
GET https://$instanceId.id.nevis.cloud/nevis/api/v1/users/$userId/passkeys?{queryParameters}
Parameters
Parameter | In | Type | Required / Optional | Description |
---|---|---|---|---|
instanceId | path | string | required | The ID of your Identity Cloud instance |
userId | path | string | required | The ID of the user |
limit | query | integer | optional | The maximum size limit of the token-based pagination results Default 1000 |
continuationToken | query | string | optional | The token to retrieve the next set of the token-based pagination results |
Example request
Set the ID of the user.
userId=your-user-id-123
curl --request GET "https://$instanceId.id.nevis.cloud/nevis/api/v1/users/$userId/passkeys?limit=10" \
--header "Authorization: Bearer $accessKey"
HTTP response
On success
HTTP/1.1 200
is returned on success
Parameter | Type | Description |
---|---|---|
items | array of passkeys | The collection of passkeys |
_pagination | object | The pagination object. For more information, see Token-based pagination. |
The items
array may contain one or more passkeys.
passkey
Parameter | Type | Description |
---|---|---|
userId | string | The ID of the user to whom the passkey belongs |
passkeyId | string | The ID of the passkey |
aaguid | string | A 128-bit identifier indicating the type (for example make and model) of the authenticator |
rpId | string | The domain of the party who uses this authentication for its website |
userAgent | string | The client application sends the userAgent when a passkey is registered or used for authentication. |
userFriendlyName | string | Human readable name of the userAgent |
stateName | enum | The state of the passkey Values: active ,invalid |
created | string | The date of the passkey creation |
lastModified | string | Date when the passkey was last modified |
version | integer | The version of the passkey, used for optimistic locking |
Example response
{
"items": [
{
"passkeyId": "9911629d-f212-41d3-94d6-4450a1a12259",
"userId": "1022ae0f-0125-4afc-ab69-c813e1b6b161",
"aaguid": "581bb990-7ea2-49d7-a826-760b1b219581",
"rpId": "your-company.com",
"userAgent": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/109.0.0.0 Safari/537.36",
"userFriendlyName": "Chrome on Linux",
"stateName": "active",
"version": 1,
"created": "2023-11-14T07:34:24Z",
"lastModified": "2023-11-14T07:34:24Z"
},
{
"passkeyId": "12ef04ee-2800-41d1-a230-cb55d59204a0",
"userId": "1022ae0f-0125-4afc-ab69-c813e1b6b161",
"aaguid": "d6e77b22-21c7-45a1-a2a0-7c5094de0ef9",
"rpId": "your-company.com",
"userAgent": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/109.0.0.0 Safari/537.36",
"userFriendlyName": "Chrome on Linux",
"stateName": "active",
"version": 1,
"created": "2023-11-15T08:34:24Z",
"lastModified": "2023-11-15T08:34:24Z"
}
],
"_pagination": {
"continuationToken": "2471467743000_a721ec6d-dcbf-4bcf-ac15-8ba7bba4135c",
"limit": 1000
}
}
On missing credential
HTTP/1.1 404
is returned if no user is found with the given userId
.
User is not found
{
"error": "User with id: 3eb1c041-c76b-4ae8-8307-db29b97d516a cannot be found."
}
On failure
HTTP/1.1 401
is returned if the authorization failed due to an invalid access key.
HTTP/1.1 422
is returned if invalid query parameters were given.
HTTP/1.1 500
is returned if an unexpected error occurred.