{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/scrapiq-io/json-schema/scrapiq-io-extract-request-schema.json",
  "title": "ExtractRequest",
  "description": "Request to extract structured data from a URL.",
  "x-generated": "2026-11-24",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/scrapiq-io-openapi.json#/components/schemas/ExtractRequest",
  "properties": {
    "url": {
      "type": "string",
      "maxLength": 2083,
      "minLength": 1,
      "format": "uri",
      "title": "Url",
      "description": "URL to fetch and extract from"
    },
    "schema": {
      "anyOf": [
        {
          "additionalProperties": true,
          "type": "object"
        },
        {
          "type": "null"
        }
      ],
      "title": "Schema",
      "description": "Optional JSON schema describing fields to extract. If omitted, returns raw cleaned text."
    },
    "format": {
      "type": "string",
      "enum": [
        "json",
        "text",
        "markdown"
      ],
      "title": "Format",
      "description": "Output format. 'json' for structured extraction, 'text' for plain text, 'markdown' for clean markdown.",
      "default": "json"
    },
    "include_metadata": {
      "type": "boolean",
      "title": "Include Metadata",
      "description": "Include page metadata (title, description, author, date) in the response.",
      "default": true
    }
  },
  "type": "object",
  "required": [
    "url"
  ]
}