Skip to main content
Glama

pt_configure_dhcp_server

Creates or edits a DHCP pool on a Server-PT, validates it against the subnet, enables the service, and reads each pool back. Sets gateway, DNS, and the IP range handed to clients.

Instructions

Creates or edits a DHCP pool on a Server-PT (GUI: Services > DHCP), validated against its subnet, switches the service on and reads every pool back. No CLI (a Server-PT has none). Router DHCP: plan with dhcp=True or CLI ip dhcp pool. Exclusions or showing the page on screen: pt_server_dhcp (same JS backend, server_dhcp_js).

The server needs a static IP inside the pool's subnet (else warning DHCP_SERVER_NO_IP). PT never leases the server's own IP but DOES lease the gateway's if the range covers it.

  • device: the Server-PT.

  • network / mask: pool subnet ("192.168.10.0", "255.255.255.0"). No network = read-only.

  • gateway / dns: what clients receive (empty dns = left alone).

  • start_ip: first IP handed out; empty = after a .1 gateway, else the first host.

  • max_users: number of IPs; 0 = to the end of the subnet.

  • pool_name: default "serverPool" (the factory pool the GUI shows); another name creates or edits that pool, never duplicates.

  • port: serving port (default FastEthernet0). enabled: service On/Off.

  • drop_factory_pool: with a custom pool_name, delete the factory serverPool if it was never configured (it would hand out .1, the gateway).

  • remove: delete pool_name instead. dry_run: validate and return the JS only.

Example: pt_configure_dhcp_server(device="DHCP-A", network="192.168.10.0", gateway="192.168.10.1", dns="8.8.8.8", start_ip="192.168.10.3")

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": {
      "device": "<device>"
    },
    "name": "pt_configure_dhcp_server"
  }
}

Input Schema

NameRequiredDescriptionDefault
dnsNo
maskNo255.255.255.0
portNoFastEthernet0
deviceYes
removeNo
dry_runNo
enabledNo
gatewayNo
networkNo
start_ipNo
max_usersNo
pool_nameNoserverPool
drop_factory_poolNo

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.12.0

TDQS

A4.7/5.0
Behavior4/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 well: it discloses the DHCP_SERVER_NO_IP prerequisite (server needs a static IP in the pool subnet), the lease quirk (server's own IP never leased, but the gateway's is if covered), service on/off via enabled, and that the tool reads every pool back. It is slightly thin on failure/rollback semantics for remove and on idempotency guarantees when re-editing an existing pool, keeping it from a 5.

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 purpose and alternatives are front-loaded, then parameters are bulleted one per line, which is well structured for a 13-parameter tool. A few phrasings are terse to the point of being cryptic ("else warning DHCP_SERVER_NO_IP", "validate and return the JS only"), costing a little clarity, but there is essentially no wasted text.

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 13-parameter mutation tool with no annotations, the description covers prerequisites, per-parameter defaults, destructive behaviors (remove, drop_factory_pool), a validation-only mode, and a worked example. Return values are partly handled by the existing output schema, so nothing essential is missing before an agent can call it correctly.

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

Parameters5/5

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

Schema description coverage is 0%, so the description must compensate for all 13 parameters, and it effectively does: every parameter is explained with format and default behavior (network/mask example, empty dns = left alone, start_ip empty = after a .1 gateway else first host, max_users 0 = to end of subnet, pool_name default serverPool, port default FastEthernet0). The drop_factory_pool explanation even covers the consequence (it would hand out .1, the gateway).

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?

"Creates or edits a DHCP pool on a Server-PT (GUI: Services > DHCP)" gives a specific verb, resource, and platform, and immediately bounds scope with "No CLI (a Server-PT has none)". It also distinguishes itself from the router-side path (plan with dhcp=True or `ip dhcp pool`) and from pt_server_dhcp, so an agent can route correctly 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 Guidelines5/5

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

Explicit alternatives and the conditions that select them are stated: router DHCP goes through dhcp=True/CLI, while exclusions or on-screen page display belong to pt_server_dhcp (same backend). It also names the read-only mode ("No network = read-only") and dry_run, giving the agent clear when-to-use and when-not-to-use boundaries.

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

Deploy Server

Other Tools