Interface: WorkflowHandleWithFirstExecutionRunId<T>
client.WorkflowHandleWithFirstExecutionRunId
This interface is exactly the same as WorkflowHandle except it
includes the firstExecutionRunId
returned from start.
Type parameters
Name | Type |
---|---|
T | extends Workflow = Workflow |
Hierarchy
↳
WorkflowHandleWithFirstExecutionRunId
Properties
client
• Readonly
client: WorkflowClient
Readonly accessor to the underlying WorkflowClient
Inherited from
firstExecutionRunId
• Readonly
firstExecutionRunId: string
Run Id of the first Execution in the Workflow Execution Chain.
workflowId
• Readonly
workflowId: string
The workflowId of the current Workflow
Inherited from
Methods
cancel
▸ cancel(): Promise
<IRequestCancelWorkflowExecutionResponse
>
Cancel a running Workflow
Returns
Promise
<IRequestCancelWorkflowExecutionResponse
>
Inherited from
describe
▸ describe(): Promise
<WorkflowExecutionDescription
>
Describe the current workflow execution
Returns
Promise
<WorkflowExecutionDescription
>
Inherited from
query
▸ query<Ret
, Args
>(def
, ...args
): Promise
<Ret
>
Query a running or completed Workflow.
Example
await handle.query(getValueQuery);
await handle.query<number, []>('getValue');
Type parameters
Name | Type |
---|---|
Ret | Ret |
Args | extends any [] = [] |
Parameters
Name | Type | Description |
---|---|---|
def | string | QueryDefinition <Ret , Args > | a query definition as returned from defineQuery or query name (string) |
...args | Args | - |
Returns
Promise
<Ret
>
Inherited from
result
▸ result(): Promise
<WorkflowResultType
<T
>>
Promise that resolves when Workflow execution completes
Returns
Promise
<WorkflowResultType
<T
>>
Inherited from
signal
▸ signal<Args
>(def
, ...args
): Promise
<void
>
Signal a running Workflow.
Example
await handle.signal(incrementSignal, 3);
Type parameters
Name | Type |
---|---|
Args | extends any [] = [] |
Parameters
Name | Type | Description |
---|---|---|
def | string | SignalDefinition <Args > | a signal definition as returned from defineSignal |
...args | Args | - |
Returns
Promise
<void
>
Inherited from
terminate
▸ terminate(reason?
): Promise
<ITerminateWorkflowExecutionResponse
>
Terminate a running Workflow
Parameters
Name | Type |
---|---|
reason? | string |
Returns
Promise
<ITerminateWorkflowExecutionResponse
>