Upgrade a case
POST/api/v1/playbook-cases/:case_id/upgrade
Moves a case to another version of its playbook: the playbook's current version, or the version named, an earlier one included. Values carry over by node ID, and every node's state is read against the new version: a node added is open, a node removed leaves the structure while its entries stay, a node whose input reads another field is stale, and a value its input's new schema refuses is missing again. The cascade then runs what became runnable. With wait: true it answers once every execution queued, and every one those queue, has settled or parked. Each upgrade is recorded with what moved; the version the case is already on records nothing.
The case's upstream bindings follow the target version: a name it declares on the same playbook keeps its case, any other binding is dropped, and each name it declares that the case does not bind is bound from upstreams, by the rules of create. A declared name left unbound is 400 PLAYBOOK_CASE_UPSTREAM_INVALID and moves nothing.
An execution running is 409 PLAYBOOK_CASE_BUSY; one queued but not started settles superseded. An upgrade made with a credential the case's own work, or that of a case reading it as an upstream, runs as is 403 PLAYBOOK_SELF_WRITE.
Request
Responses
- 200
- 400
- 401
- 403
- 404
- 409
- 413
- 429
- 500
- 502
- 4XX
The case on its new version
Bad request — a version the playbook does not have, or PLAYBOOK_CASE_UPSTREAM_INVALID: an upstream the target version declares left unbound, a name it does not declare or the case already binds, or a case that cannot be bound
Unauthorized
Forbidden, or an upgrade from the case's own work
Case not found
An execution of the case is running
REQUEST_REJECTED — the request body is over the size the body parser accepts
QUOTA_EXCEEDED — a requests quota on the calling API key or its project is spent for the window; Retry-After says when it reopens
Response Headers
Seconds until the quota window admits a request again
Unexpected server error — INTERNAL_ERROR, with the raw message never forwarded
The deployment's admission service is asked about this write and did not answer — ADMISSION_UNAVAILABLE; the write did not happen
The deployment's admission service refused this write — answered under the service's own 4xx status, with its code (matching ^[A-Za-z_][A-Za-z0-9_]{0,63}$, not necessarily an ERROR_CODES key), message and meta; the write did not happen. A status this operation also declares on its own is documented there