Registers OmniRoute — a multi-provider model routing proxy — as a first-class text inference, embedding, image generation, video generation, and web search provider in OpenClaw. Routes through models from 236+ providers with automatic fallback, live model discovery, and OpenAI-compatible transport.
# Install from ClawHub
openclaw plugins install clawhub:@ekinnee/omniroute-provider
# Set your OmniRoute API key
export OMNIROUTE_API_KEY="your-key-here"
# Verify it works
openclaw models list | grep omnirouteOmniRoute appears as a model provider immediately. Select omniroute/auto when OmniRoute advertises it, or pick any chat-capable model discovered from OmniRoute's live catalog.
| Variable | Required | Default | Description |
|---|---|---|---|
OMNIROUTE_API_KEY |
Yes | — | API key for your OmniRoute gateway |
OMNIROUTE_BASE_URL |
No | http://localhost:20128/v1 |
Custom base URL |
Override the base URL in your OpenClaw config:
{
models: {
providers: {
omniroute: {
baseUrl: "http://localhost:20128/v1",
},
},
},
}This is useful for Docker, remote, or cloud-hosted OmniRoute instances.
OmniRoute can also serve OpenClaw embedding requests through POST /v1/embeddings.
Configure a specific embedding model from OmniRoute's GET /v1/models response:
{
agents: {
defaults: {
memorySearch: {
provider: "omniroute",
model: "provider/embedding-model-from-omniroute",
},
},
},
}The plugin does not default embeddings to auto. Embedding model and dimensionality are part of the vector index identity, so changing either can invalidate an existing index or make queries fail.
OmniRoute can serve OpenClaw image generation requests through POST /v1/images/generations.
Configure a specific image model from OmniRoute's GET /v1/models response:
{
agents: {
defaults: {
imageGenerationModel: {
primary: "omniroute/provider/image-model-from-omniroute",
},
},
},
}The initial image support is text-to-image only. Image edits and reference images remain planned. The plugin does not default image generation to auto; use an image-capable model that OmniRoute advertises.
OmniRoute can serve OpenClaw web search requests through POST /v1/search.
The plugin registers itself as a web search provider automatically — no additional configuration needed.
{
tools: {
web: {
search: {
provider: "omniroute",
},
},
},
}The web search tool supports query, count (1-10), freshness (day/week/month/year), country, and language parameters. Results include titles, URLs, snippets, and full page content when available.
- Live model discovery — On startup, the plugin fetches
GET /v1/modelsfrom your OmniRoute gateway and registers chat-capable rows asomniroute/<model-id>. These models are available at runtime for model routing and inference. Note thatopenclaw models listreads from the cached static catalog and may only show theautofallback model — the full live-discovered catalog is used during actual routing. - Static fallback — The
omniroute/automodel is available when OmniRoute is offline or unauthenticated, so setup can proceed without a running gateway. When live discovery succeeds,autois shown only if OmniRoute returns it. - OpenAI-compatible transport — Text requests use standard OpenAI chat completions format (
POST /v1/chat/completions) with streaming usage support. - Configured embeddings — Embedding requests use OmniRoute's OpenAI-compatible
POST /v1/embeddingsendpoint, but require a configured embedding model instead of falling back toauto. - Configured image generation — Image requests use OmniRoute's OpenAI-compatible
POST /v1/images/generationsendpoint with a configured image model. - Web search — Search requests use OmniRoute's
POST /v1/searchendpoint. The plugin registers as a web search provider automatically.
The plugin currently exposes OmniRoute as an OpenAI-compatible chat provider. The longer-term goal is to cover OmniRoute's full published API surface as OpenClaw plugin capabilities mature.
| Capability | Status |
|---|---|
Chat completions (/v1/chat/completions) |
✅ Initial support |
Live model catalog (GET /v1/models) |
✅ Initial support |
Embeddings (/v1/embeddings) |
✅ Initial support |
Image generation (/v1/images/generations) |
✅ Initial support |
Image edits (/v1/images/edits) |
🔜 Planned (part of ImageGenerationProvider) |
Web search (/v1/search) |
✅ Initial support |
Speech (/v1/audio/speech) |
🔜 Planned |
Transcription (/v1/audio/transcriptions) |
🔜 Planned |
Video generation (/v1/videos/generations) |
✅ Initial support |
Music generation (/v1/music/generations) |
🔜 Planned |
| OmniRoute Endpoint | Notes |
|---|---|
/v1/responses |
OpenAI Responses API — no OpenClaw provider surface |
/v1/completions |
Legacy completions — no OpenClaw provider surface |
/v1/messages |
Anthropic-compatible — no OpenClaw provider surface |
/v1/rerank |
Cohere-compatible rerank — no OpenClaw provider surface |
/v1/moderations |
OpenAI-compatible moderation — no OpenClaw provider surface |
/v1/batches |
Batch processing — no OpenClaw provider surface |
/v1/files |
File uploads — no OpenClaw provider surface |
git clone https://github.com/ekinnee/omniroute-openclaw
cd omniroute-openclaw
pnpm install
pnpm testMIT