Skip to main content
Glama

Web Reader Pro

Messy-to-Clean Converter: turn any messy text, email, chat, page or PDF into strict JSON that matches your schema

structure_to_json

Send text (or a url) and a JSON Schema (or a simple field list). Returns data that is validated against the schema: numbers cleaned, dates as YYYY-MM-DD, enums matched, required fields checked; if the first try fails it is fixed and re-checked automatically. Each field is marked found_in_source, derived or empty, and missing values are null instead of guesses. Not charged if valid JSON cannot be produced. Price 0.01 USDC per call; first 3 calls per day free.

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": {
      "schema": "<schema>"
    },
    "name": "structure_to_json"
  }
}

Input Schema

NameRequiredDescriptionDefault
urlNoInstead of text: a page, PDF, Word or Excel URL
textNoThe messy input (max 200,000 chars). Or use url.
schemaYesJSON Schema ({type: object, properties: {...}}) or a field list like ["name", {"name": "total", "type": "number"}]
strictNoDefault true: error (no charge) if output cannot match the schema
paymentNoOptional x402 payment (base64 X-PAYMENT header value). Not needed while the free daily sample lasts.
instructionsNoOptional extra rules

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A3.8/5.0
Behavior4/5

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

With no annotations, the description carries the full behavioral burden and does most of it well: it discloses the automatic fix-and-recheck loop, per-field provenance marking (found_in_source / derived / empty), nulls instead of hallucinated values, and the failure-cost rule 'Not charged if valid JSON cannot be produced'. Pricing (0.01 USDC per call, 3 free per day) and the optional x402 payment requirement are also surfaced. Minor gaps remain around URL fetch failures and data retention, but the mutation/cost/failure semantics an agent needs are present.

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?

One dense but well-ordered paragraph: inputs first, then what comes back, then automation and provenance, then cost. Almost every clause carries information the agent needs; the pricing sentences are justified by the payment parameter, though the string runs long and could be split for scannability.

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?

For a six-parameter tool with a nested schema object and no output schema, the description covers the essential ground: accepted inputs, validation and repair behavior, the shape of returned fields, and billing semantics. It leaves only secondary details (URL fetch error behavior, input size limits) to the schema.

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

Parameters4/5

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

Schema coverage is 100%, so the baseline is 3, but the description adds meaning beyond the schema: it clarifies that the schema argument accepts either a full JSON Schema or a simple field list, and it ties the strict parameter to the no-charge-on-invalid-output guarantee and to the payment parameter's free-tier condition. The text-vs-url mutual exclusivity is reinforced rather than merely repeated.

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 description names a concrete verb and resource: send text or a URL plus a JSON Schema and get data validated against it, with cleaning rules spelled out (numbers, YYYY-MM-DD dates, enums, required fields). That makes the tool's function unmistakable, but it never contrasts itself with likely-adjacent siblings such as extract_fields or read_url, leaving the agent to infer the difference.

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 implied by the input pattern ('Send text (or a url) and a JSON Schema'), and the text//url choice is stated as an alternative. There is no explicit when-to-use or when-not guidance, and no pointer to another tool when a schema-driven extraction is not what's needed.

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.