Skip to content

peers.list

Every client attached to this shared server: id, the client's own name and version from its initialize, transport, when it attached, when it was last seen, and what it announced. In-memory, gone with the process.

Every client attached to this shared server: id, the client's own name and version from its initialize, transport, when it attached, when it was last seen, and what it announced. In-memory, gone with the process.

  • query
  • behaviorally_verified
  • module peers
  • #peers
  • #coordination

Exposure

Where this one definition is reachable. Absence is explicit: a surface not listed does not carry it.

surfaceas
MCPtool majordomus_peers
HTTPGET /api/v1/peers operationId peers.list
command line

Schemas

The canonical input and output, from the Rust types; the MCP tool schema and the OpenAPI parameters and responses are derived from these.

input · Empty

No input.

No properties: the capability takes no input.

JSON Schema
{
  "additionalProperties": false,
  "description": "No input.",
  "title": "Empty",
  "type": "object"
}

output · PeerList

The answer of `peers.list`: every client attached to this shared server.

propertytyperequireddescription
caller one of 2 no The caller's own peer id, when the call came through an MCP session.
count integer yes How many peers are attached, the caller included.
overlaps array no Every pair of peers whose claimed scope meets, each pair once. Empty is the ordinary case, and a reader who sees an entry here is looking at two sessions about to do the same work.
peers array yes The peers, in attachment order; `p1` started the server. A peer that announced something and then went away is still here, with `attached: false`.
JSON Schema
{
  "$defs": {
    "Announcement": {
      "description": "What a peer said it is working on.",
      "properties": {
        "at": {
          "description": "When it was announced, RFC 3339, UTC.",
          "type": "string"
        },
        "intent": {
          "description": "One line: the task or intent, in the peer's words.",
          "type": "string"
        },
        "scope": {
          "description": "Repository-relative paths the peer expects to touch; informational, never enforced here.",
          "items": {
            "type": "string"
          },
          "type": "array"
        }
      },
      "required": [
        "intent",
        "scope",
        "at"
      ],
      "type": "object"
    },
    "ClientInfo": {
      "description": "What a client said about itself in `initialize`.",
      "properties": {
        "name": {
          "description": "`clientInfo.name`: `claude-code`, `codex`, `gemini-cli`, whatever the client sends.",
          "type": "string"
        },
        "title": {
          "description": "`clientInfo.title`, when the client sends one.",
          "type": [
            "string",
            "null"
          ]
        },
        "version": {
          "description": "`clientInfo.version`.",
          "type": "string"
        }
      },
      "required": [
        "name",
        "version"
      ],
      "type": "object"
    },
    "Overlap": {
      "description": "Two peers that claimed the same ground.\n\nReported when the second of them announces, so that a collision is known at the moment\nit is created rather than discovered afterwards in the history of a branch.",
      "properties": {
        "attached": {
          "description": "Whether that peer is still attached. An overlap with a departed peer is a weaker\nsignal than one with a live session, and the reader is told which it is.",
          "type": "boolean"
        },
        "intent": {
          "description": "What it said it was doing.",
          "type": "string"
        },
        "paths": {
          "description": "The claims that meet: one line per pair, `yours` and `theirs`.",
          "items": {
            "$ref": "#/$defs/OverlapPath"
          },
          "type": "array"
        },
        "peer": {
          "$ref": "#/$defs/PeerId",
          "description": "The other peer."
        }
      },
      "required": [
        "peer",
        "attached",
        "intent",
        "paths"
      ],
      "type": "object"
    },
    "OverlapPath": {
      "description": "One pair of claims that contain one another.",
      "properties": {
        "theirs": {
          "description": "The path the other peer claimed.",
          "type": "string"
        },
        "yours": {
          "description": "The path the announcing peer claimed.",
          "type": "string"
        }
      },
      "required": [
        "yours",
        "theirs"
      ],
      "type": "object"
    },
    "Peer": {
      "description": "One peer as the board lists it.",
      "properties": {
        "announcement": {
          "anyOf": [
            {
              "$ref": "#/$defs/Announcement"
            },
            {
              "type": "null"
            }
          ],
          "description": "Its announcement, when it made one."
        },
        "attached": {
          "description": "Whether the session is still attached. A peer that announced something and then\nwent away is kept and listed with `attached: false`: what it said it was working on\noutlives the connection that said it, because the work does.",
          "type": "boolean"
        },
        "client": {
          "$ref": "#/$defs/ClientInfo",
          "description": "The client behind it."
        },
        "connected_at": {
          "description": "When it attached, RFC 3339, UTC.",
          "type": "string"
        },
        "id": {
          "$ref": "#/$defs/PeerId",
          "description": "`p1`, `p2`, ..."
        },
        "last_seen_seconds_ago": {
          "description": "Seconds since its last message.",
          "format": "uint64",
          "minimum": 0,
          "type": "integer"
        },
        "transport": {
          "$ref": "#/$defs/Transport",
          "description": "How it is attached."
        }
      },
      "required": [
        "id",
        "client",
        "transport",
        "connected_at",
        "last_seen_seconds_ago",
        "attached"
      ],
      "type": "object"
    },
    "PeerId": {
      "description": "A peer's identity for the life of the server: `p1`, `p2`, ... in attachment order.\n`p1` is the session that started the server.",
      "type": "string"
    },
    "Transport": {
      "description": "How a peer reached the server.",
      "oneOf": [
        {
          "const": "stdio",
          "description": "The owner's own client, on the process's stdin and stdout.",
          "type": "string"
        },
        {
          "const": "http",
          "description": "MCP over HTTP at `/mcp`: a `majordomus mcp` bridge, or a client speaking it directly.",
          "type": "string"
        }
      ]
    }
  },
  "description": "The answer of `peers.list`: every client attached to this shared server.",
  "properties": {
    "caller": {
      "anyOf": [
        {
          "$ref": "#/$defs/PeerId"
        },
        {
          "type": "null"
        }
      ],
      "description": "The caller's own peer id, when the call came through an MCP session."
    },
    "count": {
      "description": "How many peers are attached, the caller included.",
      "format": "uint",
      "minimum": 0,
      "type": "integer"
    },
    "overlaps": {
      "description": "Every pair of peers whose claimed scope meets, each pair once. Empty is the\nordinary case, and a reader who sees an entry here is looking at two sessions\nabout to do the same work.",
      "items": {
        "$ref": "#/$defs/Overlap"
      },
      "type": "array"
    },
    "peers": {
      "description": "The peers, in attachment order; `p1` started the server. A peer that announced\nsomething and then went away is still here, with `attached: false`.",
      "items": {
        "$ref": "#/$defs/Peer"
      },
      "type": "array"
    }
  },
  "required": [
    "count",
    "peers"
  ],
  "title": "PeerList",
  "type": "object"
}

Policies

benchmark
required — a target on every transport the exposure declares; the cases are the input type's
cache
disabled — every call runs the handler

Benchmark targets

Derived from the registry for this repository: one requirement per transport, and the cases the input type provides. The whole matrix is on the benchmarks page.

transportstatecasestargets
directcovered1default
mcpcovered1default
httpcovered1default

The moments this answers