Tokenlab MCP Server logo

Tokenlab MCP Server

by hedging8563

Connects agents to TokenLab model discovery, pricing, inference, media generation, files, embeddings, and async tasks.

Install Tokenlab MCP Server

Pick your client, then add it in one click or paste the config.

STDIONode.js
~/Library/Application Support/Claude/claude_desktop_config.json
claude_desktop_config.json
{
  "mcpServers": {
    "hedging8563-tokenlab-mcp-server": {
      "command": "npx",
      "args": [
        "-y",
        "@tokenlabai/mcp-server"
      ]
    }
  }
}

Settings → Developer → Edit Config, merge this into mcpServers, then fully quit and reopen Claude Desktop.

Install not yet sandbox-tested— the server itself is confirmed live (we called its tools/list endpoint). The stdio install command is a separate, ongoing check.

Overview

hedging8563/tokenlab-mcp-server connects MCP clients to TokenLab's public catalog and developer API. It exposes model and pricing discovery without credentials, plus credentialed tools for native OpenAI, Anthropic, and Gemini requests, media generation, files, embeddings, reranking, translation, and asynchronous jobs. Reach for it when an agent needs current model capabilities and pricing before selecting an endpoint, or when one MCP connection should cover text, multimodal, and media workflows. The server runs over stdio and preserves the native request shapes of the supported APIs.

Use cases

  • Discover models and compare pricing before selecting an inference route
  • Call OpenAI, Anthropic, or Gemini-compatible model endpoints from an MCP client
  • Generate and poll video, music, or 3D media tasks
  • Process files, embeddings, reranking, audio, and translation through TokenLab
  • Generate or edit images while handling synchronous and asynchronous results

Key features

  • Public model and pricing discovery without an API key
  • Native OpenAI, Anthropic, and Gemini request formats
  • Image, audio, video, music, and 3D generation tools
  • Async task polling and supported task cancellation
  • File, embedding, reranking, and translation operations
  • Configurable tool profiles and JSON Schema modes

Tools31

What Tokenlab MCP Server lets your agent do. Expand a tool for its parameters.

Verified live~12.2k tokens of context

Security & health

What it can reach and how reliably it runs — from our own checks, not the maintainer’s claims.

ActiveLast checked 1d ago

Recent health check succeeded.

19/19 checks healthy over the last 78d

Supply-chain signal

No high-severity advisories surfaced by our automated scan.

Critical 0High 0Medium 0Low 0

Scanned 7d ago via OSV.dev · @tokenlabai/mcp-server (npm)

Adoption & maintenance

Factual signals from GitHub, npm, and our automated checks — not a rating.

GitHub stars1Stargazers on the source repository.
npm downloads3kPackage downloads in the last 30 days.
Last commit2d agoMost recent push to the default branch.
Tools exposed31Callable tools this server registers over MCP.
Directory activity3 viewsConfig copies, upvotes, and views on AllMCPs.

How Tokenlab MCP Server works

What hedging8563/tokenlab-mcp-server does

hedging8563/tokenlab-mcp-server presents TokenLab's model catalog and developer API as MCP tools. Public operations cover model listing, model details, pricing, and model comparison without an API key. Credentialed operations can call OpenAI-compatible Chat Completions, the OpenAI Responses API, Anthropic Messages, and Gemini GenerateContent, along with image, speech, transcription, translation, embedding, reranking, and multimodal embedding endpoints.

The server also covers asynchronous video, music, and 3D generation through task creation, status retrieval, and cancellation where the selected task supports it. File upload, listing, retrieval, content retrieval, and deletion are available for supported TokenLab and provider-specific workflows.

How it works

Install the npm package or run the included Docker image, then connect an MCP client to the server's stdio process. The default core profile exposes catalog functions and the main inference, media, file, embedding, reranking, and translation layers. catalog narrows the tool list to public discovery and pricing, while full exposes the broader allowlisted developer API. Schema modes control how much of the generated JSON Schema is shown to the client.

Tool definitions are generated from TokenLab's OpenAPI contract with an MCP-specific overlay. Calls are validated against the complete generated schema before an HTTP request is sent. Native endpoint shapes remain available instead of being converted into one shared prompt format. The server returns structured MCP content while retaining serialized text for clients that use older response handling.

