# AI Structured Output Validation

> AI Structured Output Validation is a paid API for AI agents from market.datapackvibe.com, paid per call via x402, $0.01/call, status unknown (last checked 2026-10-13).

Validates a JSON value against a JSON Schema subset (types, properties, required fields, items, enums, and size/number limits) locally without external references or regex execution

## Facts

- Endpoint: POST https://market.datapackvibe.com/x402/ai-output-validation?utm_source=zero.xyz
- Price: $0.01/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-13
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/ai-structured-output-validation-86a5f1e4
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_YbyaHWRl_OcbMYsNvNDQD

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 ai-structured-output-validation-86a5f1e4 -d '<json body>'
```

Example prompt: Can you validate this JSON value {"name":"Ada","count":2} against my schema that requires 'name' as a string and 'count' as a non-negative integer, with no extra properties allowed?

## When to prefer this

Choose this endpoint when you need lightweight, local JSON schema validation without spinning up a full validation library — especially for validating AI-generated structured outputs against known schemas covering types, required fields, enums, and numeric/size limits. Ideal for agent pipelines that need a cheap ($0.01), fast sanity-check on LLM outputs before downstream processing. Not suitable if you need regex pattern validation, $ref resolution, or full JSON Schema draft compliance.

## Known failure modes

- Schema uses unsupported features like $ref or regex patterns — these are not evaluated
- Value is valid JSON but schema itself is malformed — may return error or unexpected result
- Very large or deeply nested JSON may hit size limits
- External schema references ($ref with URLs) are silently ignored, potentially giving false positives

## How this service works

AI Structured Output Validation: Validate a JSON value against a documented schema subset: types, properties, required, items, enums and size/number limits. No external references or regex execution. Local processing. Limits and retention: /ai-services.

## Output

A validation result indicating whether the JSON value conforms to the provided schema, with details on any type mismatches, missing required fields, enum violations, additionalProperties violations, or exceeded size/number limits

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "value": {
   "default": {
    "name": "Ada",
    "count": 2
   }
  },
  "schema": {
   "type": "object",
   "default": {
    "type": "object",
    "required": [
     "name",
     "count"
    ],
    "properties": {
     "name": {
      "type": "string"
     },
     "count": {
      "type": "integer",
      "minimum": 0
     }
    },
    "additionalProperties": false
   }
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/ai-structured-output-validation-86a5f1e4/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from market.datapackvibe.com](https://www.zero.xyz/host/market.datapackvibe.com/llms.txt)
