Gathering detailed insights and metrics for razorpay
Gathering detailed insights and metrics for razorpay
Gathering detailed insights and metrics for razorpay
Gathering detailed insights and metrics for razorpay
npm install razorpay
Typescript
Module System
Node Version
NPM Version
98.3
Supply Chain
99.2
Quality
83
Maintenance
100
Vulnerability
100
License
JavaScript (100%)
Total Downloads
7,318,737
Last Day
6,408
Last Week
69,639
Last Month
292,518
Last Year
2,860,360
MIT License
215 Stars
444 Commits
115 Forks
187 Watchers
124 Branches
1,108 Contributors
Updated on Jul 01, 2025
Minified
Minified + Gzipped
Latest Version
2.9.6
Package Id
razorpay@2.9.6
Unpacked Size
318.75 kB
Size
53.14 kB
File Count
63
NPM Version
8.19.4
Node Version
16.20.2
Published on
Feb 24, 2025
Cumulative downloads
Total Downloads
Last Day
6.4%
6,408
Compared to previous day
Last Week
-1.5%
69,639
Compared to previous week
Last Month
-1.9%
292,518
Compared to previous month
Last Year
75.1%
2,860,360
Compared to previous year
1
Official nodejs library for Razorpay API.
Read up here for getting started and understanding the payment flow with Razorpay: https://docs.razorpay.com/docs/getting-started
1npm i razorpay
Documentation of Razorpay's API and their usage is available at https://docs.razorpay.com
Instantiate the razorpay instance with key_id
& key_secret
. You can obtain the keys from the dashboard app (https://dashboard.razorpay.com/#/app/keys)
1const Razorpay = require('razorpay'); 2 3var instance = new Razorpay({ 4 key_id: 'YOUR_KEY_ID', 5 key_secret: 'YOUR_KEY_SECRET', 6});
Instantiate the razorpay instance with access_token
. The access_token
can be obtained only in case if you are a platform partner. For more information, refer page - https://razorpay.com/docs/partners/platform/.
1const Razorpay = require('razorpay'); 2 3var instance = new Razorpay({ 4 "oauthToken": "ACCESS_TOKEN" 5})
x The resources can be accessed via the instance. All the methods invocations follows the namespaced signature
1// API signature 2// {razorpayInstance}.{resourceName}.{methodName}(resourceId [, params]) 3 4// example 5instance.payments.fetch(paymentId);
Every resource method returns a promise.
1instance.payments 2 .all({ 3 from: '2016-08-01', 4 to: '2016-08-20', 5 }) 6 .then(response => { 7 // handle success 8 }) 9 .catch(error => { 10 // handle error 11 });
If you want to use callbacks instead of promises, every resource method will accept a callback function as a last parameter. The callback functions will behave as Error First Callbacks
1instance.payments.all( 2 { 3 from: '2016-08-01', 4 to: '2016-08-20', 5 }, 6 (error, response) => { 7 if (error) { 8 // handle error 9 } else { 10 // handle success 11 } 12 } 13);
1npm install
1npm test
master
branch. Make sure you have the latest changes in the local masterCHANGELOG.md
& bump the version in package.json
npm publish
commandMIT Licensed. See LICENSE.txt for more details
No vulnerabilities found.
Reason
no dangerous workflow patterns detected
Reason
no binaries found in the repo
Reason
license file detected
Details
Reason
Found 25/27 approved changesets -- score normalized to 9
Reason
dependency not pinned by hash detected -- score normalized to 2
Details
Reason
1 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
detected GitHub workflow tokens with excessive permissions
Details
Reason
project is not fuzzed
Details
Reason
security policy file not detected
Details
Reason
12 existing vulnerabilities detected
Details
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
Score
Last Scanned on 2025-06-23
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More