> ## Documentation Index
> Fetch the complete documentation index at: https://docs.tracecat.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Get Workflow Execution

> Get a workflow execution.



## OpenAPI

````yaml https://platform.tracecat.com/api/openapi.json get /workspaces/{workspace_id}/workflow-executions/{execution_id}
openapi: 3.1.0
info:
  title: Tracecat API
  summary: Tracecat API
  description: The open source AI automation platform for security teams and agents.
  termsOfService: >-
    https://docs.google.com/document/d/e/2PACX-1vQvDe3SoVAPoQc51MgfGCP71IqFYX_rMVEde8zC4qmBCec5f8PLKQRdxa6tsUABT8gWAR9J-EVs2CrQ/pub
  contact:
    name: Tracecat Founders
    email: founders@tracecat.com
  license:
    name: AGPL-3.0
    url: https://www.gnu.org/licenses/agpl-3.0.html
  version: '1'
servers:
  - url: /api
security: []
tags:
  - name: public
    description: Public facing endpoints
  - name: workflows
    description: Workflow management
  - name: actions
    description: Action management
  - name: triggers
    description: Workflow triggers
  - name: secrets
    description: Secret management
  - name: variables
    description: Workspace variable management
paths:
  /workspaces/{workspace_id}/workflow-executions/{execution_id}:
    get:
      tags:
        - workflow-executions
      summary: Get Workflow Execution
      description: Get a workflow execution.
      operationId: workflow-executions-get_workflow_execution
      parameters:
        - name: workspace_id
          in: path
          required: true
          schema:
            type: string
            format: uuid
            title: Workspace Id
        - name: execution_id
          in: path
          required: true
          schema:
            type: string
            title: Execution Id
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WorkflowExecutionRead'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - APIKeyCookie: []
        - ServiceAccountApiKeyBearer: []
