{
  "markdown": "# sentinelone-mcp\n\nMultitenant Streamable HTTP wrapper for [sentinel-one/purple-mcp](https://github.com/Sentinel-One/purple-mcp), built so the [wyre-technology MCP gateway](https://github.com/wyre-technology/mcp-gateway) can forward per-tenant SentinelOne credentials as HTTP headers.\n\n## Why\n\n`purple-mcp` is a great first-party MCP server, but it reads its SentinelOne console token + URL from environment variables at process startup, which makes it single-tenant per container. Our gateway is multi-tenant: every request carries the calling org's credentials as HTTP headers, and the vendor container has to translate those headers into something the upstream understands.\n\nThis image bundles `purple-mcp` plus a small Node/Fastify proxy. The proxy:\n\n1. Listens on `:8080` with `POST /mcp` and `GET /health`.\n2. Reads `x-purplemcp-token` and `x-purplemcp-base-url` from each incoming request.\n3. Lazily spawns one `purple-mcp --mode streamable-http` child per `(token, base-url)` tenant on a private loopback port, with the right env vars set.\n4. Proxies the request body to that child and streams the response back.\n5. Evicts idle children after 60 minutes (`IDLE_EVICT_MS`).\n\nThe result is a single container that the gateway can talk to like any other vendor MCP server.\n\n## Configuration\n\n| Env var | Default | Notes |\n|---|---|---|\n| `PORT` | `8080` | Public listen port. |\n| `PURPLE_MCP_DIR` | `/opt/purple-mcp` | Where purple-mcp source + venv live. |\n| `PURPLE_MCP_PYTHON` | `/opt/purple-mcp/.venv/bin/python` | Python interpreter from the upstream venv. |\n| `IDLE_EVICT_MS` | `3600000` | Idle tenant timeout (60 min). Longer keeps children warm and avoids repeated cold starts. |\n| `SPAWN_READY_TIMEOUT_MS` | `30000` | How long to wait for a child to start serving HTTP. |\n| `MAX_CHILDREN` | `50` | Cap on distinct concurrent tenant children. A new-tenant spawn beyond the cap is rejected (`502`) rather than evicting an existing child. |\n| `LOG_LEVEL` | `info` | Fastify log level. |\n\n## Request headers\n\nThe gateway must forward these headers on every `/mcp` request:\n\n| Header | SentinelOne credential |\n|---|---|\n| `x-purplemcp-token` | `PURPLEMCP_CONSOLE_TOKEN` (Account- or Site-level service user token) |\n| `x-purplemcp-base-url` | `PURPLEMCP_CONSOLE_BASE_URL` (e.g. `https://yourtenant.sentinelone.net`) |\n\n## Build\n\n```bash\ndocker build -t ghcr.io/wyre-ai/sentinelone-mcp:latest .\n```\n\n## License\n\nApache-2.0. The bundled `purple-mcp` is MIT-licensed by SentinelOne.\n",
  "bytes": 2490,
  "sha": "82ba211421ee49b8fdc4b3ce9dd5099e4c7454ac1e4cf9aeebf34a3cb7dbc24f",
  "repo_slug": "wyre-technology/sentinelone-mcp",
  "fonte": "repo",
  "truncated": false,
  "api": "https://agentalog.com/api/listings/mcp_io_github_wyre_technology_sentinelone_mc_948f495a/readme"
}