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

@tsparticles/mcp-server

v4.6.0

Published

MCP server for tsParticles - generate options from natural language and suggest required plugins

Readme

@tsparticles/mcp-server

MCP (Model Context Protocol) server for tsParticles. Lets AI assistants inspect package catalogs, suggest required plugins and bundles from options, and generate tsParticles configurations from natural language.

Quick Start (local)

npx @tsparticles/mcp-server

The server runs on stdio and can be connected to any MCP-compatible client:

Claude Desktop configuration

Add this to your claude_desktop_config.json:

{
  "mcpServers": {
    "tsparticles": {
      "command": "npx",
      "args": ["@tsparticles/mcp-server"]
    }
  }
}

Tools

| Tool | Description | | ------------------ | -------------------------------------------------------------------------------------- | | suggest_plugins | Given a tsParticles options object, returns the npm packages and imports needed | | list_packages | Lists available packages, optionally filtered by category or search query | | get_package_info | Returns detailed info about a specific package | | diagnose_issues | Analyzes options for configuration problems and performance issues | | generate_code | Generate complete code from a natural language description with smart bundle selection |

Resources

| URI | Description | | ----------------------------- | --------------------------- | | tsparticles://packages | Complete package catalog | | tsparticles://options/guide | Options structure reference | | tsparticles://bundles | Bundle selection guide |

Prompt

| Name | Description | | ------------------ | ----------------------------------------------------------------- | | generate-options | Generates tsParticles options from a natural language description |

Deploy (remote HTTP)

The server can also run as an HTTP endpoint, accessible by any MCP client that supports SSE.

HTTP mode binds to 127.0.0.1 by default. Binding to any other interface requires an auth token; startup fails if a non-loopback host is configured without one. Use HTTPS at a trusted reverse proxy or tunnel when connecting over an untrusted network.

Authentication

Set a bearer token to require Authorization: Bearer <token> on every request to /mcp when binding beyond loopback:

export MCP_AUTH_TOKEN="$(openssl rand -hex 32)"
npx @tsparticles/mcp-server --port 3000 --host 0.0.0.0

The CLI reads the exported MCP_AUTH_TOKEN automatically. Configure your MCP client to send the same value in the Authorization: Bearer <token> header. The exported token remains available in your shell for copying into the client configuration. On loopback, no token is required; origin checks still restrict browser-originated requests, but are not authentication and do not protect non-browser clients.

Rate limiting

MCP traffic and unauthenticated requests have separate in-memory rate limits, so failed authentication attempts cannot consume the MCP request budget. The server also limits each client IP to 10 sessions and caps the process at 500 sessions. These controls are process-local and do not replace rate limiting at a reverse proxy or CDN.

When running behind a reverse proxy, pass each proxy's IP with --trusted-proxy <IP> (repeat the flag for multiple hops) or set MCP_TRUSTED_PROXIES to a comma-separated list. The edge proxy must overwrite or append the connecting client IP to X-Forwarded-For; the server walks the trusted proxy chain from right to left to resolve the client address.

Option 1: Direct access (no tunnel)

# Start on port 3000 (loopback only)
npx @tsparticles/mcp-server --port 3000
# Health check: http://localhost:3000/health
# MCP endpoint:  http://localhost:3000/mcp

Option 2: Docker (pre-built image)

The container listens on all interfaces, so provide a token:

export MCP_AUTH_TOKEN="$(openssl rand -hex 32)"
docker run -d -p 3000:3000 -e MCP_AUTH_TOKEN tsparticles/mcp-server

Option 3: Docker Compose (build from source)

# Set a token, then build and start
export MCP_AUTH_TOKEN="$(openssl rand -hex 32)"
docker compose up -d

# Or with Cloudflare Tunnel for public HTTPS access
docker compose --profile tunnel up

MCP_AUTH_TOKEN is required by Compose because the container binds to all interfaces. Set it in your environment or in a .env file next to docker-compose.yml before starting the server or the tunnel. If all traffic arrives through a reverse proxy, set MCP_TRUSTED_PROXIES to the comma-separated IP addresses of every trusted proxy hop so rate limits and session quotas use the real client address. The edge proxy must overwrite or append the connecting client IP to X-Forwarded-For.

This prints a temporary URL like https://random.trycloudflare.com. Configure your MCP client with https://random.trycloudflare.com/mcp as the endpoint.

Option 4: Docker + Synology Reverse Proxy

If you have a Synology NAS:

  1. Build the image and start the container:
docker compose up -d
  1. On DSM, go to Control Panel > Application Portal > Reverse Proxy and add:

| Field | Value | | -------------------- | --------------------------- | | Source protocol | HTTPS | | Source hostname | your-nas-domain.example.com | | Source port | 8443 | | Enable HSTS | yes | | Destination protocol | HTTP | | Destination hostname | localhost | | Destination port | 3000 |

  1. Configure your MCP client with https://your-nas-domain.example.com:8443/mcp.

Option 5: Docker + Cloudflare Tunnel (permanent)

For a permanent URL (instead of the random trycloudflare.com):

  1. Install cloudflared and log in:
docker run cloudflare/cloudflared tunnel login
  1. Create a tunnel and route your domain:
cloudflared tunnel create tsparticles-mcp
cloudflared tunnel route dns tsparticles-mcp mcp.yourdomain.com
  1. Create a config file:
# config.yml
tunnel: tsparticles-mcp
credentials-file: /root/.cloudflared/tunnel.json
ingress:
  - hostname: mcp.yourdomain.com
    service: http://localhost:3000
  - service: http_status:404
  1. Run:
docker compose up -d mcp-server
cloudflared tunnel run tsparticles-mcp

Your MCP endpoint will be https://mcp.yourdomain.com/mcp.

Client endpoint configuration

When connecting to a remote HTTP server, use the endpoint URL with /mcp path:

https://your-server.example.com/mcp

Build from source

pnpm install
pnpm run build
pnpm run start        # stdio mode
pnpm run start:http   # HTTP mode on port 3000