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

sbox-mcp-documentation

v2.0.1

Published

MCP server for searching and reading s&box game engine documentation and API reference

Readme

sbox-mcp-documentation

npm version License: MIT

An MCP (Model Context Protocol) server that provides AI assistants with searchable access to the full s&box game engine documentation — 180+ pages of guides, tutorials, and concepts — plus the complete API reference with 1,800+ types and 15,000+ members.

Quick Start

No installation required — use npx directly in your MCP config:

{
    "servers": {
        "sbox-docs": {
            "type": "stdio",
            "command": "npx",
            "args": ["-y", "sbox-mcp-documentation"]
        }
    }
}

Or install globally:

npm install -g sbox-mcp-documentation

Features

Documentation

  • Full-text search across all s&box documentation with fuzzy matching and relevance ranking
  • Direct page retrieval with chunked reading for large pages
  • Category browsing to discover available documentation topics

API Reference

  • API type search across 1,800+ public types (classes, structs, enums, interfaces) with member-aware ranking
  • Detailed type lookup — methods, properties, fields, events, XML doc comments, and inheritance info
  • Chunked output for large types so no detail is truncated

General

  • Automatic caching — docs cached for 4 hours, API schema cached for 24 hours
  • Background indexing on startup — both subsystems ready within seconds
  • Built-in self-tests to verify the server is working correctly

Data Sources

Documentation

Documentation is fetched from the official Facepunch docs via the Outline wiki API, which returns raw Markdown directly. The server crawls the full document tree (~202 entries, 180+ with content) and builds a local search index using MiniSearch.

API Reference

The API schema is downloaded from the Facepunch CDN as a JSON file (the same data powering sbox.game/api). It contains all public types from the s&box assembly — 1,800+ types with full member signatures, XML doc comments, and inheritance info. The server strips internal/compiler-generated types and indexes everything with MiniSearch for fast fuzzy lookup.

Installation

Option 1: npx (recommended)

No install needed. Just reference npx sbox-mcp-documentation in your MCP configuration (see below).

Option 2: Global install

npm install -g sbox-mcp-documentation

Option 3: From source

git clone https://github.com/fiedlermarius/sbox-mcp-documentation.git
cd sbox-mcp-documentation
npm install
npm run build

Configuration

VS Code (GitHub Copilot)

Add to .vscode/mcp.json in your workspace:

{
    "servers": {
        "sbox-docs": {
            "type": "stdio",
            "command": "npx",
            "args": ["-y", "sbox-mcp-documentation"]
        }
    }
}

Cursor

Add to .cursor/mcp.json:

{
    "mcpServers": {
        "sbox-docs": {
            "command": "npx",
            "args": ["-y", "sbox-mcp-documentation"]
        }
    }
}

Claude Desktop

Add to your Claude Desktop config (%APPDATA%/Claude/claude_desktop_config.json on Windows):

{
    "mcpServers": {
        "sbox-docs": {
            "command": "npx",
            "args": ["-y", "sbox-mcp-documentation"]
        }
    }
}

Local Checkout Example

If you want to use a local checkout instead of npx, update your configuration as follows:

{
    "servers": {
        "sbox-docs": {
            "type": "stdio",
            "command": "node",
            "args": ["<path-to-repo>/dist/index.js"]
        }
    }
}

As shown above, you need to replace "command": "npx" and "args" with "command": "node" and "args": ["<path-to-repo>/dist/index.js"].

Tools

| Tool | Description | |------|-------------| | sbox_search_docs | Search documentation with fuzzy matching. Returns titles, URLs, categories, and relevant snippets. Supports category filtering and result limits. | | sbox_get_doc_page | Fetch a specific documentation page as Markdown. Supports chunked reading via start_index and max_length for large pages. | | sbox_list_doc_categories | List all documentation categories with page counts. Useful for discovering what topics are available. | | sbox_search_api | Search the s&box API reference by type name, namespace, or keyword. Returns matching types with namespace, description, and top member names. | | sbox_get_api_type | Get full details for a specific API type — all methods, properties, fields, events, XML doc comments, and inheritance. Supports chunked output for large types. | | sbox_cache_status | Show cache and index health — page counts, freshness, and whether both docs and API indexing are complete. | | sbox_run_tests | Run built-in self-tests for all six modules (cache, search, crawler — docs and API). Returns pass/fail results per test case. |

Architecture

docs.facepunch.com (Outline API)          cdn.sbox.game (AssemblySchema JSON)
        │                                           │
        ▼                                           ▼
   DocCrawler ──► POST /api/shares.info       ApiCrawler ──► resolves schema URL
        │         POST /api/documents.info          │         downloads + filters types
        │                                           │
        ▼                                           ▼
    DocCache ──► ~/.sbox-docs-mcp/cache/       ApiCache ──► ~/.sbox-docs-mcp/cache/
        │        manifest.json (TTL 4h)              │        api-types.json (TTL 24h)
        │                                           │
        ▼                                           ▼
   DocSearch ──► MiniSearch index            ApiSearch ──► MiniSearch index
                 title (3x), category (2x),              name (4x), fullName (3x),
                 content (1x)                            members (2x), namespace (1.5x)

Cache Behavior

  • Location: ~/.sbox-docs-mcp/cache/
  • Docs TTL: 4 hours (configurable via SBOX_DOCS_CACHE_TTL env var, in seconds)
  • API TTL: 24 hours — the schema is large (~9 MB) and changes infrequently
  • Custom directory: Set SBOX_DOCS_CACHE_DIR env var
  • Both caches are populated on server startup in the background
  • Set SBOX_API_SCHEMA_URL to pin a specific schema version

Related Projects

License

MIT