import type * as Extend from "../index"; /** * Workflow run object. */ export interface WorkflowRun { /** The type of object. In this case, it will always be `"workflow_run"`. */ object: "workflow_run"; /** * The ID of the workflow run. * * Example: `"workflow_run_xKm9pNv3qWsY_jL2tR5Dh"` */ id: string; workflow: Extend.WorkflowSummary; workflowVersion: Extend.WorkflowVersionSummary; /** * A URL to view this workflow run in the Extend dashboard. * * Example: `"https://dashboard.extend.ai/workflows/workflow_run_xKm9pNv3qWsY_jL2tR5Dh"` */ dashboardUrl: string; status: Extend.WorkflowRunStatus; /** The metadata that was passed in when running the Workflow. */ metadata: Extend.RunMetadata; /** * The batch ID of the WorkflowRun. If this WorkflowRun was created as part of a batch of files, all runs in that batch will have the same batch ID. * * Example: `"batch_7Ws31-F5"` */ batchId: string | null; files: Extend.FileSummary[]; /** The reason why the workflow run failed. Will only be included if the workflow run status is "FAILED". */ failureReason: string | null; /** A more detailed message about the failure. Will only be included if the workflow run status is "FAILED". */ failureMessage: string | null; /** * The time (in UTC) at which the workflow run was created. Will follow the RFC 3339 format. Will be null if the run hasn't started yet. * * Example: `"2025-04-28T17:01:39.285Z"` */ initialRunAt: string | null; /** * The email address of the person who reviewed the workflow run. Will be null if the workflow run has not been reviewed. * * Example: `"jane.doe@example.com"` */ reviewedByUser: string | null; /** Whether the workflow run has been reviewed. */ reviewed: boolean; /** * A note that is added if a workflow run is rejected. * * Example: `"Invalid invoice format"` */ rejectionNote: string | null; /** * The time (in UTC) at which the workflow run was reviewed. Will follow the RFC 3339 format. Will be null if the workflow run has not been reviewed. * * Example: `"2024-03-21T16:45:00Z"` */ reviewedAt: string | null; /** * The time (in UTC) at which the workflow run started executing. This will always be after the `initialRunAt` time. Will follow the RFC 3339 format. Will be null if the workflow run has not started executing. * * Example: `"2024-03-21T15:30:00Z"` */ startTime: string | null; /** * The time (in UTC) that the workflow finished executing. Will follow the RFC 3339 format. Will be null if the workflow run has not finished executing. * * Example: `"2024-03-21T15:35:00Z"` */ endTime: string | null; /** An array of WorkflowStepRun objects. Each WorkflowStepRun represents a single run of a WorkflowStep and contains details about the step's execution and result. */ stepRuns: Extend.StepRun[]; /** * Usage credits consumed by this workflow run, including a breakdown of every contributing child run. * * **Availability:** Will not be returned for runs created before October 7, 2025 or for customers on legacy billing systems. */ usage: Extend.RunUsage | null; }