Caricamento in corso...
Caricamento in corso...
Last synced: Today, 22:00
Technical reference for the OpenClaw framework. Real-time synchronization with the official documentation engine.
Use this file to discover all available pages before exploring further.
OpenRouter provides a unified API that routes requests to many models behind a single endpoint and API key. It is OpenAI-compatible, so most OpenAI SDKs work by switching the base URL.
text```bash} openclaw models set openrouter/<provider>/<model> ```
json5{ env: { OPENROUTER_API_KEY: "sk-or-..." }, agents: { defaults: { model: { primary: "openrouter/auto" }, }, }, }
Bundled fallback examples:
| Model ref | Notes |
|---|---|
text openrouter/auto | OpenRouter automatic routing |
text openrouter/moonshotai/kimi-k2.6 | Kimi K2.6 via MoonshotAI |
OpenRouter can also back the
image_generateagents.defaults.imageGenerationModeljson5{ env: { OPENROUTER_API_KEY: "sk-or-..." }, agents: { defaults: { imageGenerationModel: { primary: "openrouter/google/gemini-3.1-flash-image-preview", timeoutMs: 180_000, }, }, }, }
OpenClaw sends image requests to OpenRouter's chat completions image API with
modalities: ["image", "text"]aspectRatioresolutionimage_configagents.defaults.imageGenerationModel.timeoutMsimage_generatetimeoutMsOpenRouter can also back the
video_generate/videosagents.defaults.videoGenerationModeljson5{ env: { OPENROUTER_API_KEY: "sk-or-..." }, agents: { defaults: { videoGenerationModel: { primary: "openrouter/google/veo-3.1-fast", }, }, }, }
OpenClaw submits text-to-video and image-to-video jobs to OpenRouter, polls the returned
polling_urlunsigned_urlsreference_imagegoogle/veo-3.1-fast720P1080P16:99:16OpenRouter can also be used as a TTS provider through its OpenAI-compatible
/audio/speechjson5{ messages: { tts: { auto: "always", provider: "openrouter", providers: { openrouter: { model: "hexgrad/kokoro-82m", voice: "af_alloy", responseFormat: "mp3", }, }, }, }, }
If
messages.tts.providers.openrouter.apiKeymodels.providers.openrouter.apiKeyOPENROUTER_API_KEYOpenRouter uses a Bearer token with your API key under the hood.
On real OpenRouter requests (
https://openrouter.ai/api/v1| Header | Value |
|---|---|
text HTTP-Referer | text https://openclaw.ai |
text X-OpenRouter-Title | text OpenClaw |
text X-OpenRouter-Categories | text cli-agent |
© 2024 TaskFlow Mirror
Powered by TaskFlow Sync Engine