{"uid":"cap_VPv7Mr8iul52U9Zvh5h05","slug":"company-enrich-agentdiet-dev-llm-json-repair-schema-validator-8f67286f","name":"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://company-enrich.agentdiet.dev/v1/llm-json-schema-healer)","url":"https://company-enrich.agentdiet.dev/v1/llm-json-schema-healer?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_o_QledZ6w2crBD7SNj3iQ","protocol":"mpp","methodType":"crypto","chain":"tempo","mode":"charge","costAmount":"0.002","costPer":"request","priority":0,"asset":"0x833589fcd6edb6e08f4c7c32d4f71b54bda02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":"company-enrich.agentdiet.dev","brandSlug":"company-enrich-agentdiet-dev-mpp","brandBaseUrl":"https://company-enrich.agentdiet.dev","brandDocsUrl":null,"whatItDoes":"Deterministically repairs malformed, truncated, or markdown-wrapped LLM JSON outputs (trailing commas, markdown fences, single quotes) so multi-agent pipelines can safely consume them.","exampleAgentPrompt":"My LLM just returned this JSON with trailing commas and markdown code fences — can you deterministically repair it so I can parse it cleanly: ```json {\"name\": \"Acme\", \"score\": 42,} ```?","exampleUseCases":[{"title":"Fix crashed agent pipeline JSON","prompt":"The agent in my pipeline returned malformed JSON with single quotes and a trailing comma — something like {'company': 'OpenAI', 'founded': 2015,} — can you repair it into valid JSON so the next step doesn't crash?"},{"title":"Strip markdown fences from LLM output","prompt":"My LLM wrapped its JSON response in triple backtick markdown fences and now my parser is breaking. Here's the raw output: ```json {\"result\": true} ``` — please strip the fences and return clean parseable JSON."},{"title":"Heal truncated JSON from long generation","prompt":"My model got cut off mid-generation and produced a truncated JSON object that's missing closing braces. Can you repair this broken JSON so it's valid: {\"items\": [{\"id\": 1, \"name\": \"widget\""}],"resultDescription":"Returns a repaired, valid JSON object where the input malformed, truncated, or markdown-wrapped JSON string has been deterministically fixed — trailing commas removed, markdown fences stripped, single quotes converted to double quotes, and missing closing brackets/braces added as needed.","failureModes":["Input JSON too severely corrupted to deterministically repair — returns error indicating repair not possible","Empty or whitespace-only raw_json input — validation error","Input exceeds maximum length limits — truncation or rejection error","Ambiguous structure where multiple valid repairs exist — may return one interpretation without warning"],"whenToPreferThis":"Choose this endpoint when your multi-agent pipeline or LLM workflow is receiving JSON outputs that are syntactically broken due to common LLM failure modes (trailing commas, markdown wrapping, single quotes, truncation) and you need a fast, deterministic fix before downstream parsing. Prefer this over a general-purpose JSON library when the errors are specifically LLM-output patterns and you need a hosted, pay-per-call solution compatible with x402/MCP agent architectures.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-21T07:22:03.415Z","isFirstParty":false,"canonicalSlug":"company-enrich-agentdiet-dev-llm-json-repair-schema-validator-8f67286f"}