Task Runs
Set Task Run State
Set a task run state, invoking any orchestration rules.
POST
/
api
/
task_runs
/
{id}
/
set_state
Headers
x-prefect-api-version
string
Path Parameters
id
string
requiredThe task run id
Body
application/json
state
object
requiredThe intended state.
force
boolean
default: falseIf false, orchestration rules will be applied that may alter or prevent the state transition. If True, orchestration rules are not applied.
Response
200 - application/json
A container for the output of state orchestration.
state
object | null
requiredRepresents the state of a run.
status
enum<string>
requiredEnumerates return statuses for setting run states.
Available options:
ACCEPT
, REJECT
, ABORT
, WAIT
details
object
requiredDetails associated with an ACCEPT state transition.
Was this page helpful?