list_nodes
Lists ROS 2 graph nodes (or mock graph) from one ros2 node list call, including namespaces, lifecycle status, and duplicate counts.
Instructions
ROS 2 graph only; on a DDS-only setup use list_participants. List the nodes on the ROS 2 graph (or the mock graph) from one ros2 node list call as a NodeListing: name, namespace, full_name, duplicate_count, lifecycle (managed node; state not read, lifecycle_note if unknown), by_namespace counts. duplicates lists full names used by several nodes (a per-node tool then answers for one of them, unidentified). Nodes starting with an underscore are hidden and a node on another ROS_DOMAIN_ID is invisible. Empty nodes when the graph has none. Use get_node_info for one node's interfaces. Raises an MCP error without a ros2 CLI. Cheap (two CLI calls). Duration: ROS lock, one call at a time, ends within 45 s; busy if held.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "list_nodes"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| note | No | One sentence of context, or `None`. | |
| nodes | Yes | Nodes on the graph, one entry per distinct full name, sorted by name. | |
| total | Yes | Distinct node names on the graph (no cap applies). | |
| returned | Yes | Length of `nodes`. | |
| truncated | Yes | True when `returned` is less than `total` because of a cap. | |
| duplicates | Yes | Full names that appear more than once on the graph. Empty when every name is unique. | |
| by_namespace | No | Distinct full names per namespace (`/` is the root), sorted by namespace. | |
| lifecycle_note | No | Why `lifecycle` could not be determined (service list failed), else `None`. | |
| mode_effective | Yes | `live` or `mock` (fixtures). | |
| lifecycle_count | No | Nodes with `lifecycle` true. |