Authenticate Payer
  • 28 Aug 2023
  • 9 Minutes to read
  • Contributors
  • Dark
    Light
  • PDF

Authenticate Payer

  • Dark
    Light
  • PDF

Article summary

This message is used to process Authentication for mobile payments coming through the Mobile SDK channel. It doesn't perform any financial transaction and it's limited to authentication only. The outcome of this message indicates whether the authentication is friction-less or requires further authentication steps (Challenge mode).

You need to invoke the Mobile Payment or Mobile Pre-Auth after invoking this message and proceeding with any further authentication steps if required.  

It is based on the API Communication Model described in the Communication Model section. The merchant should handle the authentication process using 3DS Mobile SDK after invoking Authenticate Payer message and the returning ‘Response.StatusCode’ parameter is (20001) (Challenge).

If the returning ‘Response.StatusCode’  parameter is (00000), then no further authentication steps are required (friction-less).

This message is dedicated for credit card payments only and not suitable for Apple Pay or other payment methods.

Request Parameters

ParameterDescription
MessageID
required

An alphanumeric value that represents the action for defined unique numbers as mentioned below: 

  • 17 for Authenticate Payer
  • Field Type: Alphanumeric
  • Length: 2
  • Sample Data: 17
TransactionID
required

The merchant generates the Transaction ID. It represents a unique identifier for the transaction and is alphanumeric which must not include special characters or spaces.

  • Field Type: Alphanumeric
  • Length: 40
  • Sample Data: 1440954863817
MerchantID
required
An alphanumeric value that represents the unique Merchant ID at SmartRoute. The Payment Gateway operation team provides this value based on the merchant enrollment.
  • Field Type: Alphanumeric
  • Length: 40
  • Sample Data: MID0001

Amount
required
A numeric value that contains the ISO Formatted item purchase invoice amount with no decimal point. For example, 100 for 1.00 USD.
  • Field Type: Numeric
  • Length: 9
  • Sample Data: 100
CurrencyISOCode
required
A numeric value that contains the ISO formatted code for the currency, not the character value. For example, 840 for USD.
  • Field Type: Numeric 
  • Length: 3
  • Sample Data: 840
PaymentMethod
required
An Alphanumeric value indicates the payment method. It should be 1
indicating a Card Payment.
  • Field Type: Numeric 
  • Length: 1
  • Sample Data: 1
SecureHash
required
An alphanumeric value that represents the generated hex-encoded hash using hashing algorithm SHA-2 (256) by concatenating parameters as a single string starting with the merchant’s Merchant Authentication Token. Then all parameters (required parameters and optional parameters - if available) are ordered alphabetically. By parameter’s name should be part of the secure hash, with no separators and no terminating character.

Appendix B: Secure Hash – API Payment; for more information, see secure hash generation. 

  • Field Type: Alphanumeric
  • Length: 64
  • Sample Data: e9fbb3c46ec9c7dec2a318edc283bbbea27bc5d7bf7da30f4f2e62b89df74a2e

ClientIPaddress
required
An alphanumeric value that represents the client’s public IP Address.
  • Field Type: Alphanumeric
  • Length: 19
  • Sample Data: 79.183.118.666 
CardNumber
conditional
The customer’s card number to be used in the payment.

  • Field Type: Numeric
  • Length: 19
  • Sample Data: 4111111111111111
ExpiryDateYear
conditional
The customer’s card expiry date (year)digits that are used in the payment. The format of this parameter should be in the form (YY). 
  • Field Type: Numeric 
  • Length: 2
  • Sample Data: 17
ExpiryDateMonth
conditional
The customer’s card expiry date (month) digits are used in the payment. The format of this parameter should be in the form (MM).
  • Field Type: Numeric 
  • Length: 2
  • Sample Data: 02
SecurityCode
required
The customer’s card Security Code (e.g. CVV or CVC) depends on the Card Type used in the payment. 
  • Field Type: Numeric 
  • Length: 4
  • Sample Data: 123
AgreementID
conditional

