Skip to main content
Glama

Validate a route against Routes.php

validate_route

Checks whether a route collides with routes in app/Config/Routes.php and follows kebab-case {param} syntax; read-only, never modifies files.

Instructions

Verifies (read-only) that a route does not collide with the routes registered in app/Config/Routes.php and follows the framework's kebab-case {param} syntax. Never modifies files.

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": {
      "method": "<method>",
      "path": "<path>"
    },
    "name": "validate_route"
  }
}

Input Schema

NameRequiredDescriptionDefault
pathYes
methodYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.6.0

TDQS

B3.3/5.0
Behavior3/5

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

With no annotations supplied, the description carries the full burden and does cover the most important trait: 'Verifies (read-only)' and 'Never modifies files' effectively declare a safe, non-destructive operation. However, it says nothing about what happens on failure (thrown error vs. returned collision report), whether it inspects file contents at call time, or whether it needs the file to be present.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two tight sentences with the safety guarantee front-loaded as a parenthetical and the file it reads named immediately. Nothing is wasted and the key constraint is not buried.

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

Completeness3/5

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

For a two-parameter read-only validator with no output schema, the definition explains what is checked but not what comes back — an agent cannot tell whether a collision surfaces as a tool error, a boolean, or a list. That result-shape gap is the main thing left unaddressed.

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

Parameters2/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. It adds some meaning for 'path' by referencing kebab-case {param} syntax, but the required 'method' parameter is never mentioned at all, and there is no explanation of the path pattern's allowance for leading slash or parameter placeholders.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource (verifies a route) and names the concrete referent it validates against, app/Config/Routes.php, plus the syntax rule it enforces. It is distinguishable from the scaffold_* siblings at a glance, though it never names an alternative tool explicitly.

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

Usage Guidelines3/5

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

Usage is only implied: the agent must infer that this should be run before registering a new route. There is no explicit when-to-use trigger, no when-not guidance, and no mention of how this differs from lint_against_framework_rules.

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