Skip to main content
Glama
Iqram09

kong-ai-gateway-mcp

by Iqram09

Run a full diagnostic on a route

diagnose_route
Read-onlyIdempotent

Diagnose route issues in Kong Gateway by running rule-based checks on configuration, plugins, upstream health, and consumer credentials, returning structured findings.

Instructions

Runs a complete, rule-based diagnostic on one route and returns structured findings.

This is the highest-value tool in this server and usually the right SECOND call, after find_route_by_path. It performs the whole investigation a careful engineer would -- resolve the route, resolve its service, collect plugins at all three scopes, check upstream target health, check the named consumer's credentials and ACL groups, compare against the declared configuration baseline -- and applies the diagnostic rules to the result.

USE WHEN: the user reports a problem with a route or path. Prefer it over assembling the same picture yourself from get_route + list_plugins_for_route + check_upstream_health: it is one call instead of four, and it will not mistake "not collected" for "not present".

Pass consumer whenever the user named a specific client. Without it, consumer-specific causes are invisible and the diagnosis will look clean when it is not.

RETURNS: confidence CONFIRMED | PARTIAL | INSUFFICIENT_EVIDENCE summary one-sentence verdict findings[] each with code, severity, observedState, expectedState, evidence[], recommendedNextStep observed what Kong actually reports (route, service, effective plugins, consumer, upstream) gaps[] evidence that could not be collected, and what that prevents concluding suggestedNextSteps[]

HOW TO READ IT: every finding is derived from Kong by deterministic rules -- these are facts, not guesses. Report them as such, and cite the evidence entries. Respect confidence: PARTIAL means something could not be read and a further problem may be hidden there. Zero findings with CONFIRMED means the route is genuinely fine; say so rather than inventing a cause.

LIMITATIONS: inspects gateway configuration and Kong's own health verdicts only. It does not send traffic, read gateway logs, or observe live request behaviour. A backend that returns HTTP 500 on every request looks perfectly healthy here.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathNoURL path the user named, e.g. "/payments". Use this when the user described a path.
routeNoRoute name or `route:<name>` reference, when you already know it.
consumerNoConsumer username to check credentials and ACL membership for. Supply this whenever the user named a specific client, since consumer-specific causes (missing credential, wrong ACL group) cannot be detected without it.

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?

Annotations already declare readOnly/idempotent/non-destructive, yet the description adds substantial non-obvious behavior: it will not mistake 'not collected' for 'not present', confidence may be PARTIAL meaning a cause could be hidden, and the LIMITATIONS paragraph discloses it does not send traffic, read logs, or observe live behavior (so an HTTP 500 backend looks healthy). That is exactly the kind of context annotations cannot carry.

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?

Long but strongly front-loaded and organized under USE WHEN / RETURNS / HOW TO READ IT / LIMITATIONS headers, so it is scannable rather than padded. The RETURNS inventory is justified by the absence of an output schema, though some lines (e.g. the repeated consumer warning) are mildly redundant.

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?

With no output schema, the description fully compensates by enumerating the return fields (confidence, summary, findings[], observed, gaps[], suggestedNextSteps) and teaching how to interpret confidence and zero-finding results. Nothing needed to call or read the tool correctly is missing.

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

Parameters3/5

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

Schema description coverage is 100%, so path/route/consumer are already well documented, including the consequence of omitting consumer. The description restates the consumer guidance but adds no syntax or format detail beyond the schema, so baseline 3 is appropriate.

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 ('Runs a complete, rule-based diagnostic on one route') and explicitly positions itself against siblings, calling itself the right SECOND call after find_route_by_path. An agent can distinguish it from get_route or check_upstream_health 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 USE WHEN clause ('the user reports a problem with a route or path') plus a named alternative set (get_route + list_plugins_for_route + check_upstream_health) and the condition that selects this tool over them (one call instead of four). Also gives a conditional invocation rule for the consumer parameter.

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