The agreement Id represents a unique identifier for the agreement between the merchant and the payer where the payer authorizes the merchant to perform subsequent transactions (i.e. recurring) without their active participation. The subsequent transactions shall share the same agreement Id provided in this first transaction. The value is generated by the merchant and should be unique per recurring series. 

  • Field Type: Alphanumeric
  • Length: 20
  • Sample Data: 17b61316feafe09feb
Note:
The same value should be provided while performing a recurring payment across the recurring series for this payer.
AgreementType
conditional

Alphabetical value represents the type of subsequent transactions, if any, that will be initiated based on this first transactions.

Possible values are: 

  • Recurring 
  • Unscheduled
  • Other
  • Field Type: Alphanumeric
  • Length: N/A
  • Sample Data: Recurring
PaymentDescription 
optional

An alphanumeric string that contains a narrative Payment Description of the invoice, which uses the language specified in the language parameter. This value should be UTF-8 encoded. It is entered into the secure hash generation process. 

  • Field Type: Alphanumeric
  • Length: 100
  • Sample Data: SamplePayment
CardHolderName
conditional

The customer’s cardholder name is used in the payment.

  • Field Type: Alphabetic
  • Length: 64
  • Sample Data: Card Holder Name
ItemID
optional
An alphanumeric value that represents the custom item ID.
  • Field Type: Alphanumeric
  • Length: 25
  • Sample Data: Item1
Channel
required

The Channel to be used by SmartRoute System. It should be sent 3 in this message.

  • Field Type: Numeric
  • Length: 1
  • Sample Data: 3
Quantity
optional
A numeric value greater than ZERO represents the quantity of purchased Items.
  • Field Type: Numeric
  • Length: 5
  • Sample Data: 1
Version
optional

A numeric value with (.) separator represents the command's version to be used. If this value is not provided, SmartRoute will consider its default value which is 1.0

Possible version values:

-  2.0 or higher: an additional response field will be returned from SmartRoute to merchant that represents the payment method used "Response.PaymentMethod"

-  2.1 or higher: indicates that the merchant will provide the AgreementID and AgreementType fields.

  • Field Type: Numeric
  • Length: 5
  • Sample Data: 1.0
FrameworkInfo
required
An alphanumeric value that represents the client’s used framework
  • Field Type: Alphanumeric
  • Length: 30
  • Sample Data: Android 7.0
Token
optional
The token is used in this request; to represent previously used card information. This parameter is a part of the tokenization parameters. For more information, see Tokenization.
  • Field Type: Alphanumeric
  • Length: 64
  • Sample Data: 17b61316feafe09feb806ce33cdbfc85aed1b4173ed604f8fd5fa3cf72a02e27
AppID
required
A unique identifier for the app on the payer's device. The 3-D Secure SDK generates this identifier each time the app is installed or updated. This field corresponds to EMVCo field sdkAppID.

  • Field Type: Alphanumeric
  • Length: 36

SDKEncryptedData
required
Information about the payer's device collected and encrypted by the 3-D Secure SDK. The data is a JSON Web Encryption (JWE) object in JSON format.

This field corresponds to EMVCo field sdkEncData.

  • Field Type: Alphanumeric
  • Length: 64000
EphemeralPublicKey
required
A public key generated by the 3-D Secure SDK. This key is used to establish a secure session between the 3DS SDK and the issuer's Access Control Server (ACS) when the payer is required to be presented with an authentication challenge. The key is a JSON Web Key (JWK) object in JSON format.

This field corresponds to EMVCo field sdkEphemPubKey.

  • Field Type: Alphanumeric with Special characters
  • Length: 257
SDKReferenceNumber
required
An identifier of the vendor and version of the 3-D Secure SDK assigned by EMVCo

This field corresponds to EMVCo field sdkReferenceNumber.

  • Field Type: Alphanumeric
  • Length: 32
SDKTransactionID
required
A unique identifier assigned by the 3-D Secure SDK for the transaction.

This field corresponds to EMVCo field sdkTransID.

  • Field Type: Alphanumeric
  • Length: 32
SDKInterface
required
The User Interface (UI) formats that the payer's device supports. These are the formats that can be used to render the screens presented to the payer during an authentication challenge.

This field corresponds to EMVCo data element sdkInterface in the field deviceRenderOptions.
Possible Values:
  • NATIVE
  • HTML
