/

to search

Introducing Setu Changelog Check it out ↗

#Check payment status

This is a generic payment status api, that accepts the id of the payment-link to show the status of the last payment done on the payment-link.

Staging hosthttps://umap.setu.co/api
MethodGET
Path/v1/merchants/payments/product-instances/{paymentLinkId}/last
HeadermerchantId
Authorization: Bearer <insert_token_here>. Generate this token using OAuth or JWT.

Content-Type—will be application/json
API referenceCheck payment status ↗
Sample response
{
"amount": 10000,
"createdAt": "2023-09-04T12:08:20+0530",
"currency": "INR",
"customerAccountType": "savings",
"customerVpa": "test-auto-tyvmm59i9b@pineaxis",
"id": "01ARZ3NDEKTSV4RRFFQ69G5FAV",
"merchantId": "01ARZ3NDEKTSV4RRFFQ69G5FAV",
"merchantReferenceId": "01ARZ3NDEKTSV4RRFFQ69G5FAV",
"merchantVpa": "test-auto-beibfev2oq@pineaxis",
"productInstanceId": "01ARZ3NDEKTSV4RRFFQ69G5FAV",
"reason": {
"code": "unable-to-fulfill-request",
"desc": "unable-to-fulfill-request",
"npciErrCode": "YG",
"npciErrDesc": "MERCHANT ERROR (PAYEE PSP)",
"npciRespCode": "YG",
"npciRespDesc": "MERCHANT ERROR (PAYEE PSP)"
},
"refId": "1240689979139556558",
"rrn": "124068997913",
"status": "initiated",
"txnId": "SETmBZkQOV0M7wyyP1V4PIFhRSzW5eSjmYI",
"txnNote": "testpay"
}

In the above response:

  • id is a unique ID that is associated with this payment and can be used to track it later.
  • reason object is only populated when there are errors from the NPCI.

#Check payment history

This is a generic payment status api, that accepts the id of the payment-link and returns 5 latest payments done on the payment-link.

This API can be useful to check the payments done on the payment-link that accept multiple payments.


Staging hosthttps://umap.setu.co/api
MethodGET
Path/v1/merchants/payments/product-instances/{paymentLinkId}/history
HeadermerchantId
Authorization: Bearer <insert_token_here>. Generate this token using OAuth or JWT.

Content-Type—will be application/json
API referenceCheck Payment History ↗
Sample response
{
"payments": [
{
"amount": 10000,
"createdAt": "2023-09-04T12:08:20+0530",
"currency": "INR",
"customerAccountType": "savings",
"customerVpa": "test-auto-tyvmm59i9b@pineaxis",
"id": "01ARZ3NDEKTSV4RRFFQ69G5FAV",
"merchantId": "01ARZ3NDEKTSV4RRFFQ69G5FAV",
"merchantReferenceId": "01ARZ3NDEKTSV4RRFFQ69G5FAV",
"merchantVpa": "test-auto-beibfev2oq@pineaxis",
"productInstanceId": "01ARZ3NDEKTSV4RRFFQ69G5FAV",
"reason": {
"code": "unable-to-fulfill-request",
"desc": "unable-to-fulfill-request",
"npciErrCode": "YG",
"npciErrDesc": "MERCHANT ERROR (PAYEE PSP)",
"npciRespCode": "YG",
"npciRespDesc": "MERCHANT ERROR (PAYEE PSP)"
},
"refId": "1240689979139556558",
"requestId": "cjqml1f2e5ocq2mesej0",
"rrn": "124068997913",
"status": "initiated",
"txnId": "SETmBZkQOV0M7wyyP1V4PIFhRSzW5eSjmYI",
"txnNote": "testpay"
},
{
"amount": 10000,
"createdAt": "2023-09-04T12:08:20+0530",
"currency": "INR",
"customerAccountType": "savings",
"customerVpa": "test-auto-tyvmm59i9b@pineaxis",
"id": "01ARZ3NDEKTSV4RRFFQ69G5FAV",
"merchantId": "01ARZ3NDEKTSV4RRFFQ69G5FAV",
"merchantReferenceId": "01ARZ3NDEKTSV4RRFFQ69G5FAV",
"merchantVpa": "test-auto-beibfev2oq@pineaxis",
"productInstanceId": "01ARZ3NDEKTSV4RRFFQ69G5FAV",
"reason": {
"code": "unable-to-fulfill-request",
"desc": "unable-to-fulfill-request",
"npciErrCode": "YG",
"npciErrDesc": "MERCHANT ERROR (PAYEE PSP)",
"npciRespCode": "YG",
"npciRespDesc": "MERCHANT ERROR (PAYEE PSP)"
},
"refId": "1240689979139556558",
"requestId": "cjqml1f2e5ocq2mesej0",
"rrn": "124068997913",
"status": "initiated",
"txnId": "SETmBZkQOV0M7wyyP1V4PIFhRSzW5eSjmYI",
"txnNote": "testpay"
}
]
}

Was this page helpful?