Zaakpay Express Checkout

Web Redirection flow

In Zaakpay Express Checkout Flow, you can easily integrate it with your website and start accepting online payment through various payment methods such as Credit and Debit Card, Net banking, UPI and Wallet.
Once the customer clicks on the payment button, It redirects to the Zaakpay Standard Checkout Page.

719

📘

Haven't created your account yet?

Please follow our Getting started guide.

Transact API

Purpose: This API can be used to initiate a transaction and redirect user to Zaakpay Express Checkout Page.

Environment details:

Request Type: POST
Endpoint: /api/paymentTransact/V8

Request Attributes

These Attributes are mentioned in the same order in which Zaakpay Payment Gateway calculates the checksum (Excluding checksum).

Fields DataType Mandatory Description
amount String Y Value should be in paisa. Min Value 100 & Max Value 10000000.
bankid String N For Net Banking, ID of selected bank. e.g. SBI
buyerAddress String N Max length 100 alphanumeric Street address of the buyer. (Part of billing address)
buyerCity String N Max length 30 alphabet, Min length 3. (Part of billing address).
buyerCountry String N Country of the buyer.
buyerEmail String Y Valid email address of the buyer. Should be unique for each user.
buyerFirstName String N Max length 30, alphanumeric characters, no special characters or dashes.
buyerLastName String N Max length 30, alphanumeric characters, no special characters or dashes. First name and last name cannot be same. Last Name on card.
buyerPhoneNumber String N Buyer’s landline or mobile phone number, numeric only, no dashes, no spaces. e.g. 123456778
buyerPincode String N Buyer’s pin/zip code. Can have numbers, spaces & hyphens (-) only ( Part of billing address ). e.g. 110092
buyerState String N State of the buyer. (Part of billing address). e.g. Delhi
currency String Y Curreny Values defined by Zaakpay. e.g. INR
isAutoRedirect String N Value should be True/False.
debitorcredit N Values must be netbanking/wallet/upi
bankid String N Value should be bankid. e.g. SBI
merchantIdentifier String Y Zaakpay’s unique alphanumeric merchant identifier. You can get it from Zaakpay dashboard.
merchantIpAddress String N buyer’s IP address as recorded by your website. e.g. 127.0.0.1
mode String N 1 digit only, Numeric. Value 1 = Domain check, 0=To skip Domain check.
orderId String Y Merchant's unique transaction identifier. Max Length should be 40 and must be unique per website. Note: Orderid should be an alphanummeric value. eg.ZAAK20170421.
product1Description String N Max length 100. Free text, alphanumeric.
product2Description String N Max length 100. Free text, alphanumeric.
product3Description String N Max length 100. Free text, alphanumeric.
product4Description String N Max length 100. Free text, alphanumeric.
productDescription String N Max length 100. Free text, alphanumeric. Text description of what you are selling. Atleast 1 product description is mandatory to show in the bill on payment page. e.g. name of book, name of mobile etc
productInfo JSON N To show Order Details with Offers on Checkout Page. e.g. productInfo= ""customizationField"":""Cashback"", ""listProduct"":[ ""description"":""Apollo Health Insurance"", ""cost"":""Rs.80,000.00"", ""customizationValue"":""Rs.8,123.00"" ], ""terms"":""Cashback will get credited inMobiKwik Wallet"".
purpose String N 1 digit only, Numeric. e.g. Value 0=Service, 1=Goods, 2=Auction, 3=Other
returnUrl String N Url where you want Zaakpay PG to post the response. This must be the domain(or a sub- domain of it).
shipToAddress String N Max length 30, alphanumeric. You may specify this only when buyer’s address is different from shipping address.
shipToCity String N Max length 30, minimum length 3 alphabet. Shipping address city.
shipToCountry String N Shipping address country.
shipToFirstname String N Max length 30, alphanumeric characters, no special characters or dashes.
shipToLastname String N Max length 30, alphanumeric characters, no special characters or dashes.
shipToPhoneNumber String N Shipping address landline or mobile phone number. Numeric only, no dashes,no spaces.
shipToPincode String N Shipping address pin/zip code. Can have Numbers 2-12 digits, Spaces and Hyphens (-)only.
shipToState String N Shipping address state
showMobile String N False:We show the full-fledged version unconditionally. DETECT:We do detection of the user Agent of the browser from which the request is sent & route accordingly. True: Only allowed, if PG represent mobile view. We show the mobile page unconditionally. missing/not sent: Same as DETECT (i.e. We do detection at our end ).
txnDate String N Transaction date in yyyy-mm-dd format. e.g. 1996-04-15
txnType String N Numeric: Zaakpay Checkout will show the tab on the payment page which corresponds to the txnType you provide. e.g. 1-All, 11- Card, 12- Net-Banking, 13- Wallets, 14- UPI, 15 - Only allow Credit Cards, 16 -Only allow Debit Cards, 17 - EZEClick, 18 - ATM+PIN, 19 - MasterPass, 20 - EMI.
paymentOptionTypes String N To display more than one payment options on the Checkout page corresponds to paymentOptionTypes provided. parameter can now have values 1,11,12,13,14,15,16 and be "_" underscore separated. e.g. 11_12.
zpPayOption String N Which Zaakpay Payment Gateway option have you used for this transaction. 1 digit only, numeric default value is 1. e.g. 0=on_zaakpay, 1=button_redirect, 2=widget_redirect, 3=api.
checksum String Y To be calculated on all request parameters that are posted to Zaakpay API.

