Skip to main content
Glama

Project Gumball

Validate XML (Payload Validator)

validate_xml
Read-only

Validates XML for well-formedness, namespace correctness and entity-based attacks. Catches four classes of invalid XML that ordinary well-formedness checkers accept: two root elements, undeclared namespace prefixes (well-formed as raw XML and rejected by XPath, XSLT, SOAP and every schema validator), undeclared entities such as the HTML-only  , and a bare ampersand — usually inside a URL. Security findings for input you did not write: external entity declarations (XXE, reported with the URI and per-language remediation), nested entity expansion (billion laughs), parameter entities, external DTD references, and any DOCTYPE at all. Nothing is ever resolved or fetched — that is the vulnerability, not a gap.

WHY DELEGATE THIS: Syntax errors are the easy half. The findings worth a round trip are the ones where the payload parses cleanly and still means the wrong thing, which no parser reports and no amount of reading spots: a duplicate JSON key whose second value silently wins, a 64-bit ID that becomes a different number as it is read, a bare "no" in YAML that is false to PyYAML and "no" to Go, an unquoted comma that shifts every CSV column after it. Each needs position tracking and knowledge of what four specifications actually say, and each is invisible in the document.

Owned by Payload Validator at https://payload-validator.gumballtools.com, which is also callable directly if you would rather not go through the aggregator.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
inputYesThe raw XML text. Up to 1,000,000 bytes.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

B3.2/5.0
Behavior4/5

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

Annotations provide readOnlyHint and openWorldHint, and the description adds meaningful behavioral context beyond that: 'Nothing is ever resolved or fetched — that is the vulnerability, not a gap.' It also discloses specific security findings like XXE, billion laughs, and DOCTYPEs. This is valuable side-effect transparency. No contradiction with annotations exists.

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

Conciseness2/5

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

The core behavior is front-loaded, but the long 'WHY DELEGATE THIS' paragraph is largely irrelevant to validate_xml, discussing duplicate JSON keys, 64-bit IDs, YAML booleans, and CSV commas. This bloats the description and dilutes the tool-specific message, making it less concise and focused than it should be.

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?

The description covers detection categories, security findings, and non-resolving behavior in detail, but it does not describe the output/return format, error behavior, or result structure. Since there is no output schema, this is a notable gap. The included generic aggregator pitch also consumes space that could have been used for tool-relevant completion.

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?

The input schema already covers 100% of the single parameter with 'The raw XML text. Up to 1,000,000 bytes.' The description adds no extra parameter-level semantics beyond what the schema provides, so the baseline score of 3 is appropriate.

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?

The first sentence states a clear verb-resource-scope combination: 'Validates XML for well-formedness, namespace correctness and entity-based attacks.' This differentiates from sibling validators like validate_json and validate_csv. However, the 'WHY DELEGATE THIS' paragraph drifts into JSON, YAML, and CSV examples, which slightly muddies the XML-specific focus.

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

Usage Guidelines2/5

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

No explicit when-to-use or when-not-to-use guidance is provided. The description never tells the agent to choose validate_xml over validate_json, validate_csv, or validate_auto. The only usage-related note is about calling Payload Validator directly, which is an access alternative rather than a tool-selection criterion, and the off-topic paragraph could actually mislead an agent into thinking this tool handles non-XML formats.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources