Resume workflow¶
Resumes a paused workflow and executions paused by the workflow pause action. It does not create a new run.
POST https://moi.matrixorigin.cn/newmoi/workflow/v2/workflow-apps/{workflow_id}/resume
Before you call¶
Use Get workflow details to confirm the workflow. Prepare a personal access token with workflow manage permission and the target workspace ID.
Path parameters¶
Replace $AI_STUDIO_API_KEY, $WORKSPACE_ID, and $WORKFLOW_ID with your own values.
curl -X POST "https://moi.matrixorigin.cn/newmoi/workflow/v2/workflow-apps/$WORKFLOW_ID/resume" \
-H "X-API-Key: $AI_STUDIO_API_KEY" \
-H "X-Workspace-ID: $WORKSPACE_ID"
Parameter |
Type |
Required |
Description |
|---|---|---|---|
|
string |
Yes |
Workflow ID to resume. |
Successful response¶
Returns 200 with the resumed workflow detail. Other workflow detail fields follow Get workflow details.
{"code": "OK", "msg": "OK", "data": {"workflow": {"id": "wf-001", "name": "daily-import", "status": "ready", "available_actions": ["update", "delete", "run", "pause"], "execution_summary": {"total_executions": 8, "active_executions": 0}}}}
The following fields are in data.workflow.
Field |
Type |
Description |
|---|---|---|
|
string |
|
|
string |
|
|
object |
Resumed workflow detail. |
|
string |
Workflow ID. |
|
string |
Workflow name. |
|
string |
Status after resuming. |
|
string[] |
Actions allowed in the current state. |
|
object |
Execution summary. |
|
integer |
Total executions. |
|
integer |
Active executions. |
Error response¶
{"code": "ErrConflict", "msg": "Resource state conflict", "data": null}
Field |
Type |
Description |
|---|---|---|
|
string |
Error code. |
|
string |
Error message. |
|
null |
Empty on error. |
Next steps¶
Keep data.workflow.id. Use Start a workflow job to run it now, or Get workflow details to check its status.