Response Attributes

These are the Response Attributes of Zaakpay Payment Gateway. Response Checksum is calculated based on the below Attributes only.

Fields Description
orderId It is a unique transaction identifier for merchant.
responseCode It is a max 3 digits Zaakpay’s Response code. E.g. Response code 100 is for Successful transaction.
responseDescription It is a description of Zaakpay’s Response code. E.g. Description of Response code 100 is “The transaction was completed successfully”.
checksum Checksum calculated by Zaakpay on all response attributes.
amount Transaction Amount in paisa.
doRedirect True or False
paymentMode Mode of the Payment. E.g. "card"
cardId Unique number generated for card (to fetch the stored card)
cardScheme Visa, MasterCard etc.
cardToken Masked card number First 4 & Last 4 digits of card numbe. E.g. 4012 XXXX XXXX 1881.
bank Name of bank for card.
bankid for Net Banking, ID of selected bank
paymentmethod Payment Method ID for Card and Net Banking transactions. For Card transaction, payment Method ID starts with C and N for Net Banking. It is alphanumeric value with max length 6. First letter is C or N, followed by 5 digits max.
cardhashId Unique id for each card number used in transaction.
productDescription As Received with the Request
product1Description As Received with the Request
product2Description As Received with the Request
product3Description As Received with the Request
product4Description As Received with the Request
pgTransId Zaakpay Transaction ID
pgTransTime Zaakpay Transaction Date & Time

CheckSum Calculation

For both integrity & data-authenticity verification before sending data to the API. We use an algorithm HMAC SHA-256 to calculate the checksum.
Checksum is calculated on all request parameters that is posted to the API. We require data to be posted to Zaakpay server in the NVP (Name-Value Pairs) format.

To calculate the checksum please follow the process below:

  • Create a list of all parameters which you are passing to the API. String used in checksum calculation has a predefined sequence in which parameters are to be concatenated.
  • Create a concatenated string in alphabetical order of all data values in your list, with ampersand '&' at the end of each item with the parameter name. e.g.amount=amountvalue&buyerAddress=buyerAddressvalue&buyerEmail=buyerEmailvalue&merchantIdentifier=merchantIdentifiervalue&orderid=orderIdvalue&...
  • Calculate the checksum using the HMAC SHA-256 algorithm, the concatenated string as data and your generated secret key. Checksum String should be in the same order in which request parameters are posted.
  • The resulting checksum calculated should be posted to the Zaakpay API along with other data.

Note : The empty parameters are not to be used in the checksum calculation.

You can check the checksum string generated against the provided request parameters here. The secret key , returnUrl and currency were already configured for the sandbox environment.

📘

Want to simulate Zaakpay Express Checkout Flow?

Follow below steps to initiate the transactions.

Initiate Transaction

  1. Click on Transact API to make a test transaction. Please refer to the below Image.
  2. Insert Merchant Identifier and other fields on our Demo Page.
  3. Click on the "Pay Now" button to proceed with the transaction on Zaakpay.
  4. Use the Test Card details for our Staging Credentials and use live cards for our Live Environment.
  5. Zaakpay will post the response of the transaction to the provided return URL.

