{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/amazon-textract/json-schema/amazon-textract-detect-document-text-request-schema.json",
  "title": "DetectDocumentTextRequest",
  "x-generated": "2026-11-11",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/amazon-textract-text-detection-api-openapi.yml#/components/schemas/DetectDocumentTextRequest",
  "type": "object",
  "properties": {
    "Document": {
      "$ref": "#/$defs/Document"
    }
  },
  "required": [
    "Document"
  ],
  "$defs": {
    "Document": {
      "type": "object",
      "properties": {
        "Bytes": {
          "type": "string",
          "format": "byte",
          "description": "A blob of base64-encoded document bytes. The maximum size of a document that's provided in a blob of bytes is 5 MB. The document bytes must be in PNG or JPEG format. If you're using an AWS SDK to call Amazon Textract, you might not need to base64-encode image bytes passed using the Bytes field."
        },
        "S3Object": {
          "$ref": "#/$defs/S3Object"
        }
      }
    },
    "S3Object": {
      "type": "object",
      "properties": {
        "Bucket": {
          "type": "string",
          "description": "The name of the S3 bucket. Note that the # character is not valid in the file name."
        },
        "Name": {
          "type": "string",
          "description": "The file name of the input document. Image files may be in PDF, TIFF, JPEG, or PNG format."
        },
        "Version": {
          "type": "string",
          "description": "If the bucket has versioning enabled, you can specify the object version."
        }
      }
    }
  }
}