razorpay / razorpay-node

Razorpay node.js bindings
MIT License
182 stars 111 forks source link

Success handler only returns "razorpay_payment_id" in live mode. #258

Closed devblin closed 2 years ago

devblin commented 2 years ago
const razorOptions = {
    "key": keyId,
    "amount": amount,
    "currency": "INR",
    "name":"test payment",
    "image": image,
    "order_id": orderId,
    "prefill": {
        "name": user.name,
        "email": user.email
    },
    "handler": function(res) {
        console.log(res); 
    },
    "modal": {
        "ondismiss": function () {
             window.location.href = "/events";
        }
    }
}

In Test Mode:

Success handler returns proper response fields as mentioned in razorpay doc.

But In Live Mode:

On successfuly payment (amount deducted from user's bank account), succes handler returns only razorpay_payment_id, without razorpay_order_id, razorpay_signature

{ 
  created_at: 1643955638,
  razorpay_payment_id: "pay_SOME_ID",
  status: "captured",
  status_code: 200
}
onlit commented 2 years ago

facing the same issue!

Tharun-b777 commented 2 years ago

Hey, I am also facing the same issue, These are my responses in

Test Mode: Screenshot (1241)_LI

Live Mode:

Screenshot (1240)_LI

monetree commented 2 years ago

https://razorpay.com/docs/payments/payment-gateway/web-integration/standard/build-integration/#11-create-an-order-on-your-server

as per the doc it should return

"handler": function (response){ alert(response.razorpay_payment_id); alert(response.razorpay_order_id); alert(response.razorpay_signature) }

but it returns only. razorpay_payment_id

paarthibank commented 2 years ago

Hey I am also facing the same issue.

gokul-00 commented 2 years ago

facing same issue :(

devblin commented 2 years ago

Closing this issue, as the problem was temporary (received mail regarding this from razorpay), there was an unexpected issue in payment through UPI-QR.