# Forest Agent Tools JSON Schema Validator

> Forest Agent Tools JSON Schema Validator is a paid API for AI agents from http--forest-gas-station-mainnet--lcjl27p8lmjs.code.run, paid per call via x402, $0.001/call, status unknown (last checked 2026-10-22).

Validates caller-supplied JSON against the Forest bounded JSON Schema subset v1 and returns deterministic, machine-readable violation reports with stable paths — no network I/O, inference, or mutation.

## Facts

- Endpoint: POST https://http--forest-gas-station-mainnet--lcjl27p8lmjs.code.run/json/validate?utm_source=zero.xyz
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-22
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/forest-agent-tools-json-schema-validator-c925ccfe
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_5kIks0-icQ2Ut31luxdMp

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 forest-agent-tools-json-schema-validator-c925ccfe -d '<json body>'
```

Example prompt: Before I trust this JSON output from the pipeline, validate it against this schema: {"type":"object","properties":{"name":{"type":"string"},"age":{"type":"integer"}},"required":["name","age"]} — and tell me exactly which fields violate it, if any.

## When to prefer this

Choose this endpoint when you need a fast, deterministic, side-effect-free JSON schema validation with stable violation paths — especially in agent pipelines where you must verify structured LLM output or third-party payloads before trusting or forwarding them. Prefer this over general-purpose validators when you need machine-readable violation paths and guaranteed no network I/O, remote $ref resolution, or regex evaluation, making it safe to call in sandboxed or latency-sensitive agent workflows.

## Known failure modes

- Malformed JSON in the value or schema field returns a parse error
- Schema uses features outside the Forest bounded subset (e.g. remote $ref, regex patterns) — unsupported keywords are ignored or rejected
- Missing required fields (value or schema) returns a 400-level error
- Payment not included or invalid causes HTTP 402 response
- Extremely deeply nested schemas may hit processing limits

## How this service works

Machine-readable contract for active Forest paid capabilities. Unsigned paid calls return HTTP 402 with a PAYMENT-REQUIRED x402 challenge.

## Output

A deterministic, machine-readable report of schema violations found in the submitted JSON value, including stable dot-notation or JSON Pointer paths to each offending field and a description of each violation. Returns an empty violations list if the value is fully valid. No mutations are made to the input.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "value": {
   "description": "Public value value used to scope this lookup."
  },
  "schema": {
   "type": "object",
   "description": "Public schema value used to scope this lookup."
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "ok": true,
  "data": {
   "valid": false,
   "truncated": false,
   "violations": [],
   "input_bytes": 0,
   "schema_nodes": 1,
   "schema_scope": "forest_bounded_json_schema_subset_v1",
   "violation_count": 0,
   "value_nodes_visited": 0
  },
  "meta": {
   "cache": "miss",
   "provider": "local-json",
   "checked_at": "2026-01-01T00:00:00.000Z",
   "duration_ms": 0
  },
  "version": "1",
  "capability": "json.validate"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/forest-agent-tools-json-schema-validator-c925ccfe/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from http--forest-gas-station-mainnet--lcjl27p8lmjs.code.run](https://www.zero.xyz/host/http--forest-gas-station-mainnet--lcjl27p8lmjs.code.run/llms.txt)
