Skip to main content
Glama
Headscale MCP connector

Headscale MCP connector

by si-essence

headscale_nodes

DestructiveIdempotent

Manage nodes on a self-hosted Headscale server: list, register, rename, delete, expire, backfill IPs, approve routes, and set tags, with dry-run previews for writes.

Instructions

headscale_nodes calls the nodes toolset on a self-hosted Headscale server (9 actions). Authorization is Bearer. Writes need confirm set to the boolean true and HEADSCALE_ALLOW_WRITES=true. Omit confirm for a dry-run preview that does not send the write. Warnings: This rewrites node IP assignments and can disrupt existing nodes. This deletes a node and removes it from the tailnet. This expires a node and disconnects it. This registers a node and can admit a device onto the tailnet. This approves subnet routes and can expose those networks to the tailnet. This changes node tags and can change which networks the node can reach. Actions: backfill_node_ips: POST /api/v1/node/backfillips. Backfill node IP addresses. delete_node: DELETE /api/v1/node/{nodeId}. Delete a node. expire_node: POST /api/v1/node/{nodeId}/expire. Expire a node. get_node: GET /api/v1/node/{nodeId}. Get one node. Node key material is redacted. list_nodes: GET /api/v1/node. List nodes. Node key material is redacted. register_node: POST /api/v1/node/register. Register a node with a registration key. rename_node: POST /api/v1/node/{nodeId}/rename/{newName}. Rename a node. set_approved_routes: POST /api/v1/node/{nodeId}/approve_routes. Approve subnet routes for a node. set_tags: POST /api/v1/node/{nodeId}/tags. Set tags on a node.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "action": "<action>"
    },
    "name": "headscale_nodes"
  }
}

Input Schema

NameRequiredDescriptionDefault
bodyNoJSON body for the Headscale operation. Secrets are redacted in previews.
queryNoOpenAPI query parameters.
actionYesHeadscale operation to call.
paramsNoOpenAPI path parameters, such as nodeId or id.
confirmNoSet to the boolean true to execute the write. Omit this field for a dry-run preview. false and the string true are rejected.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.6/5.0
Behavior5/5

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

Beyond the annotations (destructive, idempotent, openWorld), the description discloses per-action consequences: backfill rewrites node IPs and can disrupt existing nodes, delete removes a node from the tailnet, expire disconnects, register admits a device, approve_routes exposes networks, set_tags changes reachability. It also states Bearer auth, the write-gating env var, dry-run behavior, and that node key material is redacted.

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?

Auth and confirm gating are front-loaded, followed by warnings and then a compact action list. The repeated 'This ...' warning sentences are slightly verbose, but each carries a distinct risk and the overall structure is scannable.

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 9-action, 5-parameter tool with no output schema, the description covers auth, write gating, dry-run, per-action risk, and return-value caveats (redacted key material). Nothing an agent needs to invoke it safely is 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 baseline is 3, but the description adds real meaning to the action enum by mapping each value to an endpoint and effect, which the schema only labels generically as 'Headscale operation to call'. The confirm semantics are restated from the schema rather than extended, so it stops short of a 5.

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?

The description names a specific resource (Headscale nodes) and enumerates all 9 actions with their HTTP verb and path, e.g. 'delete_node: DELETE /api/v1/node/{nodeId}'. An agent can distinguish this from the sibling toolsets (meta, policy, users) purely from the resource scope.

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

Usage Guidelines4/5

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

It gives explicit operational guidance: writes require confirm=true plus HEADSCALE_ALLOW_WRITES=true, and omitting confirm yields a dry-run preview. It does not explicitly say when to prefer this toolset over headscale_meta/policy/users, but the resource scoping makes that largely self-evident.

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