OpenClaw had no Library target, so Library -> MCP had no switch for it,
and the router couldn't be turned on there. OpenClaw 2026.11.6 reads MCP
servers from openclaw.json's mcp.servers. Its schema is strict: an
unknown key such as timeout, type or toolFilter.allow fails the whole
config. So the new fmtOpenClaw writes only keys OpenClaw accepts:
- remote servers: url, transport (streamable-http or sse) and headers;
- local servers: command, args and env;
- requestTimeoutMs for magpie's own long servers (its default is 60s).
The transport is written for every remote server, because OpenClaw
treats a url with no transport as SSE. Keys the user set themselves are
left alone: toolFilter, requestTimeoutMs, auth, enabled and the rest.
OpenClaw fails the whole file on an unset ${VAR}, so it gets no env
refs.
Image generation and built-in search (2nd half of the report): magpie
wires OpenClaw as openai-completions. OpenClaw's native OpenAI web
search applies only to direct OpenAI traffic, and image_generate needs
an image provider configured in OpenClaw. The gateway drops nothing.
With this target, Magpie Image and Magpie Web Search can now be given to
OpenClaw as MCP servers. Native wiring is #7334. Refs #5897.
Run:
- TestOpenClawMCP and TestOpenClawMCPHub (new) on mote.
- Real OpenClaw 2026.11.6 (Node 24.22.1) in a sandbox HOME on mote, on
the openclaw.json magpie wrote:
- "Config valid", and mcp doctor all ok;
- mcp status shows magpie as streamable-http;
- mcp probe lists the tools of the stdio server (with env), of the
streamable HTTP magpie entry, and of a user server with toolFilter.
- Full acceptance on mote at b9dc1d0be + this commit:
- gofmt -l clean;
- go vet, GOOS=linux go vet -tags nogui and GOOS=windows go vet ok;
- build ok;
- go test -tags nogui -timeout 45m ./...: every package ok except
four reds outside internal/library. Three are filed:
TestOpenCodeGoOwnFreeModelGetsNothingOfOpenCodes (#7117),
TestBuiltinsTranslated (#7257) and
TestSettingsSaveKeepsWhatItDoesNotSend (#7240). The fourth,
TestShimIgnoresDialogWordsInHistory, is new as #7341.
Broken by hand:
- the old targets.go (no openclaw case): both tests red;
- encode writing transport "http": both tests red;
- removing transport in real OpenClaw: mcp status said sse and the
probe timed out against the streamable server.
Not tried:
- a real magpie gateway hub (a fake streamable MCP server stood in);
- OpenClaw skills and instructions targets;
- the GUI switch in a browser.