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

@sochdb/flowtrace-claude-code

v0.1.0

Published

Flowtrace observability plugin for Claude Code - automatic tracing of all tool calls and sessions

Downloads

6

Readme

@sochdb/flowtrace-claude-code

Flowtrace observability plugin for Claude Code - automatic tracing of all tool calls and sessions.

Features

  • 📊 Automatic Tracing: Traces every tool call (Bash, Edit, Write, Read, etc.)
  • 🔗 Session Tracking: Links all tool calls within a session
  • ⏱️ Duration Tracking: Measures time spent on each tool execution
  • 🚫 Non-blocking: Never interrupts or slows down Claude Code
  • 📈 Dashboard Integration: View traces in Flowtrace UI

Installation

npm install -g @sochdb/flowtrace-claude-code

This will automatically install the plugin to ~/.claude/plugins/flowtrace.

Manual Installation

If auto-install doesn't work, run:

npx @sochdb/flowtrace-claude-code

Or copy manually:

cp -r node_modules/@sochdb/flowtrace-claude-code/plugin ~/.claude/plugins/flowtrace

Configuration

The plugin is configured via environment variables:

| Variable | Default | Description | |----------|---------|-------------| | FLOWTRACE_ENABLED | true | Enable/disable tracing | | FLOWTRACE_URL | http://localhost:9600 | Flowtrace server URL | | FLOWTRACE_TENANT_ID | 1 | Tenant identifier | | FLOWTRACE_PROJECT_ID | 1 | Project identifier |

Example

# Set Flowtrace URL
export FLOWTRACE_URL="http://localhost:9600"

# Run Claude Code
claude

What Gets Traced

Session Events

  • SessionStart: When a Claude Code session begins
  • Stop: When a session ends

Tool Calls

Every tool invocation is traced with:

| Tool | Traced Data | |------|-------------| | Bash | Command, output, exit code, duration | | Edit | File path, changes, duration | | Write | File path, content length, duration | | Read | File path, lines read, duration | | Glob | Pattern, matches, duration | | Grep | Pattern, file, matches, duration | | LS | Directory, entries, duration | | Task | Subtask description, result, duration |

Viewing Traces

  1. Start Flowtrace:

    open /Applications/Flowtrace.app
    # or
    flowtrace serve
  2. Open the Flowtrace UI at http://localhost:9600

  3. Navigate to Traces to see all Claude Code activity

  4. Filter by:

    • Project
    • Session
    • Tool name
    • Time range

Plugin Structure

flowtrace/
├── .claude-plugin/
│   └── plugin.json          # Plugin metadata
├── core/
│   ├── __init__.py
│   └── client.py            # Flowtrace API client
├── hooks/
│   ├── __init__.py
│   ├── hooks.json           # Hook definitions
│   ├── sessionstart.py      # Session start handler
│   ├── pretooluse.py        # Pre-tool execution handler
│   ├── posttooluse.py       # Post-tool execution handler
│   └── stop.py              # Session end handler
└── README.md

Troubleshooting

Traces not appearing

  1. Check Flowtrace is running:

    curl http://localhost:9600/api/v1/health
  2. Verify environment variable:

    echo $FLOWTRACE_URL
  3. Check plugin is loaded:

    claude /plugin list

Disable temporarily

export FLOWTRACE_ENABLED=false
claude

Development

To modify the plugin:

  1. Edit hooks in hooks/ directory
  2. Modify the client in core/client.py
  3. Test with Claude Code:
    claude

License

MIT