Fetch Payments for an Order
GET/v1/orders/:id/paymentsClick to copy
Use this endpoint to fetch all the payments made for an order. The response contains all the authorised or failed payments for that order.
Is this page helpful?
Curl
change language
change language
1curl -u [YOUR_KEY_ID]:[YOUR_KEY_SECRET]\23-X GET https://api.razorpay.com/v1/orders/order_DaaS6LOUAASb7Y/payments \
Success
1{2"entity":"collection",3"count":2,4"items":[5{6"id":"pay_N8FUmetkCE2hZP",7"entity":"payment",8"amount":100,9"currency":"MYR",10"status":"failed",11"order_id":"order_N8FRN5zTm5S3wx",12"invoice_id":null,13"international":false,14"method":"fpx",15"amount_refunded":0,16"refund_status":null,17"captured":false,18"description":null,19"card_id":null,20"bank":"HSBC",21"wallet":null,22"email":"nur.aisyah@example.com",23"contact":"+6026901125",24"notes":{25"notes_key_1":"Tea, Earl Grey, Hot",26"notes_key_2":"Tea, Earl Grey… decaf."27},28"fee":null,29"tax":null,30"error_code":"BAD_REQUEST_ERROR",31"error_description":"Payment was unsuccessful due to a temporary issue. If amount got deducted, it will be refunded within 5-7 working days.",32"error_source":"gateway",33"error_step":"payment_response",34"error_reason":"payment_failed",35"acquirer_data":{36"auth_code":null37},38"created_at":170168868439},40{41"id":"pay_N8FVRD1DzYzBh1",42"entity":"payment",43"amount":100,44"currency":"MYR",45"status":"captured",46"order_id":"order_N8FRN5zTm5S3wx",47"invoice_id":null,48"international":false,49"method":"fpx",50"amount_refunded":0,51"refund_status":null,52"captured":true,53"description":null,54"card_id":null,55"bank":"HSBC",56"wallet":null,57"email":"siti.aisyah@example.com",58"contact":"+6026901126",59"notes":{60"notes_key_1":"Tea, Earl Grey, Hot",61"notes_key_2":"Tea, Earl Grey… decaf."62},63"fee":2,64"tax":0,65"error_code":null,66"error_description":null,67"error_source":null,68"error_step":null,69"error_reason":null,70"acquirer_data":{71"auth_code":null72},73"created_at":170168872174}75]76}
Path Parameters
id *
stringUnique identifier of the order for which the payments should be retrieved.
Response Parameters
idstringUnique identifier of the payment.
entitystringIndicates the type of entity.
amountintegerThe payment amount in currency subunits. For example, for an amount of RM 1.00 enter 100.
currencystringThe currency in which the payment is made.
statusstringThe status of the payment. Possible values:
createdauthorizedcapturedrefundedfailed
methodstringThe payment method used for making the payment. Possible values:
cardwalletfpx
order_idstringOrder id, if provided. Know more about
.descriptionstringDescription of the payment, if any.
internationalbooleanIndicates whether the payment is done via an international card or a domestic one. Possible values:
true: Payment made using international card.false: Payment not made using international card.
refund_statusstringThe refund status of the payment. Possible values:
nullpartialfull
amount_refundedinteger The amount refunded in currency subunits. For example, if amount_refunded = 100, it is equal to RM 1.00.
capturedbooleanIndicates if the payment is captured. Possible values:
true: Payment has been captured.false: Payment has not been captured.
emailstringCustomer email address used for the payment.
contactstringCustomer contact number used for the payment.
feeintegerFee (including tax) charged by us.
taxintegerTax charged for the payment.
error_codestring Error that occurred during payment. For example, BAD_REQUEST_ERROR.
error_descriptionstring Description of the error that occurred during payment. For example, Payment processing failed because of incorrect OTP.
error_sourcestring The point of failure. For example, customer.
error_stepstring The stage where the transaction failure occurred. The stages can vary depending on the payment method used to complete the transaction. For example, payment_authentication.
error_reasonstring The exact error reason. For example, incorrect_otp.
notesjson objectContains user-defined fields, stored for reference purposes.
created_atintegerTimestamp, in UNIX format, on which the payment was created.
card_idstringThe unique identifier of the card used by the customer to make the payment.
walletstring The name of the wallet used by the customer to make the payment. For example, payzapp.
acquirer_dataarrayA dynamic array consisting of a unique reference numbers.
Show child parameters (3)
bankstring The 4-character bank code which the customer's account is associated with. For example, UTIB for Axis Bank.
Fetch Payments for an Order
GET/v1/orders/:id/paymentsClick to copy
Use this endpoint to fetch all the payments made for an order. The response contains all the authorised or failed payments for that order.
Is this page helpful?
Path Parameters
id *
stringUnique identifier of the order for which the payments should be retrieved.
Response Parameters
idstringUnique identifier of the payment.
entitystringIndicates the type of entity.
amountintegerThe payment amount in currency subunits. For example, for an amount of RM 1.00 enter 100.
currencystringThe currency in which the payment is made.
statusstringThe status of the payment. Possible values:
createdauthorizedcapturedrefundedfailed
methodstringThe payment method used for making the payment. Possible values:
cardwalletfpx
order_idstringOrder id, if provided. Know more about
.descriptionstringDescription of the payment, if any.
internationalbooleanIndicates whether the payment is done via an international card or a domestic one. Possible values:
true: Payment made using international card.false: Payment not made using international card.
refund_statusstringThe refund status of the payment. Possible values:
nullpartialfull
amount_refundedinteger The amount refunded in currency subunits. For example, if amount_refunded = 100, it is equal to RM 1.00.
capturedbooleanIndicates if the payment is captured. Possible values:
true: Payment has been captured.false: Payment has not been captured.
emailstringCustomer email address used for the payment.
contactstringCustomer contact number used for the payment.
feeintegerFee (including tax) charged by us.
taxintegerTax charged for the payment.
error_codestring Error that occurred during payment. For example, BAD_REQUEST_ERROR.
error_descriptionstring Description of the error that occurred during payment. For example, Payment processing failed because of incorrect OTP.
error_sourcestring The point of failure. For example, customer.
error_stepstring The stage where the transaction failure occurred. The stages can vary depending on the payment method used to complete the transaction. For example, payment_authentication.
error_reasonstring The exact error reason. For example, incorrect_otp.
notesjson objectContains user-defined fields, stored for reference purposes.
created_atintegerTimestamp, in UNIX format, on which the payment was created.
card_idstringThe unique identifier of the card used by the customer to make the payment.
walletstring The name of the wallet used by the customer to make the payment. For example, payzapp.
acquirer_dataarrayA dynamic array consisting of a unique reference numbers.
Show child parameters (3)
bankstring The 4-character bank code which the customer's account is associated with. For example, UTIB for Axis Bank.
Curl
change language
change language
1curl -u [YOUR_KEY_ID]:[YOUR_KEY_SECRET]\23-X GET https://api.razorpay.com/v1/orders/order_DaaS6LOUAASb7Y/payments \
Success
1{2"entity":"collection",3"count":2,4"items":[5{6"id":"pay_N8FUmetkCE2hZP",7"entity":"payment",8"amount":100,9"currency":"MYR",10"status":"failed",11"order_id":"order_N8FRN5zTm5S3wx",12"invoice_id":null,13"international":false,14"method":"fpx",15"amount_refunded":0,16"refund_status":null,17"captured":false,18"description":null,19"card_id":null,20"bank":"HSBC",21"wallet":null,22"email":"nur.aisyah@example.com",23"contact":"+6026901125",24"notes":{25"notes_key_1":"Tea, Earl Grey, Hot",26"notes_key_2":"Tea, Earl Grey… decaf."27},28"fee":null,29"tax":null,30"error_code":"BAD_REQUEST_ERROR",31"error_description":"Payment was unsuccessful due to a temporary issue. If amount got deducted, it will be refunded within 5-7 working days.",32"error_source":"gateway",33"error_step":"payment_response",34"error_reason":"payment_failed",35"acquirer_data":{36"auth_code":null37},38"created_at":170168868439},40{41"id":"pay_N8FVRD1DzYzBh1",42"entity":"payment",43"amount":100,44"currency":"MYR",45"status":"captured",46"order_id":"order_N8FRN5zTm5S3wx",47"invoice_id":null,48"international":false,49"method":"fpx",50"amount_refunded":0,51"refund_status":null,52"captured":true,53"description":null,54"card_id":null,55"bank":"HSBC",56"wallet":null,57"email":"siti.aisyah@example.com",58"contact":"+6026901126",59"notes":{60"notes_key_1":"Tea, Earl Grey, Hot",61"notes_key_2":"Tea, Earl Grey… decaf."62},63"fee":2,64"tax":0,65"error_code":null,66"error_description":null,67"error_source":null,68"error_step":null,69"error_reason":null,70"acquirer_data":{71"auth_code":null72},73"created_at":170168872174}75]76}