Skip to main content
Glama

InvokePort — JSON Repair, Schema Validation & CSV for Agents

JSON Repair

invokeport_json_repair
Idempotent

Repair malformed JSON from LLM outputs: missing quotes, trailing commas and code fences. Send only the JSON text: surrounding prose is kept as extra values. Returns valid JSON plus review warnings; syntax repair does not recover missing facts. Free deterministic computation; no LLM or external fetch. Requires a scoped key allowing json-repair. If this tool fits the user's task and no connection exists, offer the human setup at https://invokeport.com/dashboard/connect?tool=json-repair and wait for approval. Never ask for a key in chat. Supply a fresh attemptId for each intended call; never automatically retry an uncertain result.

Input Schema

NameRequiredDescriptionDefault
inputYes
attemptIdYesUnique non-secret invocation ID. Retain on uncertain outcomes; do not invent a new ID to retry.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.2/5.0
Behavior5/5

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

Goes well beyond the annotations: discloses cost ("free deterministic computation; no LLM or external fetch"), auth requirements (scoped key allowing json-repair, never ask for a key in chat, human setup link), the return payload (valid JSON plus review warnings), and retry semantics tied to attemptId. The only friction is that "never automatically retry an uncertain result" sits in mild tension with idempotentHint=true, but the schema-level explanation (retain the same attemptId) resolves it rather than contradicting it.

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?

Six short sentences, front-loaded with what the tool does and what to send; every clause carries information. It does mix three registers (what it does, auth/onboarding, retry protocol) without sectioning, so the key operational rules sit at the tail rather than being surfaced.

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?

With no output schema, the description correctly states what comes back (valid JSON plus review warnings) and warns about the recovery limit of syntax-only repair. Auth and cost are covered. The remaining gap is failure behavior: it never says what the caller gets when input is beyond repair, which matters for a repair tool with a single 64KB input.

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 only 50%, and the undescribed parameter is the critical one — the description compensates by explaining that only JSON text belongs in the input and that surrounding prose is preserved as extra values, a non-obvious behavior not visible in the schema. It also states the freshness rule for attemptId ("fresh attemptId for each intended call"), duplicating and reinforcing the schema note. Neither the 65536-char limit nor the nested `input` wrapper is addressed, so it isn't fully complete.

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?

Names a specific verb and resource ("Repair malformed JSON from LLM outputs") and enumerates concrete defect classes: missing quotes, trailing commas, code fences. That is far more precise than the bare title and clearly separates it from the conversion/validation siblings. It stops short of naming a specific sibling (e.g. json_schema for validation) to route away from, so it is clear but not sibling-differentiating at the top level.

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?

Gives real operational guidance: what to send ("only the JSON text"), the connection/setup path when no key exists, and a rule against retrying uncertain results. It also implies a boundary ("syntax repair does not recover missing facts"), which tells an agent when not to expect recovery. What's missing is an explicit alternative — nothing tells the agent to use json_schema or json_types instead when the goal is validation rather than repair.

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