UIType
optional
Indicates the UI types which the SDK supports for displaying authentication challenges within the app. A comma separated list of the payer authentication methods that you will accept for this payment.

This field corresponds to EMVCo data element sdkUiType in the field deviceRenderOptions.

  • Field Type: Alphanumeric
  • Length: 255
  • Sample Data: TEXT, MULTI_SELECT, SINGLE_SELECT 
ExtraFields
optional
A parameter which allows to send new parameters in CSV + JSON format

Example of usage: “ExtraField1”:”Value” , “ExtraField2”:”Value2”.

This filed will be implemented without an actual usage for it in the runtime, and is kept there for future purposes and used as per the need.

  • Field Type: Alphanumeric with Special characters
  • Length: 255


Response Parameters

ParameterDescription

Response.StatusCode 
required

An alphanumeric value that represents the response code that covers errors generated by the SmartRoute.  

Appendix A: API Payment Response Codes for descriptive details about Response Codes. 

  • Field Type: Alphanumeric
  • Length: 5
  • Sample Data: 00000
Response.StatusDescription 
required

An alphanumeric value that represents a message describing the response status received from SmartRoute. This parameter is filled only after a complete execution process using the language specified in the request. This value should be UTF-8 encoded when it is entered into the secure hash generation process.

  • Field Type: Alphanumeric
  • Length: 100
  • Sample Data: Payment processed successfully
Response.Amount
required

A numeric value that contains the purchase amount of the item.
The value is in ISO format with no decimal point. Also. For example, 100 for 1.00 USD.

  • Field Type: Numeric
  • Length: 9
  • Sample Data: 100
Response.CurrencyISOCode 
required

The numeric value is in ISO format for the currency. The value should be neither character value nor decimal point.

For example, 840 for US Dollar, 400 for JOD.

  • Field Type: Numeric
  • Length: 3
  • Sample Data: 840
Response.MerchantID 
required
An alphanumeric value that represents the unique ID of the merchant at SmartRoute. The SmartRoute operation team provides this value upon merchant enrollment. 
  • Field Type: Alphanumeric
  • Length: 40
  • Sample Data: MID0001
Response.TransactionID 
required
The merchant generates the Transaction ID. It represents a unique identifier for the transaction and is alphanumeric which must not include special characters or spaces.
  • Field Type: Alphanumeric
  • Length: 40
  • Sample Data: 201508180000001
Response.MessageID 
required

An alphanumeric value that represents the action for defined unique numbers as mentioned below: 

  • 17 for API Payment   
  • Field Type: Alphanumeric
  • Length: 2
  • Sample Data: 17
Response.SecureHash 
required

An alphanumeric value that represents the generated hex-encoded hash using hashing algorithm SHA-2 (256) by concatenating parameters as a single string starting with the merchant’s Merchant Authentication Token. Then all parameters (required parameters and optional parameters - if available) are ordered alphabetically. By parameter’s name should be part of the secure hash, with no separators and no terminating character.

Appendix B: Secure Hash – API Payment; for more information, see secure hash generation. 

  • Field Type: Alphanumeric
  • Length: 64
  • Sample Data:e9fbb3c46ec9c7dec2a318edc283bbbea27bc5d7bf7da30f4f2e62b89df74a2e 
Response.PaymentMethod  
conditional

An Alphanumeric value indicates the payment method. Supported values depend on the requested version as follows:  

  • Field Type: Alphanumeric
  • Length: 42
  • Sample Data: 1
Condition:
The SmartRoute operation team, upon merchant enrollment, provides possible Card Names.  
Response.GatewayStatusCode 
optional
An alphanumeric value that represents the gateway response code. This code covers errors generated by the chosen gateway. 
  • Field Type: Alphanumeric
  • Length: 15
  • Sample Data: 0000
Response.GatewayStatusDescription 
optional

An alphanumeric value that represents a message describing the response status received from the chosen gateway using the language specified in the request.

After completing the execution process, this parameter is filled in. This value should be UTF-8 encoded when it is entered into the secure hash generation process. 

  • Field Type: Alphanumeric
  • Length: 100
  • Sample Data: Sample Gateway Description 
