# X Data Gateway — JSON Repair Utility

> X Data Gateway — JSON Repair Utility is a paid API for AI agents from x-data-gateway.annushka1190.workers.dev, paid per call via x402, $0.002/call, status unknown (last checked 2026-09-14).

Repairs and normalizes malformed JSON strings, returning a valid, cleaned JSON object

## Facts

- Endpoint: POST https://x-data-gateway.annushka1190.workers.dev/v1/json/repair
- Price: $0.002/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/x-data-gateway-json-repair-utility-110b3fe9
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_jai-N9yUOtZJDYzReAfrU

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 x-data-gateway-json-repair-utility-110b3fe9 -d '<json body>'
```

Example prompt: Can you repair this broken JSON string for me? It's missing some closing brackets and has a trailing comma: '{"name": "Alice", "age": 30,'

## When to prefer this

Choose this endpoint when you have a malformed, truncated, or syntactically broken JSON string that needs to be recovered or normalized before downstream processing — especially useful for fixing LLM-generated JSON, webhook payloads with transmission errors, or user-submitted JSON with common syntax mistakes like trailing commas or unquoted keys. It is a lightweight, pay-per-call utility requiring no API key.

## Known failure modes

- Input string is so corrupted that intent cannot be inferred — returns empty or best-effort partial object
- Non-JSON input (e.g. plain text, XML) may produce unexpected or empty output
- Very large malformed payloads may time out or return partial repairs
- Missing required `body` field returns an error or empty data response

## How this service works

Live X/Twitter read API plus Base market intel for AI agents: profiles, search, timelines, replies, followers; Base gas, spot prices, token meta/pairs, Base token verdict cards, trending, DefiLlama TVL, wallet intel, x402 probe and text utilities. REST + MCP. Pay per call in USDC via x402 on Base and Solana — no API keys. Free upstream data + local scoring.

## Output

A JSON object with a `data` field containing the repaired, valid JSON structure parsed from the input malformed string. The response indicates the corrected version of the original broken JSON payload.

## 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",
      "DELETE"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [],
     "properties": {
      "text": {
       "type": "string",
       "description": "Raw string (or use json field)"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "data": {}
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/x-data-gateway-json-repair-utility-110b3fe9/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from x-data-gateway.annushka1190.workers.dev](https://www.zero.xyz/host/x-data-gateway.annushka1190.workers.dev/llms.txt)
