`nemoclaw <sandbox> mcp add` configures mcporter, but the OpenClaw agent never loads that config — MCP appears wired while the agent has no servers
- Dominant language
- TypeScript
- Stars
- 22.5k
- Forks
- 3.1k
- Avg merge
- 1d 43m
- Merged PRs (30d)
- 718
Description
```
Host: Windows 11 + WSL2 Ubuntu (kernel 5.15.167.4-microsoft-standard-WSL2), Docker Desktop (WSL2 backend)
NemoClaw v0.0.109 (OpenShell runtime 0.0.101) · OpenClaw 2026.7.1 (2d2ddc4) · mcporter 0.7.3 (in sandbox)
Sandbox: `retrace-pilot`, Debian GNU/Linux 13 (trixie) · Provider: ollama-local → http://host.openshell.internal:11434/v1, preferredInferenceApi openai-completions · Ollama 0.33.2 (Windows host)
Models: qwen3.5:4b (2a654d98e6fb, 3.4GB), qwen3:8b (500a1f067a9f, 5.2GB)
MCP server under test: stateless Streamable HTTP endpoint (JSON or SSE responses; GET/DELETE → 405), bearer auth
```
_Found while wiring an MCP audit server ([Retrace](https://github.com/jordandru/retrace)) into an OpenClaw agent running in a NemoClaw sandbox; the full debugging trail is in a public provenance ledger: https://retrace-api.slcwitit.workers.dev/s/sh_ea81439e010abb1c0ec7167c (events evt_20c50c96, evt_4b22e5aa, evt_f14b52db)._
**What happens**
`nemoclaw retrace-pilot mcp add retrace --url https://…/mcp --env RETRACE_MCP_TOKEN` writes the server into `workspace/config/mcporter.json` (mcporter's shape, `baseUrl` key). `nemoclaw … mcp list` and `mcp status retrace --tools` then both succeed — status even enumerates the server's tools — so everything looks wired.
But the OpenClaw agent inside the sandbox never reads mcporter.json. Its own MCP registry is `.openclaw/openclaw.json` → `mcp.servers`, which expects `url` (not `baseUrl`). Result: the agent runs with zero MCP servers while every `nemoclaw mcp …` command reports healthy.
**Repro**
1. `nemoclaw mcp add --url --env TOKEN_VAR`
2. `nemoclaw mcp status --tools` → tools listed ✓
3. Ask the agent to call any of those tools → it has none.
**Config shapes** (token redacted)
Generated by `mcp add` at `workspace/config/mcporter.json` — the file the agent never loads:
{"mcpServers": {"retrace": {"baseUrl": "https://…/mcp", "headers": {"Authorization": "Bearer [REDACTED]:resolve:env:RETRACE_MCP_TOKEN"}}}, "imports": []}
Meanwhile: `openclaw mcp list` → "No OpenClaw-managed MCP servers configured in /sandbox/.openclaw/openclaw.json", and feeding the mcporter shape there is rejected —
[2026-09-03T15:01:56.885+00:00] [bundle-mcp] skipped server "retrace" because its command is missing and its url is missing.
The shape that works: `openclaw mcp set retrace` with {"url": "https://…/mcp", "headers": {"Authorization": "Bearer [REDACTED]"}} — `url`, not `baseUrl`. NemoClaw's own bridge record (host `~/.nemoclaw/sandboxes.json`) declares {"server": "retrace", "agent": "openclaw", "adapter": "mcporter", …} — an adapter contract the agent side never honors. Copying mcporter.json into /sandbox/.openclaw/config/ changed nothing.
**Expected**
Either `mcp add` writes to the registry the selected runtime actually loads, or `mcp status` should say it is reporting mcporter's view, not the agent's.
**Workaround** we used: register the server manually in `.openclaw/openclaw.json` with `url`. Ledger: evt_4b22e5aa.
Contributor guide
Research direction
Start at the `nemoclaw mcp add`, `mcp list`, and `mcp status` entry points, then trace how `workspace/config/mcporter.json` relates to `.openclaw/openclaw.json`. Reproduce the reported sequence and verify which registry the selected OpenClaw runtime loads. Done means the added server is usable by the agent, or status clearly identifies when it reports only mcporter's view.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- backend-api-design, cli
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Active
- Clarity
- Clearly specified
- Newbie friendliness
- 55/100