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

@triptyk/delegate-mcp

v0.1.2

Published

Generic multi-provider MCP delegate server for Claude Code. Sonnet orchestrates, cheap providers execute.

Readme

delegate-mcp

Generic multi-provider MCP delegate server for Claude Code.

Sonnet/Opus stay in the driver's seat. When a sub-task is best handled by a cheaper or longer-context model (GLM, MiniMax, Kimi, DeepSeek, …), Claude calls one of the delegate_* tools. No CLI switching, no model routing flags, no lost flat-fee subscriptions.

Architecture

Claude Code (Sonnet/Opus, Anthropic Team flat fee)
  │
  ↓ MCP tools over stdio
delegate-mcp
  │
  ├─→ delegate_bulk          → cheapest provider in routing.bulk
  ├─→ delegate_long_context  → best for >10k tokens
  ├─→ delegate_reasoning     → second-opinion model
  ├─→ delegate_to            → explicit provider pick
  └─→ list_providers         → discovery
       │
       ↓ (HTTP, per-provider adapter)
   ┌────────┬─────────┬─────────┬──────────┐
   │  GLM   │ MiniMax │  Kimi   │ DeepSeek │  (each via its own flat-fee key)
   └────────┴─────────┴─────────┴──────────┘

Why this design

  • No double billing. Anthropic stays on the Team OAuth flow (zero per-token cost). GLM / others called via their flat-fee API keys. No traffic goes through CCR or a token-counting proxy.
  • Sonnet orchestrates. Tool descriptions (delegate_bulk: for repetitive boilerplate…) guide Sonnet to pick the right delegation point. You don't manage routing flags.
  • One CLI session. Replaces the zoda / cc / ccg split. Open Claude Code and that's it.
  • Add providers in 8 lines of YAML. No code changes needed for new endpoints that speak Anthropic-Messages or OpenAI-Chat-Completions wire formats.
  • Failover built-in. If GLM is rate-limited, requests automatically retry on the next provider in the strategy list.

Install

1. Create the config

npx @triptyk/delegate-mcp init

This creates ~/.config/delegate-mcp/providers.yaml from the bundled example and prints the next steps.

2. Fill in your providers and API keys

Open the generated file and uncomment/configure the providers you want to use:

$EDITOR ~/.config/delegate-mcp/providers.yaml

Then export the corresponding API keys in ~/.zshrc (or your secret manager — Infisical, pass, etc.):

export ZAI_API_KEY="sk-zai-…"
# export MINIMAX_API_KEY="…"
# export MOONSHOT_API_KEY="…"
# export DEEPSEEK_API_KEY="…"

3. Register with Claude Code

claude mcp add --scope user --transport stdio delegate \
  -- npx -y @triptyk/delegate-mcp

Verify:

claude mcp list

You should see delegate connected. Open Claude Code (claude) and Sonnet will discover the tools automatically.

Not configured yet? If you skip steps 1–2 and Claude Code launches the server anyway, it starts in degraded mode and exposes a single delegate_setup_required tool. Call it (or ask Claude to call it) to get the exact setup instructions.

Usage

You don't call the tools — Sonnet does. Just describe what you want:

"Generate 30 unit tests covering edge cases for the parseInvoice function. Use delegate_bulk."

Sonnet will call delegate_bulk with the task and context, GLM produces the tests, and Sonnet integrates the result.

To force a provider:

"Use delegate_to with provider_hint='glm' and model_override='glm-4.5-air' to draft a CHANGELOG from these commits."

Adding a provider

  1. Add an entry under providers: in providers.yaml (see commented examples).
  2. Add the provider name to the relevant routing.* lists.
  3. Set the API key env var.
  4. Restart Claude Code (so the MCP server re-reads config).

No code change required as long as the provider speaks anthropic or openai wire format. For exotic protocols, add a new adapter in src/providers/.

Development

npm run dev          # tsx watch mode
npm run typecheck    # strict tsc check
npm run build        # emit dist/

Logs go to stderr (stdout is reserved for MCP JSON-RPC). Use log_level: debug in your YAML for full request traces, then watch:

tail -f ~/.claude/logs/mcp-delegate.log   # if Claude Code persists MCP logs
# or use `claude mcp logs delegate`

License

MIT — internal Triptyk tooling.