Response.GatewayName 
optional
This value represents the gateway name that processed the transaction. It can be alphanumeric with special characters like space, ‘@’ and ‘_’.
  • Field Type: Alphanumeric and Some Special
  • Length: 40
  • Sample Data: TestGateway
Response.RRN 
optional
An alphanumeric value that represents a Receipt Reference Number for the current payment transaction. This value is returned if the value is provided from the gateway.
  • Field Type: Alphanumeric
  • Length: 60
  • Sample Data: 201508201600462840000000000
Response.ApprovalCode 
optional

Approval Code received from Payment Processor such as Visa. The values are returned in the following cases:

  • Only after a successful transaction
  • Value is provided from the gateway
  • Field Type: Alphanumeric
  • Length: 10
  • Sample Data: 12345678
Response.CardNumber 
optional
An alphanumeric value represents the masked Card Number.
  • Field Type: Alphanumeric
  • Length: 19
  • Sample Data: 4747******123
Response.Token 
optional
The token that is assigned to the entered card information; responds to a “GenerateToken” flag with the value “Yes”. This parameter is a part of the tokenization parameters; for more information, see Tokenization.
  • Field Type: Alphanumeric
  • Length: 64
  • Sample Data: 7b61316feafe09feb806ce33cdbfc85aed1b4173ed604f8fd5fa3cf72a02e27
Response.ThreeDServerTrxnID
conditional
The field contains the unique identifier assigned by the 3DS Server for this authentication. This is referred to in the EMVCo specification for 3-D Secure as threeDSServerTransID.

This field is returned in case of 3DS v.2 only.

  • Field Type: Alphanumeric
  • Length: 50
Response.ACSTrxnID
conditional
A unique transaction identifier assigned by the Access Control Server to identify the 3DS transaction.

This field is returned in case of 3DS v.2 only.

  • Field Type: Alphanumeric
  • Length: 36
Response.ChallengeContent 
conditional
Information provided by the issuer's Access Control Server (ACS) that is used to render the screens presented to the payer during an authentication challenge.

This field corresponds to EMVCo field acsSignedContent.

This field is returned in case of 3DS v.2 only.

  • Field Type: Alphanumeric with Special characters.
  • Length: 16384
Response.UIType
conditional
A comma separated list of the payer authentication methods that 3DS SDK will accept for this payment. Indicates the UI types which the SDK supports for displaying authentication challenges within the app.

This field corresponds to EMVCo data element sdkUiType in the field deviceRenderOptions.

This field is returned in case of 3DS v.2 only.

Value must be one or more comma separated members of the following list.
  • SINGLE_SELECT
  • MULTI_SELECT
  • OUT_OF_BAND
  • OTHER_HTML
Response.ChallengeCompletionUrl
conditional
This value is only returned when you authenticate the payer in-app using 3-D Secure authentication version 2 and a challenge is required. This URL must be called after the challenge has been completed; for example, when the ACS has confirmed the challenge completion. This allows the gateway to retrieve the authentication result after the challenge has been completed.

  • Field Type: Alphanumeric with Special characters.
  • Length: 1024
Response.SDKInterface
conditional
The User Interface (UI) formats that the payer's device supports. These are the formats that can be used to render the screens presented to the payer during an authentication challenge. It is retuned only for 3DS v2 when a challenge is required.

This field corresponds to EMVCo data element sdkInterface in the field deviceRenderOptions.

Possible Values:
  • HTML - The device supports HTML format. 
  • NATIVE - The device supports the UI format native to the payer's device.
Response.ACSRefNumber
conditional
Unique identifier assigned to the issuer's Access Control Server (ACS) by the EMVCo. It is retuned only for 3DS v2.

This field corresponds to EMVCo field acsRefNumber.

  • Field Type: Alphanumeric with Special characters.
  • Length: 32
Response.ChallengeRequired
conditional
An identifier which informs the merchant if this transaction requires a challenge (for 3DS v1 and 3DS v2).

Possible Values:
  • Y
  • N
Response.ThreeDSVersion
required
3DS Version as received from the Authentication process.

Possible Values:
  • 3DS1
  • 3DS2



What's Next