Migrate a task to a newer workflow version
POST/api/v1/tasks/:task_id/migrate
Moves an open task onto a newer version of its workflow. A state the target version also declares maps to itself; state_map maps a state it lacks. The payload is re-validated against the target payload_schema. The mapped state's on_enter is not fired: transition the task when you want the target's automation. A task with a dispatch in flight or a transition pending approval is refused, since both belong to the version they started under. Recorded in history as a row with transition: null and both versions.
Request
Responses
- 200
- 400
- 401
- 403
- 404
- 409
The task on the target version
The version does not exist or is not newer than the task's, the current state is unmapped, a mapped state is undeclared or terminal, or the payload fails the target payload_schema
Unauthorized
Forbidden
Task not found
The task is closed, has a transition pending approval, or has a dispatch in flight