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

mcpfile

v0.0.1

Published

alternative mcp client, built for production

Readme

McpFile

McpFile is a standard file format for declaring mcp servers for an mcp client (normally an agent). It also comes with a Client SDK.

TLDR

stick this in a file with a .json extension.

{
  "mcpServers": {
    "my-server-name": {
      // name of the server.
      "type": "http", // transport name, use http or sse
      "url": "https://example.com/mcp" // if http or sse you can use the url.
    }
  }
}

The application/agent developer can use the Mcpfile SDK to connect to the servers, manage authentication, get lovely lifecycle hooks and helper methods which don't exist on the MCP SDK Client (yet).

Motivation

This came about because every MCP Client (Cursor, Claude Code, Claude Desktop, Windsurf, OpenCode, Gemini CLI, Codex CLI etc) use a slightly different standard for declaring MCP servers for an agent.

Whats more there is no good standard definition for an MCP client which can be used in production. Mcp SDK Client can only connect to one server at a time. there are no lifecycle hooks. you cant dump the state to a file (specifically for durable object hibernation). This causes loads of issues since everyone has to reinvent the wheel. This project will also include a sdk for use with mcpfile. The hope is that this can ll be pushed upstream to the official SDK.

Spec

mcpfiles are defined in json. They normally have the name .mcp.json but you can call them anything. Particular implementation is up to the client but it would be expected that any file called .mcp.json in a particular working directory should be loaded by default.

Server Names

When loaded as tools every tools will be prefixed with mcp****. This namespacing is to prevent name collisions. As a result there are restrictions on server names. They should be alphanumeric -_ with no spaces. These will throw errors.

Remote Servers

{
  "mcpServers": {
    "my-server-name": {
      "type": "http", // or sse (deprecated)
      "url": "https://example.com/mcp"
    }
  }
}

Local Servers

  • node
{
  "mcpServers": {
    "server-name": {
      "command": "npx",
      "args": ["-y", "mcp-server"],
      "env": {
        "API_KEY": "value"
      }
    }
  }
}
  • python
{
  "mcpServers": {
    "server-name": {
      "command": "python",
      "args": ["mcp-server.py"],
      "env": {
        "API_KEY": "value"
      }
    }
  }
}

you can also point to an env file with envFile param.

{
  "mcpServers": {
    "server-name": {
      "command": "python",
      "args": ["mcp-server.py"],
      "envFile": ".env"
    }
  }
}

Allowed tools

This allows users to specify which tools, prompts and resources are allowed to be used by the agent. This is completely optional. By default all are allowed.

{
  "mcpServers": {
    "my-server-name": {
    "type": "http", // or sse (deprecated)
    "url": "https://example.com/mcp",
    "allowedTools": ["tool1", "tool2"] // optional - these follow either the exact name of the tool or the namespaced version (mcp__<server-name>__<tool-name>)
    "allowedPrompts": ["prompt1", "prompt2"] // optional
    "allowedResources": ["resource1", "resource2"] // optional
    }
  }
}

Disabled

This allows users to disable a server without removing it from a config. This is completely optional. By default all are enabled.

{
  "mcpServers": {
    "my-server-name": {
      "type": "http", // or sse (deprecated)
      "url": "https://example.com/mcp",
      "disabled": true // optional
    }
  }
}

Config Interpolation

(borrowed from cursor) since they did a really good job.

Config interpolation Use variables in mcp.json values. Mcpfile resolves variables in these fields: command, args, env, url, and headers.

Supported syntax:

${env:NAME} environment variables ${userHome} path to your home folder ${workspaceFolder} project root (the folder that contains .cursor/mcp.json) ${workspaceFolderBasename} name of the project root ${pathSeparator} and ${/} OS path separator Examples

{
  "mcpServers": {
    "local-server": {
      "command": "python",
      "args": ["${workspaceFolder}/tools/mcp_server.py"],
      "env": {
        "API_KEY": "${env:API_KEY}"
      }
    }
  }
}
{
  "mcpServers": {
    "remote-server": {
      "url": "https://api.example.com/mcp",
      "headers": {
        "Authorization": "Bearer ${env:MY_SERVICE_TOKEN}"
      }
    }
  }
}

SDK (for agent developers)

The SDK consists of 4 parts which you can use together or seperately as you see fit.

Parser

The parser takes a mcpfile and returns a list of servers and the config to connect to each server. This is directly plugable into the MCP SDK Client.connect() function.

Client

This client is essentially an extension to the McpSDK Client. It adds lifecycle hooks (tbc). It will also handle authentication, lifecycle hooks and helper methods which don't exist on the MCP SDK Client (yet).

Manager

Here we add all the juicy bits that you need for production

It will handle multiple servers connected.

Router

tbc