# Agent Dev Tools – JSON Validate & Format

> Agent Dev Tools – JSON Validate & Format is a paid API for AI agents from agent-dev-tools.frcompanycheck.workers.dev, paid per call via x402, $0.002/call, status unknown (last checked 2026-10-16).

Validates a JSON string and returns its type, structural stats, pretty-printed form, and minified form

## Facts

- Endpoint: POST https://agent-dev-tools.frcompanycheck.workers.dev/v1/json/validate?utm_source=zero.xyz
- Price: $0.002/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-16
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/agent-dev-tools-json-validate-format-fe1e8adc
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_a4JN4po6rpWOEz13tz27k

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 agent-dev-tools-json-validate-format-fe1e8adc -d '<json body>'
```

Example prompt: Can you check if this JSON is valid and give me a pretty-printed version with 2-space indentation: '{"name":"Alice","scores":[10,20,30]}'?

## When to prefer this

Use this endpoint when you need fast, stateless JSON validation or formatting without setting up an account or API key — especially inside an AI agent pipeline that already handles x402 micropayments. Ideal for one-off checks, CI tooling, or agent workflows where JSON correctness needs to be verified before downstream processing.

## Known failure modes

- Invalid or unparseable JSON input returns a validation error with no charge
- Missing required `json` field returns a 400-level error
- Indent value outside 0–8 range may be rejected or clamped
- Extremely large JSON strings may time out or exceed worker limits

## How this service works

Fast deterministic developer utilities for AI agents, paid per call in USDC via x402 (no account, no API key): UUID v4/v7, secure random numbers, dice, MD5/SHA/HMAC hashing, base64/hex/URL/HTML encoding, JSON validation/formatting, QR code SVG, password generation, JWT decoding and text statistics. Pure computation, nothing stored. Errors are never charged.

## Output

Returns a JSON object with: `valid` (boolean), `type` (JSON root type like 'object' or 'array'), `stats` (node count, max depth, object key count), `pretty` (indented string), and `minified` (compact string). If invalid, returns an error description without charging.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "json": {
   "type": "string",
   "description": "The JSON text to validate (a string)"
  },
  "indent": {
   "type": "integer",
   "description": "Pretty-print indent 0-8 (default 2)"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "type": "object",
  "stats": {
   "nodes": 6,
   "max_depth": 2,
   "object_keys": 2
  },
  "valid": true,
  "pretty": "{\n  \"a\": 1 ...",
  "minified": "{\"a\":1,\"b\":[1,2,3]}"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/agent-dev-tools-json-validate-format-fe1e8adc/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from agent-dev-tools.frcompanycheck.workers.dev](https://www.zero.xyz/host/agent-dev-tools.frcompanycheck.workers.dev/llms.txt)
