On this page

Agents

delete-peer-agent

Can be held for approval

Remove a peer agent connection. Get its connection_id from list-peer-agents or register-peer-agent. Needs the fabric:orchestrate.write grant.

The shape of result for delete-peer-agent is not recorded here: it was not captured against a live deployment. Call it once and read what comes back rather than assuming a shape.

curl -sS -X POST https://fabric.wexa.ai/mcp/$FABRIC_PROJECT_ID \
  -H "authorization: Bearer $FABRIC_API_KEY" \
  -H "Mcp-Session-Id: $MCP_SESSION_ID" \
  -H "content-type: application/json" -H "accept: application/json" \
  -d '{"jsonrpc":"2.0","id":3,"method":"tools/call","params":{"name":"delete-peer-agent","arguments":{"connection_id":"6ab3e1c07f2d9a4b1c5e8d20"}}}'

Parameters

ParameterTypeRequiredNotes
connection_idstringRequiredFrom list-peer-agents or register-peer-agent. A connection an interop_agent node still delegates to is not removed.
Errors
  • UpstreamError (502): an interop_agent node still delegates to the connection. The message names each agent and its process flow, and says nothing was removed. Retrying will not help until those nodes are repointed or removed.
  • UpstreamError (502): the platform could not check which agents still reference the connection, so it was left in place.
More details

A connection that an interop_agent node still delegates to is not removed, so a running process flow is not broken by accident. The call fails with an error that names each such agent and its process flow, and nothing is removed. Repoint each of those nodes at another connection, or remove the node, then delete the connection. A refusal reads like this:

connection 6ab3e1c07f2d9a4b1c5e8d20 is still delegated to by "Match invoices" in process flow "Accounts payable" — repoint each one at another connection, or remove the node, then delete this connection. Nothing was removed.

There is no rotate operation. To change a connection's credential, register a new connection, repoint the nodes, then delete the old one; the steps are under register-peer-agent.

Result fields

FieldWhat it is
connection_idThe connection that was removed.
deletedtrue. A connection that was not removed is an error, never a result.
still_referenced_byAlways empty on a result: a connection something still references is refused instead.

Every tool call works the same way: How every tool call works.