Deployments
Preview

Get what comes next for a deployment

How new snapshots reach it and what limits them: its pipeline stage with auto-promotion and soak (live: `configured` is true when a pipeline the caller can read carries one of its apps and has a stage in its environment), deploy windows and freezes (shape only, empty until guardrails, M3), and its d

GET
/deployments/{deploymentId}/next
cookiebetter-auth.session_token<token>

Better Auth session cookie. Production uses the __Secure- prefixed name.

deploymentId*string
Formatuuid

Response Body

OK.

application/json
  1. response
configured*boolean

Whether a pipeline stage decides what comes next. False when no pipeline the caller can read has a stage for the deployment.

arrival*DeploymentArrival

How new snapshots arrive: branch takes one on each push to a branch (Automatic), request takes one only when asked or when a pipeline promotes one in.

Value in"branch""request"
pipeline*|

The pipeline whose stage the deployment sits in; null when it is in none.

stage*|

The stage of that pipeline in the deployment's environment; null when it is in none.

autoPromote*boolean

Whether the stage takes snapshots by auto-promotion.

soakSeconds*|

The stage's soak in seconds; null when it has none.

nextSnapshot*|

The newest snapshot rendered for the deployment that is newer than the one running, was not held back and has not been applied, with when it arrives (null until pipelines decide that). Null when there is none.

windows*array<>

Shape only; empty until windows (M3).

freezes*array<>

Shape only; empty until freezes (M3).

drift*

What happens to drift. detect records and shows it. revert_after reverts what still differs revertAfterSeconds after it was found. revert reverts at once. A revert is the drift revert action, run as the system and recorded in Activity. A deployment that only observes only detects.

Example Request
curl -X GET 'https://wardn.example.com/api/v1/deployments/497f6eca-6276-4993-bfeb-53cbbbba6f08/next'
Example Response
{  "configured": true,  "arrival": "branch",  "pipeline": {    "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",    "name": "string"  },  "stage": {    "name": "string"  },  "autoPromote": true,  "soakSeconds": 0,  "nextSnapshot": {    "snapshotId": "09520abc-01e6-4da1-8fa5-f10e3883c861",    "brief": {      "contentId": "string",      "origin": "sync",      "commitSubject": "string",      "commitAuthor": "string",      "committedAt": "2019-08-24T14:15:22Z",      "change": {        "kind": "image",        "app": "string",        "from": "string",        "to": "string"      },      "apps": [        {          "appId": "28c365d5-df94-4a54-8217-3ce51d068868",          "name": "string",          "sourceRepo": "string",          "sourcePath": "string",          "renderType": "string",          "commit": "string",          "branch": "string",          "branchProtected": true,          "prNumber": 0,          "pusher": "string",          "commitSubject": "string",          "commitAuthor": "string",          "committedAt": "2019-08-24T14:15:22Z",          "refKind": "branch",          "refName": "string",          "commitsSince": 0,          "commitRange": [            {              "sha": "string",              "subject": "string",              "author": "string"            }          ]        }      ]    },    "contentId": "string",    "arrivesAt": "2019-08-24T14:15:22Z"  },  "windows": [    {      "name": "string",      "opensAt": "2019-08-24T14:15:22Z",      "closesAt": "2019-08-24T14:15:22Z"    }  ],  "freezes": [    {      "name": "string",      "startsAt": "2019-08-24T14:15:22Z",      "endsAt": "2019-08-24T14:15:22Z"    }  ],  "drift": {    "mode": "detect",    "revertAfterSeconds": 60  }}