Authentication
Each API call will need to be authenticated by way of a merchantid issued by LatPay along with a key, which will be a SHA-256/SHA-512 hash of a set of post fields along with a predefined secret agreed between merchant & Latpay at the time of account setup.
Checkout Request#
Part A
In case of Checkout request, the authentication key is “merchantkey” which is a SHA-256 hash of the following parameters.
| Name | Description |
|---|---|
| amount# | Purchase amount – 2 decimal places |
| currency# | The 3 digit ISO currency code |
| deviceid# | a unique number assigned and linked to a specific point-of-sale (POS) terminal or workstation (Provided on account setup) |
| terminalsecret# | (Secret passphrase provided by merchant to Latpay during account setup) |
Sample:
Part B
In case of Checkout request, the authentication key is “authkey” which is a SHA-512 hash of the following parameters.
Sample:
Checkout Response#
Part A
In case of Checkout response, the authentication key is “responsekey” which is a SHA-256 hash of the following parameters.
| Name | Description |
|---|---|
| transactionid# | Unique id provided by Latpay |
| amount# | Purchase amount – 2 decimal places |
| currency# | The 3 digit ISO currency code |
| deviceid# | a unique number assigned and linked to a specific point-of-sale (POS) terminal or workstation (Provided on account setup) |
| responsesecret# | (Secret passphrase provided by Latpay to merchant during account release) |
Sample:
Part B
In case of Checkout response, the authentication key is “responsekey” which is a SHA512 hash of the following parameters.
Sample:
Reversal Request#
Part A
In case of Reversal request, the authentication key is “merchantkey” which is a SHA-256 hash of the following parameters.
When transactionid Posted
| Name | Description |
|---|---|
| transactionid# | Unique id provided by Latpay |
| amount# | Purchase amount – 2 decimal places |
| currency# | The 3 digit ISO currency code |
| deviceid# | A unique number assigned and linked to a specific point-of-sale (POS) terminal or workstation (Provided on account setup) |
| terminalsecret# | Secret passphrase provided by merchant to Latpay during account setup |
When transactionid Omitted
| Name | Description |
|---|---|
| amount# | Purchase amount – 2 decimal places |
| currency# | The 3 digit ISO currency code |
| deviceid# | A unique number assigned and linked to a specific point-of-sale (POS) terminal or workstation (Provided on account setup) |
| terminalsecret# | Secret passphrase provided by merchant to Latpay during account setup |
Sample:
Part B
In case of Checkout request, the authentication key is “authkey” which is a SHA-512 hash of the following parameters.
Sample:
Reversal Response#
Part A
Responsekey which is a SHA- 256 hash of the following parameters:
| Name | Description |
|---|---|
| transactionid# | Unique id provided by Latpay |
| amount# | Purchase amount – 2 decimal places |
| currency# | The 3 digit ISO currency code |
| deviceid# | a unique number assigned and linked to a specific point-of-sale (POS) terminal or workstation (Provided on account setup) |
| responsesecret# | (Secret passphrase provided by Latpay to merchant during account release) |
Sample:
Part B
In case of Checkout response, the authentication key is “responsekey” which is a SHA512 hash of the following parameters.
Sample:
Status Check Request#
In case of Status check request, the authentication key is “merchantkey” which is a SHA-256 hash of the following parameters.
When transactionid Posted
| Name | Description |
|---|---|
| transactionid# | Unique id provided by Latpay |
| amount# | Purchase amount – 2 decimal places |
| currency# | The 3 digit ISO currency code |
| deviceid# | A unique number assigned and linked to a specific point-of-sale (POS) terminal or workstation (Provided on account setup) |
| TerminalSecret# | Secret passphrase provided by merchant to Latpay during account setup |
When transactionid Omitted
| Name | Description |
|---|---|
| amount# | Purchase amount – 2 decimal places |
| currency# | The 3 digit ISO currency code |
| deviceid# | A unique number assigned and linked to a specific point-of-sale (POS) terminal or workstation (Provided on account setup) |
| TerminalSecret# | Secret passphrase provided by merchant to Latpay during account setup |
Sample:
In case of Checkout request, the authentication key is “authkey” which is a SHA-512 hash of the following parameters.
Sample:
Status Check Response#
Responsekey which is a SHA2 hash of the following parameters:
| Name | Description |
|---|---|
| transactionid# | Unique id provided by Latpay |
| accountid# | merchant account provided by Latpay |
| storeid# | unique id for each store (provided on account setup) |
| deviceid# | a unique number assigned and linked to a specific point-of-sale (POS) terminal or workstation (provided on account setup) |
| responsesecret# | secret passphrase provided by Latpay to merchant during account setup |
Sample:
In case of Checkout response, the authentication key is “responsekey” which is a SHA512 hash of the following parameters.
Sample:
Reversal Status Check Request#
Part A In case of Reversal Status check request, the authentication key is “merchantkey” which is a SHA-256 hash of the following parameters.
Part B
In case of Checkout request, the authentication key is “authkey” which is a SHA-512 hash of the following parameters.
Sample:
Reversal Status Check Response#
Responsekey which is a SHA2 hash of the following parameters:
In case of Checkout response, the authentication key is “responsekey” which is a SHA512 hash of the following parameters.
Sample:
3dsecureauth Request#
In case of 3dsecureauth request, the authentication key is “authkey” which is a SHA-512 hash of the following parameters.
Sample:
3dsecureauth Response#
In case of 3dsecureauth response, the authentication key is “responsekey” which is a SHA512 hash of the following parameters.
Sample:
HPS Refund request#
In case of Refund request, "transactionkey" is a SHA-256 hash of the following parameters.
HPS Refund Status Check#
In case of Refund status check request, "transactionkey" is a SHA-256 hash of the following parameters.
HPS Authstatuscheck#
In case of Authstatuscheck request, “transactionkey” is a SHA256 hash of the following parameters.
Sample:
HPS secure3DPayment#
In case of HPS secure3DPayment request, the authentication key is “transkey” which is a SHA256 hash of the following parameters.
**Sample:**