Skip to main content
Glama

Project Gumball

Validate YAML (Payload Validator)

validate_yaml
Read-only

Validates a YAML document, including the values that mean different things to different loaders — found by resolving each unquoted scalar under both spec versions and comparing, not by matching a list of words. In YAML 1.1 (PyYAML) the bare words no/yes/on/off/y/n are booleans, so a country list loses Norway and the "on:" key of every GitHub Actions workflow is really the key true; 0755 is 493 under 1.1 and 755 under 1.2, both numbers so nothing looks wrong; 1:30 is the base-60 integer 90. Also duplicate keys, tabs used as indentation, non-breaking spaces mistaken for indentation, aliases with no anchor, merge keys, multi-document streams, and alias bombs. Quoted values are never flagged.

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 YAML text. Up to 1,000,000 bytes.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.2/5.0
Behavior5/5

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

The description is exceptionally transparent about what the validator does: it resolves unquoted scalars under both YAML spec versions, reports duplicate keys, detects tabs/NBSP indentation issues, aliases without anchors, merge keys, multi-document streams, and alias bombs, and never flags quoted values. This adds far more behavioral context than the readOnlyHint/openWorldHint annotations alone provide.

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

Conciseness3/5

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

The description is front-loaded with the core behavior and contains valuable technical detail, but the 'WHY DELEGATE THIS' section repeats earlier examples, such as the bare 'no' scalar, and includes rhetorical flourishes like 'which no parser reports and no amount of reading spots'. It is informative but longer and more redundant than necessary.

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?

Given the tool's complexity and the absence of an output schema, the description covers the validation scope thoroughly: spec version differences, dangerous YAML constructs, and what will not be flagged. It does not describe the exact output/return format or error reporting structure, which would make it fully complete for an agent, but it gives enough context for correct selection and invocation.

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 fully documents the single parameter 'input' as raw YAML text up to 1,000,000 bytes, giving 100% schema description coverage. The description adds useful behavioral context about how the YAML will be interpreted, but it does not substantially expand the semantic meaning of the parameter itself beyond what the schema already states.

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?

The description states a specific verb and resource: it validates a YAML document and goes beyond syntax to flag semantic issues across YAML 1.1/1.2 loader differences. It clearly separates itself from sibling validators like validate_json, validate_csv, and validate_xml by focusing on YAML-specific behavior.

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?

The description makes clear that this tool is for validating YAML text, including subtle loader-version discrepancies, duplicate keys, aliases, and multi-document streams. It does not explicitly name sibling validators as alternatives or say 'use validate_json for JSON', but the YAML-focused framing gives an agent clear context for when to select it.

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