components:
  schemas:
    WorkflowExecutionRead:
      properties:
        id:
          type: string
          title: Id
          description: The ID of the workflow execution
        run_id:
          type: string
          title: Run Id
          description: The run ID of the workflow execution
        start_time:
          type: string
          format: date-time
          title: Start Time
          description: The start time of the workflow execution
        execution_time:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Execution Time
          description: When this workflow run started or should start.
        close_time:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Close Time
          description: When the workflow was closed if closed.
        status:
          type: string
          enum:
            - RUNNING
            - COMPLETED
            - FAILED
            - CANCELED
            - TERMINATED
            - CONTINUED_AS_NEW
            - TIMED_OUT
        workflow_type:
          type: string
          title: Workflow Type
        task_queue:
          type: string
          title: Task Queue
        history_length:
          type: integer
          title: History Length
          description: Number of events in the history
        parent_wf_exec_id:
          anyOf:
            - type: string
              pattern: >-
                (wf-[0-9a-f]{32}|wf_[0-9a-zA-Z]+)[:/]((exec_[0-9a-zA-Z]+|exec-[\w-]+|(?:sch-[0-9a-f]{32}|[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12})-.*))
            - type: 'null'
          title: Parent Wf Exec Id
        trigger_type:
          $ref: '#/components/schemas/TriggerType'
        execution_type:
          $ref: '#/components/schemas/ExecutionType'
          description: >-
            Execution type (draft or published). Draft uses the draft workflow
            graph.
          default: published
        events:
          items:
            $ref: '#/components/schemas/WorkflowExecutionEvent'
          type: array
          title: Events
          description: The events in the workflow execution
        interactions:
          items:
            $ref: '#/components/schemas/InteractionRead'
          type: array
          title: Interactions
          description: The interactions in the workflow execution
      type: object
      required:
        - id
        - run_id
        - start_time
        - status
        - workflow_type
        - task_queue
        - history_length
        - trigger_type
        - events
      title: WorkflowExecutionRead
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    TriggerType:
      type: string
      enum:
        - manual
        - scheduled
        - webhook
        - case
      title: TriggerType
      description: Trigger type for a workflow execution.
    ExecutionType:
      type: string
      enum:
        - draft
        - published
      title: ExecutionType
      description: >-
        Execution type for a workflow execution.


        Distinguishes between draft (development) and published (production)
        executions.
    WorkflowExecutionEvent:
      properties:
        event_id:
          type: integer
          title: Event Id
        event_time:
          type: string
          format: date-time
          title: Event Time
        event_type:
          $ref: '#/components/schemas/WorkflowEventType'
        task_id:
          type: integer
          title: Task Id
        event_group:
          anyOf:
            - $ref: '#/components/schemas/EventGroup_TypeVar_'
            - type: 'null'
          description: >-
            The action group of the event. We use this to keep track of what
            events are related to each other.
        failure:
          anyOf:
            - $ref: '#/components/schemas/EventFailure'
            - type: 'null'
        result:
          anyOf:
            - {}
            - type: 'null'
          title: Result
        role:
          anyOf:
            - $ref: '#/components/schemas/Role'
            - type: 'null'
        parent_wf_exec_id:
          anyOf:
            - type: string
              pattern: >-
                (wf-[0-9a-f]{32}|wf_[0-9a-zA-Z]+)[:/]((exec_[0-9a-zA-Z]+|exec-[\w-]+|(?:sch-[0-9a-f]{32}|[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12})-.*))
            - type: 'null'
          title: Parent Wf Exec Id
        workflow_timeout:
          anyOf:
            - type: number
            - type: 'null'
          title: Workflow Timeout
      type: object
      required:
        - event_id
        - event_time
        - event_type
        - task_id
      title: WorkflowExecutionEvent
    InteractionRead:
      properties:
        id:
          type: string
          format: uuid
          title: Id
        created_at:
          type: string
          format: date-time
          title: Created At
        updated_at:
          type: string
          format: date-time
          title: Updated At
        type:
          $ref: '#/components/schemas/InteractionType'
        status:
          $ref: '#/components/schemas/InteractionStatus'
        request_payload:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Request Payload
        response_payload:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Response Payload
        expires_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Expires At
        wf_exec_id:
          type: string
          pattern: >-
            (wf-[0-9a-f]{32}|wf_[0-9a-zA-Z]+)[:/]((exec_[0-9a-zA-Z]+|exec-[\w-]+|(?:sch-[0-9a-f]{32}|[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12})-.*))
          title: Wf Exec Id
        actor:
          anyOf:
            - type: string
            - type: 'null'
          title: Actor
        action_ref:
          type: string
          title: Action Ref
        action_type:
          type: string
          title: Action Type
      type: object
      required:
        - id
        - created_at
        - updated_at
        - type
        - status
        - request_payload
        - response_payload
        - wf_exec_id
        - actor
        - action_ref
        - action_type
      title: InteractionRead
      description: Model for reading an interaction.
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
        input:
          title: Input
        ctx:
          type: object
          title: Context
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
    WorkflowEventType:
      type: string
      enum:
        - WORKFLOW_EXECUTION_STARTED
        - WORKFLOW_EXECUTION_COMPLETED
        - WORKFLOW_EXECUTION_FAILED
        - WORKFLOW_EXECUTION_TERMINATED
        - WORKFLOW_EXECUTION_CANCELED
        - WORKFLOW_EXECUTION_CONTINUED_AS_NEW
        - WORKFLOW_EXECUTION_TIMED_OUT
        - ACTIVITY_TASK_SCHEDULED
        - ACTIVITY_TASK_STARTED
        - ACTIVITY_TASK_COMPLETED
        - ACTIVITY_TASK_FAILED
        - ACTIVITY_TASK_TIMED_OUT
        - ACTIVITY_TASK_CANCELED
        - CHILD_WORKFLOW_EXECUTION_STARTED
        - CHILD_WORKFLOW_EXECUTION_COMPLETED
        - CHILD_WORKFLOW_EXECUTION_FAILED
        - CHILD_WORKFLOW_EXECUTION_CANCELED
        - CHILD_WORKFLOW_EXECUTION_TERMINATED
        - START_CHILD_WORKFLOW_EXECUTION_INITIATED
        - CHILD_WORKFLOW_EXECUTION_TIMED_OUT
        - WORKFLOW_EXECUTION_SIGNALED
        - WORKFLOW_EXECUTION_UPDATE_ACCEPTED
        - WORKFLOW_EXECUTION_UPDATE_REJECTED
        - WORKFLOW_EXECUTION_UPDATE_COMPLETED
      title: WorkflowEventType
      description: The event types we care about.
    EventGroup_TypeVar_:
      properties:
        event_id:
          type: integer
          title: Event Id
        udf_namespace:
          type: string
          title: Udf Namespace
        udf_name:
          type: string
          title: Udf Name
        udf_key:
          type: string
          title: Udf Key
        action_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Action Id
        action_ref:
          anyOf:
            - type: string
            - type: 'null'
          title: Action Ref
        action_title:
          anyOf:
            - type: string
            - type: 'null'
          title: Action Title
        action_description:
          anyOf:
            - type: string
            - type: 'null'
          title: Action Description
        action_input:
          anyOf:
            - $ref: '#/components/schemas/RunActionInput'
            - $ref: '#/components/schemas/DSLRunArgs'
            - $ref: '#/components/schemas/GetWorkflowDefinitionActivityInputs'
            - $ref: '#/components/schemas/InteractionResult'
            - $ref: '#/components/schemas/InteractionInput'
            - $ref: '#/components/schemas/UnreadableTemporalPayload'
          title: Action Input
        action_result:
          anyOf:
            - {}
            - type: 'null'
          title: Action Result
        current_attempt:
          anyOf:
            - type: integer
            - type: 'null'
          title: Current Attempt
        retry_policy:
          $ref: '#/components/schemas/ActionRetryPolicy'
        start_delay:
          type: number
          title: Start Delay
          default: 0
        join_strategy:
          $ref: '#/components/schemas/JoinStrategy'
          default: all
        related_wf_exec_id:
          anyOf:
            - type: string
              pattern: >-
                (wf-[0-9a-f]{32}|wf_[0-9a-zA-Z]+)[:/]((exec_[0-9a-zA-Z]+|exec-[\w-]+|(?:sch-[0-9a-f]{32}|[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12})-.*))
            - type: string
              pattern: ^agent/[0-9a-f]8-[0-9a-f]4-[0-9a-f]4-[0-9a-f]4-[0-9a-f]12$
            - type: 'null'
          title: Related Wf Exec Id
      type: object
      required:
        - event_id
        - udf_namespace
        - udf_name
        - udf_key
        - action_input
      title: EventGroup[TypeVar]
    EventFailure:
      properties:
        message:
          type: string
          title: Message
        cause:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Cause
        root_cause_message:
          anyOf:
            - type: string
            - type: 'null'
          title: Root Cause Message
      type: object
      required:
        - message
      title: EventFailure
    Role:
      properties:
        type:
          type: string
          enum:
            - user
            - service
            - service_account
          title: Type
        workspace_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Workspace Id
        bound_workspace_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Bound Workspace Id
        organization_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Organization Id
        user_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: User Id
        service_account_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Service Account Id
        service_id:
          type: string
          enum:
            - tracecat-api
            - tracecat-bootstrap
            - tracecat-cli
            - tracecat-executor
            - tracecat-agent-executor
            - tracecat-case-triggers
            - tracecat-llm-gateway
            - tracecat-mcp
            - tracecat-runner
            - tracecat-schedule-runner
            - tracecat-service
            - tracecat-ui
          title: Service Id
        is_platform_superuser:
          type: boolean
          title: Is Platform Superuser
          default: false
        scopes:
          anyOf:
            - items:
                type: string
              type: array
              uniqueItems: true
            - type: 'null'
          title: Scopes
      additionalProperties: true
      type: object
      required:
        - type
        - service_id
      title: Role
      description: >-
        The identity, intrinsic bindings, and resolved authorization context.


        User roles

        ----------

        - User roles are authenticated via JWT.

        - The `user_id` is the user's JWT 'sub' claim.

        - User roles do not have an associated `service_id`, this must be None.


        Service roles

        -------------

        - Service roles are authenticated via API key.

        - Used for internal services to authenticate with the API.

        - A service's `user_id` is the user it's acting on behalf of. This can
        be None for internal services.
    InteractionType:
      type: string
      enum:
        - approval
        - response
      title: InteractionType
    InteractionStatus:
      type: string
      enum:
        - idle
        - pending
        - error
        - timed_out
        - completed
      title: InteractionStatus
    RunActionInput:
      properties:
        task:
          $ref: '#/components/schemas/ActionStatement'
        exec_context:
          $ref: '#/components/schemas/ExecutionContext'
        run_context:
          $ref: '#/components/schemas/RunContext'
        interaction_context:
          anyOf:
            - $ref: '#/components/schemas/InteractionContext'
            - type: 'null'
        stream_id:
          type: string
          title: Stream Id
          default: <root>:0
        session_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Session Id
        registry_lock:
          $ref: '#/components/schemas/RegistryLock'
      type: object
      required:
        - task
        - exec_context
        - run_context
        - registry_lock
      title: RunActionInput
      description: This object contains all the information needed to execute an action.
    DSLRunArgs:
      properties:
        role:
          $ref: '#/components/schemas/Role'
        dsl:
          anyOf:
            - $ref: '#/components/schemas/DSLInput'
            - type: 'null'
        wf_id:
          type: string
          title: Wf Id
        trigger_inputs:
          anyOf:
            - oneOf:
                - $ref: '#/components/schemas/InlineObject'
                - $ref: '#/components/schemas/ExternalObject'
                - $ref: '#/components/schemas/CollectionObject'
              discriminator:
                propertyName: type
                mapping:
                  collection:
                    $ref: '#/components/schemas/CollectionObject'
                  external:
                    $ref: '#/components/schemas/ExternalObject'
                  inline:
                    $ref: '#/components/schemas/InlineObject'
            - type: 'null'
          title: Trigger Inputs
        parent_run_context:
          anyOf:
            - $ref: '#/components/schemas/RunContext'
            - type: 'null'
        runtime_config:
          $ref: '#/components/schemas/DSLConfig-Output'
          description: >-
            Runtime configuration that can be set on workflow entry. Note that
            this can override the default config in DSLInput.
        timeout:
          type: string
          format: duration
          title: Timeout
          description: Platform activity start-to-close timeout.
        schedule_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Schedule Id
          description: >-
            The schedule ID that triggered this workflow, if any. Auto-converts
            from legacy 'sch-<hex>' format.
        execution_type:
          $ref: '#/components/schemas/ExecutionType'
          description: >-
            Execution type (draft or published). Draft executions use draft
            aliases for child workflows.
          default: published
        time_anchor:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Time Anchor
          description: >-
            The workflow's logical time anchor for FN.now() and related
            functions. If not provided, computed from TemporalScheduledStartTime
            (for schedules) or workflow start_time (for other triggers). Stored
            as UTC.
        registry_lock:
          anyOf:
            - $ref: '#/components/schemas/RegistryLock'
            - type: 'null'
          description: >-
            Registry version lock for action execution. Contains origins (origin
            -> version) and actions (action_name -> origin) mappings.
      type: object
      required:
        - role
        - wf_id
      title: DSLRunArgs
    GetWorkflowDefinitionActivityInputs:
      properties:
        role:
          $ref: '#/components/schemas/Role'
        workflow_id:
          type: string
          title: Workflow Id
        version:
          anyOf:
            - type: integer
            - type: 'null'
          title: Version
        task:
          anyOf:
            - $ref: '#/components/schemas/ActionStatement'
            - type: 'null'
      type: object
      required:
        - role
        - workflow_id
      title: GetWorkflowDefinitionActivityInputs
    InteractionResult:
      properties:
        message:
          type: string
          title: Message
        detail:
          anyOf:
            - {}
            - type: 'null'
          title: Detail
      type: object
      required:
        - message
      title: InteractionResult
      description: >-
        Output for the workflow interaction handler. This is used on the client
        side.
    InteractionInput:
      properties:
        interaction_id:
          type: string
          format: uuid
          title: Interaction Id
        execution_id:
          type: string
          pattern: >-
            (wf-[0-9a-f]{32}|wf_[0-9a-zA-Z]+)[:/]((exec_[0-9a-zA-Z]+|exec-[\w-]+|(?:sch-[0-9a-f]{32}|[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12})-.*))
          title: Execution Id
        action_ref:
          type: string
          title: Action Ref
        data:
          additionalProperties: true
          type: object
          title: Data
      type: object
      required:
        - interaction_id
        - execution_id
        - action_ref
        - data
      title: InteractionInput
      description: >-
        Input for the workflow interaction handler. This is used on the client
        side.
    UnreadableTemporalPayload:
      properties:
        error:
          type: string
          const: unreadable_temporal_payload
          title: Error
          default: unreadable_temporal_payload
        error_type:
          type: string
          title: Error Type
        encoding:
          type: string
          title: Encoding
        payload_size_bytes:
          type: integer
          title: Payload Size Bytes
      type: object
      required:
        - error_type
        - encoding
        - payload_size_bytes
      title: UnreadableTemporalPayload
      description: Structured placeholder for Temporal payloads that cannot be decoded.
    ActionRetryPolicy:
      properties:
        max_attempts:
          type: integer
          title: Max Attempts
          description: >-
            Total number of execution attempts. 0 means unlimited, 1 means no
            retries.
          default: 1
        timeout:
          type: integer
          title: Timeout
          description: Timeout for the action in seconds.
          default: 300
        retry_until:
          anyOf:
            - type: string
            - type: 'null'
          title: Retry Until
          description: Retry until a specific condition is met.
      type: object
      title: ActionRetryPolicy
    JoinStrategy:
      type: string
      enum:
        - any
        - all
      title: JoinStrategy
    ActionStatement:
      properties:
        ref:
          type: string
          pattern: ^[a-z0-9_]+$
          title: Ref
          description: Unique reference for the task
        description:
          type: string
          title: Description
          default: ''
        action:
          type: string
          pattern: ^[a-z0-9_.]+$
          title: Action
          description: Action type. Equivalent to the UDF key.
        args:
          additionalProperties: true
          type: object
          title: Args
          description: Arguments for the action
        depends_on:
          items:
            type: string
          type: array
          title: Depends On
          description: Task dependencies
        interaction:
          anyOf:
            - oneOf:
                - $ref: '#/components/schemas/ResponseInteraction'
                - $ref: '#/components/schemas/ApprovalInteraction'
              description: An interaction configuration
              discriminator:
                propertyName: type
                mapping:
                  approval:
                    $ref: '#/components/schemas/ApprovalInteraction'
                  response:
                    $ref: '#/components/schemas/ResponseInteraction'
            - type: 'null'
          title: Interaction
          description: Whether the action is interactive.
        run_if:
          anyOf:
            - type: string
            - type: 'null'
          title: Run If
          description: Condition to run the task
        for_each:
          anyOf:
            - type: string
            - items:
                type: string
              type: array
            - type: 'null'
          title: For Each
          description: Iterate over a list of items and run the task for each item.
        retry_policy:
          $ref: '#/components/schemas/ActionRetryPolicy'
          description: Retry policy for the action.
        start_delay:
          type: number
          title: Start Delay
          description: >-
            Delay before starting the action in seconds. If `wait_until` is also
            provided, the `wait_until` timer will take precedence.
          default: 0
        wait_until:
          anyOf:
            - type: string
            - type: 'null'
          title: Wait Until
          description: >-
            Wait until a specific date and time before starting. Overrides
            `start_delay` if both are provided.
        join_strategy:
          $ref: '#/components/schemas/JoinStrategy'
          description: >-
            The strategy to use when joining on this task. By default, all
            branches must complete successfully before the join task can
            complete.
          default: all
        environment:
          anyOf:
            - type: string
            - type: 'null'
          title: Environment
          description: >-
            Override environment for this action's execution. Can be a template
            expression.
        mask_output:
          type: boolean
          title: Mask Output
          description: >-
            If true, redact this action's result in workflow execution API
            responses while preserving internal workflow data flow between
            actions.
          default: false
      type: object
      required:
        - ref
        - action
      title: ActionStatement
    ExecutionContext:
      properties:
        ACTIONS:
          additionalProperties:
            $ref: '#/components/schemas/TaskResult'
          type: object
          title: Actions
        TRIGGER:
          anyOf:
            - oneOf:
                - $ref: '#/components/schemas/InlineObject'
                - $ref: '#/components/schemas/ExternalObject'
                - $ref: '#/components/schemas/CollectionObject'
              discriminator:
                propertyName: type
                mapping:
                  collection:
                    $ref: '#/components/schemas/CollectionObject'
                  external:
                    $ref: '#/components/schemas/ExternalObject'
                  inline:
                    $ref: '#/components/schemas/InlineObject'
            - type: 'null'
          title: Trigger
        ENV:
          $ref: '#/components/schemas/DSLEnvironment'
        SECRETS:
          additionalProperties: true
          type: object
          title: Secrets
        VARS:
          additionalProperties: true
          type: object
          title: Vars
        var:
          additionalProperties: true
          type: object
          title: Var
      type: object
      required:
        - ACTIONS
        - TRIGGER
      title: ExecutionContext
      description: |-
        Workflow execution context with typed fields.

        ACTIONS and TRIGGER are always present. Other fields are optional since
        contexts may be built incrementally during workflow execution.
    RunContext:
      properties:
        wf_id:
          type: string
          title: Wf Id
        wf_exec_id:
          type: string
          pattern: >-
            (wf-[0-9a-f]{32}|wf_[0-9a-zA-Z]+)[:/]((exec_[0-9a-zA-Z]+|exec-[\w-]+|(?:sch-[0-9a-f]{32}|[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12})-.*))
          title: Wf Exec Id
        wf_run_id:
          type: string
          format: uuid4
          title: Wf Run Id
        environment:
          type: string
          title: Environment
        logical_time:
          type: string
          format: date-time
          title: Logical Time
      type: object
      required:
        - wf_id
        - wf_exec_id
        - wf_run_id
        - environment
        - logical_time
      title: RunContext
      description: >-
        This is the runtime context model for a workflow run. Passed into
        activities.
    InteractionContext:
      properties:
        interaction_id:
          type: string
          format: uuid
          title: Interaction Id
        execution_id:
          type: string
          pattern: >-
            (wf-[0-9a-f]{32}|wf_[0-9a-zA-Z]+)[:/]((exec_[0-9a-zA-Z]+|exec-[\w-]+|(?:sch-[0-9a-f]{32}|[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12})-.*))
          title: Execution Id
        action_ref:
          type: string
          title: Action Ref
      type: object
      required:
        - interaction_id
        - execution_id
        - action_ref
      title: InteractionContext
      description: The context of the interaction.
    RegistryLock:
      properties:
        origins:
          additionalProperties:
            type: string
          type: object
          title: Origins
        actions:
          additionalProperties:
            type: string
          type: object
          title: Actions
        origin_fingerprints:
          additionalProperties:
            type: string
          type: object
          title: Origin Fingerprints
      type: object
      required:
        - origins
        - actions
      title: RegistryLock
      description: |-
        Registry version lock with action-level bindings for O(1) resolution.

        Attributes:
            origins: Maps repository origin to pinned version string.
                Example: {"tracecat_registry": "2024.12.10.123456"}
            actions: Maps action name to its source origin.
                Example: {"core.transform.reshape": "tracecat_registry"}
            origin_fingerprints: Optional immutable manifest fingerprints for origins.
                New executors use the builtin fingerprint to decide whether their
                bundled tracecat_registry package is an exact match for the lock.
    DSLInput:
      properties:
        title:
          type: string
          title: Title
        description:
          type: string
          title: Description
        entrypoint:
          $ref: '#/components/schemas/DSLEntrypoint'
        actions:
          items:
            $ref: '#/components/schemas/ActionStatement'
          type: array
          title: Actions
        config:
          $ref: '#/components/schemas/DSLConfig-Output'
        triggers:
          items:
            $ref: '#/components/schemas/Trigger'
          type: array
          title: Triggers
        returns:
          anyOf:
            - {}
            - type: 'null'
          title: Returns
          description: The action ref or value to return.
        error_handler:
          anyOf:
            - type: string
            - type: 'null'
          title: Error Handler
          description: The action ref to handle errors.
      type: object
      required:
        - title
        - description
        - entrypoint
        - actions
      title: DSLInput
      description: |-
        DSL definition for a workflow.

        The difference between this and a normal workflow engine is that here,
        our workflow execution order is defined by the DSL itself, independent
        of a workflow scheduler.

        With a traditional
        This allows the execution of the workflow to be fully deterministic.
    InlineObject:
      properties:
        typename:
          anyOf:
            - type: string
            - type: 'null'
          title: Typename
        type:
          type: string
          const: inline
          title: Type
        data:
          title: Data
      type: object
      required:
        - type
        - data
      title: InlineObject
      description: Data stored inline (not externalized).
    ExternalObject:
      properties:
        typename:
          anyOf:
            - type: string
            - type: 'null'
          title: Typename
        type:
          type: string
          const: external
          title: Type
        ref:
          $ref: '#/components/schemas/ObjectRef'
      type: object
      required:
        - type
        - ref
      title: ExternalObject
      description: Data externalized to blob storage.
    CollectionObject:
      properties:
        typename:
          anyOf:
            - type: string
            - type: 'null'
          title: Typename
        type:
          type: string
          const: collection
          title: Type
        manifest_ref:
          $ref: '#/components/schemas/ObjectRef'
        count:
          type: integer
          title: Count
        chunk_size:
          type: integer
          title: Chunk Size
        element_kind:
          type: string
          enum:
            - value
            - stored_object
          title: Element Kind
        schema_version:
          type: integer
          title: Schema Version
          default: 1
        index:
          anyOf:
            - type: integer
            - type: 'null'
          title: Index
      type: object
      required:
        - type
        - manifest_ref
        - count
        - chunk_size
        - element_kind
      title: CollectionObject
      description: >-
        Handle to a collection manifest stored in blob storage.


        Represents huge collections without embedding list[StoredObject] in
        history.

        The manifest contains chunk references for paged access.


        This is a small, history-safe handle. The actual data lives in chunked

        blobs referenced by the manifest.


        Attributes:
            manifest_ref: Reference to the manifest blob containing chunk refs.
            count: Total number of elements in the collection.
            chunk_size: Number of items per chunk.
            element_kind: Whether elements are raw values or StoredObject handles.
            schema_version: Manifest schema version for forward compatibility.
    DSLConfig-Output:
      properties:
        environment:
          type: string
          title: Environment
          description: >-
            The workflow's target execution environment. This is used to isolate
            secrets across different environments.If not provided, the default
            environment (default) is used.
          default: default
        timeout:
          type: number
          title: Timeout
          description: >-
            Workflow timeout in seconds. If set to 0, the workflow has no
            timeout.
          default: 0
      type: object
      title: DSLConfig
      description: |-
        This is the runtime configuration for the workflow.

        Activities don't need access to this.
    ResponseInteraction:
      properties:
        type:
          type: string
          const: response
          title: Type
        timeout:
          anyOf:
            - type: number
            - type: 'null'
          title: Timeout
          description: The timeout for the interaction in seconds.
      type: object
      required:
        - type
      title: ResponseInteraction
      description: Configuration for a response interaction.
    ApprovalInteraction:
      properties:
        type:
          type: string
          const: approval
          title: Type
        timeout:
          anyOf:
            - type: number
            - type: 'null'
          title: Timeout
          description: The timeout for the interaction in seconds.
        required_approvers:
          type: integer
          title: Required Approvers
          description: Number of approvers required before the action can proceed.
          default: 1
        approver_groups:
          items:
            type: string
          type: array
          title: Approver Groups
          description: List of groups that are allowed to approve this action.
        message:
          type: string
          title: Message
          description: Custom message to display to approvers.
          default: ''
        approve_if:
          anyOf:
            - type: string
            - type: 'null'
          title: Approve If
          description: Condition to approve the action.
      type: object
      required:
        - type
      title: ApprovalInteraction
      description: Configuration for an approval interaction.
    TaskResult:
      properties:
        result:
          oneOf:
            - $ref: '#/components/schemas/InlineObject'
            - $ref: '#/components/schemas/ExternalObject'
            - $ref: '#/components/schemas/CollectionObject'
          title: Result
          discriminator:
            propertyName: type
            mapping:
              collection:
                $ref: '#/components/schemas/CollectionObject'
              external:
                $ref: '#/components/schemas/ExternalObject'
              inline:
                $ref: '#/components/schemas/InlineObject'
        result_typename:
          type: string
          title: Result Typename
        error:
          anyOf:
            - {}
            - type: 'null'
          title: Error
        error_typename:
          anyOf:
            - type: string
            - type: 'null'
          title: Error Typename
        interaction:
          anyOf:
            - {}
            - type: 'null'
          title: Interaction
        interaction_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Interaction Id
        interaction_type:
          anyOf:
            - type: string
            - type: 'null'
          title: Interaction Type
        collection_index:
          anyOf:
            - type: integer
            - type: 'null'
          title: Collection Index
      type: object
      required:
        - result
        - result_typename
      title: TaskResult
      description: |-
        Result of executing a DSL node.

        With uniform envelope design, `result` is always a StoredObject:
        - InlineObject when data is small or externalization is disabled
        - ExternalObject when data is large and externalization is enabled
    DSLEnvironment:
      properties:
        workflow:
          additionalProperties: true
          type: object
          title: Workflow
        environment:
          type: string
          title: Environment
        variables:
          additionalProperties: true
          type: object
          title: Variables
        registry_version:
          type: string
          title: Registry Version
      type: object
      title: DSLEnvironment
      description: DSL Environment context. Has metadata about the workflow.
    DSLEntrypoint:
      properties:
        ref:
          anyOf:
            - type: string
            - type: 'null'
          title: Ref
          description: The entrypoint action ref
        expects:
          anyOf:
            - additionalProperties:
                $ref: '#/components/schemas/ExpectedField-Output'
              type: object
            - type: 'null'
          title: Expects
          description: >-
            Expected trigger input schema. Use this to specify the expected
            shape of the trigger input.
      type: object
      title: DSLEntrypoint
    Trigger:
      properties:
        type:
          type: string
          enum:
            - schedule
            - webhook
          title: Type
        ref:
          type: string
          pattern: ^[a-z0-9_]+$
          title: Ref
        args:
          additionalProperties: true
          type: object
          title: Args
      type: object
      required:
        - type
        - ref
      title: Trigger
    ObjectRef:
      properties:
        backend:
          type: string
          const: s3
          title: Backend
          default: s3
        bucket:
          type: string
          title: Bucket
        key:
          type: string
          title: Key
        size_bytes:
          type: integer
          title: Size Bytes
        sha256:
          type: string
          title: Sha256
        content_type:
          type: string
          title: Content Type
          default: application/json
        encoding:
          type: string
          enum:
            - json
            - json+zstd
            - json+gzip
          title: Encoding
          default: json
        created_at:
          type: string
          format: date-time
          title: Created At
      type: object
      required:
        - bucket
        - key
        - size_bytes
        - sha256
      title: ObjectRef
      description: >-
        Reference to an externalized object in blob storage.


        This is a typed reference that replaces large payloads in workflow
        context.

        Only dereference ObjectRef instances created by Tracecat - never
        arbitrary URIs.
    ExpectedField-Output:
      additionalProperties: true
      type: object
  securitySchemes:
    APIKeyCookie:
      type: apiKey
      in: cookie
      name: fastapiusersauth
    ServiceAccountApiKeyBearer:
      type: http
      description: Tracecat service account API key.
      scheme: bearer

````