ssimplifi-prism-mcp
v1.8.0
Published
Model Context Protocol server for Prism by Ssimplifi — exposes the AI gateway's chat, catalog, usage, cache, and admin surface as MCP tools.
Maintainers
Readme
ssimplifi-prism-mcp
Model Context Protocol server for the Prism AI gateway. Lets Claude Desktop, Cursor, Zed, Continue, Cline, and any other MCP-capable client call Prism's chat endpoint, look up the model catalog, estimate costs, check usage / cache / savings, and submit feedback — all from inside an AI conversation.
Install
npm install -g ssimplifi-prism-mcpConfigure (Claude Desktop)
Edit ~/Library/Application Support/Claude/claude_desktop_config.json (macOS) or %APPDATA%\Claude\claude_desktop_config.json (Windows) and add:
{
"mcpServers": {
"prism": {
"command": "prism-mcp",
"env": {
"PRISM_API_KEY": "prism_sk_..."
}
}
}
}Restart Claude Desktop. The Prism tools appear in the model's tool list automatically.
Configure (Cursor, Zed, Continue, Cline)
All speak the same MCP stdio protocol. Find your client's MCP config UI and add:
| Field | Value |
|---|---|
| Server name | prism |
| Command | prism-mcp (must be on PATH) |
| Env: PRISM_API_KEY | your prism_sk_* key |
| Env: PRISM_MCP_WRITE_KEY | (optional) write-scope key for mutating tools |
Tier requirements
Every MCP tool requires Pro ($19/mo) or Team ($49/mo) tier on the account behind the API key. On startup, the server calls /v1/whoami and:
- Free / Paid (pay-as-you-go) tier → server registers 0 tools and logs an upgrade URL to stderr. The MCP client shows "no capabilities available."
- Pro / Team → all read tools register immediately.
This matches the v1.8 plan: chat + admin orchestration via MCP is a power-user feature; the chat API itself remains universal at /v1/chat/completions for any tier.
Read-scope tools (registered when PRISM_API_KEY is set)
| Tool | What it does |
|---|---|
| prism_chat | Send a chat message; returns the response + tokens + cost |
| prism_list_models | Live model catalog (provider, capability, $/1M) |
| prism_estimate_cost | Estimate a call's cost before sending |
| prism_get_usage | Your usage stats (tokens, $, by-model/mode) |
| prism_get_savings | Public global savings counter |
| prism_get_cache_stats | Your cache hit rate + savings |
| prism_submit_feedback | Submit thumbs / rating / comment on a request |
| prism_list_keys | List your API keys (no secrets exposed) |
| prism_get_balance | Prepaid balance + tier |
| prism_get_session | Messages stored for a session ID |
| prism_list_recent_requests | Recent chat requests with latency + cost |
| prism_get_provider_health | Rolling 5-min provider health weights |
Write-scope tools (registered when PRISM_MCP_WRITE_KEY is set — coming in P3b)
Mutating tools (cache settings, routing policy, budget caps, member kicks, key revokes, etc.) are gated by a second key — PRISM_MCP_WRITE_KEY — that's only issued after email confirmation. Run prism mcp enable-writes via the ssimplifi-cli to start the email flow.
Even with the write key set, every destructive tool uses a Layer-1 confirmation pattern: the first call returns { status: "confirmation_required", consequences: [...] }, and the AI client must re-call with confirmed: true to proceed. This prevents accidental damage from prompt-injection or AI mid-conversation slips.
Development
cd mcp
npm install
npm run build # tsc → dist/
npm run dev # tsc --watch
PRISM_API_KEY=prism_sk_... echo "" | node dist/index.js # quick startup smokeLicense
Apache-2.0