Video, music, and 3D requests always return asynchronous tasks. Image operations can be synchronous or asynchronous depending on the selected model, so callers should inspect the returned delivery mode and poll with get_task_status when necessary. Larger binary results are written to an artifact directory rather than returned inline.

Setup and configuration

Run the package with npx -y @tokenlabai/mcp-server, install it with npm and start it locally, or build and run the supplied Docker image. Set TOKENLAB_API_BASE to use a different TokenLab API base URL; it defaults to https://api.tokenlab.sh. Public catalog and pricing calls work without credentials. Set TOKENLAB_API_KEY for inference, generation, task, embedding, reranking, decision, and translation calls.

TOKENLAB_MCP_TOOL_PROFILE accepts catalog, core, or full. TOKENLAB_MCP_SCHEMA_MODE accepts portable, exact, or strict. Additional settings control request timeout, local upload size, inline binary response size, and the artifact output directory through TOKENLAB_REQUEST_TIMEOUT_MS, TOKENLAB_MCP_MAX_FILE_BYTES, TOKENLAB_MCP_INLINE_BYTES, and TOKENLAB_ARTIFACT_DIR.

Tools and capabilities

  • Discover available models, supported request formats, parameters, endpoints, and pricing.
  • Compare public details and prices for multiple model IDs.
  • Submit OpenAI-compatible, Anthropic-native, and Gemini-native inference requests.
  • Generate or edit images, create speech, transcribe or translate audio, and create multimodal embeddings.
  • Create and monitor video, music, and 3D generation jobs.
  • Upload, inspect, retrieve, and delete supported files.
  • Produce text embeddings and rerank documents by relevance.

Chat image data URLs should use their actual image MIME type. Recognized PNG, JPEG, WebP, and GIF payloads labeled as generic binary are corrected before forwarding; unrecognized generic binary image payloads are rejected locally.

Limitations and notes

Streaming-only and realtime operations are excluded because stdio MCP calls return one final result. Provider availability depends on the selected model's advertised request format and the availability of a matching TokenLab route; a model name alone does not guarantee support for Responses or Gemini requests. Failed generation requests are not retried automatically. Clients should confirm billable or destructive actions and treat model or API output as untrusted content.

Reviews

No reviews yet — be the first to share how it worked for you.

Frequently Asked Questions about Tokenlab MCP Server

hedging8563/tokenlab-mcp-server is an MCP server that connects AI clients to TokenLab's public model catalog and developer API. Its main tools discover models and pricing, call OpenAI-, Anthropic-, and Gemini-compatible inference endpoints, generate media, manage files, create embeddings, rerank documents, translate content, and monitor asynchronous tasks.

Install it with `npx -y @tokenlabai/mcp-server`, or run `npm install` followed by `npm start`. It can also run from the supplied Docker image with an interactive container. Configure the resulting stdio process in an MCP client such as Claude Desktop.

No, a TokenLab API key is not required for public model discovery and pricing tools. Set `TOKENLAB_API_KEY` for text inference, media generation, asynchronous tasks, embeddings, reranking, decisions, and translation operations.

Set `TOKENLAB_MCP_TOOL_PROFILE=catalog` for the smallest public-only tool list, or use `core` for the default set. Set `TOKENLAB_MCP_TOOL_PROFILE=full` when the broader allowlisted developer API is needed.

Related MCP servers

Add a badge to your READMEShow it’s listed — live SVG, Markdown or HTML.

AllMCPs Directory Badge

Full Badge Customizer

Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.

Badge Style:
Live Dynamic SVG PreviewTokenlab MCP Server AllMCPs Directory Badge
Markdown (GitHub README)
[![AllMCPs](https://allmcps.com/api/badge/hedging8563-tokenlab-mcp-server?style=directory)](https://allmcps.com/mcp/hedging8563-tokenlab-mcp-server)
HTML Embed
<a href="https://allmcps.com/mcp/hedging8563-tokenlab-mcp-server"><img src="https://allmcps.com/api/badge/hedging8563-tokenlab-mcp-server?style=directory" alt="Tokenlab MCP Server on AllMCPs" /></a>