Skip to main content
Glama

Util JSON validate

util_json_validate
Read-onlyIdempotent

Use when you must check that a JSON document fits a schema before acting on it: validates json against a JSON Schema subset. Returns the exact paid x402 request for your input (GET /util/json-validate, $0.001 per call), with the response schema and an example; call that URL with an x402 or MPP client to get the data. Bad input is refused before any charge.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
jsonYesThe document (JSON text; an object in a POST body is accepted too)
schemaYesJSON Schema (subset) as JSON text

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.4/5.0
Behavior5/5

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

Annotations only cover the safe-read profile (readOnly, idempotent, openWorld, non-destructive); the description goes well beyond that by disclosing the paid model ($0.001 per call), the non-obvious indirect return (a paid x402 request rather than the data), and the no-charge-on-bad-input behavior. That is exactly the behavioral context structured fields 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?

The use case is front-loaded before the mechanics, and every clause carries information (subset scope, price, endpoint, client requirement, refund behavior). It is dense and slightly run-on, but nothing is padding.

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 carries the full burden and does so: it explains that the immediate return is a payment request, where to send it, what accompanies it (response schema and example), and how bad input is handled. An agent has everything needed to invoke and follow through.

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% and both parameters already carry descriptions in the schema, including the note that an object body is accepted. The description adds no format or syntax detail beyond the schema, so the baseline 3 applies.

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 ('validates json against a JSON Schema subset') and names the precondition for use ('before acting on it'). No sibling tool (util_base64, util_hash, util_jwt_decode) overlaps, so an agent can pick this out immediately.

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?

'Use when you must check that a JSON document fits a schema before acting on it' gives an explicit when-to-use trigger, and the closing clause explains the follow-up call with an x402 or MPP client. It does not name when-not-to-use or an alternative validator, but no sibling competes for the same job, so the gap is minor.

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.