npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@marcosreuquen/osv-check

v1.1.0

Published

CLI tool to check packages for known vulnerabilities using the OSV.dev API (npm, PyPI, and more)

Readme

osv-check

CLI tool to check packages for known vulnerabilities using the OSV.dev API.

Supports multiple ecosystems: npm, PyPI, and more coming soon.

Zero dependencies. Requires Node.js >= 22.

Install

npm install -g osv-check

Usage

Check a specific package version

osv-check [email protected]

Check the latest version of a package

osv-check lodash

Automatically resolves the latest version from the npm registry and checks it for vulnerabilities.

List all known vulnerabilities across all versions

osv-check lodash --all

Shows every known vulnerability with affected version ranges.

Check a PyPI package

osv-check [email protected] -e pypi
osv-check requests -e pypi          # latest version
osv-check requests -e pypi --all    # all versions

Check all dependencies in your project

osv-check

This auto-detects manifest files (package.json, requirements.txt) in the current directory and checks all dependencies.

Scoped packages (npm)

osv-check @angular/[email protected]
osv-check @angular/core              # latest version

Options

| Flag | Description | |------|-------------| | -e, --ecosystem <name> | Ecosystem for single-package check (npm, pypi) | | -a, --all | Show all vulnerabilities across all versions (requires package name without version) | | -h, --help | Show help message | | -v, --version | Show version |

Supported ecosystems

| Ecosystem | Manifest file | Registry | Status | |-----------|---------------|----------|--------| | npm | package.json | registry.npmjs.org | ✅ | | PyPI | requirements.txt | pypi.org | ✅ |

Exit codes

  • 0 — No vulnerabilities found
  • 1 — Vulnerabilities found or error occurred

Programmatic API

import { queryPackage, queryMultiple } from 'osv-check';

// Check a specific version
const result = await queryPackage('lodash', '4.17.15');
console.log(result.vulns);

// Check without version (returns all vulnerabilities)
const allVulns = await queryPackage('lodash');
console.log(allVulns.vulns);

// PyPI package
const pyResult = await queryPackage('requests', '2.25.0', 'PyPI');
console.log(pyResult.vulns);

Adding a new ecosystem

Create a new file in src/ecosystems/ following this pattern:

// src/ecosystems/my-ecosystem.js
export default {
  name: 'MyEcosystem',        // Must match OSV API ecosystem name
  manifestFile: 'manifest.lock',
  async parseManifest(dir) {
    // Read and parse the manifest file
    // Return: [{ name, version, ecosystem: 'MyEcosystem' }]
  },
  async fetchLatestVersion(name) {
    // Fetch latest version from the ecosystem registry
    // Return: '1.2.3'
  },
};

Then register it in src/ecosystems/index.js.

License

MIT