Read one change waiting for a review
The draft with what it changes against the version it was made on, who may approve it and the reviews so far.
better-auth.session_token<token>Better Auth session cookie. Production uses the __Secure- prefixed name.
pipelineId*stringuuiddraftId*stringuuidThe draft.
application/json- response
yaml*stringThe draft's graph as pipeline.yaml, which the diff against baseYaml shows.
baseYaml*stringThe graph of the version the draft was made on, as pipeline.yaml.
approverGroups*array<>Who may approve, row by row, with the people in each.
number*integerThe draft's number among the pipeline's drafts.
graph?|The graph the draft proposes, for a draft of the graph; null for a draft of the settings.
id*stringuuidpipelineId*stringuuidkind*string"graph""settings"source?stringWhat made the draft when it was not a person's edit, such as preset:<id>.
changes*array<>What the draft changes against the version it was made on.
approvers*array<string>Who may approve it, as the rules stood when the draft was made.
basedOn*integerThe version the change was made on.
summary*stringcreatedBy*createdAt*stringdate-timestate*string"open""approved""declined""superseded""withdrawn"version?|The version an approved draft became.
reviews*array<>curl -X GET 'https://wardn.example.com/api/v1/pipelines/497f6eca-6276-4993-bfeb-53cbbbba6f08/drafts/497f6eca-6276-4993-bfeb-53cbbbba6f08'{ "yaml": "string", "baseYaml": "string", "approverGroups": [ { "label": "string", "why": "string", "people": [ { "id": "string", "name": "string", "image": "string" } ] } ], "number": 0, "graph": { "stages": [ { "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "name": "string", "environmentId": "19f5cc2e-7657-437a-9268-83cd3d563563", "arrival": "auto_promote", "soakSeconds": 0, "config": { "which": "qualified", "ifSeveral": "replace", "allowRequests": true, "configOnly": true, "incoming": "all", "narrow": [ { "field": "cluster", "op": "is", "value": "string" } ], "rules": [ { "id": "string", "type": "approval", "section": "gate", "title": "string", "note": "string", "locked": true, "params": {} } ], "onReject": "keep", "onQualify": "notify", "notifyTarget": "string", "rollout": { "mode": "all", "waves": [ { "id": "string", "name": "string", "detail": "string", "targets": "string", "verify": "string", "next": "confirm", "soakSeconds": 0, "selector": { "property1": "string", "property2": "string" } } ], "onFail": "pause", "retries": "2", "timeout": "15m" }, "health": { "watchSeconds": 0, "onFail": "pause" }, "requestForm": "string", "agents": { "autonomy": "observe", "cap": "observe", "perHour": 0, "may": { "property1": true, "property2": true }, "read": { "mode": "off", "agentId": "string" } }, "preset": { "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "version": 1 } }, "position": 0, "environmentName": "string", "environmentClass": "string" } ], "routes": [ { "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "fromStageId": "877db427-5907-4b80-a8b2-ab6c3e6f1fc9", "toStageId": "ccc70001-c375-49a1-b702-44689ce3757f", "kind": "main", "must": "qualified", "label": "string" } ] }, "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "pipelineId": "621ef2b0-ba1d-48e5-89dc-b778e6ed42fd", "kind": "graph", "source": "string", "changes": [ { "kind": "string", "subject": "string", "detail": "string" } ], "approvers": [ "string" ], "basedOn": 0, "summary": "string", "createdBy": { "id": "string", "name": "string" }, "createdAt": "2019-08-24T14:15:22Z", "state": "open", "version": 0, "reviews": [ { "approver": true, "by": { "id": "string", "name": "string" }, "decision": "approve", "note": "string", "at": "2019-08-24T14:15:22Z" } ]}List the changes made to a pipeline that needed a review GET
The drafts of the pipeline, newest first, at most 50, so the list is not paged; `state` keeps one state. A draft is an edit that the pipeline's settings said needs a review before it becomes a version.
Withdraw a change waiting for a review POST
Closes an open draft at the request of the person who made it; it takes `pipeline:read`, because what is checked is who the person is, not what they may edit. The pipeline stays as it is. Anyone else is refused (409 `pipeline.withdraw_refused`), and so is a draft that was already decided (409 `pipel