OpenRouter

OpenRouter

OpenRouter, one API for hundreds of AI models: search the model catalog with prices, providers, benchmarks and rankings, check the key's spending, look up past generations, and send chat completions, embeddings and image requests to any model.

7 日間無料 · クレジットカード不要 · EU ホスト

OpenRouter に何でも聞ける

AnythingMCP 経由で OpenRouter に実際のプロンプトを試そう — Claude がツールを呼び出し、回答します。あなたのメッセージで Enter を押すと Cloud にインストールします。

OpenRouter を Cloud にインストール
OpenRouter · MCP 経由でライブ
共有
Opus 4.7

Claude は AI のため誤ることがあります。回答をご確認ください。

2 分でセットアップ

  1. 1cloud.anythingmcp.com で無料トライアル開始。
  2. 2コネクターストアで OpenRouter をクリック。資格情報を貼り付け。
  3. 3MCP API キーを発行し、AI クライアントを MCP URL に向ける。
OpenRouter を今すぐインストール

OpenRouter のガイド

主要 AI クライアント向けのステップバイステップセットアップ。

OpenRouter のセットアップ

コネクタ定義そのものから:認証情報の入手先、必要な権限、このアダプタが呼び出す API。 コネクタ作者により英語で提供されています。

OpenRouter

This connector uses the OpenRouter API (https://openrouter.ai/api/v1), one OpenAI-compatible endpoint in front of hundreds of models from OpenAI, Anthropic, Google, Meta, Mistral, DeepSeek and others. It searches the model catalog, compares providers, prices and benchmarks, shows what the key has spent, looks up past generations, and sends chat completions, embeddings and image requests to any model.

Setup (2 minutes)

  1. Sign in at https://openrouter.ai and add credits under Settings, Credits (free :free models work without credits, within daily limits).
  2. Open Settings, API Keys (https://openrouter.ai/settings/keys), click Create Key, give it a name and, strongly recommended, a credit limit: the key can spend the account balance up to that limit.
  3. Paste the key (it starts with sk-or-v1-) into OPENROUTER_API_KEY. It is sent as Authorization: Bearer. Requests carry HTTP-Referer and X-OpenRouter-Title headers that name AnythingMCP as the calling app on OpenRouter.
  4. Run openrouter_get_current_key to check the key.

Workflow

  • Choose a model: openrouter_list_models (filters such as q, category, supported_parameters=tools, max_price, context, sort=pricing-low-to-high) or openrouter_list_user_models for the models this key may use under the account's privacy settings and guardrails. Then openrouter_get_model for one model's details, openrouter_list_model_endpoints for the providers that serve it with their prices, uptime, latency and throughput, and openrouter_list_providers for provider slugs and data policies.
  • Compare quality and popularity: openrouter_list_benchmarks (Artificial Analysis, Design Arena, OpenRouter evals), openrouter_get_model_rankings (top models by tokens per day, week or month).
  • Run a model: openrouter_chat_completion with model and messages; models adds fallbacks, provider steers routing (order, only, sort by price or throughput, data_collection deny, zdr), response_format asks for JSON, reasoning sets the effort. openrouter_create_embeddings for vectors, openrouter_generate_image for images (returned as image content). These three spend credits: confirm with the user before repeated or large calls and set max_completion_tokens to cap a reply.
  • Spending: openrouter_get_current_key shows the key's limit, limit_remaining and usage today, this week, this month and in total. openrouter_get_generation gives the exact cost, tokens and provider of one call (its id is the id of the completion; it can take a few seconds to appear), openrouter_get_generation_content the stored prompt and output when prompt logging is on.

Reading the answers

  • Model ids are author/slug (openai/gpt-4o); split them for author and slug. Variants: :free (free, rate limited), :online (web search), :nitro (fastest provider), :floor (cheapest), :thinking.
  • Prices in the catalog are strings in USD per token ("0.0000025" = 2.50 USD per million tokens); request and image are per request or per image. The max_price filters and the routing max_price take USD per million tokens. Costs and usage in key and generation answers are USD.
  • A completion returns choices[0].message.content, the finish_reason (stop, length when the token cap was hit, tool_calls, content_filter) and usage with token counts and cost. The provider field says who served it.
  • created is Unix seconds; dates are UTC.

Paging: the model list tools return 50 models by default; pass offset 50, 100, ... with the same limit until a page comes back shorter than limit. Prefer filters and sort over reading the whole catalog.

Limits: :free models allow 20 requests a minute and 50 a day (1,000 a day once 10 USD of credits were ever bought). Paid models are limited by the account balance, the key's credit limit and any budgets an organization admin set; openrouter_get_current_key shows them. Benchmarks allow 30 requests a minute per key.

Not included: credit balance of the whole account, activity reports, analytics and key management need a separate management key and are not part of this connector; streaming, the legacy text completions endpoint, batches, video and audio are not exposed either.

Errors: 401 invalid or disabled key; 402 not enough credits or the key's limit is used up (error.metadata.limit_source says which; add credits or raise the limit); 403 blocked by a guardrail or moderation; 404 unknown model or generation; 408 timeout; 429 rate limited (wait, or use a paid variant); 502 the model's provider failed; 503 no provider matches the routing requirements (relax provider). A provider error during generation can arrive with HTTP 200 and an error object; it is reported as a failed call.

あなたの AI は OpenRouter から 2 クリック先。

コネクターをインストール、資格情報を貼り付け、AI に質問。7 日間無料、クレジットカード不要。