# SchemaSure Image Extraction

> SchemaSure Image Extraction is a paid API for AI agents from schemasure.com, paid per call via x402, $0.03/call, status unknown (last checked 2026-09-14).

Extracts structured, JSON-Schema-valid typed JSON from PNG, JPEG, or WebP document images using a pay-per-call x402 API

## Facts

- Endpoint: POST https://schemasure.com/v2/extract-image
- Price: $0.03/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/schemasure-image-extraction-68f36126
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_KOMMcVJZw42wDJmRzaDwM

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 schemasure-image-extraction-68f36126 -d '<json body>'
```

Example prompt: Extract the invoice number, date, vendor name, line items, and total amount from this JPEG invoice image and return the result as strictly typed JSON matching my schema — use up to 3 repair attempts if needed.

## When to prefer this

Choose this endpoint when you need to extract structured, typed, schema-validated JSON from image files (PNG, JPEG, WebP) such as scanned documents, photos of forms, receipts, or ID cards. It is especially valuable when downstream systems require strict JSON Schema conformance, since the API guarantees the output satisfies your provided schema or does not charge. Prefer it over generic OCR services when typed fields, data validation, and schema enforcement are required. The pay-only-on-success model (failed extractions are not settled) makes it low-risk for batch document processing pipelines.

## Known failure modes

- Image MIME type does not match decoded file signature — request rejected
- Base64 image data is malformed or empty — parsing error
- Provided JSON Schema is invalid or malformed — schema error
- Extracted data cannot be made to conform to the schema within maxRepairs iterations — call not settled, no charge
- Unsupported image format (e.g. GIF, TIFF) — rejected with unsupported MIME type error
- Image content is too low quality or illegible for reliable extraction — may return partial or failed result

## How this service works

Extract strict, JSON-Schema-valid typed JSON from a PNG, JPEG, or WebP document image. Failed extraction calls are not settled. Always-paid x402 V2 image API.

## Output

A structured JSON object that is guaranteed to satisfy the provided JSON Schema (draft 2020-12), containing typed values extracted from the image. The response only includes fields defined in the schema when strict mode is enabled. If extraction fails to validate within the allowed repair iterations, the call is not settled and no charge is applied.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "image": {
   "type": "object",
   "required": [
    "data",
    "mimeType"
   ],
   "properties": {
    "data": {
     "type": "string",
     "minLength": 1,
     "description": "Base64-encoded image bytes without a data-URL prefix.",
     "contentEncoding": "base64"
    },
    "mimeType": {
     "enum": [
      "image/png",
      "image/jpeg",
      "image/webp"
     ],
     "type": "string",
     "description": "Declared image media type; it must match the decoded file signature."
    }
   },
   "additionalProperties": false
  },
  "schema": {
   "type": "object",
   "description": "JSON Schema (draft 2020-12) that the returned `data` is guaranteed to satisfy."
  },
  "options": {
   "type": "object",
   "properties": {
    "strict": {
     "type": "boolean",
     "default": true,
     "description": "Drop fields not present in the schema."
    },
    "maxRepairs": {
     "type": "integer",
     "maximum": 5,
     "minimum": 0,
     "description": "Max validate->re-prompt repair iterations."
    }
   },
   "additionalProperties": false
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/schemasure-image-extraction-68f36126/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from schemasure.com](https://www.zero.xyz/host/schemasure.com/llms.txt)
