Skip to main content
Glama

pt_apply_qos

Configures and verifies per-class QoS (MQC) on Cisco router interfaces via IOS CLI, creating class maps, policy maps, and outbound service policies.

Instructions

Configures QoS (MQC) on a router through IOS CLI, each line verified: one class-map match-any per class, a policy-map whose class-default gets fair-queue, and service-policy output on the interface. Measured on a 2911.

  • router / interface: e.g. "R1", "GigabitEthernet0/1" (the WAN side).

  • policy_name: one word, e.g. "WAN-OUT".

  • classes: [{"name", "match_dscp"?, "match_protocol"?, "priority_kbps"|"bandwidth_kbps"}]. At least one match per class (both = match-any); exactly one action. Measured: match_protocol "rtp", match_dscp "ef", priority_kbps. Other DSCP values, other protocols and bandwidth_kbps are accepted but NOT verified (warning).

  • direction: "output" only (queuing actions are outbound in IOS).

  • dry_run: validate and return the CLI/payload without sending.

Example: pt_apply_qos(router="R1", interface="GigabitEthernet0/1", policy_name="WAN-OUT", classes=[{"name": "VOICE", "match_protocol": "rtp", "match_dscp": "ef", "priority_kbps": 512}]) Check: pt_read_qos(device="R1").

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": {
      "router": "<router>",
      "interface": "<interface>",
      "policy_name": "<policy_name>",
      "classes": "<classes>"
    },
    "name": "pt_apply_qos"
  }
}

Input Schema

NameRequiredDescriptionDefault
routerYes
classesYes
dry_runNo
directionNooutput
interfaceYes
policy_nameYes

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.12.0

TDQS

A4.4/5.0
Behavior4/5

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

With no annotations, the description carries the behavioral burden well: it reveals that each CLI line is verified, that only rtp/ef DSCP/priority_kbps is actually verified while other DSCP values, other protocols and bandwidth_kbps are accepted but NOT verified with a warning, and that dry_run returns the CLI payload without sending. It does not disclose idempotency (what happens if the policy or class-map already exists), required privilege level, or whether partial failures roll back — gaps for a mutating CLI tool with zero annotation coverage.

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?

Front-loaded with the action and CLI outcome, then organized as tight bullets and a worked example — most sentences earn their place. The "Measured on a 2911" fragments and the duplicated caveat about unverified values add a little redundancy that could be consolidated.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a complex seven-field tool with a nested object array and an output schema present (so return values need no explanation), the definition covers shape, constraints, verification limits and a verification follow-up. The remaining hole is lifecycle behavior — existing-policy conflicts, rollback on partial CLI failure, and platform applicability beyond the 2911.

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 coverage is 0%, so the description must compensate, and it does: router/interface examples with the "WAN side" hint, policy_name constrained to one word, and a detailed classes contract (name plus match_dscp/match_protocol/priority_kbps or bandwidth_kbps, at least one match per class, both matches means match-any, exactly one action). Direction and dry_run semantics are also explained, and a full worked example anchors the nested array shape.

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?

States a specific verb and resource — configures QoS (MQC) on a router via IOS CLI — and spells out the concrete artifacts it produces (per-class class-map match-any, a policy-map with fair-queue on class-default, service-policy output on the interface). That is far more specific than the apply_* siblings and lets an agent tell it apart from pt_apply_acl or pt_apply_bgp without opening a schema.

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?

Gives clear usage context: direction is constrained to "output" because IOS queuing actions are outbound, dry_run is offered for validate-without-send, and the closing "Check: pt_read_qos(device=\"R1\")" routes the agent to the verification sibling. It stops short of explicit when-not-to-use guidance (e.g., when a policy already exists or when the platform differs from a 2911).

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