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

agent-receipt

v0.2.0

Published

MCP server that generates structured receipts for Claude Code sessions

Readme

agent-receipt

Automatic receipts for every Claude Code session. Track intent, tool calls, cost, side effects, and outcome quality — without Claude's cooperation.

agent-receipt demo

Install

npx agent-receipt init

That's it. This adds Claude Code hooks and an MCP server to your project. Every session automatically gets a receipt.

What's in a receipt?

| Field | Description | |---|---| | Intent | What the session set out to do | | Outcome | What actually happened | | Intent Score | 0.0–1.0 alignment score (via Haiku) | | Cost | Token counts and USD estimate by model | | Tool Calls | Every tool invocation with input/output | | Side Effects | File writes, deletes, git pushes, API calls | | Duration | Wall clock time |

How it works

Claude Code hooks fire on lifecycle events — no prompting required:

| Hook | What happens | |---|---| | SessionStart | Creates a session row in local SQLite | | PostToolUse | Logs each tool call (name, input, response) | | PostToolUseFailure | Logs failed tool calls with error | | SessionEnd | Finalizes the receipt: aggregates calls, detects side effects, calculates cost |

Receipts are stored locally at ~/.agent-receipt/receipts.db.

Commands

agent-receipt init              # Set up hooks + MCP in current project
agent-receipt init --dry-run    # Preview without writing files
agent-receipt setup             # Install hooks globally (~/.claude/settings.json)
agent-receipt setup --local     # Install hooks in current project only

MCP tools

The MCP server exposes tools for explicit overrides on top of automatic hook tracking:

  • receipt_start — Set intent, tags, and budget for the current session
  • receipt_log_tool_call — Log a tool call manually
  • receipt_end — End session and generate receipt with optional outcome
  • receipt_score — Submit intent score after evaluating the scoring prompt

Receipt format

Receipts export as Markdown for pasting in PRs:

## Agent Receipt `rec_a1b2c3d4`

**Intent:** Add user authentication
**Outcome:** Executed 12 tool call(s): wrote auth middleware, added tests...
**Intent Score:** 0.85 (via host)

**Cost:** $0.42 · 28,400 tokens · 3m 12s

**Side Effects:**
- File writes: src/auth.ts, src/middleware.ts, tests/auth.test.ts
- Bash: npm install jsonwebtoken
- Git: committed changes

Storage

Local SQLite database at ~/.agent-receipt/receipts.db. No data leaves your machine.

License

MIT