search
Your Paytm for business app is working and will keep working beyond March 15th, 2024. Click to know more

POSTFetch Link API

Use Case

This API can be used to get all links created as per the filters defined by the merchant. The merchant can filter by

  1. Date
  2. Link Status
  3. Link/Invoice ID
  4. Recipient Name
  5. Recipient Mobile
  6. Recipient Email

Request Attributes

Content Type : JSON

Head

AttributeDescription
timestamp
string(15)
optional

EPOCH timestamp of the time at which request is being sent.
Example: 1588402269

clientId
string(3)
optional

Paytm use the merchant key on the basis of clientId parameter value. It requires only if the merchant has more than one key.

Example: C11

version
string(4)
optional

Version of the API.

Example: v2

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 parameter identifies whether the API works on checksum authentication. The value to be sent in tokenType is 'AES' for this API.

signature
string(108)
mandatory

Paytm validates the request and ensures that parameters are not tempered by verifying the signature in the request. For creating the checksum (signature) refer to the steps given in Checksum Logic.
Note: Create the signature using the body parameter of the request.

Body

AttributeDescription
merchantRequestId
string
optional

Unique ID to be generated by merchant.

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

linkId
long
optional

Unique Identifier for each Link

pageNo
int
optional

Page Number

pageSize
int
optional

Page Size = Total Links/Total no. of Pages

searchFilterRequestBody
object
optional

Seach Filter Request 

SeachFilterRequest
+
AttributeDescription
fromDate
string
optional

Date From

toDate
string
optional

Date To

isActive
boolean
optional

Whether Link is Active or not.

linkTypeMultiple
array
optional

Link type

Possible Values: ["FIXED","GENERIC"]

linkDescription
string
optional

This is the link-description from which link can be fetched

customerName
string
optional

This is customerName from which link can be fetched

customerPhone
string
optional

This is customerPhone Number through which link can be fetched

customerEmail
string
optional

This is customerEmail through which link can be fetched

paymentStatus
string
optional

This is the payment status values which link can be fetched

Possible Values: PENDING, INIT, EXPIRED, PAID

invoiceId
string
optional

invoice number or unique id

resellerId
string
optional

Applicable for resellers. The ID will be shared at the time of onboarding.

Example: "Dipend011"

resellerName
string
optional

Name of the reseller

Example: "Automation"

Response Attributes

Content Type : JSON

Head

AttributeDescription
timestamp
string(15)

EPOCH timestamp of the time at which response is being sent.
Example: 1588402269

clientId
string(3)

Paytm use the merchant key on the basis of clientId parameter value. It requires only if the merchant has more than one key.

Example: C11

version
string

Version of the API passed in the request.
Example: v1

channelId
string(3)

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

This parameter identifies whether the API works on checksum authentication. The value to be sent in tokenType is 'AES' for this API.

signature
string(108)

Paytm validates the request and ensures that parameters are not tempered by verifying the signature in the request. For creating the checksum (signature) refer to the steps given in Checksum Logic.
Note: Create the signature using the body parameter of the request.

Body

AttributeDescription
resultInfo
object

This parameter gives the information about the result of the API response

ResultInfo
+
AttributeDescription
resultCode
string

This is the resultCode corresponding to a particular message and is returned to the merchant. It's maximum length is 64. The different result codes corresponding to this API are mentioned below.

resultStatus
string

This parameter indicates the status of API call.

 

Possible Values: SUCCESS, FAILED

resultMessage
string(256)

This parameter is the result message which contains information about the result.The different result messages corresponding to this API are mentioned below.
 

links
object

Details of the Links

Links
+
AttributeDescription
LinkID
long

Unique Link Identifier

merchantUniqueId
string

Unique Identifier sent by merchant

shortUrl
string

Smart Payment Link URL. This should be shared with the customer

linkName
string

Name as specified by the merchant at the time of Link creation

linkDescription
string

Description of Link as set by each merchant

linkType
string

Type of Link

amount
double

Link Amount

isActive
boolean

Is Link Active or not?

expiryDate
string

Link Expiry Date

merchantHtml
string

This can be used to create a ‘Pay with Paytm’ button on merchant App & Website. Please embed this HTML behind the button.

