# Deterministic A2A Broken-JSON Repair & Schema Validator

> Deterministic A2A Broken-JSON Repair & Schema Validator is a paid API for AI agents from cve-intel.agentdiet.dev, paid per call via MPP, $0.002/call, status unknown (last checked 2026-10-21).

Repairs truncated or malformed LLM JSON outputs (trailing commas, markdown fences, single quotes) so multi-agent pipelines never crash

## Facts

- Endpoint: GET https://cve-intel.agentdiet.dev/v1/structured-output?utm_source=zero.xyz
- Price: $0.002/call
- Payment: MPP
- Status: unknown
- Last checked: 2026-10-21
- Activations on Zero: 0
- Provider: cve-intel.agentdiet.dev
- Website: https://cve-intel.agentdiet.dev
- Canonical page: https://www.zero.xyz/c/cve-intel-agentdiet-dev-deterministic-a2a-broken-json-repair-schema-dfc150d7
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_8ftJkGFOyjVrlu-LbyFIG

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability cve-intel-agentdiet-dev-deterministic-a2a-broken-json-repair-schema-dfc150d7
```

Example prompt: This JSON from my LLM is broken — it has trailing commas, single quotes, and a markdown code fence wrapper. Can you repair it into valid JSON so my pipeline doesn't crash? Here it is: ```json {'name': 'test', 'value': 42,}```

## When to prefer this

Choose this endpoint when your multi-agent pipeline receives malformed, truncated, or markdown-wrapped JSON from an LLM and needs deterministic (not AI-based) repair before passing data to a downstream tool. Ideal for production agent orchestration where reliability matters and you cannot afford nondeterministic re-prompting. Prefer over regex-based manual fixes when the malformations are compound (e.g. both trailing commas AND markdown fences AND single quotes at once).

## Known failure modes

- JSON is too severely corrupted to deterministically repair — returns error indicating repair was not possible
- Input string is not JSON at all (e.g. plain prose) — may return parse failure
- Ambiguous truncation that could resolve to multiple valid structures — may return best-guess or error
- Very large malformed JSON strings may exceed query parameter length limits
- Missing required raw_json parameter returns 400 error

## How this service works

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://cve-intel.agentdiet.dev/v1/structured-output)

## Output

A repaired, valid JSON object that has been cleaned of common LLM output artifacts including trailing commas, markdown code fences (backticks), single quotes, and truncation issues — returned as a parseable JSON object ready for downstream agent consumption

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "required": [
  "raw_json"
 ],
 "properties": {
  "raw_json": {
   "type": "string",
   "minLength": 1,
   "description": "Malformed, truncated, or markdown-wrapped JSON string to deterministically repair"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "object"
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/cve-intel-agentdiet-dev-deterministic-a2a-broken-json-repair-schema-dfc150d7/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from cve-intel.agentdiet.dev](https://www.zero.xyz/host/cve-intel.agentdiet.dev/llms.txt)
