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

@rebo89/token-vault

v0.1.0

Published

TokenVault — MCP server, SDK, and CLI for the TokenVault design-token builder

Downloads

25

Readme

TokenVault MCP (@rebo89/token-vault)

MCP (Model Context Protocol) server, SDK, and CLI for TokenVault (the Design System Builder).

This is an authoring channel, not a runtime channel. Apps consume tokens at runtime by reading the DTCG tokens.json that DSB publishes to GitHub. The MCP is what lets an agent (e.g. a Claude Code session running inside a consumer project) read the live state AND create / update / delete tokens against the design system — proposing missing tokens for components, renaming things, importing a palette, etc.

Three frontends, same underlying API:

  • Claude Code/Desktop — connect the MCP server, drive it with natural language
  • SDK — programmatic access in Node.js/TypeScript
  • CLI — command-line interface for scripts and automation

Installation

Published to npm as @rebo89/token-vault (public). Consumers run it with npx — no clone or build needed. Requires Node >= 22.

1. Get an API key

In the web app: open the design system → Settings → API Keys → "New key". Copy the dsb_… value. One key is scoped to one design system, so generate a fresh one per design system you want to expose.

2. Register the MCP in a consumer project

From inside the consumer project's root directory:

claude mcp add token-vault \
  --scope local \
  --env DSB_API_KEY=dsb_YOUR_KEY_HERE \
  -- npx -y @rebo89/token-vault mcp

--scope local keeps the registration personal to this project (lives in your ~/.claude.json, not committed) — the right choice when each project consumes its own design system with its own key.

Alternatively, commit a project-scope .mcp.json so every teammate gets the registration automatically, and keep the key out of git (e.g. read it from a gitignored file):

{
  "mcpServers": {
    "token-vault": {
      "command": "sh",
      "args": [
        "-c",
        "DSB_API_KEY=\"$(cat \"$(git rev-parse --show-toplevel)/.dsb-api-key\")\" exec npx -y @rebo89/token-vault mcp"
      ]
    }
  }
}

Verify with claude mcp list — you should see token-vault: … ✓ Connected.

Working from this repo (development)

Clone, npm install && npm run build in mcp/, then point Claude at the local build instead of npx:

claude mcp add token-vault \
  --scope local \
  --env DSB_API_KEY=dsb_YOUR_KEY_HERE \
  -- node /absolute/path/to/design-system-builder/mcp/dist/mcp/server.js

Then use Claude naturally:

  • "List my design system collections"
  • "Create a warm earthy color palette"
  • "Check my colors for accessibility issues"
  • "Export my tokens in DTCG format"

Switching design systems

Each project gets its own registration with its own key. To re-point a project at a different design system:

claude mcp remove token-vault
# then re-add with the new design system's key

Available MCP Tools

| Tool | Description | |------|-------------| | list_collections | List all collections in the design system | | get_tokens | Get tokens from a collection | | export_dtcg | Export tokens in DTCG format | | get_design_system | Get design system info | | create_collection | Create a new collection | | create_token | Create a new token | | update_token | Update a token | | delete_token | Delete a token | | suggest_color_palette | Generate color palette suggestions | | analyze_accessibility | Check color contrast ratios | | suggest_token_names | Analyze naming conventions |

CLI Usage

The published package installs a token-vault binary (run ad hoc with npx @rebo89/token-vault …):

# List collections
token-vault list collections

# List tokens
token-vault list tokens --collection abc123

# Export in DTCG format
token-vault export --format dtcg --output tokens.json

# Show design system info
token-vault info

# Start MCP server manually
token-vault mcp

SDK Usage

npm install @rebo89/token-vault
import { DesignSystemBuilderClient } from '@rebo89/token-vault';

const client = new DesignSystemBuilderClient({
  apiKey: process.env.DSB_API_KEY!
});

// List collections
const collections = await client.listCollections();

// Get tokens
const tokens = await client.getTokens({ collectionId: 'abc123' });

// Create a token
const tokenId = await client.createToken({
  collectionId: 'abc123',
  name: 'primary/500',
  type: 'color',
  value: '#3b82f6'
});

// Export in DTCG format
const dtcg = await client.exportDtcg();

Development

# Install dependencies
npm install

# Build
npm run build

# Watch mode
npm run dev

# Type check
npm run typecheck

License

MIT