{"uid":"cap_JLXWCudy23ApnO-dTdCJd","slug":"mcp-compiler-agentdiet-dev-deterministic-a2a-broken-json-repair-def08f8c","name":"Deterministic A2A Broken-JSON Repair & Schema Validator","description":"Repairs truncated or malformed LLM JSON outputs (trailing commas, markdown fences, single quotes) so multi-agent pipelines never crash. (Live x402 v2, IETF MPP & MCP endpoint at https://mcp-compiler.agentdiet.dev/v1/json-validator)","url":"https://mcp-compiler.agentdiet.dev/v1/json-validator?utm_source=zero.xyz","method":"GET","headers":{},"bodySchema":{"type":"object","required":["raw_json"],"properties":{"raw_json":{"type":"string","minLength":1,"description":"Malformed, truncated, or markdown-wrapped JSON string to deterministically repair"}}},"responseSchema":{"type":"object"},"example":null,"exampleRequest":null,"tags":[],"displayCostAmount":"0.002","displayCostAsset":"USD","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.002/call","primary":{"kind":"static","protocol":"mpp","network":"tempo","amountUsd":"0.002","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"mpp","network":"tempo","amountUsd":"0.002","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_Guq8jzk47EnLjeNaIfbfl","protocol":"mpp","methodType":"crypto","chain":"tempo","mode":"charge","costAmount":"0.002","costPer":"request","priority":0,"asset":"0x833589fcd6edb6e08f4c7c32d4f71b54bda02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":"mcp-compiler.agentdiet.dev","brandSlug":"mcp-compiler-agentdiet-dev-mpp","brandBaseUrl":"https://mcp-compiler.agentdiet.dev","brandDocsUrl":null,"whatItDoes":"Repairs malformed, truncated, or markdown-wrapped LLM JSON outputs deterministically so multi-agent pipelines never crash.","exampleAgentPrompt":"This LLM response came back with broken JSON — trailing commas, markdown code fences, and single quotes everywhere — can you run it through the JSON repair service and give me back something I can actually parse?","exampleUseCases":[{"title":"Fixing broken LLM pipeline output","prompt":"The language model just returned JSON with trailing commas and a markdown code block wrapper and my pipeline is crashing — can you repair this raw output so it's valid JSON I can use?"},{"title":"Sanitizing single-quoted JSON from agent","prompt":"One of my agents sent back JSON using single quotes instead of double quotes and it's failing to parse — please fix it into proper valid JSON."},{"title":"Recovering truncated JSON response","prompt":"The API response got cut off mid-object and now the JSON is malformed — can you try to repair this truncated JSON string and return a valid version?"}],"resultDescription":"Returns a repaired, valid JSON object derived from the malformed input — with trailing commas removed, markdown fences stripped, single quotes normalized to double quotes, and truncation corrected where possible.","failureModes":["Input JSON is too severely corrupted or truncated to deterministically repair — returns error or partial result","Empty or whitespace-only raw_json input — returns validation error","Non-JSON content passed as input (e.g. plain text or binary) — may return unrecoverable error","Rate limit or payment failure via x402 — returns 402 Payment Required"],"whenToPreferThis":"Choose this endpoint when an LLM or agent in your pipeline produces JSON that fails to parse due to common formatting issues like trailing commas, markdown code fences, single quotes, or truncation. It is ideal for hardening multi-agent workflows that rely on structured LLM outputs, especially when you need a deterministic (non-AI) fix rather than re-prompting the model.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-21T07:21:36.906Z","isFirstParty":false,"canonicalSlug":"mcp-compiler-agentdiet-dev-deterministic-a2a-broken-json-repair-987bc021"}