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

@tokenspace/local-mcp

v0.3.0

Published

Run a Tokenspace workspace as a local MCP server over `stdio`.

Downloads

766

Readme

@tokenspace/local-mcp

Run a Tokenspace workspace as a local MCP server over stdio.

Quickstart

bunx @tokenspace/local-mcp ./my-workspace

Or install it globally:

bun add -g @tokenspace/local-mcp
tokenspace-local-mcp ./my-workspace

Requirements

  • Bun >=1.3.9
  • A local Tokenspace workspace directory

Usage

tokenspace-local-mcp ./my-workspace

Optional flags:

tokenspace-local-mcp <workspace-dir> \
  [--sessions-root-dir <dir>] \
  [--build-cache-dir <dir>] \
  [--system-dir <dir>]

Expected startup logs go to stderr:

  • Tokenspace local MCP ready on stdio
  • Workspace: ...
  • Fingerprint: ...
  • Build: fresh-build or Build: cache-hit
  • Startup: ...ms
  • Session: ...
  • Sandbox: ...
  • Bundle: ...
  • Control: http://127.0.0.1:...

stdout is reserved for MCP JSON-RPC traffic.

Claude Code

claude mcp add tokenspace-local-mcp --scope project -- \
  bun $(which tokenspace-local-mcp) ./my-workspace

An equivalent .mcp.json entry is:

{
  "mcpServers": {
    "tokenspace-local-mcp": {
      "command": "bun",
      "args": [
        "/absolute/path/to/tokenspace-local-mcp",
        "/absolute/path/to/workspace"
      ]
    }
  }
}

Discovery Resources

Clients can inspect these resources immediately after connecting:

  • tokenspace://session/manifest
    • session metadata, control URL, and build origin
  • tokenspace://workspace/metadata
    • compiler metadata including capabilities, skills, credentials, and models
  • tokenspace://workspace/token-space-md
    • raw TOKENSPACE.md contents when the workspace defines it
  • tokenspace://approvals/pending
    • pending approval requests plus approval URLs

Control UI

The Control: startup log points at a localhost dashboard that lets you:

  • inspect workspace and session details
  • approve or deny pending requests
  • set and delete secret credentials
  • see whether env credentials are present for the current process

Notes:

  • secret credentials use Bun's secret store when available, with a file fallback under ~/.tokenspace/local-mcp/secrets
  • env credentials are never stored in the UI; they are read from the local MCP process environment
  • oauth credentials are listed but still unsupported in local MCP
  • declared session and user secret credentials are intentionally stored as workspace-local values for now

Troubleshooting

The first run for a workspace fingerprint is a fresh build. Repeated launches of unchanged workspaces should switch to Build: cache-hit.

If you want an isolated cache for debugging:

bunx @tokenspace/local-mcp ./my-workspace --build-cache-dir /tmp/tokenspace-local-mcp-cache

No TOKENSPACE resource

tokenspace://workspace/token-space-md is only exposed when the workspace actually has a TOKENSPACE.md.