var key_id = '##########';
var key_secret = '##############';
var instance = new Razorpay({
key_id: key_id,
key_secret: key_secret
});
instance.orders.create({
amount: 1000,
currency: "INR",
receipt: '9876',
payment_capture: true
}, (error, response) => {
if ((error)) {
// handle error
console.log("error - ", error);
res.send("err");
} else {
// handle success
console.log("response - ", response);
res.send("ok");
}
});
这是我在节点js中的代码,用于从razor pay生成订单ID 但这总是抛出错误,当我打印错误时,它显示以下消息 {状态:未定义,错误:未定义}