Please try your first staging transaction here along with checksum string generation against the provided request attributes.

🚧

Trying on Live Environment? Please keep the below point in mind.

  • Only Live Credentials will work on Live Environment, which you can generate from Zaakpay Dashboard.
  • Fill required details "Website URL" and "Redirect URL" in Zaakpay Dashboard and save it ("Developers">"Integration Urls").
  • Use Live cards for Live transactions.
  • For more details, Please refer to our FAQ.

Sample Request

This is the sample CURL request for reference. It takes required attributes only to initiate a transaction.

curl --location --request POST 'https://zaakstaging.zaakpay.com/api/paymentTransact/V8?amount=200&[email protected]&currency=INR&merchantIdentifier=fb2016ffd3a64b2994a6289dc2b671a4&orderId=ZPTest_1629007746215446&checksum=0606a7a82bd53d28ec97ba641c5f078776d6ebcf65e96e3c810294c21acb63cf' \
--header 'Cache-Control: no-cache' \
--header 'Postman-Token: c2376ff3-c001-4eeb-b828-ac3ebcc4d3b0' \
--header 'Cookie: JSESSIONID=C209398BAF749BB3935D44783B97C0A7'
amount=200&[email protected]&currency=INR&merchantIdentifier=fb2016ffd3a64b2994a6289dc2b671a4&orderId=ZPTest_1629007746215446&

Secret Key :
0678056d96914a8583fb518caf42828a

Generated Checksum : 0606a7a82bd53d28ec97ba641c5f078776d6ebcf65e96e3c810294c21acb63cf

❗️

Getting Error code: 182 "Merchant Data not complete in our database" ?

To resolve this error please follow the below steps:

  • Login to your Zaakpay account
  • Go to Developers tab > Select "Integration Urls"
  • Fill in "Website URL" and "Redirect URL"
  • Save the data. Initiate new test transaction.

Sample Response

This is a sample response of above transaction.

orderId	ZPTest_1629007746215446
responseCode	100
responseDescription	The transaction was completed successfully.
checksum	c8ad85f594f2c79e517715087405422b7bce125361dde65b49e4e8447607e8b9
amount	200
doRedirect	false
paymentMode	Wallet
cardId	NA
cardScheme	NA
cardToken	NA
bank	Mobikwik Wallet
bankid	MW
paymentMethod	N1053
cardhashid	NA
productDescription	NA
product1Description	NA
product2Description	NA
product3Description	NA
product4Description	NA
pgTransId	ZP5cd9a0435670f
pgTransTime	10/05/2021 17:48:19
txnData={
   "merchantIdentifier":"fb2016ffd3a64b2994a6289dc2b671a4",
   "txns":[
      {
         "amount":"200",
         "pgTransId":"ZP5cd9a0435670f",
         "orderId":"ZPTest_1629007746215446",
         "paymentMode":"Wallet",
         "cardScheme":"NA",
         "product3Description":"NA",
         "cardToken":"NA",
         "responseCode":"100",
         "bank":"Mobikwik Wallet",
         "bankid":"MW",
         "doRedirect":"false",
         "product1Description":"NA",
         "product4Description":"NA",
         "responseDescription":"The transaction was completed successfully. ",
         "cardId":"NA",
         "cardhashid":"NA",
         "paymentMethod":"N1053",
         "product2Description":"NA",
         "pgTransTime":"10\/05\/2021 17:48:19",
         "txnDate":"2021-10-05 17:48:20.354",
         "productDescription":"NA"
      }
   ]
}&checksum=5416275cc981e2508aee02d77994e13719603465b92df98b1a1b3ab26cd5c18a

👍

Final Response after Redirection

After completion of transaction, Zaakpay will redirect back to merchant’s returnUrl with the Response Attributes.

Response Checksum

Response Checksum will be calculated on all parameters in the same order as given below. Prepare checksum string by concatenating all param value with ampersand '&' at the end of each value with the parameter name. For Instance, Please refer to below Response Checksum String and Generated Checksum.

