POSTValidate API - EMI Subvention
Use Case
This api validates the dynamic conditions on the payment gateway page. Merchant needs to send one of the cacheCardtoken and cardNumber
Request Attributes
Head
Attribute | Description |
---|---|
channelId string(3) optional | The parameter value identifies the Channel for which API call is initiated. Possible values:
WEB
,
For websites, the value to be passed should be "WEB"
WAP
For Mobile websites/App, the value to be passed should be "WAP"
|
requestId string(32) mandatory | Unique reference ID for a transaction which is generated by merchant and sent in the request |
requestTimestamp string(15) mandatory | EPOCH timestamp of the time at which request is being sent. |
version string(4) mandatory | Version of the API. Example: v1 |
tokenType string mandatory | This is for authentication method. |
token string mandatory | For tokenType SSO, use SSO Token of Paytm User. |
Body
Attribute | Description | ||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
mid string(20) mandatory | Paytm provides MID as a unique identifier to each merchant. For your staging MID, click here. You get the production MID post the account activation. Example: INTEGR7769XXXXXX9383 | ||||||||||||||||||||||||||
planId string mandatory | ID of the plan | ||||||||||||||||||||||||||
items object mandatory | Item list sent for EMI For Item based only | ||||||||||||||||||||||||||
Items +
| |||||||||||||||||||||||||||
paymentDetails object mandatory | PaymentDetails | ||||||||||||||||||||||||||
PaymentDetails +
| |||||||||||||||||||||||||||
generateTokenForIntent boolean optional | It's value can be True or False. In case, the merchant wants to start the transaction, then it's value should be sent as True, else it's value should be sent as False. | ||||||||||||||||||||||||||
customerId string mandatory | Unique reference ID for every customer which is generated by merchant. Special characters allowed in CustId are @, ! ,_ ,$, | ||||||||||||||||||||||||||
cacheCardToken boolean conditional | Conditional (either of cacheCardToken or cardNumber should be present) | ||||||||||||||||||||||||||
subventionAmount string optional | Amount on which merchant wants to offer subvention/Amount eligible for subvention For Amount based only Example: 4000.00 | ||||||||||||||||||||||||||
price string optional | Total amount of the cart without any subvention being applied For Amount based only Example: 7000.00 | ||||||||||||||||||||||||||
offerId string mandatory | OfferId of the product | ||||||||||||||||||||||||||
cardTokenInfo object optional | Token data required to process a token transaction. | ||||||||||||||||||||||||||
cardTokenInfo +
|
Response Attributes
Head
Attribute | Description |
---|---|
requestId string | Unique reference ID for a transaction which is generated by merchant. |
responseTimestamp string(15) | EPOCH timestamp of the time at which response is being sent. |
version string(2) | Version of the API passed in the request. |
Body
Attribute | Description | ||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
resultInfo object | This parameter gives the information about the result of the API response | ||||||||||||||||||||||||||||||||||
ResultInfo +
| |||||||||||||||||||||||||||||||||||
planId string | ID of the plan | ||||||||||||||||||||||||||||||||||
pgPlanId string | Identified for the EMI plan. Its value will be in the form BANK_CODE|TENUREE | ||||||||||||||||||||||||||||||||||
emiType enum | Type of EMI. It's value can be SUBVENTION or STANDARD. | ||||||||||||||||||||||||||||||||||
emiLabel string | Label for EMI [Subvention, "Zero/Low Cost EMI", Standard EMI] | ||||||||||||||||||||||||||||||||||
rate string | Rate of interest in percentage for this EMI charged by bank. | ||||||||||||||||||||||||||||||||||
interval string | Interval of EMI in months e.g. 3, 6, 9, 12 etc. | ||||||||||||||||||||||||||||||||||
emi string | Effective EMI cost per month for the item. | ||||||||||||||||||||||||||||||||||
interest string | Interest amount for this EMI charged by bank. | ||||||||||||||||||||||||||||||||||
gratifications object | Gratitifications available on the plans. This field will be present for only subvention EMI plans. | ||||||||||||||||||||||||||||||||||
Gratifications +
| |||||||||||||||||||||||||||||||||||
itemBreakUpList object | Item wise breakUp of EMI and gratifications. | ||||||||||||||||||||||||||||||||||
ItemBreakUp +
| |||||||||||||||||||||||||||||||||||
bankId string | ID of the bank | ||||||||||||||||||||||||||||||||||
bankName string | Name of the bank to which card belongs. | ||||||||||||||||||||||||||||||||||
bankCode string | Bank code of the card (ICICI,SBI...) | ||||||||||||||||||||||||||||||||||
cardType string | Type of Card(CREDIT_CARD or DEBIT_CARD) | ||||||||||||||||||||||||||||||||||
bankLogoUrl string | URL for bank logo | ||||||||||||||||||||||||||||||||||
emiSubventionToken string | Token which is generated when merchant intends to do payment on the card of customer. This field is present in the response when generateTokenForIntent boolean in the request is 'True'. It will be needed to send in the initiateTransaction API request. | ||||||||||||||||||||||||||||||||||
finalTransactionAmount string | Amount that is returned after subvention is applied |
Response Codes & Messages
resultCode | resultStatus | resultMsg |
---|---|---|
0000 | S | Success |
0001 | F | FAILED |
1001 | F | Request prameters are not valid |
1007 | F | Missing mandatory element |
2006 | F | MID is invalid |
EMI_001 | F | Mandatory info is missing |
EMI_002 | F | Items's data is not valid |
EMI_003 | F | Items are empty |
EMI_004 | F | Some error occured. Please try later |
EMI_005 | F | Plans not available right now. Please try later |
EMI_006 | F | No emi options are available for these items |
EMI_007 | F | Invalid bank details |
EMI_008 | F | You are not eligible for availing EMI on this card |
EMI_009 | F | Selected plan does not exist |
EMI_010 | F | Selected plan is not eligible for these items |
EMI_011 | F | Selected plan details might have changed |
EMI_012 | F | Lock is acquired, please try after some time |
EMI_013 | F | Cards details are invalid |
EMI_014 | F | No subvented items found to be stamped |
EMI_015 | F | Order data could not be stamped. Please try again |
EMI_016 | F | Order item status could not be updated. Please try again |
EMI_017 | F | More than 2 retries are not allowed |
EMI_018 | F | EMI is not enabled on some items |
EMI_019 | F | Some of the selected offers are invalid |
EMI_020 | F | Selected plan is not offered by this bank |
curl -X POST 'https://securegw-stage.paytm.in/theia/api/v1/emiSubvention/validateEmi?mid={mid}' \
--header 'Content-Type: application/json' \
--data '{"body":{"items":[{"id":"ITEMID_98765","productId":"PRODUCTID_98765","brandId":"BRANDID_98765","categoryList":["Electronics"],"quantity":"1","price":"1000","verticalId":"PAYTM_EMI","isEmiEnabled":true,"offerDetails":{"offerId":"OFFERID_98765"}}],"mid":"{mid}","customerId":"CUST_001","planId":"PLANID_98765","paymentDetails":{"totalTransactionAmount":"1000","cardBin":"411111"},"generateTokenForIntent":true},"head":{"requestId":"REQUESTID_98765","token":"{checksum}","tokenType":"CHECKSUM"}}'