# Connecting Fleet, Atlas, ID and agent harnesses

MCPX helps an agent find a tool by its description and call it through the gateway. Atlas searches the user's corpus after an authorized caller selects its search tool. Indexing Atlas documents into the shared MCPX catalog would change both the disclosure boundary and the unit of retrieval. Keep tool descriptions and corpus chunks in their respective indexes. As of source revision `1f9bc15391ca`, the hosted Atlas Worker offers one MCP search tool. The Worker routes it through the same executor as REST and describes a fixed hosted-per-user identity and personal ceiling. Registering that URL gives agents a route. It does not identify the four harnesses independently. [Worker](https://github.com/developing-today/code/blob/1f9bc15391ca1c2efa639463a6369392456c27e5/pkgs/atlas-search/worker/src/mcp.ts#L2) · [Cross-client acceptance #8625](https://github.com/developing-today/code/issues/8625)

## Fleet routing and identity

For the pass-through proposed in #10390, resolve the endpoint in this order: explicit override, configured service endpoint, then the standard local endpoint. Resolve the credential for the selected endpoint and audience independently. Return an error when no matching credential is available. An explicit endpoint override must never redirect a credential resolved for the default host. Names of grants and endpoints are suitable diagnostics. Header values and URL query strings need to stay out of diagnostic output. Apply the same route checks to the raw-operation form. Preserve exit codes, structured refusals, request IDs, stdin and cancellation across the CLI boundary. [Fleet surface #10389](https://github.com/developing-today/code/issues/10389) · [Endpoint resolution #10390](https://github.com/developing-today/code/issues/10390)

The existing Fleet search client deliberately signals service failure to its caller for a visible standalone fallback. Keep that behavior for callers already entitled to standalone search. An MCP-scoped delegation authorizes only its declared route and corpora. A timeout, denial or unknown identity cannot implicitly authorize a filesystem search. For a multi-hop gateway path record the immediate principal and effective delegated scope at each hop. Intersect permissions again when expanding a fan-out. Include a visited-gateway set and a hop limit. When several destinations expose the same display name, return stable qualified identities. A partial read result should enumerate failed destinations within the caller's visibility. A fan-out mutation requires separately authorized target operations with a per-target outcome. [Fleet client](https://github.com/developing-today/code/blob/1f9bc15391ca1c2efa639463a6369392456c27e5/pkgs/fleet/crates/fleet-search/src/client.rs#L11) · [Aggregation #10393](https://github.com/developing-today/code/issues/10393) · [Delegation #10405](https://github.com/developing-today/code/issues/10405)

## Atlas acceptance across harnesses

Perform acceptance with synthetic documents at two sensitivity levels in two distinct corpora. Give OpenClaw, OpenCode, OpenChamber and Muse independently attributable caller identities. For each lane retain the asserted grant, the gateway decision, the Atlas decision, the permitted chunk and its source reference, and the trace ID. Prove corpus and sensitivity constraints inside Atlas's candidate queries before scoring. Reuse an identical query first with the wider grant and then with the narrower one on the same warm service. The restricted caller must receive no restricted hit, snippet, count, suggestion or cache metadata derived from the wider result. A denied call at MCPX must have zero downstream requests. An Atlas-side refusal must remain distinguishable in the gateway outcome.

The capability model can serve four agent clients acting for one owner without adding tenant administration. Drew retains the separate product decision in #12900 thread 2 concerning future service load and result handling. Partition caches by the effective disclosure scope and policy revision or bypass sharing until a safe key exists. Keep diagnostics free of corpus content. The existing hosted identity establishes the baseline, while the four successful positive and negative lane receipts establish acceptance. [Atlas reference](https://developing-today.github.io/code/atlas/reference/mcp.html) · [Decision #12900](https://github.com/developing-today/code/issues/12900)

## ID authority and nested code execution

ID already exposes policy evaluation as a library. Its PolicySession verifies advertised definitions, observes frames, evaluates named actions, produces an owner summary and verifies its audit. The bridge tests demonstrate real library call sites. A deployed network endpoint that maps worlds or apps into MCPX namespaces is a separate delivery. Start with one world and a deterministic synthetic action. Pin the tool definitions, verify the world and app grant at invocation, record the ID policy outcome, and preserve revocation on world exit. An ID refusal must propagate unchanged in substance through the gateway. Reverse traffic to external tools must pass the gateway's ceiling as well as ID's authority check. [PolicySession](https://github.com/developing-today/code/blob/1f9bc15391ca1c2efa639463a6369392456c27e5/pkgs/id/crates/id-caps/src/mcp_policy.rs#L613) · [Bridge test](https://github.com/developing-today/code/blob/1f9bc15391ca1c2efa639463a6369392456c27e5/pkgs/id/tests/mcp_spike_e2e.rs) · [ID MCP reference](https://developing-today.github.io/code/id/reference/mcp.html)

For nested code mode, treat each nested tool call as an operation under the inherited grant. The ability to execute a script does not itself grant access to every namespace available to the daemon. Pin discovery to the same identity and revision as invocation. Respect an upstream's code-mode setting and define one boundary that translates arguments, deadlines, structured results and cancellation. Test self-recursion, A-to-B-to-A, refusal inside a nested call, and a write whose upstream response is lost. Record the last as an uncertain outcome and reconcile using a durable operation identity where the upstream supports one. [Code-mode interop #1940](https://github.com/developing-today/code/issues/1940)

## Harness adapters and shared libraries

The OpenCode v2 adapter and the harness-independent TypeScript daemon client already exist. Keep host UI, local discovery and consent prompting in the adapters. Keep operation shapes, error handling and ranking semantics in shared code. Generate or check the four harness skills against the same supported operation list, help output, and cancellation and consent fixtures. Require an actual session in each host before claiming it supports a given workflow. Retire the deployed v1 integration only after its deployed consumer is ported and rollback has been exercised. [Shared client](https://github.com/developing-today/code/blob/1f9bc15391ca1c2efa639463a6369392456c27e5/pkgs/mcpx/plugin/core/daemon.ts) · [OpenCode v2](https://github.com/developing-today/code/blob/1f9bc15391ca1c2efa639463a6369392456c27e5/pkgs/mcpx/plugin/opencode/v2) · [Skill sources](https://github.com/developing-today/code/blob/1f9bc15391ca1c2efa639463a6369392456c27e5/pkgs/mcpx/plugin/opencode/skills) · [Remaining dependency #2841](https://github.com/developing-today/code/issues/2841#issuecomment-6943099429)

The Go client exposes typed invocation around the daemon API. Its test calls task_get with a path parameter, which gives an executable example of argument encoding. Operations currently returns a slice of an internal API type. Before promising a stable library ABI, expose a nameable public operation descriptor and specify compatibility for fields, errors, option defaults, cancellation and unknown operations. Keep offline catalog and settings evaluation independent of daemon dialing, secret resolution and process startup. A C or Wasm host should own explicit handles with bounded lifetimes. Run identical allocation, cancellation and refusal vectors against each binding before offering cross-language parity. [Public client](https://github.com/developing-today/code/blob/1f9bc15391ca1c2efa639463a6369392456c27e5/pkgs/mcpx/pkg/client/client.go#L77) · [Call-site example](https://github.com/developing-today/code/blob/1f9bc15391ca1c2efa639463a6369392456c27e5/pkgs/mcpx/pkg/client/client_test.go#L111) · [Embedding #1877](https://github.com/developing-today/code/issues/1877)
