Retry workflow jobs in batches

Retry the specified execution under a scheduled job, or all failed executions under the scheduled job. Interface success simply means that the bulk retry request was accepted.

HTTP
POST $CLOUDSIGMA_API_BASE/workflow/v2/workflow-apps/{workflow_id}/executions/batch-retry

Before you call

Configure the CloudSigma regional endpoint and authentication before calling. The endpoint, credentials, workspace, and resource IDs must belong to the same region. First query the workflow job list to determine the workflow, source scheduling job and the range that needs to be retried. Prepare personal access token and target workspace ID that can access the target workspace.

Confirm that the current identity has permission to run the target workflow and access permissions to the files and volumes referenced by the input.

Request body

Replace $WORKFLOW_ID, $CLOUDSIGMA_API_KEY, $WORKSPACE_ID, $SOURCE_DISPATCH_JOB_ID in the example with actual values.

Shell
curl -X POST "$CLOUDSIGMA_API_BASE/workflow/v2/workflow-apps/$WORKFLOW_ID/executions/batch-retry" \
  -H "X-API-Key: $CLOUDSIGMA_API_KEY" \
  -H "X-Workspace-ID: $WORKSPACE_ID" \
  -H 'Content-Type: application/json' \
  -d '{
    "source_dispatch_job_id": "'"$SOURCE_DISPATCH_JOB_ID"'",
    "all_failed": true,
    "request_id": "retry-20260828-001"
  }'

Parameter

Type

Required

Description

workflow_id

string

Yes

workflow ID, located in the request path.

Request body

Field

Type

Required

Description

source_dispatch_job_id

string

Yes

Source scheduled job ID. Cannot be empty.

execution_ids

array or null

No

Execution ID to retry. Do not pass all_failed: true when using this field.

all_failed

boolean or null

No

When filling in true, retry all failed executions under the source scheduled job.

request_id

string

Yes

The unique identifier of this batch request. Cannot be empty.

request_id identifies a request for the same select set, persists across retries, and respects byte length limits. Retrying with the same ID does not restart the run, nor does it guarantee that a partially started batch will succeed.

Successful response

JSON
{
  "code": "OK",
  "msg": "OK",
  "data": {
    "source_dispatch_job_id": "dispatch-source-001",
    "dispatch_job_id": "dispatch-retry-001",
    "status": "waiting",
    "accepted_count": 1,
    "replayed": false
  }
}

Field

Type

Description

data.source_dispatch_job_id

string

Source scheduled job ID.

data.dispatch_job_id

string

The ID of the scheduled job created or reused in this batch retry.

data.status

string

Current status of batch retry requests. Values: waiting, running, completed, failed, cancelled.

data.accepted_count

integer

The number of executions that will be retried this time.

data.replayed

boolean

Whether it is a repeated request for the same request_id.

Use the scheduled job ID in the response Query the workflow job list to confirm the status of retry execution.

Error response

The business error response only contains code and msg, but does not contain data.

JSON
{
  "code": "ErrParamInvalid",
  "msg": "请求参数无效"
}

Field

Type

Description

code

string

error code.

msg

string

Readable error message.

Last updated on