Resume workflow job

Requests the resumption of a specified workflow job. A successful request only means that the server accepts the recovery operation; please check the job status again to confirm subsequent execution.

HTTP
POST $CLOUDSIGMA_API_BASE/workflow/v2/workflow-apps/{workflow_id}/executions/{execution_id}/resume

Before you call this API

Configure the regional API endpoint and authentication, and select the target workspace.

First query job details and check whether available_actions contains recovery.

Request

Shell
curl -X POST "$CLOUDSIGMA_API_BASE/workflow/v2/workflow-apps/$WORKFLOW_ID/executions/$EXECUTION_ID/resume" \
  -H "X-API-Key: $CLOUDSIGMA_API_KEY" \
  -H "X-Workspace-ID: $WORKSPACE_ID"

Path parameters

ParameterTypeRequiredDescription
workflow_idstringRequiredWorkflow ID.
execution_idstringRequiredJob ID.

Successful response

Returns 200 on success. data.execution returns the current execution information processed by the server.

JSON
{
  "code": "OK",
  "msg": "OK",
  "data": {
    "execution": {
      "execution_id": "exec-001",
      "workflow_id": "wf-001",
      "status": "running",
      "available_actions": ["pause", "cancel"],
      "execution_mode": "one_shot",
      "input_payload": {},
      "vars_payload": {}
    }
  }
}
FieldTypeDescription
codestring`OK` when successful.
msgstring`OK` when successful.
data.execution.execution_idstringExecution ID.
data.execution.workflow_idstringWorkflow ID.
data.execution.statusstringCurrent execution status.
data.execution.available_actionsstring[]Currently allowed operations.
data.execution.execution_modestringExecution mode.
data.execution.cron_expressionstringCron expression; only returned in timing mode.
data.execution.input_payloadobjectExpanded run input.
data.execution.vars_payloadobjectExpanded run variables.
data.execution.moi_task_idstringTask ID; returned when assigned by the server.
data.execution.moi_case_idstringCase ID; returned when assigned by the server.
data.execution.moi_workflow_def_idstringWorkflow definition ID; returned when assigned by the server.
data.execution.moi_workflow_version_idstringWorkflow version ID; returned when assigned by the server.
data.execution.pause_scopestringPause scope; returned if there is a value.
data.execution.errorstringError; returned if there is a value.
data.execution.started_atstringExecution start time; returned if there is a value.
data.execution.ended_atstringExecution end time; returned if there is a value.
data.execution.created_atstringExecution creation time; returned if there is a value.
data.execution.updated_atstringExecution update time; returned if there is a value.

Error response

JSON
{
  "code": "ErrConflict",
  "msg": "资源状态冲突",
  "data": null
}
FieldTypeDescription
codestringError code.
msgstringReadable error message.
datanull`null` in an error response.

Follow-up operations

Use the same job ID query workflow job details to confirm recovery and continue tracking until completion.

Last updated on