# JSON Guard — Validate & PII-Detect JSON

> JSON Guard — Validate & PII-Detect JSON is a paid API for AI agents from shelf.thirdmade.net, paid per call via x402, $0.001/call, status unknown (last checked 2026-09-14).

Validates a JSON string for correctness, detects PII within its values, and reports schema statistics for use as a data-quality gate.

## Facts

- Endpoint: GET https://shelf.thirdmade.net/probe/json-guard
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/json-guard-validate-pii-detect-json-650e880f
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_Oy8A32X-of-ETyoiL-VRS

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 json-guard-validate-pii-detect-json-650e880f
```

Example prompt: Can you run this JSON through the json-guard validator and tell me if it's valid and whether it contains any PII? Here's the payload: {"name":"John Doe","email":"john@example.com","age":34}

## When to prefer this

Use this endpoint when you need a lightweight, pay-per-call JSON validation and PII scanning gate — especially in agentic pipelines where you want to catch malformed or sensitive data before it reaches storage, logging, or downstream APIs. Prefer it over manual regex checks or heavy-weight data-loss-prevention tools when you need a fast, single-call quality check that combines syntax validation with PII detection and schema statistics in one response.

## Known failure modes

- Malformed or missing 'json' query parameter returns a validation error
- Extremely large JSON payloads may be rejected or time out
- Ambiguous values that resemble but aren't PII may produce false positives
- Non-UTF-8 or binary-encoded strings may fail parsing
- Network or upstream service errors return a 5xx response

## How this service works

Validates JSON, detects PII inside values, reports schema stats. Pipeline agents use this as a data-quality gate.

## Output

Returns a JSON object indicating whether the input is valid JSON, a list of detected PII fields or values (e.g. email addresses, phone numbers, SSNs) found within the payload, and schema statistics such as field counts, types, and structural summary.

## 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"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "json"
     ],
     "properties": {
      "json": {
       "type": "string",
       "description": "JSON text to validate"
      }
     }
    }
   },
   "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/json-guard-validate-pii-detect-json-650e880f/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from shelf.thirdmade.net](https://www.zero.xyz/host/shelf.thirdmade.net/llms.txt)
