Replace a preset
Saves a new version of the preset, which stages linked to it follow. The kind cannot change.
better-auth.session_token<token>Better Auth session cookie. Production uses the __Secure- prefixed name.
presetId*stringuuidIdempotency-Key?stringMakes 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.
^[A-Za-z0-9_.:-]+$1 <= length <= 255application/json- body
name*string1 <= length <= 63description?stringlength <= 200kind*string"pipeline""stage""rollout""guardrail"ownerTeamId?stringEmpty for the platform team.
sharedWith?array<string>everyone or team ids; empty means everyone.
body*Which part is set depends on the preset's kind.
The updated preset.
application/json- response
follows?array<>On an update, what happened to each pipeline whose stage follows the preset.
id*stringuuidname*stringdescription*stringkind*string"pipeline""stage""rollout""guardrail"ownerTeamId*stringsharedWith*array<string>version*integerbody*Which part is set depends on the preset's kind.
linkedStages*integerStages in active pipelines that follow this preset.
builtin*booleanWardn ships it with every organization. It cannot be changed or deleted (409 preset.builtin).
usedBy*integerActive pipelines created from it.
createdAt*stringdate-timeupdatedAt*stringdate-timecurl -X PUT 'https://wardn.example.com/api/v1/pipeline-presets/497f6eca-6276-4993-bfeb-53cbbbba6f08' \ -H 'Content-Type: application/json' \ -d '{ "name": "string", "kind": "pipeline", "body": {}}'{ "follows": [ { "pipelineId": "621ef2b0-ba1d-48e5-89dc-b778e6ed42fd", "pipelineName": "string", "stageName": "string", "result": "updated", "version": 0, "draftNumber": 0, "draftId": "dfb8a430-52c9-4ba8-8878-6bd070da9488", "reason": "string" } ], "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "name": "string", "description": "string", "kind": "pipeline", "ownerTeamId": "string", "sharedWith": [ "string" ], "version": 0, "body": { "arrival": "auto_promote", "stage": { "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 } }, "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" }, "stages": [ { "name": "string", "environmentClass": "string", "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 } } } ], "settings": {} }, "linkedStages": 0, "builtin": true, "usedBy": 0, "createdAt": "2019-08-24T14:15:22Z", "updatedAt": "2019-08-24T14:15:22Z"}