Promote the draft to staging
Revalidates the locked mutable draft, its reusable catalog and transfer references, after-call dependencies, and baseline budget; snapshots it as the next immutable version; then points staging at it. A successful new logical intent always advances the aggregate revision; replaying the same Idempotency-Key returns the original response instead of creating another snapshot.
bearerAuthAuthorizationBearer <token>Use a Voice API key or connected-app OAuth access token. Authentication.
id*stringuuidIdempotency-Key*stringRequired. Reuse the same key to retry this write safely. Retries and idempotency.
^[A-Za-z0-9!#$%&'*+.^_`|~-]+$1 <= length <= 255If-Match?stringOptional strong ETag (or *) from a prior response. A stale tag returns 412 without changing the resource.
application/json- body
name?stringOptional human-readable snapshot label. When present, the trimmed value must contain at least one non-whitespace character; an empty or whitespace-only value returns 422 invalid_body with a field error for name rather than being treated as omitted.
length <= 120Success
application/json- response
id*stringID of the immutable snapshot created from the draft.
uuidagent_id*stringuuidstaging_version_id*stringNew staging pointer; equal to id for this operation.
uuidversion*integer1 <= valuerevision*integerint641 <= valueupdated_at*stringAggregate update timestamp corresponding to revision.
date-timecurl -X POST 'https://api.kejue.co/v1/agents/497f6eca-6276-4993-bfeb-53cbbbba6f08/promote-staging' \ -H 'Idempotency-Key: string' \ -H 'Content-Type: application/json' \ -d '{ "name": "Initial production candidate"}'{ "id": "33333333-3333-4333-8333-333333333333", "agent_id": "11111111-1111-4111-8111-111111111111", "staging_version_id": "33333333-3333-4333-8333-333333333333", "version": 1, "revision": 4, "updated_at": "2026-07-20T09:15:00Z"}