{"uid":"cap_LkFgOQx1t6yzPVFc6kIHy","slug":"hn-pulse-agentdiet-dev-deterministic-a2a-broken-json-repair-schema-5046b505","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://hn-pulse.agentdiet.dev/v1/schema-repair)","url":"https://hn-pulse.agentdiet.dev/v1/schema-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_S8MQq1dKXNwqlIFRr0n-l","protocol":"mpp","methodType":"crypto","chain":"tempo","mode":"charge","costAmount":"0.002","costPer":"request","priority":0,"asset":"0x833589fcd6edb6e08f4c7c32d4f71b54bda02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":"hn-pulse.agentdiet.dev","brandSlug":"hn-pulse-agentdiet-dev-mpp","brandBaseUrl":"https://hn-pulse.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 from the LLM came back totally broken — it has trailing commas, markdown code fences, and single quotes. Can you repair it so I can use it in the next pipeline step? Here's the raw output: ```{'name': 'Alice', 'age': 30,}```","exampleUseCases":[{"title":"Fix LLM output in agent pipeline","prompt":"The language model just returned a JSON block wrapped in markdown fences with trailing commas and it's crashing my pipeline. Can you repair this raw output so it's valid JSON I can pass to the next step: ```json\n{\"user\": \"Bob\", \"score\": 42,}\n```"},{"title":"Recover truncated JSON response","prompt":"My LLM call got cut off mid-response and returned this incomplete JSON: {\"items\": [{\"id\": 1, \"name\": \"foo\". Can you fix and complete it so it's parseable?"},{"title":"Sanitize single-quoted JSON from chatbot output","prompt":"This chatbot output used single quotes instead of double quotes everywhere and I can't parse it — {'status': 'ok', 'count': 5}. Please convert it into valid JSON I can work with."}],"resultDescription":"A JSON object containing the repaired, valid JSON — with markdown fences stripped, trailing commas removed, single quotes converted to double quotes, and truncations corrected — ready for downstream agent consumption","failureModes":["Severely corrupted input with no recoverable structure returns an error or empty result","Input that is already valid JSON still passes through successfully","Extremely long or deeply nested malformed JSON may time out","Ambiguous truncations may be repaired in unexpected ways"],"whenToPreferThis":"Choose this endpoint when your multi-agent pipeline receives raw LLM-generated JSON that may be malformed, truncated, or wrapped in markdown code fences, and you need a deterministic repair rather than a probabilistic or LLM-based fix. Ideal for production pipelines where reliability and idempotency matter and you cannot afford downstream crashes due to bad JSON.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-11-21T12:40:51.480Z","isFirstParty":false,"canonicalSlug":"hn-pulse-agentdiet-dev-deterministic-a2a-broken-json-repair-schema-e04c99ac"}