createdDate
string

Date & Time of Creation of the Link

status
string

Link Creation Status

NotificationDetails
object

Notification Details

NotificationDetails
+
AttributeDescription
customerName
string

Name of the Customer which will be sent in the notification message

contact
string

Contact Number of customer where the notification will be sent

notifyStatus
string

Status of the notification

timestamp
string

Unix Timestamp of the response

customerContact
object

Contact Details of Customer

shortUrl
string

Smart Payment Link URL. This should be shared with the customer

longUrl
string

Payment Link URL. Not to be shared with the customer

successfulPaymentCount
string

Total count of successful payment

isPartialPaymentEnabled
boolean

Partial payment is enabled or not

isPaymentFormAttached
boolean

Payment form is attached or not

linkNotes
string

Link notes

simplifiedSubvention
Object

Subvention Details

simplifiedSubvention
+
AttributeDescription
customerId
string

Customer id

selectPlanOnCashierPage
string

Display EMI subvention details on cashier page

subventionAmount
string

Amount on which subvention is applied.

items
Object

Items for subvention

items
+
AttributeDescription
verticalId
string

Vertical ID.

isEmiEnabled
string

EMI is enabled for the product or not.

isPhysical
string

State of the product sold.

quantity
string

Quantity of the product.

productId
string

Unique product identifier.

price
string

Cumulative price of the product.

brandId
string

Product brand identifier.

categoryList
List

Product category identifier.

model
string

Model id of the product.

merchantId
string

Merchant ID.

id
string

Unique identifier for the item.

simplifiedPaymentOffers
object

Object of Simplified Payment Offers.

simplifiedPaymentOffers
+
AttributeDescription
promoCode
string

Promo Code attached to the link

applyAvailablePromo
string

Returns if all available promos were applies

validatePromo
string

Return if validation be done during a transaction.

cartDetails
object

SKU detail on which the Promo Code has to be applied.

cartDetails
+
AttributeDescription
items
Array of Objects

List of items

items
+
AttributeDescription
id
string

Identified for every item generated by the merchant
Eg: “105”

amount
string

Price of the product
Eg:  "amount": “150”

productDetail
Object

Information to identify the item

productDetail
+
AttributeDescription
id
string

Product identifier configured in the bank offer
Eg:  "id": "123400232343411113e331"

Note: This is the same value as passed in model attribute of simplifiedSubvention object in initiateTransaction API.

 

brandId
string

Brand identifier configured in the bank offer
Eg:  "brandId": "1102" for Apple products

Note: Currently only numeric values are supported

 

categoryIds
Array of Strings

Category identified configured in the bank offer
Eg:  [ "521" ] for iPhones

Note: Currently only numeric values are supported

 

enablePaymentMode
array of objects

List of the payment modes which are enable on this link

enablePaymentMode
+
AttributeDescription
mode
string

Mode of payment enabled

channels
Array of strings

Channel associated with mode.

disablePaymentMode
Array of objects

List of the payment modes which are disabled on this link

disablePaymentMode
+
AttributeDescription
mode
string

Mode of payment disabled

channels
Array of strings

Channel associated with mode.

linkOrderId
string

The Unique reference ID of the Order associated with the link

singleTransactionOnly
boolean

Tells if single transaction allowed on this link (success or failed)

mid
string(20)

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

countLink
string

Count of Links as part of the result

Response Codes & Messages

resultCoderesultStatusresultMessage
200SUCCESSSuccess
404FAILEDData Not Found
501FAILEDInternal Server Error
502FAILEDUnknown Error Occurred
5004FAILEDempty merchant Id.
5028FAILEDChecksum provided is invalid.
5029FAILEDrequest body cannot be empty
5030FAILEDrequest head cannot be empty
Staging
Production
https://securegw-stage.paytm.in/link/fetchcopy icon
REQUEST
RESPONSE
CURL
JAVA
NODE
PHP
PYTHON
DOTNET
curl -X POST 'https://securegw-stage.paytm.in/link/fetch' \
--header 'Content-Type: application/json' \
--data '{"body":{"mid":"{mid}"},"head":{"tokenType":"AES","signature":"{signature}"}}'
copy icon