POSTFetch All Offers API
Use Case
To fetch merchant's all payment instrument based offers with Paytm.
Request Attributes
Head
Attribute | Description |
---|---|
requestId string optional | Unique reference ID which is given in request payload |
requestTimestamp string(15) optional | EPOCH timestamp of the time at which request is being sent. |
version string(4) optional | Version of the API. Example: v1 |
channelId string(3) mandatory | 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"
|
tokenType string mandatory | This is for the authentication method. • For SSO token authentication, the value is SSO. • For checksum authentication, the value is CHECKSUM. |
token string optional | • In case of tokenType SSO, Inputs could be SSO token value. • In case of tokenType CHECKSUM, Inputs could be CHECKSUM value. Note: Create the checksum using the body parameter of the request. |
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 |
Response Attributes
Head
Attribute | Description |
---|---|
requestId string | Unique reference ID for a transaction which is generated by merchant and sent in the request |
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 +
| |||||||||||||||||||||||||||
paymentOffers object | Payment offers contains promo details like promocode, offer, termsUrl, etc. | ||||||||||||||||||||||||||
PaymentOffers +
|
Response Codes & Messages
resultCode | resultStatus | resultMsg |
---|---|---|
00000000 | S | Success |
1001 | F | Request parameters are not valid. |
9999 | F | Something went wrong. |
2005 | F | Checksum provided is invalid. |
curl -X POST 'https://securestage.paytmpayments.com/theia/api/v1/fetchAllPaymentOffers?mid={mid}' \
--header 'Content-Type: application/json' \
--data '{"body":{"mid":"{mid}"},"head":{"channelId":"WEB","tokenType":"CHECKSUM","token":"{CHECKSUM}"}}'