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

@packetrove/cli

v0.8.0

Published

Packetrove network calculations and IP diagnostics for scripts and agents.

Readme

Packetrove CLI

Network calculations and IP diagnostics for humans, scripts, and agents.

The @packetrove/cli package contains the packetrove executable and bundles its runtime dependencies. CIDR calculations run locally without a network connection. The public-ip command queries the public IP observed for this machine's connection.

CLI versions follow Packetrove's product releases. npm versions and Git tags use the same plain number, such as 0.1.0.

Installation

Install the npm package with Node.js and npm; Git, pnpm, and a source checkout are not needed:

npm install --global @packetrove/cli
packetrove --help

Alternatively, run a published version without a global installation:

npx @packetrove/cli cidr-cover 203.0.113.1 203.0.113.2 203.0.113.6 --json

Supported Node.js versions are 22.22.2 or later in the 22.x line, 24.15.0 or later in the 24.x line, and 26 or later. To build your own copy, follow the source installation guide.

Cover IP addresses and CIDR ranges

packetrove cidr-cover 203.0.113.1 203.0.113.2 203.0.113.6
packetrove cidr-cover --stdin --json < addresses.txt

Use 1 to 1,000 IPv4 entries or IPv6 entries. CIDR host bits are normalized; duplicates and overlaps count once. The example returns 203.0.113.0/29, covering eight addresses, including five beyond the supplied three. That wider range permits additional addresses in an allowlist or blocks additional addresses in a blocklist. The command calculates a range without applying firewall rules.

Each entry accepts at most 64 characters. Standard-input lines are trimmed and blank lines are ignored. Line buffering stays bounded even for a very long entry or surrounding whitespace; length issues retain their combined input indexes, without echoing input values. See the CLI guide for error details.

With --json, success writes the shared result object to stdout. Errors write the shared error object to stderr and exit with status 1. Address counts are decimal strings, including IPv6 counts beyond JavaScript's safe integer limit. A failed output write may leave partial stdout; check the exit status before using a result.

Check the current public IP

packetrove public-ip
packetrove public-ip --json
packetrove public-ip --api-origin http://localhost:8787 --json

Without --json, stdout contains just the address and a newline. The default endpoint is https://api.packetrove.com/v1/public-ip; a lookup makes a network request with a 10-second timeout, no cache, and no redirects. --api-origin supports a self-hosted HTTP or HTTPS origin without credentials, a path, query, or fragment.

The result describes the connection from the machine running the command. A VPN or proxy changes the observed address. One request observes IPv4 or IPv6; it does not separately discover both families.

Documentation and license

Packetrove is licensed under the MIT License. This package includes LICENSE and THIRD_PARTY_NOTICES for the bundled third-party components.