Search
/api/npm/search
Search packages with scores, maintainers and downloads
Scrappa's npm API returns public npm registry data as structured JSON. Search packages with quality, popularity and maintenance scores, and read any package with dependencies, dist info, maintainers, version history, weekly and monthly downloads and the readme.
Try it now
Use the first endpoint in this API family with a Scrappa API key. Every account includes 500 free monthly credits, so you can validate the response shape before buying credits.
curl -X GET "https://scrappa.co/api/npm/package?package=lodash" \
-H "Accept: application/json" \
-H "X-API-KEY: YOUR_API_KEY"
{
"success": true,
"data": {
"name": "lodash",
"version": "4.18.1",
"description": "Lodash modular utilities.",
"license": "MIT",
"dependencies": {},
"dist": {
"tarball": "https://registry.npmjs.org/lodash/-/lodash-4.18.1.tgz",
"shasum": "ff2b66c1f6326d59513de2407bf881439812771c",
"integrity": "sha512-dMInicTPVE8d1e5otfwmmjlxkZoUpiVLwyeTdUsi/Caj/gfzzblBcCE5sRHV/AsjuCmxWrte2TNGSYuCeCq...",
"unpacked_size": 1413741,
"file_count": 1051
},
"downloads": {
"last_week": null,
"last_month": null
}
}
}
Structured data for real applications. Here are some ideas.
Read dependencies, peer dependencies, engines and licenses of any package version.
Search the registry with qualifiers and rank results by quality, popularity and maintenance.
Follow weekly and monthly downloads and release dates to see which libraries grow.
Track maintainers, publishers and new versions of the packages you depend on.
Everything you need in one API.
/api/npm/search
Search packages with scores, maintainers and downloads
/api/npm/package
One package with dependencies, versions, downloads and readme
See how Scrappa compares to npm registry API (direct).
| Feature | Scrappa | npm registry API (direct) |
|---|---|---|
| Package, downloads and version history in one call | Three separate APIs | |
| Scoped names handled for you | Manual URL encoding | |
| Large packages capped safely | You parse multi-MB documents | |
| Price per 1k requests | From $0.20 | Free, but you build the wrapper |
Yes. Pass the full name, for example @types/node, as the package parameter.
The readme of the latest release. Other versions return the readme only when npm stores it with that version.
Each successful request uses one Scrappa credit. Failed requests are never charged and the API never answers with HTTP 429. An upstream outage returns a retryable 503.
No. Scrappa is an independent service and is not affiliated with or endorsed by npm. It returns public npm data as JSON.