amount=200&bank=Mobikwik Wallet&bankid=MW&cardId=NA&cardScheme=NA&cardToken=NA&cardhashid=NA&doRedirect=false&orderId=ZPTest_1629007746215446&paymentMethod=N1053&paymentMode=Wallet&responseCode=100&responseDescription=The transaction was completed successfully. &productDescription=NA&product1Description=NA&product2Description=NA&product3Description=NA&product4Description=NA&pgTransId=ZP5cd9a0435670f&pgTransTime=10/05/2021 17:48:19&
c8ad85f594f2c79e517715087405422b7bce125361dde65b49e4e8447607e8b9

Zaakpay Payment Gateway Response codes

These are the transact API response codes. For more response code, Please download Zaakpay Express Checkout Flow Document Directly from here.

Response Code Response Description
100 The transaction was completed successfully.
101 Merchant not found. Please check your merchantIdentifier field.
102 Customer cancelled transaction.
103 Fraud Detected.
104 Customer Not Found.
105 Transaction details not matched.
106 IpAddress BlackListed.
107 Transaction Amount not in specified amount range.
108 Validation Successful.
109 Validation Failed.
110 MerchantIdentifier field missing or blank.
111 MerchantIdentifier Not Valid.
126 Date received with request was not valid.
127 ReturnUrl does not match the registered domain.
128 Order Id Already Processed with this Merchant.
129 OrderId field missing or blank.
130 OrderId received with request was not Valid.
131 ReturnUrl field missing or blank.
132 ReturnUrl received with request was not Valid
133 BuyerEmail field missing or blank.
134 BuyerEmail received with request was not Valid.
135 BuyerFirstName field missing or blank.
136 BuyerFirstName received with request was not Valid.
137 BuyerLastName field missing or blank.
138 BuyerLastName received with request was not Valid.
139 BuyerAddress field missing or blank.
140 BuyerAddress received with request was not Valid.
141 BuyerCity field missing or blank.
142 BuyerCity received with request was not Valid.
143 BuyerState field missing or blank
144 BuyerState received with request was not Valid.
145 BuyerCountry field missing or blank.
146 BuyerCountry received with request was not Valid.
147 BuyerPincode field missing or blank.
148 BuyerPinCode received with request was not Valid.
149 BuyerPhoneNumber field missing or blank.
150 BuyerPhoneNumber received with request was not Valid.
151 TxnType field missing or blank.
152 TxnType received with request was not Valid.
153 ZpPayOption field missing or blank.
154 ZpPayOption received with request was not Valid.
155 Mode field missing or blank.
156 Mode received with request was not Valid.
157 Currency field missing or blank.
158 Currency received with request was not Valid.
159 Amout field missing or blank.
160 Amount received with request was not Valid.
161 BuyerIpAddress field missing or blank.
162 BuyerIpAddress received with request was not Valid.
163 Purpose field missing or blank.
164 Purpose received with request was not Valid.
165 ProductDescription field missing or blank.
166 ProductDescription received with request was not Valid.
167 Product1Description received with request was not Valid.
168 Product2Description received with request was not Valid.
169 Product3Description received with request was not Valid.
170 Product4Description received with request was not Valid.
171 ShipToAddress received with request was not Valid.
172 ShipToCity received with request was not Valid.
173 ShipToState received with request was not Valid.
174 ShipToCountry received with request was not Valid.
175 ShipToPincode received with request was not Valid.
176 ShipToPhoneNumber received with request was not Valid.
177 ShipToFirstname received with request was not Valid.
178 ShipToLastname received with request was not Valid.
179 Date is blank.
179 Date received with request was not valid.
180 Checksum received with request is not equal to what we calculated.
181 Merchant Data Complete.
182 Merchant data not completed in our database.
183 Unfortunately, the transaction has failed.
400 The transaction was declined by the issuing bank.
401 The transaction was rejected by the acquiring bank.
402 This test transaction has been successfully completed.
403 Transaction failed because this card has been blocked by Zaakpay Payment Gateway.
404 Transaction failed due to security checks.
501 Debitorcredit is blank.
502 Bankid is blank.
503 Encrypted pan is blank.
504 Card is blank.
505 Nameoncard is blank.
506 Encrypted cvv is blank.
507 Encrypted expiry month is blank.

❗️

Transactions Failing on Live Environment?

  • Make sure you are using Live cards for Live Transactions.
  • For more details, Please refer to our FAQ.