{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/scribetools-com/json-schema/scribetools-com-upload-urls-request-schema.json",
  "title": "UploadUrlsRequest",
  "x-generated": "2026-11-24",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/_original/scribetools-com-api-openapi.json#/components/schemas/UploadUrlsRequest",
  "properties": {
    "files": {
      "items": {
        "type": "string"
      },
      "type": "array",
      "title": "Files",
      "description": "List of filenames to upload"
    },
    "file_infos": {
      "anyOf": [
        {
          "items": {
            "$ref": "#/$defs/UploadFileInfo"
          },
          "type": "array"
        },
        {
          "type": "null"
        }
      ],
      "title": "File Infos",
      "description": "Per-file upload metadata. Preferred over files/file_pages because it is stable when multiple files have the same filename."
    },
    "file_pages": {
      "anyOf": [
        {
          "additionalProperties": {
            "type": "integer",
            "maximum": 2000.0,
            "minimum": 1.0
          },
          "type": "object"
        },
        {
          "type": "null"
        }
      ],
      "title": "File Pages",
      "description": "Map of filename to page count"
    },
    "file_sizes": {
      "anyOf": [
        {
          "additionalProperties": {
            "type": "integer"
          },
          "type": "object"
        },
        {
          "type": "null"
        }
      ],
      "title": "File Sizes",
      "description": "Map of filename to file size in bytes"
    },
    "idempotency_key": {
      "anyOf": [
        {
          "type": "string",
          "format": "uuid"
        },
        {
          "type": "null"
        }
      ],
      "title": "Idempotency Key",
      "description": "Client-generated submission id. Reusing it returns stable upload paths and allows job creation to collapse request replays."
    }
  },
  "type": "object",
  "$defs": {
    "UploadFileInfo": {
      "properties": {
        "id": {
          "type": "string",
          "title": "Id"
        },
        "filename": {
          "type": "string",
          "title": "Filename"
        },
        "size_bytes": {
          "anyOf": [
            {
              "type": "integer"
            },
            {
              "type": "null"
            }
          ],
          "title": "Size Bytes"
        },
        "pages": {
          "anyOf": [
            {
              "type": "integer",
              "maximum": 2000.0,
              "minimum": 1.0
            },
            {
              "type": "null"
            }
          ],
          "title": "Pages"
        }
      },
      "type": "object",
      "required": [
        "id",
        "filename"
      ],
      "title": "UploadFileInfo"
    }
  }
}