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

ccreport

v2.8.5

Published

Claude Code usage reporter - View official usage stats and OpenTelemetry metrics

Readme

ccreport

Claude Code / Codex usage reporter - View usage stats, OpenTelemetry metrics, and cost reports from the command line.

Installation

npm install -g ccreport

Update

npm install -g ccreport@latest

Usage

# Show all data: official API + Codex + OTel + cost (default)
ccreport

# Show usage only (Claude Code + Codex)
ccreport usage

# Show OTel metrics only
ccreport otel

# Show cost report
ccreport cost

# Sync all data to dashboard
ccreport push

# Environment check & setup
ccreport setup

# JSON output
ccreport --json

# Verbose mode
ccreport -v

# Help
ccreport --help

Output Example

📊 Claude Code Usage (Official API)
────────────────────────────────────────

Session (5h):  71% used
  Resets at: 5:00pm (Asia/Saigon)

Weekly (1W):   74% used
  Resets at: Feb 5, 12:00pm (Asia/Saigon)

📡 Data source: Official Anthropic API

📊 Codex Usage
────────────────────────────────────────

Session (5h):  2% used
  Resets at: 3:30pm (Asia/Saigon)

Weekly (1W):   9% used
  Resets at: Feb 10, 12:00pm (Asia/Saigon)

📡 Data source: OpenAI Codex API

Commands

| Command | Description | |---------|-------------| | ccreport | Show official API + Codex + OTel + cost | | ccreport usage | Show Claude Code + Codex usage | | ccreport otel | Show OTel metrics only | | ccreport cost | Show cost report | | ccreport push | Sync official API + OTel + cost to dashboard | | ccreport setup | Environment check & setup |

Data Sources

Official API (Claude Code)

  • Requires Claude Code login
  • Shows exact usage percentage (matches /usage command)
  • Includes reset times

Codex API

  • Requires Codex CLI login (codex command)
  • Shows session/weekly usage percentage
  • Shows reviews usage and credits balance
  • Skipped automatically if not logged in

OpenTelemetry (OTel)

  • Requires OTel collector setup
  • Shows detailed token breakdown
  • Shows cost by model

Environment Variables

| Variable | Description | Default | |----------|-------------|---------| | CODEX_HOME | Codex data directory | ~/.codex | | OTEL_DATA_DIR | OTel data directory | ~/.claude-otel/data | | SYNC_API_URL | Dashboard sync API URL | (public dashboard) | | SYNC_USER_ID | User ID for sync | $USER |

Requirements

  • Node.js >= 18.0.0
  • Claude Code login (for official API)
  • Codex CLI login (optional, for Codex usage)
  • OTel collector (optional, for detailed metrics)

License

MIT