razorpay generate signature in the node js

Solutions on MaxInterview for razorpay generate signature in the node js by the best coders in the world

showing results for - "razorpay generate signature in the node js"
Blythe
21 Jun 2016
1const crypto = require("crypto");
2const hmac = crypto.createHmac('sha256', RAZORPAY_KEY_SECRET);
3
4hmac.update(razorpayOrderId + "|" + razorpayPaymentId);
5let generatedSignature = hmac.digest('hex');
6
7let isSignatureValid = generatedSignature == payload.razorpay_signature;
8