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

origin-mcp-server

v0.1.0

Published

Local stdio MCP server exposing an Origin project's RPML documents to coding agents.

Readme

origin-mcp-server

A Model Context Protocol server that gives a coding agent read access to one Origin project's RPML documents, plus an incremental "what changed since last time" feed.

It authenticates with a project-scoped API key (generated in the Origin web app under 接入 MCP on a project, or the user menu → API 密钥) and talks to the origin-mcp Supabase Edge Function. The Supabase service-role secret never leaves the backend — this package only ever holds the scoped key.

Run it with no install via npx -y origin-mcp-server (requires Node.js ≥ 18).

Tools

| Tool | Input | Returns | |------|-------|---------| | list_documents | — | Every file/folder in the project (id, name, kind, parent_id, position, updated_at). No content. | | get_document | file_id | A single document including its full content. | | get_changes | — | Documents changed since the last sync, each with change_type (added/modified/deleted) and latest content (null when deleted). |

Incremental sync & .origin-lock.json

get_changes reads the cursor from .origin-lock.json in the current working directory, requests everything newer from the backend, returns it to the agent, then advances the cursor to the new head version. So:

  • First call (no lock, or version: 0) replays the full current document set as added.
  • Subsequent calls return only what changed since the previous get_changes, including deletions.

list_documents and get_document are read-through and do not move the cursor — only get_changes is a sync point. The lock file holds { project_id, version, hash, last_synced_at } where hash is a SHA-256 of the last consumed change set (integrity/debugging).

Configuration

Two environment variables, supplied by your MCP client config (recommended) or a local .env in the working directory:

ORIGIN_API_KEY=origin_...                 # generated in the Origin web app
ORIGIN_API_URL=https://<project-ref>.supabase.co/functions/v1/origin-mcp

The Origin web app's 接入 MCP dialog generates the key and emits a ready-to-paste config block with both values filled in.

Register with an MCP client

{
  "mcpServers": {
    "origin": {
      "command": "npx",
      "args": ["-y", "origin-mcp-server"],
      "env": {
        "ORIGIN_API_KEY": "origin_...",
        "ORIGIN_API_URL": "https://<project-ref>.supabase.co/functions/v1/origin-mcp"
      }
    }
  }
}

Try it with the inspector

ORIGIN_API_KEY=origin_... ORIGIN_API_URL=https://<ref>.supabase.co/functions/v1/origin-mcp \
  npx @modelcontextprotocol/inspector npx -y origin-mcp-server

Local development

cd mcp-server
npm install
npm run build      # → dist/
npm run dev        # run from source via tsx

Rotating a key

Revoke or delete the key in the Origin web app (project → 接入 MCP, or user menu → API 密钥) and generate a new one. The key is a project secret — keep .env and .origin-lock.json out of version control (both are gitignored).