Check Status request is used for checking of payment status on orderReference.
The request is to be formed at the side of merchant and to be transferred through POST method to URL https://api.wayforpay.com/api
Request parameters:
Parameter | Description | Mandatory |
---|---|---|
transactionType | Type of request takes the value CHECK_STATUS | yes |
merchantAccount | Seller identifier | yes |
orderReference | Unique number of the order in merchant’s system | yes |
merchantSignature | Signature of the request | yes |
apiVersion | The protocol version. Default value: 1 Value 2 - include the transfer of advanced data - additional fields, delivery, comments. | yes |
For the purposes of confirmation of data validity there should be generated and transferred in the request the HMAC_MD5 control signature using SecretKey of merchant.
The line which subjects to HMAC_MD5 is generated through catenation of parameters merchantAccount, orderReference divided with “;” (semi-column) in coding UTF-8
Response parameters:
The line which subjects to HMAC_MD5 is generated through catenation of parameters merchantAccount, orderReference, amount, currency, authCode, cardPan, transactionStatus, reasonCode divided with “;” (semi-column) in coding UTF-8
Parameter | Description | Example |
---|---|---|
merchantAccount | Seller identifier | test_merchant |
orderReference | Unique number of the order in merchant’s system | 1212dd1 |
merchantSignature | hash_hmac |
|
аmount | Amount of order | 100 |
currency | Currency of order | UAH |
authCode | Authorization code - assigned by Bank | 324567 |
createdDate | Date of creation request in psp (UTC) | 123456789 |
processingDate | Date of transaction processing | 12345678 |
cardPan | Masked card number | 42****4242 |
cardType | Card Type: Visa/MasterCard | Visa |
issuerBankCountry | Country of card | 980 |
issuerBankName | Name of the issuer of the Bank Card | PrivatBank |
transactionStatus | Transaction status | Approved |
reason | Reason for refusal | Ok |
reasonCode | Code of refusal | 1100 |
settlementDate | Date for refund of transaction Merchant | 123456789 |
settlementAmount | Amount of settlement | 98.50 |
fee | Commission psp | 1.50 |
refundAmount | Amount of all refunds | 2.3 |
An example of request and response
{
"transactionType":"CHECK_STATUS",
"merchantAccount": "test_merch_n1",
"orderReference": "DH783023",
"merchantSignature": "b95932786cbe243a76b014846b63fe92",
"apiVersion": 1
}
{
"merchantAccount": "test_merch_n1",
"orderReference": "DH783023",
"merchantSignature":"b95932786cbe243a76b014846b63fe92",
"amount": "100",
"currency": "UAH",
"authCode": "221562",
"createdDate": 123456789,
"processingDate": 123456789,
"cardPan": "44****1212",
"cardType": "Visa",
"issuerBankCountry": "UA",
"issuerBankName": "PrivatBank",
"transactionStatus": "Approved",
"reason": "ok",
"reasonCode": "1100",
"settlementDate": "123456789",
"settlementAmount": 98.50,
"fee": 1.50
}