DOCS / API REFERENCE

Roll back a deployment

POST /v1/deployments/{deployment_id}/rollback

POSTHenHouse API v1

Request

POST /v1/deployments/{deployment_id}/rollback

Authenticate with a bearer token. Create one with POST /v1/tokens or cluck login.

Parameters

NameTypeDescription
deployment_idstringThe deployment ID (path)
to_versionstringOptional version to roll back to

Example

curl -X POST https://api.pollosoft.example/v1/deployments/deployment_8f2a/rollback \
  -H "Authorization: Bearer $COOP_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"to_version": "example-to_version"}'

Response

A successful call returns 201 Created with JSON like this:

{
  "id": "dep_a032",
  "status": "rolled_back",
  "restored_version": "v181"
}

Errors

IdempotencySend an Idempotency-Key header to make retries safe. We will return the original result instead of laying a second egg.