Template drafts

Publish the draft as the template’s next version (save-as-template from the draft)

Builds one new org layer holding every change since the draft base, from state_id or the draft’s current state (a fresh capture when running). settings (TemplateSettingsInput): each given field replaces that field of the draft base’s settings, each absent one is carried forward (settings.defaults and defaults together: 422 invalid_settings). Refused with 409 draft_stale (details latest_version, draft_base_version) when the template has a version newer than the draft base that this draft did not produce, and 409 build_in_progress while a build from another source is unfinished. Immutable paths: the new version declares the template’s open version’s immutable paths (else the draft base’s) with the content the draft holds there; 422 immutable_paths_unsupported_base when the draft’s base has no guest agent with immutable_paths.v1 (details.base). 202 SaveAsTemplateResponse. Supports Idempotency-Key.

post/v1/templates/{slug}/draft/publish

Request

  • Base URL: https://api.shardflux.dev
  • URL: https://api.shardflux.dev/v1/templates/{slug}/draft/publish
  • Auth: HTTP bearer

Path parameters

slugstring required

Request body

state_idstring uuid

UUIDv7, lowercase canonical form.

descriptionstring
auto_publishboolean
acknowledged_scan_findingsstring[]

Up to 200 absolute paths the credential scan may report without failing the build (recorded in the manifest).

Response

operation: the capture (layer_snapshot) of a running workspace, null otherwise. build: poll GET …/template-builds/{id} until registration.state is registered.

Changes

No recorded changes to this operation across all 1 revision of this API.