Skip to content

MCP Server ​

AccelsRouter ships a hosted MCP (Model Context Protocol) server — a single Streamable HTTP endpoint that exposes the gateway's catalog, pricing, account and chat abilities as tools your coding agent (Claude Code, Cursor, Codex, …) can call directly.

Instead of remembering model ids and prices, your agent asks the gateway directly.

Endpoint & auth ​

Endpointhttps://router.accels.tech/mcp
TransportStreamable HTTP (stateless)
AuthAuthorization: Bearer sk-... — your normal API key

The MCP endpoint runs behind the same authentication as the API. A disabled, expired, or exhausted key is rejected, and every tool acts as that key — you only ever see the models, prices, credit and request history that key is entitled to.

Setup ​

Claude Code ​

bash
claude mcp add --transport http accelsrouter https://router.accels.tech/mcp \
  --header "Authorization: Bearer sk-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"

Cursor / generic JSON clients ​

Add to the client's MCP config (e.g. Cursor's mcp.json):

json
{
  "mcpServers": {
    "accelsrouter": {
      "url": "https://router.accels.tech/mcp",
      "headers": {
        "Authorization": "Bearer sk-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
      }
    }
  }
}

Any MCP client that speaks Streamable HTTP with a custom header works the same way — point it at the endpoint and pass the Authorization header.

Tools ​

Seven of the eight tools are read-only and free. Only send-message consumes credit.

ToolWhat it doesKey parametersCost
pingHealth check; returns ok and server time—Free
list-modelsModels this key can call, with provider, supported endpoints and the effective price for this keysearch, provider, endpoint, limit (≤500)Free
get-modelFull details for one model: description, tags, provider, endpoints, billing type, effective pricemodelFree
get-model-pricingEffective price of one model for this key (USD per 1M tokens, or per call), including the group ratiomodelFree
get-creditsThis key's own cap and spend, plus the balance that funds it (a personal balance or an organization wallet); distributor admins also see the separate distributor wallet—Free
get-generationCost, token counts and timing of one past request, by request idrequest_idFree
list-daily-model-rankingsMost-used models on the platform over the last N days, by token volumedays (≤30), limit (≤50)Free
send-messageSend a chat message to a model and return the reply, token usage and costmodel, prompt or messages, system, max_tokens, temperatureConsumes credit

send-message is dispatched internally through the normal /v1/chat/completions path, so model allow-lists, routing, rate limits and billing apply exactly as they would for a direct API call.

Request ids ​

send-message returns a request_id — the same id returned in the response headers of a direct API call. Pass it to get-generation to read the final billed cost, token counts and latency once the call is recorded.

Distributor tools ​

If you're a distributor (reseller) admin, the server exposes an extra set of read-only tools for running your distribution business. They appear only when you call with one of your own distributor keys — a personal key, or a key in your distributor workspace. Ordinary users and your customers' keys never see them. All are free; anything that moves money or changes a customer's offer stays in the console behind its own 2FA.

ToolWhat it doesKey parameters
reseller-summaryYour distributor account at a glance: wallet balance, price group, wholesale discounts and customer count—
reseller-customersYour customers with status, wallet balance, net credit you've allocated and how many models each may use—
reseller-usageUsage and profit over the last N days — standard price, what customers paid you, your cost and margin — broken down by customer, model and memberdays (≤90), customer_id (optional)
reseller-customer-logsRecent call records of one customer: model, tokens, standard price, what they paid, latency and request idcustomer_id, days (≤90), limit (≤100)
reseller-customer-offerThe models one customer may call and the per-model-series discounts you granted themcustomer_id
reseller-ledgerYour distributor wallet ledger: purchases, allocations to customers and revocations, newest firstlimit (≤100)

Typical workflow ​

A coding agent connected to the MCP server can, for example:

  1. list-models — discover what models are available to the key
  2. get-model-pricing — compare the effective price of two candidate models
  3. get-credits — check there's enough balance
  4. send-message — run a quick test prompt against the chosen model
  5. get-generation — confirm the exact cost of that call

All of this happens without leaving the agent or hard-coding model ids and prices.

Notes ​

  • Stateless — every request is a self-contained session; nothing is stored between calls.
  • Same billing as the API — credit, quotas and rate limits are shared with your key's normal API usage; the MCP server is just another way in.
  • Least privilege — issue a dedicated key (optionally quota-capped) for agents that only need catalog/pricing lookups. See API Keys.