Skip to main content
Glama

json

Read-only

Validate, format, minify, query, and summarize structured data, including line-delimited records, with precise error locations and duplicate-key checks.

Instructions

JSON: validate (line/col, hints, duplicate keys, precision loss), format, minify, query ($.a[*].b, ..id), structure summary; lines for JSON Lines.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "json"
  }
}

Input Schema

NameRequiredDescriptionDefault
opNo
pathNoor a file
textNo
linesNo
indentNo
path_exprNo
sort_keysNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.4.2

TDQS

B3.4/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=true, so the safety profile is covered. The description adds genuine behavioral detail beyond that — validate reports line/col, hints, duplicate keys, and precision loss — but leaves the return shape of 'structure', the interaction between path and text, and any size/streaming limits unstated.

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?

A single front-loaded sentence with no wasted words, and the parentheticals are dense but scannable. It is close to cryptic in places, but every clause maps to an actual operation or parameter.

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?

With seven parameters, near-zero schema coverage, no output schema, and only a readOnly annotation, this is a fairly complex tool. The description covers the operation menu well but is thin on how the parameters combine (e.g., that indent/sort_keys only matter for format) and what each operation returns.

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 only 14%, so the description should carry more weight than it does. It usefully explains path_expr via examples ($.a[*].b, ..id) and ties 'lines' to JSON Lines, but indent, sort_keys, and the text parameter are not explained anywhere.

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 the resource (JSON) and enumerates concrete operations matching the op enum: validate, format, minify, query, structure. That is a real verb+resource statement an agent can act on, though it never distinguishes this tool from adjacent siblings like markdown, diff, or convert_units.

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 operation list rather than stated: an agent can infer 'use validate to check syntax' but there is no guidance on choosing query vs structure, or on when to prefer a sibling tool for textual diffing or conversion. No exclusions or prerequisites are given.

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