Temporal Wait

Temporal Wait

Certified

Wait for a Temporal workflow to reach a terminal state

Polls DescribeWorkflowExecution at a configurable interval until the workflow completes, fails, is canceled, terminated, or times out.

On COMPLETED, retrieves and returns the workflow result as JSON. On other terminal states, fails the task by default; set failOnNonCompleted: false to emit the status instead.

yaml
type: io.kestra.plugin.temporal.workflow.Wait

Trigger an order workflow and wait for it to finish.

yaml
id: wait_order_workflow
namespace: company.team

tasks:
  - id: trigger
    type: io.kestra.plugin.temporal.workflow.Trigger
    endpoint: "localhost:7233"
    workflowType: "OrderWorkflow"
    taskQueue: "order-queue"
    workflowId: "order-{{ execution.id }}"

  - id: wait
    type: io.kestra.plugin.temporal.workflow.Wait
    endpoint: "localhost:7233"
    workflowId: "{{ outputs.trigger.workflowId }}"
    runId: "{{ outputs.trigger.runId }}"
    pollInterval: "PT5S"
    waitTimeout: "PT1H"
Properties

Temporal server endpoint

Host and port of the Temporal frontend service in host: port format. For Temporal Cloud, use the gRPC endpoint for your namespace, e.g. <namespace>.tmprl.cloud: 7233.

Workflow ID

The ID of the workflow execution to wait on.

API key for Bearer token authentication

Used with Temporal Cloud. Sent as Authorization: Bearer <apiKey> on every gRPC call; TLS is enabled automatically when this property is set. Mutually exclusive with mTLS properties.

Assets this task consumes as inputs or produces as outputs, for lineage tracking and the asset graph (Enterprise Edition). A flow declaring this property on a task is rejected in the open-source edition.

Definitions
assetFailureBehaviorstring
Possible Values
IGNOREFAILWARN

Asset failure behavior

Behavior applied to the task state when a declared asset fails to render, emit, or be persisted (e.g. a lock conflict): FAIL escalates it to FAILED, WARN (default) warns it if it would otherwise succeed, IGNORE leaves the state untouched.

enableAutobooleanstring

Whether to auto-register assets referenced dynamically at runtime that are not statically declared in inputs or outputs.

inputsarray

The assets consumed as inputs.

id*string
Min length1
typestring
outputs

The assets produced as outputs.

id*string
Min length1
Max length150
type*object
descriptionstring
displayNamestring
metadataobject
Default{}
namespacestring
Min length1
Max length150
id*string
Min length1
Max length150
type*object
descriptionstring
displayNamestring
metadataobject
Default{}
namespacestring
Min length1
Max length150
id*string
Min length1
Max length150
type*object
descriptionstring
displayNamestring
metadataobject
Default{}
namespacestring
Min length1
Max length150
id*string
Min length1
Max length150
type*object
descriptionstring
displayNamestring
metadataobject
Default{}
namespacestring
Min length1
Max length150
id*string
Min length1
Max length150
type*object
descriptionstring
displayNamestring
metadataobject
Default{}
namespacestring
Min length1
Max length150
id*string
Min length1
Max length150
type*string
Min length1

Custom asset type

descriptionstring
displayNamestring
metadataobject
Default{}
namespacestring
Min length1
Max length150

PEM-encoded CA certificate

Verifies the server certificate. Can be used alone for one-way TLS with a custom CA, or together with clientCert/clientKey for mTLS.

PEM-encoded client certificate

Used in mTLS mode. Must be provided together with clientKey.

PEM-encoded client private key

Used in mTLS mode. Must be provided together with clientCert.

Defaulttrue

Fail if the workflow ends in a non-COMPLETED state

When true (default), the task throws an exception for FAILED, CANCELED, TERMINATED, or TIMED_OUT terminal states. When false, the task succeeds and reports the status in the status output.

Temporal namespace

Defaults to default. For Temporal Cloud, typically <namespace>.<accountId>.

Poll interval

How often to check the workflow status. Defaults to 5 seconds.

Run ID

Optional. When omitted, waits on the latest run of the given workflow ID.

Maximum wait time

Total time to wait before giving up. Defaults to 1 hour. Named waitTimeout because timeout is a reserved Kestra task property that kills the task run instead of returning an output.

Workflow result

JSON-encoded return value of the workflow. Null for non-COMPLETED states.

Workflow terminal status

One of: COMPLETED, FAILED, CANCELED, TERMINATED, TIMED_OUT, CONTINUED_AS_NEW.