Skip to main content

Class: WorkflowCommand

Represents a WorkflowCommand.

Properties​

cancelChildWorkflowExecution?​

optional cancelChildWorkflowExecution?: $Properties | null

WorkflowCommand cancelChildWorkflowExecution.


cancelSignalWorkflow?​

optional cancelSignalWorkflow?: $Properties | null

WorkflowCommand cancelSignalWorkflow.


cancelTimer?​

optional cancelTimer?: $Properties | null

WorkflowCommand cancelTimer.


cancelWorkflowExecution?​

optional cancelWorkflowExecution?: $Properties | null

WorkflowCommand cancelWorkflowExecution.


completeWorkflowExecution?​

optional completeWorkflowExecution?: $Properties | null

WorkflowCommand completeWorkflowExecution.


continueAsNewWorkflowExecution?​

optional continueAsNewWorkflowExecution?: $Properties | null

WorkflowCommand continueAsNewWorkflowExecution.


eventGroupMarkers​

eventGroupMarkers: $Properties[]

Event group markers attached to the command. These are forwarded onto the corresponding server-side Command, and consequently surfaced on the resulting HistoryEvent. See temporal/api/sdk/v1/event_group_marker.proto.


failWorkflowExecution?​

optional failWorkflowExecution?: $Properties | null

WorkflowCommand failWorkflowExecution.


modifyWorkflowProperties?​

optional modifyWorkflowProperties?: $Properties | null

WorkflowCommand modifyWorkflowProperties.


requestCancelActivity?​

optional requestCancelActivity?: $Properties | null

WorkflowCommand requestCancelActivity.


requestCancelExternalWorkflowExecution?​

optional requestCancelExternalWorkflowExecution?: $Properties | null

WorkflowCommand requestCancelExternalWorkflowExecution.


requestCancelLocalActivity?​

optional requestCancelLocalActivity?: $Properties | null

WorkflowCommand requestCancelLocalActivity.


requestCancelNexusOperation?​

optional requestCancelNexusOperation?: $Properties | null

WorkflowCommand requestCancelNexusOperation.


respondToQuery?​

optional respondToQuery?: $Properties | null

WorkflowCommand respondToQuery.


scheduleActivity?​

optional scheduleActivity?: $Properties | null

WorkflowCommand scheduleActivity.


scheduleLocalActivity?​

optional scheduleLocalActivity?: $Properties | null

WorkflowCommand scheduleLocalActivity.


scheduleNexusOperation?​

optional scheduleNexusOperation?: $Properties | null

WorkflowCommand scheduleNexusOperation.


setPatchMarker?​

optional setPatchMarker?: $Properties | null

WorkflowCommand setPatchMarker.


signalExternalWorkflowExecution?​

optional signalExternalWorkflowExecution?: $Properties | null

WorkflowCommand signalExternalWorkflowExecution.


startChildWorkflowExecution?​

optional startChildWorkflowExecution?: $Properties | null

WorkflowCommand startChildWorkflowExecution.


startTimer?​

optional startTimer?: $Properties | null

WorkflowCommand startTimer.


updateResponse?​

optional updateResponse?: $Properties | null

WorkflowCommand updateResponse.


upsertWorkflowSearchAttributes?​

optional upsertWorkflowSearchAttributes?: $Properties | null

WorkflowCommand upsertWorkflowSearchAttributes.


userMetadata?​

optional userMetadata?: $Properties | null

User metadata that may or may not be persisted into history depending on the command type. Lang layers are expected to expose the setting of the internals of this metadata on a per-command basis where applicable.


variant?​

optional variant?: "startTimer" | "scheduleActivity" | "respondToQuery" | "requestCancelActivity" | "cancelTimer" | "completeWorkflowExecution" | "failWorkflowExecution" | "continueAsNewWorkflowExecution" | "cancelWorkflowExecution" | "setPatchMarker" | "startChildWorkflowExecution" | "cancelChildWorkflowExecution" | "requestCancelExternalWorkflowExecution" | "signalExternalWorkflowExecution" | "cancelSignalWorkflow" | "scheduleLocalActivity" | "requestCancelLocalActivity" | "upsertWorkflowSearchAttributes" | "modifyWorkflowProperties" | "updateResponse" | "scheduleNexusOperation" | "requestCancelNexusOperation"

WorkflowCommand variant.

Methods​

toJSON()​

toJSON(): object

Converts this WorkflowCommand to JSON.

Returns​

object

JSON object


create()​

Call Signature​

static create(properties?): WorkflowCommand & $Shape

Creates a new WorkflowCommand instance using the specified properties.

Parameters​
properties?​

$Shape

Properties to set

Returns​

WorkflowCommand & $Shape

WorkflowCommand instance

Call Signature​

static create(properties?): WorkflowCommand

Creates a new WorkflowCommand instance using the specified properties.

Parameters​
properties?​

$Properties

Properties to set

Returns​

WorkflowCommand

WorkflowCommand instance


decode()​

static decode(reader, length?): WorkflowCommand & $Shape

Decodes a WorkflowCommand message from the specified reader or buffer.

Parameters​

reader​

Uint8Array<ArrayBufferLike> | Reader

Reader or buffer to decode from

length?​

number

Message length if known beforehand

Returns​

WorkflowCommand & $Shape

WorkflowCommand

Throws​

If the payload is not a reader or valid buffer

Throws​

If required fields are missing


decodeDelimited()​

static decodeDelimited(reader): WorkflowCommand & $Shape

Decodes a WorkflowCommand message from the specified reader or buffer, length delimited.

Parameters​

reader​

Uint8Array<ArrayBufferLike> | Reader

Reader or buffer to decode from

Returns​

WorkflowCommand & $Shape

WorkflowCommand

Throws​

If the payload is not a reader or valid buffer

Throws​

If required fields are missing


encode()​

static encode(message, writer?): Writer

Encodes the specified WorkflowCommand message. Does not implicitly coresdk.workflow_commands.WorkflowCommand.verify|verify messages.

Parameters​

message​

$Properties

WorkflowCommand message or plain object to encode

writer?​

Writer

Writer to encode to

Returns​

Writer

Writer


encodeDelimited()​

static encodeDelimited(message, writer?): Writer

Encodes the specified WorkflowCommand message, length delimited. Does not implicitly coresdk.workflow_commands.WorkflowCommand.verify|verify messages.

Parameters​

message​

$Properties

WorkflowCommand message or plain object to encode

writer?​

Writer

Writer to encode to

Returns​

Writer

Writer


fromObject()​

static fromObject(object): WorkflowCommand

Creates a WorkflowCommand message from a plain object. Also converts values to their respective internal types.

Parameters​

object​

{[k: string]: any; }

Plain object

Returns​

WorkflowCommand

WorkflowCommand


toObject()​

static toObject(message, options?): object

Creates a plain object from a WorkflowCommand message. Also converts values to other types if specified.

Parameters​

message​

WorkflowCommand

WorkflowCommand

options?​

IConversionOptions

Conversion options

Returns​

object

Plain object