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

fleets

v0.1.0

Published

Fleets — Bloomberg-style multi-site GA4 + Cloudflare + GSC terminal CLI

Readme

@fleets/cli

Terminal CLI for Fleets. Per-site commands mirror the harbor UI tabs at https://fleets.run/harbor/<slug>/<tab>.

Install

npm install -g @fleets/cli

Authenticate

fleets login

Picks between two methods:

  1. browser (default) — device flow: CLI prints a URL + 8-character code, auto-opens your browser, you click authorize, CLI finishes automatically.
  2. paste a token — mint one in harbor → account → cli, paste it in.

Skip the prompt with a flag:

fleets login --browser     # force device flow
fleets login --paste       # force token paste

fleets login --token fl_xxxxxxxxxxxxxxxx   # paste in one shot (CI)
export FLEETS_TOKEN=fl_xxxxxxxxxxxxxxxx     # skip login entirely

Slug-first dispatch

The most intuitive way to run commands is to put the site slug first, like you're "inside" that site:

fleets fightbets                         # GA4 summary (defaults to stats)
fleets fightbets sources                 # top traffic sources
fleets fightbets funnel session_start view   # conversion funnel
fleets fightbets seo --range 30d         # GSC summary, last 30 days
fleets fightbets open settings           # print harbor URL

The legacy form fleets <command> <slug> (e.g. fleets sources fightbets) still works.

Commands

Setup

| Command | Description | |---|---| | fleets login | Browser device-flow auth (no paste) | | fleets add <domain> [--detect] | Create a site; --detect auto-links GA4 + GSC | | fleets connect <slug> | Auto-detect GA4 + GSC via service account | | fleets connect <slug> --property <id> | Set GA4 property explicitly | | fleets connect <slug> --gsc <site-url> | Set GSC site explicitly |

Analytics (per-site)

All accept --range (default 7d) and --json. Commands with top-N tables also accept --limit.

| Command | Tab | Data source | |---|---|---| | fleets list | — | All your sites with sparkline + Δ7d | | fleets <slug> / fleets stats <slug> | day | GA4 summary | | fleets <slug> sources | sources | GA4 traffic sources | | fleets <slug> campaigns | campaigns | GA4 UTM campaigns | | fleets <slug> referrals | referrals | GA4 referrals | | fleets <slug> landers | landers | GA4 landing pages | | fleets <slug> events | events | GA4 events | | fleets <slug> users | users | GA4 country + device breakdown | | fleets <slug> funnel <step1> <step2>… | funnel | GA4 funnel | | fleets <slug> seo | seo | Google Search Console | | fleets <slug> edge | edge | Cloudflare Analytics | | fleets <slug> speed | speed | PageSpeed Insights |

Utility

| Command | Description | |---|---| | fleets <slug> export | Daily GA4 CSV/JSON export | | fleets <slug> query "<text>" | Natural-language analytics query | | fleets <slug> open [tab] | Print the harbor URL for a site |

Environment variables

| Variable | Default | Description | |---|---|---| | FLEETS_API_URL | https://fleets.run | Override API base URL | | FLEETS_TOKEN | — | Personal access token (overrides ~/.fleets/config.json) |

Range format

All --range flags accept:

  • 7d — last 7 days
  • 30d — last 30 days
  • 90d — last 90 days
  • 24h — last 24 hours (rounds to 1 day)

Requirements

  • Node.js >= 22 (LTS)
  • Works on macOS, Linux, Windows