Skip to main content
PATCH
Update Disposition Draft

Overview

Dispositions are enabled per organization. If your organization does not have access, these endpoints return 404.
Replaces the whole draft definition. The write is guarded by the draft revision: pass the revision you read from Get Disposition Draft as expectedDraftRevision, and the call returns 409 if someone else saved first. Editing the draft never affects the published version or calls already running; publish with Publish Disposition to make changes live. Requires an admin, owner, operator, or prompter role.

Headers

string
required
Your API key for authentication.

Path Parameters

string
required
The agent’s unique identifier. Must be a UUID; otherwise returns 400 with the message agentId must be a valid UUID. Returns 404 Agent not found if the agent is not in your organization.
string
required
The disposition’s unique identifier. Must be a UUID; otherwise returns 400 with the message dispositionId must be a valid UUID. Returns 404 Disposition not found if it does not belong to this agent.

Body Parameters

Unknown fields anywhere in the body are rejected. This is a full replacement, not a merge: every field of definition must be present.
integer
required
The draft revision you last read, at least 1. If the live revision differs, nothing is written and the call returns 409 CONFLICT. On success the revision becomes expectedDraftRevision + 1.
object
required
The complete replacement definition. Schema violations return 400 BAD_REQUEST with message Invalid request body and an ext string listing each failing path. Rule violations return 400 BAD_REQUEST with message Definition failed validation and an ext string carrying problems, each with valueId and message. Drafts are validated less strictly than publishing: a structured_extraction value may omit its version pin, and judge or extractor pins may still be editable.

Response

string
The disposition this draft belongs to.
number
The new draft revision, expectedDraftRevision + 1.
string | null
The most recently published version, or null if never published.
object
The saved definition, as stored.
null | array
null on success, or a list of error objects if the request failed.

Docs for agents: llms.txt