# aiskills402 JSON Repair

> aiskills402 JSON Repair is a paid API for AI agents from api.aiskills402.com, paid per call via x402, $0.05/call, status unknown (last checked 2026-10-11).

Repairs broken or malformed JSON so it can be parsed, preserving all original values without guessing or altering data.

## Facts

- Endpoint: GET https://api.aiskills402.com/v1/skills/json-repair/file?utm_source=zero.xyz
- Price: $0.05/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-11
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/aiskills402-json-repair-6f623143
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_DuPaHBukTS6XV4sljliPY

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 aiskills402-json-repair-6f623143
```

Example prompt: This JSON came back from an API and it won't parse — it has single quotes, a trailing comma, and some comments in it. Can you repair it so it's valid JSON without changing any of the values?

## When to prefer this

Choose this endpoint when you need to recover broken JSON while guaranteeing no value is silently altered or invented — especially when data fidelity is critical. It is specifically designed to handle the full range of real-world JSON breakage patterns (LLM output artifacts, copy-paste corruption, truncated responses, Python/JS literal mixups) in a single call. Prefer it over generic string manipulation or LLM-based repair when you need deterministic, conservative repair (truncated values become null, not guesses).

## Known failure modes

- Input is so corrupted that no valid structure can be inferred — returns an error or best-effort null-heavy result
- Input is not JSON at all (e.g. plain CSV or XML) — may return unexpected output
- Very large files may time out or exceed payload limits
- Rate limiting or payment failure returns a 402 or 429 error

## How this service works

JSON Repair: Fix It, Keep Every Value: Repairs broken JSON so a program can parse it, without changing any value. Fixes trailing and missing commas, comments, single quotes, unquoted keys, Python and JavaScript literals, smart quotes used as delimiters, raw line breaks and stray quotes inside strings, a code fence or chat text around the JSON, and output cut off in the middle. A value that was cut off becomes null instead of a guess, numbers JSON cannot hold as written are kept as strings, and …

## Output

Returns a valid, parseable JSON object or array with all original values preserved. Truncated values become null rather than being guessed. Numbers that exceed JSON precision are kept as strings. Syntax issues like trailing commas, missing commas, comments, single quotes, unquoted keys, smart quotes, raw line breaks, stray quotes, Python/JavaScript literals, and surrounding code fences or chat text are all corrected.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET",
      "HEAD"
     ],
     "type": "string"
    },
    "headers": {
     "type": "object",
     "additionalProperties": {
      "type": "string"
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/aiskills402-json-repair-6f623143/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.aiskills402.com](https://www.zero.xyz/host/api.aiskills402.com/llms.txt)
