# Scenario 4: Integrator uses alternate methods to identify and validate Consumers
source: https://developer.mastercard.com/mastercard-checkout-solutions/tutorial/returninguser_unrecognized_ui/scenario-5/index.md

### Scenario 4: Integrator uses alternate methods to identify and validate Consumers {#scenario-4-integrator-uses-alternate-methods-to-identify-and-validate-consumers}

Mastercard recommends using [authenticate()](https://developer.mastercard.com/mastercard-checkout-solutions/documentation/sdk-reference/authenticate/authenticate_clicktopay/index.md) to seamlessly identify and authenticate unrecognized users across all Click to Pay systems. However, Integrators can also use the [initiateIdentityValidation()](https://developer.mastercard.com/mastercard-checkout-solutions/documentation/sdk-reference/initiate-id-validation/index.md), and [completeIdentityValidation()](https://developer.mastercard.com/mastercard-checkout-solutions/documentation/sdk-reference/complete-id-validation/index.md) methods to identify and validate consumers.

![Returning consumer on a new device](https://static.developer.mastercard.com/content/mastercard-checkout-solutions/documentation/images/clicktopay_unrecognizeduser_passkey4.png "Returning Consumer on a new device")

**Prerequisites:**   

* [Set the JavaScript library](https://developer.mastercard.com/mastercard-checkout-solutions/tutorial/integrate_apis/step2/index.md)  
* Follow the instructions in [Step 1](https://developer.mastercard.com/mastercard-checkout-solutions/documentation/use-cases/click-to-pay/repeatuser_newdevice/index.md#step-1-initialize-the-sdk-and-check-if-consumer-is-recognized)   

## Step 2: Identity Lookup and Initiate Identity Validation {#step-2-identity-lookup-and-initiate-identity-validation}

1. Consumer clicks on 'Checkout', and enters their email address, shipping address, or mobile number associated with Click to Pay, and then clicks on 'Continue'.

2. Call the [identityLookup()](https://developer.mastercard.com/mastercard-checkout-solutions/documentation/sdk-reference/identity-lookup/index.md) method of each participating SRC network to check if a specified Consumer Identity (email address or mobile phone number) is known to the Click to Pay System.

3. If consumer is known to one or more Click to Pay Systems, the `consumerPresent` and `lastUsedCardTimestamp` is returned to the Integrator to identify the SRC network with the details of the last used card.

4. Based on the last used card timestamp and `consumerPresent` response, Integrator calls the [initiateIdentityValidation()](https://developer.mastercard.com/mastercard-checkout-solutions/documentation/sdk-reference/initiate-id-validation/index.md) of the corresponding SRC network that has the last used card.

5. Mastercard sends a one-time-password (OTP) to the registered email address or mobile number. Consumer enters the OTP code sent to them on the DPA screen, provides the consent to be remembered on a device/browser, and clicks on 'Continue'.

6. Collect the consent details in [complianceSettings](https://developer.mastercard.com/mastercard-checkout-solutions/documentation/sdk-reference/common-objects/index.md#compliance-settings) object that captures the consent to provide faster checkouts in the future.

Diagram repeateduser_newdevice_lookup_2

## Step 3: Complete Identity Validation {#step-3-complete-identity-validation}

1. Call the [completeIdentityValidation()](https://developer.mastercard.com/mastercard-checkout-solutions/documentation/sdk-reference/complete-id-validation/index.md) method of the same SRC network (identified in the above step) to complete the validation of a Consumer Identity, by evaluating the supplied OTP.

   > If the consumer enters an incorrect OTP multiple times, their account can be temporarily locked: the **completeIdentityValidation** call will receive an [error response](https://developer.mastercard.com/mastercard-checkout-solutions/documentation/sdk-reference/complete-id-validation/index.md). In such a scenario, the consumer will receive a notification about the temporary account lock via an email or mobile number from the Click to Pay system. If the consumer's account is locked, the Integrator should provide an alternative way for the consumer to complete checkout.
2. If the consumer validation is successful, the Click to Pay System returns the [federated ID token](https://developer.mastercard.com/mastercard-checkout-solutions/documentation/sdk-reference/is-recognized/index.md#id-token) and the [recognition token](https://developer.mastercard.com/mastercard-checkout-solutions/documentation/support/index.md#click-to-pay) which you should secure for future recognized checkouts.

3. Call the [getSrcProfile()](https://developer.mastercard.com/mastercard-checkout-solutions/documentation/sdk-reference/get-src-profile/index.md) and provide the federated ID token to individual SRC networks to fetch the card list. The [getSrcProfile()](https://developer.mastercard.com/mastercard-checkout-solutions/documentation/sdk-reference/get-src-profile/index.md) method takes the list of [federated ID(idTokens)](https://developer.mastercard.com/mastercard-checkout-solutions/tutorial/integrate_apis/step4/index.md) and returns Click to Pay profile data to the Integrator along with the `srcCorrelationId`. Where required, the same `srcCorrelationId` must be used in the JS method/API calls for that transaction to link the calls together.

4. Retrieve and display the masked consumer details and masked card details stored with this Click to Pay profile on different Click to Pay Systems.

Diagram repeateduser_newdevice_completevalidation_2
