DocuTray

Step Types

Type definitions for Step in the DocuTray Python SDK — request and response models, fields, and enums.

Types for step execution operations.

StepExecutionStatus

Status of an asynchronous step execution.

Fields:

  • data: dict[str, Any] | None - Result data (only present when status is SUCCESS).

  • document_metadata: dict[str, Any] | None - Metadata sent with the original request (only for SUCCESS/ERROR).

  • error: str | dict[str, Any] | None - Error message or details (only present when status is ERROR).

  • execution_id: str - Unique execution ID.

  • identification: StepIdentification | None - Identification result (only present when status is SUCCESS).

  • model_config: Any

  • original_filename: str | None - Original filename of the processed file.

  • request_timestamp: datetime | None - Timestamp when execution was started.

  • response_timestamp: datetime | None - Timestamp when execution was completed (only for SUCCESS/ERROR).

  • status: StepExecutionStatusType - Current execution status.

  • step_id: str | None - Step ID that was executed.

  • step_name: str | None - Name of the step (returned when the execution is started).

  • validation: StepValidationSummary | None - Validation summary (only present when status is SUCCESS).

StepIdentification

Identification result of a step execution.

Fields:

  • confidence: float | None - Confidence score for automatic identification (omitted for fixed types).

  • documentTypeCode: str | None - Identified document type code; "other" when no configured type matched.

  • model_config: Any

  • success: bool | None - Whether identification succeeded (True even for "other" documents).

StepValidationSummary

Summarized validation of a step's conversion (informational only).

Never changes step success. Empty summaries mean validation was skipped.

Fields:

  • errors: ValidationErrorInfo - Validation errors summary.

  • model_config: Any

  • warnings: ValidationWarningInfo - Validation warnings summary.

On this page