{"uid":"cap_7nuh14T0ldCrfcJiebMsb","slug":"domain-osint-agentdiet-dev-deterministic-a2a-broken-json-repair-85a6be01","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://domain-osint.agentdiet.dev/v1/llm-json-schema-healer)","url":"https://domain-osint.agentdiet.dev/v1/llm-json-schema-healer?utm_source=zero.xyz","method":"POST","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_HMDGnV0vcd1Hja_i9kyi8","protocol":"mpp","methodType":"crypto","chain":"tempo","mode":"charge","costAmount":"0.002","costPer":"request","priority":0,"asset":"0x833589fcd6edb6e08f4c7c32d4f71b54bda02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":"domain-osint.agentdiet.dev","brandSlug":"domain-osint-agentdiet-dev-mpp","brandBaseUrl":"https://domain-osint.agentdiet.dev","brandDocsUrl":null,"whatItDoes":"Repairs truncated or malformed LLM JSON outputs (trailing commas, markdown fences, single quotes) so multi-agent pipelines never crash","exampleAgentPrompt":"This JSON came out of an LLM call and it's broken — trailing commas, single quotes, wrapped in markdown fences — can you repair it so it's valid JSON I can actually use? Here it is: ```json {name: 'Alice', scores: [10, 20,], active: true,} ```","exampleUseCases":[{"title":"Fixing LLM output in agentic pipeline","prompt":"The JSON my coding agent just returned is malformed — it has trailing commas and single quotes instead of double quotes. Can you fix it so my next pipeline step doesn't crash? Here's the raw output: {\"name\": 'Bob', \"items\": [1, 2, 3,], \"done\": true,}"},{"title":"Stripping markdown fences from AI JSON","prompt":"My AI returned a JSON blob wrapped in triple-backtick markdown fences and it's breaking my parser. Can you strip the fences and repair any syntax issues so I get clean, valid JSON back?"},{"title":"Recovering truncated JSON from LLM","prompt":"My LLM response got cut off mid-JSON — it ends abruptly without closing brackets. Can you repair and complete the truncated JSON so it's parseable? Here it is: {\"user\": \"Alice\", \"settings\": {\"theme\": \"dark\", \"notifications\":"}],"resultDescription":"A repaired, valid JSON object with syntax errors corrected — trailing commas removed, single quotes converted to double quotes, markdown fences stripped, and truncated structures closed — ready to be parsed and passed to the next step in an agent pipeline.","failureModes":["JSON is so severely truncated or corrupted that deterministic repair is impossible — returns an error","Input is not JSON at all (e.g. plain text or binary) — returns a parse error","Input exceeds size limits — may return a payload-too-large error","Ambiguous schema structure where multiple valid repairs exist — may return best-effort result with a warning"],"whenToPreferThis":"Choose this endpoint when your multi-agent or LLM pipeline receives malformed JSON — especially with trailing commas, single quotes, markdown code fences, or truncation — and you need a deterministic, non-hallucinating repair rather than asking an LLM to rewrite the JSON (which risks altering values). Ideal for production pipelines where reliability and idempotency matter and you cannot afford crashes from bad LLM outputs.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-11-21T06:44:07.295Z","isFirstParty":false,"canonicalSlug":"domain-osint-agentdiet-dev-deterministic-a2a-broken-json-repair-544ae7e3"}