{"uid":"cap_h-Md6kzW1Y6IHiiKyp4fy","slug":"email-verify-agentdiet-dev-deterministic-a2a-broken-json-repair-8326c46f","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://email-verify.agentdiet.dev/v1/json-repair)","url":"https://email-verify.agentdiet.dev/v1/json-repair?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_3M2UVvaSqwQ8-OyWNMLSz","protocol":"mpp","methodType":"crypto","chain":"tempo","mode":"charge","costAmount":"0.002","costPer":"request","priority":0,"asset":"0x833589fcd6edb6e08f4c7c32d4f71b54bda02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":"email-verify.agentdiet.dev","brandSlug":"email-verify-agentdiet-dev-mpp","brandBaseUrl":"https://email-verify.agentdiet.dev","brandDocsUrl":null,"whatItDoes":"Repairs truncated or malformed LLM JSON outputs (trailing commas, markdown fences, single quotes) into valid JSON so multi-agent pipelines never crash.","exampleAgentPrompt":"This JSON string came back from an LLM with trailing commas and markdown fences and it's breaking my pipeline — can you repair it and return valid JSON? Here it is: ```{\"name\": \"Alice\", \"age\": 30,}```","exampleUseCases":[{"title":"Fix LLM output crashing agent pipeline","prompt":"My language model returned this JSON but it has trailing commas and single quotes everywhere and my next agent step is crashing trying to parse it — can you repair it into valid JSON? Here's the raw output: {'name': 'Bob', 'score': 42,}"},{"title":"Strip markdown fences from model response","prompt":"The model wrapped its JSON in triple-backtick markdown fences and my code can't parse it — can you clean it up and give me back a proper JSON object? The raw string is: ```json\n{\"result\": \"ok\", \"count\": 5}\n```"},{"title":"Recover truncated JSON from timeout","prompt":"My LLM call timed out mid-generation and I got a truncated JSON string that cuts off in the middle — can you repair it and fill in whatever's needed to make it valid? Here it is: {\"items\": [{\"id\": 1, \"name\": \"alpha\"}, {\"id\": 2"}],"resultDescription":"A JSON object containing the repaired, valid JSON parsed from the malformed input string. The response allows downstream agents and pipeline steps to safely parse and consume the corrected data without crashing.","failureModes":["Input is so severely malformed that deterministic repair is impossible — returns error response","Input is not JSON-like at all (e.g. plain text or binary) — repair may fail or return unexpected structure","Truncation is too severe to infer intended structure — output may be incomplete","Network or service unavailability returns HTTP 5xx","Insufficient payment or missing x402 payment header returns HTTP 402"],"whenToPreferThis":"Choose this endpoint when you need deterministic, rule-based JSON repair rather than probabilistic LLM-based fixing — ideal for high-throughput multi-agent pipelines where consistency and speed matter. Prefer it when dealing with common LLM JSON failure modes: trailing commas, markdown code fences, single quotes, or mild truncation. Best suited for automated pipelines that cannot tolerate parse errors and need a reliable, cheap ($0.002/call) repair step between agent hops.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-11-21T06:34:43.760Z","isFirstParty":false,"canonicalSlug":"email-verify-agentdiet-dev-deterministic-a2a-broken-json-repair-fee515ab"}