Publish an agent version
A version is immutable once published: a change is a new version, and sessions already running an older one keep it.
POST
/v1/agents/{agent_id}/versionsAuthorization
AuthorizationBearer token · headerrequiredPath parameters
agent_idstring<uuid>requiredAgent id
Header parameters
Idempotency-KeystringRetry the same operation with this key to return its saved receipt. Scoped by the operation's authenticated caller or resource. A different input under the same key returns 409. Receipts are retained for at least 7 days after completion, then removed by an hourly sweep. After removal the key can execute again. Fresh-only secrets are never included in a replay.
min length 1 · max length 255
Request body
requiredapplication/jsonbuiltinBuiltinGrantsBodyThe servers the platform serves itself, each at `builtin:{key}`.
Show propertiesHide properties
ask_userany | AskUserGrantBodyShow propertiesHide properties
One of:
any
anyAskUserGrantBody
widgetsWidgetGrantBody[]requiredmin items 1 · max items 32
Show propertiesHide properties
Array of
WidgetGrantBodyOne of:
object
typestringrequiredAllowed:
selectobject
typestringrequiredAllowed:
textobject
typestringrequiredAllowed:
confirmobject
answerobjectrequiredThe JSON Schema an answer must match.
descriptionstringrequiredWhat the model reads to choose the widget.
max length 1024
idstringrequiredThe renderer's key. A change to `props` or `answer` that would
break a client takes a new id.
max length 64 · matches ^[a-z0-9_-]+$
propsobjectrequiredThe JSON Schema of what the agent fills in.
typestringrequiredAllowed:
customsession_display_nameSessionDisplayNameGrantBodyWhether the agent gets a `set` tool for the session's display name. A
name a user wrote is never overwritten unless it is blank; `when` decides
the rest.
Show propertiesHide properties
whenDisplayNameWhenBodyrequiredWhich session display names the agent may overwrite.
Allowed:
neveremptyuntil_user_editsfunctionsFunctionGrantBody[]Show propertiesHide properties
Array of
FunctionGrantBodydefault_policyPolicyActionBodyrequiredWhat happens when the agent reaches for a tool: it runs, it waits for an
approval on the session's approvals route, or it comes back refused.
Allowed:
allowrequire_approvaldenyhttp_credentialsHttpOriginBody[]Origins whose credential, from the session's vaults, is attached to
each request the package sends there. Each must be reachable under
`network` and listed once. A call is refused, naming the origin, when
the session's vaults hold none, more than one, or one that must be
reconnected.
max items 16
namestringrequiredThe broker serves the package at `fn:{name}`. Unique within
`functions`; `parent` is reserved.
max length 32 · matches ^[a-z0-9-]+$
networkFunctionNetworkBodyWhere a function's HTTP requests may go. Every variant refuses private
and metadata addresses.
Show propertiesHide properties
One of:
object
typestringrequiredAllowed:
noneobject
typestringrequiredAllowed:
unrestrictedobject
hostsHostPatternBody[]requiredmin items 1 · max items 64
typestringrequiredAllowed:
allowlistsourceFunctionSourceBodyrequiredWhere the package comes from. `platform` names a package the deployment
ships, e.g. `files`; `workspace` names one this workspace uploaded.
Show propertiesHide properties
One of:
object
packagestringrequiredmax length 32 · matches ^[a-z0-9-]+$
typestringrequiredAllowed:
platformobject
function_idstring<uuid>requiredtypestringrequiredAllowed:
workspaceversionVersionPinBodyrequiredThe latest version at resolution time, or an exact one.
Show propertiesHide properties
One of:
object
typestringrequiredAllowed:
latestobject
numberinteger<int32>requiredmin 1
typestringrequiredAllowed:
pinnedtimeout_secsinteger<int32> | nullHow long one call may run, in seconds; 60 when unset.
min 1 · max 300
toolsToolRuleBody[]Show propertiesHide properties
Array of
ToolRuleBodynamestringrequiredpolicyPolicyActionBodyrequiredWhat happens when the agent reaches for a tool: it runs, it waits for an
approval on the session's approvals route, or it comes back refused.
Allowed:
allowrequire_approvaldenymcpMcpGrantBody[]Show propertiesHide properties
Array of
McpGrantBodydefault_policyPolicyActionBodyrequiredWhat happens when the agent reaches for a tool: it runs, it waits for an
approval on the session's approvals route, or it comes back refused.
Allowed:
allowrequire_approvaldenynamestringrequiredThe broker serves the server at `mcp:{name}`. Unique within `mcp`;
`parent` is reserved.
max length 32 · matches ^[a-z0-9-]+$
toolsToolRuleBody[]Show propertiesHide properties
Array of
ToolRuleBodynamestringrequiredpolicyPolicyActionBodyrequiredWhat happens when the agent reaches for a tool: it runs, it waits for an
approval on the session's approvals route, or it comes back refused.
Allowed:
allowrequire_approvaldenyurlstringrequiredmodelModelConfigBodyrequiredSelects the model wire format and carries that format's settings.
Show propertiesHide properties
One of:
object
context_windowinteger<int32>requiredmin 0
effortany | AnthropicEffortBodyShow propertiesHide properties
One of:
any
anyAnthropicEffortBody
stringimage_inputany | ImageInputBodyShow propertiesHide properties
One of:
any
anyImageInputBody
stringmax_tokensinteger<int32>requiredmin 0
modelstringrequiredthinkingany | AnthropicThinkingBodyShow propertiesHide properties
One of:
any
anyAnthropicThinkingBody
One of:
object
typestringrequiredAllowed:
adaptiveobject
typestringrequiredAllowed:
disabledobject
typestringrequiredAllowed:
between_toolsobject
budget_tokensinteger<int32>requiredmin 0
typestringrequiredAllowed:
enabledformatstringrequiredAllowed:
anthropicobject
context_windowinteger<int32>requiredmin 0
image_inputany | ImageInputBodyShow propertiesHide properties
One of:
any
anyImageInputBody
stringmax_tokensinteger<int32>requiredmin 0
modelstringrequiredreasoning_effortany | ReasoningEffortBodyShow propertiesHide properties
One of:
any
anyReasoningEffortBody
stringformatstringrequiredAllowed:
openai_responsessandboxesSandboxGrantBody[]Show propertiesHide properties
Array of
SandboxGrantBodydefault_policyPolicyActionBodyrequiredWhat happens when the agent reaches for a tool: it runs, it waits for an
approval on the session's approvals route, or it comes back refused.
Allowed:
allowrequire_approvaldenyenvironmentEnvironmentRefBodyrequiredThe deployment's current image for a named platform release line.
Show propertiesHide properties
One of:
object
releasestringrequiredThe platform image line, e.g. `2026`. A line the deployment does
not offer is refused at publish.
max length 32 · matches ^[a-z0-9-]+$
typestringrequiredAllowed:
platformnamestringrequiredA label this config invents; the broker serves the sandbox at
`sandbox:{name}`. Unique within `sandboxes`; `parent` is reserved.
max length 32 · matches ^[a-z0-9-]+$
networkSandboxNetworkBodyWhere the sandbox may reach. `unrestricted` is the internet; `none` keeps
it out while the sandbox still reaches the platform's own storage for
its backups and skills.
Show propertiesHide properties
One of:
object
typestringrequiredAllowed:
unrestrictedobject
typestringrequiredAllowed:
nonetoolsToolRuleBody[]Show propertiesHide properties
Array of
ToolRuleBodynamestringrequiredpolicyPolicyActionBodyrequiredWhat happens when the agent reaches for a tool: it runs, it waits for an
approval on the session's approvals route, or it comes back refused.
Allowed:
allowrequire_approvaldenyskillsSkillGrantBody[]Show propertiesHide properties
Array of
SkillGrantBodynamestringrequiredA label this config invents; the broker serves the skill at
`skill:{name}`. Unique within `skills`; `parent` is reserved.
max length 32 · matches ^[a-z0-9-]+$
skill_idstring<uuid>requiredversionVersionPinBodyrequiredThe latest version at resolution time, or an exact one.
Show propertiesHide properties
One of:
object
typestringrequiredAllowed:
latestobject
numberinteger<int32>requiredmin 1
typestringrequiredAllowed:
pinnedsystem_promptstring | nullvolumeVolumeConfigBodyThe roots the session tree's functions reach beyond `/volume/tmp`.
Show propertiesHide properties
dataVolumeDataBodyWhether the volume offers a persistent `/volume/data` root. `enabled`
mounts it for the session tree's functions.
Show propertiesHide properties
One of:
object
typestringrequiredAllowed:
disabledobject
typestringrequiredAllowed:
enabledmodel_provider_idstring<uuid>requiredResponses
201The published version.
agent_idstring<uuid>requiredconfigAgentConfigBodyrequiredAn agent version's config: the model it runs and the tool sources it may
reach.
Show propertiesHide properties
builtinBuiltinGrantsBodyThe servers the platform serves itself, each at `builtin:{key}`.
Show propertiesHide properties
ask_userany | AskUserGrantBodyShow propertiesHide properties
One of:
any
anyAskUserGrantBody
widgetsWidgetGrantBody[]requiredmin items 1 · max items 32
Show propertiesHide properties
Array of
WidgetGrantBodyOne of:
object
typestringrequiredAllowed:
selectobject
typestringrequiredAllowed:
textobject
typestringrequiredAllowed:
confirmobject
answerobjectrequiredThe JSON Schema an answer must match.
descriptionstringrequiredWhat the model reads to choose the widget.
max length 1024
idstringrequiredThe renderer's key. A change to `props` or `answer` that would
break a client takes a new id.
max length 64 · matches ^[a-z0-9_-]+$
propsobjectrequiredThe JSON Schema of what the agent fills in.
typestringrequiredAllowed:
customsession_display_nameSessionDisplayNameGrantBodyWhether the agent gets a `set` tool for the session's display name. A
name a user wrote is never overwritten unless it is blank; `when` decides
the rest.
Show propertiesHide properties
whenDisplayNameWhenBodyrequiredWhich session display names the agent may overwrite.
Allowed:
neveremptyuntil_user_editsfunctionsFunctionGrantBody[]Show propertiesHide properties
Array of
FunctionGrantBodydefault_policyPolicyActionBodyrequiredWhat happens when the agent reaches for a tool: it runs, it waits for an
approval on the session's approvals route, or it comes back refused.
Allowed:
allowrequire_approvaldenyhttp_credentialsHttpOriginBody[]Origins whose credential, from the session's vaults, is attached to
each request the package sends there. Each must be reachable under
`network` and listed once. A call is refused, naming the origin, when
the session's vaults hold none, more than one, or one that must be
reconnected.
max items 16
namestringrequiredThe broker serves the package at `fn:{name}`. Unique within
`functions`; `parent` is reserved.
max length 32 · matches ^[a-z0-9-]+$
networkFunctionNetworkBodyWhere a function's HTTP requests may go. Every variant refuses private
and metadata addresses.
Show propertiesHide properties
One of:
object
typestringrequiredAllowed:
noneobject
typestringrequiredAllowed:
unrestrictedobject
hostsHostPatternBody[]requiredmin items 1 · max items 64
typestringrequiredAllowed:
allowlistsourceFunctionSourceBodyrequiredWhere the package comes from. `platform` names a package the deployment
ships, e.g. `files`; `workspace` names one this workspace uploaded.
Show propertiesHide properties
One of:
object
packagestringrequiredmax length 32 · matches ^[a-z0-9-]+$
typestringrequiredAllowed:
platformobject
function_idstring<uuid>requiredtypestringrequiredAllowed:
workspaceversionVersionPinBodyrequiredThe latest version at resolution time, or an exact one.
Show propertiesHide properties
One of:
object
typestringrequiredAllowed:
latestobject
numberinteger<int32>requiredmin 1
typestringrequiredAllowed:
pinnedtimeout_secsinteger<int32> | nullHow long one call may run, in seconds; 60 when unset.
min 1 · max 300
toolsToolRuleBody[]Show propertiesHide properties
Array of
ToolRuleBodynamestringrequiredpolicyPolicyActionBodyrequiredWhat happens when the agent reaches for a tool: it runs, it waits for an
approval on the session's approvals route, or it comes back refused.
Allowed:
allowrequire_approvaldenymcpMcpGrantBody[]Show propertiesHide properties
Array of
McpGrantBodydefault_policyPolicyActionBodyrequiredWhat happens when the agent reaches for a tool: it runs, it waits for an
approval on the session's approvals route, or it comes back refused.
Allowed:
allowrequire_approvaldenynamestringrequiredThe broker serves the server at `mcp:{name}`. Unique within `mcp`;
`parent` is reserved.
max length 32 · matches ^[a-z0-9-]+$
toolsToolRuleBody[]Show propertiesHide properties
Array of
ToolRuleBodynamestringrequiredpolicyPolicyActionBodyrequiredWhat happens when the agent reaches for a tool: it runs, it waits for an
approval on the session's approvals route, or it comes back refused.
Allowed:
allowrequire_approvaldenyurlstringrequiredmodelModelConfigBodyrequiredSelects the model wire format and carries that format's settings.
Show propertiesHide properties
One of:
object
context_windowinteger<int32>requiredmin 0
effortany | AnthropicEffortBodyShow propertiesHide properties
One of:
any
anyAnthropicEffortBody
stringimage_inputany | ImageInputBodyShow propertiesHide properties
One of:
any
anyImageInputBody
stringmax_tokensinteger<int32>requiredmin 0
modelstringrequiredthinkingany | AnthropicThinkingBodyShow propertiesHide properties
One of:
any
anyAnthropicThinkingBody
One of:
object
typestringrequiredAllowed:
adaptiveobject
typestringrequiredAllowed:
disabledobject
typestringrequiredAllowed:
between_toolsobject
budget_tokensinteger<int32>requiredmin 0
typestringrequiredAllowed:
enabledformatstringrequiredAllowed:
anthropicobject
context_windowinteger<int32>requiredmin 0
image_inputany | ImageInputBodyShow propertiesHide properties
One of:
any
anyImageInputBody
stringmax_tokensinteger<int32>requiredmin 0
modelstringrequiredreasoning_effortany | ReasoningEffortBodyShow propertiesHide properties
One of:
any
anyReasoningEffortBody
stringformatstringrequiredAllowed:
openai_responsessandboxesSandboxGrantBody[]Show propertiesHide properties
Array of
SandboxGrantBodydefault_policyPolicyActionBodyrequiredWhat happens when the agent reaches for a tool: it runs, it waits for an
approval on the session's approvals route, or it comes back refused.
Allowed:
allowrequire_approvaldenyenvironmentEnvironmentRefBodyrequiredThe deployment's current image for a named platform release line.
Show propertiesHide properties
One of:
object
releasestringrequiredThe platform image line, e.g. `2026`. A line the deployment does
not offer is refused at publish.
max length 32 · matches ^[a-z0-9-]+$
typestringrequiredAllowed:
platformnamestringrequiredA label this config invents; the broker serves the sandbox at
`sandbox:{name}`. Unique within `sandboxes`; `parent` is reserved.
max length 32 · matches ^[a-z0-9-]+$
networkSandboxNetworkBodyWhere the sandbox may reach. `unrestricted` is the internet; `none` keeps
it out while the sandbox still reaches the platform's own storage for
its backups and skills.
Show propertiesHide properties
One of:
object
typestringrequiredAllowed:
unrestrictedobject
typestringrequiredAllowed:
nonetoolsToolRuleBody[]Show propertiesHide properties
Array of
ToolRuleBodynamestringrequiredpolicyPolicyActionBodyrequiredWhat happens when the agent reaches for a tool: it runs, it waits for an
approval on the session's approvals route, or it comes back refused.
Allowed:
allowrequire_approvaldenyskillsSkillGrantBody[]Show propertiesHide properties
Array of
SkillGrantBodynamestringrequiredA label this config invents; the broker serves the skill at
`skill:{name}`. Unique within `skills`; `parent` is reserved.
max length 32 · matches ^[a-z0-9-]+$
skill_idstring<uuid>requiredversionVersionPinBodyrequiredThe latest version at resolution time, or an exact one.
Show propertiesHide properties
One of:
object
typestringrequiredAllowed:
latestobject
numberinteger<int32>requiredmin 1
typestringrequiredAllowed:
pinnedsystem_promptstring | nullvolumeVolumeConfigBodyThe roots the session tree's functions reach beyond `/volume/tmp`.
Show propertiesHide properties
dataVolumeDataBodyWhether the volume offers a persistent `/volume/data` root. `enabled`
mounts it for the session tree's functions.
Show propertiesHide properties
One of:
object
typestringrequiredAllowed:
disabledobject
typestringrequiredAllowed:
enabledcreated_atstring<date-time>requiredidstring<uuid>requiredmodel_provider_idstring<uuid>requiredversioninteger<int32>requiredNumbered per agent from 1.
400Malformed body, path parameter, or an invalid config.
errorErrorDetailrequiredWhat went wrong: a `code` to branch on and a `message` to show. The
message is written for a person and may change; the code will not.
Show propertiesHide properties
codeErrorCoderequiredThe machine-readable half of an error response, and the field a client
branches on. Closed: every error carries exactly one of these.
Allowed:
unauthorizedforbiddennot_foundinvalid_requestconflictclient_outdatedprecondition_failedtoo_many_requestsinternalmessagestringrequired401Missing, malformed, or invalid bearer token.
errorErrorDetailrequiredWhat went wrong: a `code` to branch on and a `message` to show. The
message is written for a person and may change; the code will not.
Show propertiesHide properties
codeErrorCoderequiredThe machine-readable half of an error response, and the field a client
branches on. Closed: every error carries exactly one of these.
Allowed:
unauthorizedforbiddennot_foundinvalid_requestconflictclient_outdatedprecondition_failedtoo_many_requestsinternalmessagestringrequired403Caller lacks agent.publish.
errorErrorDetailrequiredWhat went wrong: a `code` to branch on and a `message` to show. The
message is written for a person and may change; the code will not.
Show propertiesHide properties
codeErrorCoderequiredThe machine-readable half of an error response, and the field a client
branches on. Closed: every error carries exactly one of these.
Allowed:
unauthorizedforbiddennot_foundinvalid_requestconflictclient_outdatedprecondition_failedtoo_many_requestsinternalmessagestringrequired404No such agent, or the caller cannot see it.
errorErrorDetailrequiredWhat went wrong: a `code` to branch on and a `message` to show. The
message is written for a person and may change; the code will not.
Show propertiesHide properties
codeErrorCoderequiredThe machine-readable half of an error response, and the field a client
branches on. Closed: every error carries exactly one of these.
Allowed:
unauthorizedforbiddennot_foundinvalid_requestconflictclient_outdatedprecondition_failedtoo_many_requestsinternalmessagestringrequired409Idempotency-Key was already used for a different request.
errorErrorDetailrequiredWhat went wrong: a `code` to branch on and a `message` to show. The
message is written for a person and may change; the code will not.
Show propertiesHide properties
codeErrorCoderequiredThe machine-readable half of an error response, and the field a client
branches on. Closed: every error carries exactly one of these.
Allowed:
unauthorizedforbiddennot_foundinvalid_requestconflictclient_outdatedprecondition_failedtoo_many_requestsinternalmessagestringrequired