Deployments
Preview

Let a snapshot through the guardrails that hold it

A guardrail can hold a snapshot: the protected-branch rule of a guarded environment, a window, a missing approval. Bypassing lets that one snapshot deploy anyway, once, with a reason that Activity records; the next snapshot meets the guardrails again. It is for people who hold the bypass duty. Other

POST
/deployments/{deploymentId}/snapshots/{snapshotId}/bypass
cookiebetter-auth.session_token<token>

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

deploymentId*string
Formatuuid
snapshotId*string
Formatuuid
Idempotency-Key?string

Makes retries safe. A repeated key with the same request returns the first result and sets Idempotent-Replayed: true. The same key with a different request answers 409 idempotency.key_reused, and while the first request is still running 409 idempotency.in_progress. Results are kept for 24 hours. Server errors and refusals for lack of sign-in or permission are not kept, so a retry runs again.

Match^[A-Za-z0-9_.:-]+$
Length1 <= length <= 255
application/json
  1. body
reason*string
Length1 <= length <= 1000
ruleIds?array<string>

The guardrail rules the bypass skips, each one holding the snapshot now (409 bypass.rule_not_holding otherwise). Left out, it skips every rule that holds the snapshot. A rule it does not name still holds it.

Response Body

The snapshot, now on its way to the cluster.

application/json
  1. response
id*string
Formatuuid
deploymentId*string
Formatuuid
parentId?|
Formatuuid
origin*string
Value in"sync""promotion""rollback""drift""restore""emergency""cutover"
provenance*

Where a snapshot's content came from. The top-level fields describe the app whose push or pull request made it, or the deployment's first app; apps describes every app the snapshot covers.

resourceCount*integer
createdAt*string
Formatdate-time
createdBy*string
Example Request
curl -X POST 'https://wardn.example.com/api/v1/deployments/497f6eca-6276-4993-bfeb-53cbbbba6f08/snapshots/497f6eca-6276-4993-bfeb-53cbbbba6f08/bypass' \  -H 'Content-Type: application/json' \  -d '{  "reason": "string"}'
Example Response
{  "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",  "deploymentId": "a73c85a1-d857-491e-a6b2-51dce05de7a2",  "parentId": "70850378-7d3c-4f45-91b7-942d4dfbbd43",  "origin": "sync",  "provenance": {    "sourceRepo": "string",    "branch": "string",    "commit": "string",    "branchProtected": true,    "prNumber": 0,    "pusher": "string",    "commitSubject": "string",    "commitAuthor": "string",    "committedAt": "2019-08-24T14:15:22Z",    "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"          }        ]      }    ]  },  "resourceCount": 0,  "createdAt": "2019-08-24T14:15:22Z",  "createdBy": "string"}