Skip to main content

Get email link

The endpoint provides detailed information on the email link of a user.

HTTP request

GET https://$instanceId.id.nevis.cloud/nevis/api/v1/users/$userId/email-link

Parameters

ParameterInTypeRequired / OptionalDescription
instanceIdpathstringrequiredThe ID of your Identity Cloud instance
userIdpathstringrequiredThe ID of the user

Example request

Set the user ID.

userId=your-user-id-123
curl "https://$instanceId.id.nevis.cloud/nevis/api/v1/users/$userId/email-link" \
--header "Authorization: Bearer $accessKey"

HTTP response

On success

HTTP/1.1 200 is returned if the email link is found.

ParameterTypeDescription
personifiedLinkstringThe email link composed of a URL prefix and the hashed value of the ticket
typeenumThe type of the email link Values: invitation, passwordReset
createdstringThe date of the email link creation
lastModifiedstringThe date of the last email link modification; Initially equals the creation date
versionintegerThe version of the email link, used for optimistic locking
validity.fromstringThe start date of the email link validity period in ISO 8061 timestamp format YYYY-MM-DDThh:mm:ssZ
validity.tostringThe end date of the email link validity period in ISO 8061 timestamp format YYYY-MM-DDThh:mm:ssZ

Example response

{
"personifiedLink": "https://your-company.com/?passwordReset=6mQrI36AFVWyRTfv3KEEmETenxNtR4",
"created": "2021-11-30T14:18:18Z",
"lastModified": "2021-11-30T14:18:18Z",
"validity": {
"from": "2001-01-02T00:00:00Z",
"to": "2031-01-12T00:00:00Z"
},
"type": "passwordReset",
"version": 1
}

On missing user

HTTP/1.1 404 is returned with an error message if the user with the given userId is not found.

Example response

{
"error": "User with id: cdc891da-51ea-11ec-bf63-0242ac130002 cannot be found."
}

HTTP/1.1 404 is returned with an error message if an email link with the given userId is not found.

Example response

{
"error": "No email link found."
}

On failure

HTTP/1.1 401 is returned if the authorization fails due to an invalid access key.

HTTP/1.1 500 is returned if an unexpected error occurred.