Skip to main content
Glama

mesh_call

Invoke a mesh-advertised procedure such as build, test, search, or deploy on a trusted provider; signed DHT ads verify the realm, and results return duration and seal status.

Instructions

Invoke a procedure advertised on the mesh (build, test, search, deploy on commons hardware). The call reaches a provider directly: its signed advertisement is found in the DHT and trusted only when the realm's key authorizes it. The provider sees this agent's identity as the caller. Returns the provider's result plus duration_ms, and seal: whether this exchange went sealed (sealed 1: sealed to the provider's advertised key, seal_key_id names it; sealed 0: in the clear), the provider it was addressed to, and means, which says it in words. Defaults to the io.macula realm. Bytes: send a byte string in args as {"$bytes": ""}, e.g. {"channel_id": {"$bytes": "AQID"}}; a plain string is always text. Bytes in the result appear as {"$bytes": ""}; pass them back in the same form. prove_ownership: 1 attaches an ownership proof (asserted_by) signed by this agent's key, valid only for these args, this procedure and realm, once; what a provider does with one is its own policy (mcl-graph's learn_link credits a valid one's identity, ignores an invalid one and refuses a repeated one). args must not carry "caller". The call is sealed to the provider's advertised KEM key whenever its advertisement names one (confidential "preferred", the default); confidential "required" never calls a provider that names none and fails with code=confidentiality and its reason instead. code=sealed_refused from the provider means it could not open the sealed call even after one reseal to the key it named.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
argsNoStructured arguments for the procedure (plain JSON; this server encodes the wire). Bytes as {"$bytes": "<base64>"}.
realmNo32-byte realm id as hex (64 chars). Omit for io.macula. A provider is only trusted in a realm whose key this server holds (io.macula always; others through MACULA_MESH_REALMS), so "no trusted provider" can mean the wrong realm, not a missing service -- find a procedure's realm with mesh_find_records_by_type (record_type "procedure_advertisement").
procedureYesProcedure name as advertised, e.g. mcl-rag/search_chunks_semantic, with the realm in `realm`. The realm-prefixed form a DHT listing prints (`<64 hex>/<procedure>`) is accepted too and split into procedure + realm for you.
timeout_msNoHow long to wait for the result, in milliseconds (5000 by default).
confidentialNo"preferred" (default): sealed to the provider's advertised KEM key when its advertisement names one, in the clear when it names none. "required": never called in the clear; a provider that names no key fails with code=confidentiality (reason=no_kem_key). A sealed call never falls back to the clear. The result's seal reports whether it went sealed either way; "required" is how you refuse a clear call before it is sent.
prove_ownershipNo1 attaches an ownership proof v2 (mcl-om#7) to args, under asserted_by: this agent's key vouches for every field, for this procedure in this realm, once, and the proof verifies for nothing else. What a provider does with a proof that does not verify is its own policy. A provider's handler runs at most once per call, so the proof is never replayed by the transport. 0 or omitted: none. args must not carry "caller".

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed9 schema fields changedv0.37.0
    • changedInput schema / properties / args / description
      Previous value: -"Structured arguments for the procedure (plain JSON; this server encodes the wire)."New value: +"Structured arguments for the procedure (plain JSON; this server encodes the wire). Bytes as {\"$bytes\": \"<base64>\"}."
    • addedInput schema / properties / confidential
      Added value: +{
      +  "description": "\"preferred\" (default): sealed to the provider's advertised KEM key when its advertisement names one, in the clear when it names none. \"required\": never called in the clear; a provider that names no key fails with code=confidentiality (reason=no_kem_key). A sealed call never falls back to the clear. The result's seal reports whether it went sealed either way; \"required\" is how you refuse a clear call before it is sent.",
      +  "enum": [
      +    "preferred",
      +    "required"
      +  ],
      +  "type": "string"
      +}
    • removedInput schema / properties / direct
      Removed value: -{
      -  "description": "Resolve the procedure's DHT direct-dial advertisement and call its serving station directly, in one hop, instead of routing through <host>'s own advertise-gossip routes. host is then used only to query the DHT, not to carry the call. Ordinary (non-direct) calls depend on inter-station gossip having already propagated a route from host to the actual server -- on a large or recently-changed mesh that isn't always true yet, and the call can fail (often as temporary_relay_failure) even though the target is live and reachable. direct-dial sidesteps that gap, at the cost of failing outright if the provider only advertised the plain way (\"procedure has no direct-dial advertisement\"). Prefer this whenever a plain call fails against a target you otherwise know is up. If this server's own MACULA_MCP_UCAN is set, the token still gets attached (via callDirectWithUcan) -- this is how a UCAN-gated capability is actually reached, since today's gated capabilities happen to be advertised direct-dial only (a deployment fact, not a protocol requirement).",
      -  "type": "boolean"
      -}
    • removedInput schema / properties / host
      Removed value: -{
      -  "description": "Station to connect through, \"host[:port]\". Defaults to station-de-frankfurt.macula.io:4433.",
      -  "type": "string"
      -}
    • changedInput schema / properties / procedure / description
      Previous value: -"Procedure name as advertised, e.g. hecate-rag.search_chunks_semantic, with the realm in `realm`. The realm-prefixed form a DHT procedure_advertisement prints (`<64 hex>/<procedure>`) is accepted too and split into procedure + realm for you."New value: +"Procedure name as advertised, e.g. mcl-rag/search_chunks_semantic, with the realm in `realm`. The realm-prefixed form a DHT listing prints (`<64 hex>/<procedure>`) is accepted too and split into procedure + realm for you."
    • removedInput schema / properties / prove_identity
      Removed value: -{
      -  "description": "Sign a {citizen_did, timestamp, procedure} ownership proof with this server's own identity and merge citizen_did + proof into args, for capabilities gated by an ownership proof (hecate_mail.open_mailbox, hecate_graph.learn_link, hecate_citizens.register_presence). The proof is bound to this procedure and to this identity, so it overrides any citizen_did/proof you passed. Presence already registers this identity in hecate-citizens; this is for calling the gated capabilities as that citizen.",
      -  "type": "boolean"
      -}
    • addedInput schema / properties / prove_ownership
      Added value: +{
      +  "anyOf": [
      +    {
      +      "const": 0,
      +      "type": "number"
      +    },
      +    {
      +      "const": 1,
      +      "type": "number"
      +    }
      +  ],
      +  "description": "1 attaches an ownership proof v2 (mcl-om#7) to args, under asserted_by: this agent's key vouches for every field, for this procedure in this realm, once, and the proof verifies for nothing else. What a provider does with a proof that does not verify is its own policy. A provider's handler runs at most once per call, so the proof is never replayed by the transport. 0 or omitted: none. args must not carry \"caller\"."
      +}
    • changedInput schema / properties / realm / description
      Previous value: -"32-byte realm as hex (64 chars), the wire-level tag a procedure is scoped to -- distinct from the realm word inside an MRI string. Omit for the default all-zero realm (protocol-internal, most demo-fleet capabilities). A capability served under its own realm is unreachable without the right one here -- unknown_next_peer with the default realm doesn't necessarily mean the procedure doesn't exist."New value: +"32-byte realm id as hex (64 chars). Omit for io.macula. A provider is only trusted in a realm whose key this server holds (io.macula always; others through MACULA_MESH_REALMS), so \"no trusted provider\" can mean the wrong realm, not a missing service -- find a procedure's realm with mesh_find_records_by_type (record_type \"procedure_advertisement\")."
    • changedInput schema / properties / timeout_ms / description
      Previous value: -"Deadline in milliseconds for the connect + call."New value: +"How long to wait for the result, in milliseconds (5000 by default)."
  2. First observedv0.28.7

TDQS

A4.4/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full burden and does so unusually well: it discloses identity exposure to the provider, the sealing model (preferred/required, reseal-on-failure), specific failure codes (confidentiality, sealed_refused), replay semantics of the ownership proof, and the return shape. Nothing material about how a call behaves is left to inference.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The core purpose is front-loaded in the first clause and every subsequent sentence carries concrete information (bytes encoding, sealing, ownership proof, the caller prohibition). It is dense and undivided into sections, which makes it heavy to scan, but there is little filler.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a complex, security-sensitive RPC tool with no annotations and no output schema, the description covers invocation, encoding, security posture, error codes, and the return payload (result, duration_ms, seal, provider, means). Nothing an agent needs to call it correctly appears to be missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the schema already documents all six parameters (baseline 3). The description adds real value on top: the {"$bytes": ...} wire encoding convention, the prohibition on passing "caller" in args, and the once-and-only-for-these-args semantics of prove_ownership.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb (invoke) and resource (a procedure advertised on the mesh), with concrete examples of what those procedures do (build, test, search, deploy). It is readily distinguishable from siblings like mesh_put/mesh_get (DHT storage ops), which is what makes the RPC nature clear without opening any schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description gives conditional guidance for one parameter (confidential preferred vs required) and implies the discovery path by pointing to mesh_find_records_by_type in the realm parameter, but it never explicitly frames when to choose mesh_call over alternatives like mesh_put/mesh_get or mesh_publish. Usage is inferable rather than stated.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.