{"uid":"cap_BiZmItJQGy6ikgf-0F2Q3","slug":"email-verify-agentdiet-dev-deterministic-llm-json-repair-schema-359ed827","name":"Deterministic LLM 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/llm-json-schema-healer)","url":"https://email-verify.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_0EsllBv6sWomQkqGnzFuS","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, malformed, or markdown-wrapped JSON from LLM outputs so multi-agent pipelines can process structured data without crashing","exampleAgentPrompt":"This JSON came back from the LLM but it has trailing commas and markdown fences and is crashing my parser — can you fix it so it's valid JSON I can use? Here it is: ```{\"name\": \"Alice\", \"age\": 30,}```","exampleUseCases":[{"title":"Fixing broken LLM pipeline output","prompt":"My AI agent just returned this JSON but it has single quotes and trailing commas and my code is throwing a parse error — can you clean it up and give me valid JSON? Here's the broken output: {'user': 'Bob', 'score': 42,}"},{"title":"Stripping markdown fences from structured response","prompt":"The LLM wrapped its JSON response in markdown code fences and now my downstream service can't parse it. Can you strip the fences and repair any other issues so I get clean JSON back? The response is: ```json\n{\"status\": \"ok\", \"items\": [1, 2, 3,]}\n```"},{"title":"Recovering truncated JSON from context cutoff","prompt":"My model hit its token limit mid-response and returned an incomplete JSON object that cuts off in the middle. Can you repair and close it out so it's valid and parseable? Here's what I got: {\"report\": {\"title\": \"Q3 Summary\", \"sections\": [\"intro\", \"data\""}],"resultDescription":"A repaired, valid JSON object with all syntax errors corrected — trailing commas removed, markdown fences stripped, single quotes converted to double quotes, and truncated structures properly closed. The response is a JSON object containing the healed data ready for downstream consumption.","failureModes":["Input is so severely corrupted that deterministic repair is impossible — returns error indicating unrecoverable JSON","Input string is empty or whitespace — fails minLength validation","JSON is structurally ambiguous after truncation and cannot be deterministically closed — may return partial repair with warning","Non-JSON input (e.g. plain text, XML) passed as raw_json — repair attempt may fail or return unexpected output"],"whenToPreferThis":"Choose this endpoint when you need deterministic, rule-based JSON repair of LLM outputs rather than probabilistic LLM-based re-generation. Ideal for multi-agent pipelines where reliability and consistency are critical, especially when outputs frequently contain trailing commas, markdown code fences, or single-quoted strings. Best suited for structured data recovery in automated workflows where you cannot tolerate crashes from malformed JSON.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-28T00:31:21.653Z","isFirstParty":false,"canonicalSlug":"email-verify-agentdiet-dev-deterministic-llm-json-repair-schema-359ed827"}