@deepraxis/sdk 0.1.1-dev.522f44a → 0.1.1-dev.53bfbed

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -19611,7 +19611,7 @@ export type MediaJob = {
19611
19611
  /**
19612
19612
  * Why a queued generation job has not started yet. queue_reason is omitted once the job starts.
19613
19613
  */
19614
- queue_reason?: 'concurrency' | 'provider_throttled';
19614
+ queue_reason?: 'concurrency' | 'provider_throttled' | 'provider_queue';
19615
19615
  /**
19616
19616
  * Present while the job waits for a slot (queue_reason concurrency): its place in line among the waiting jobs of its type in this library, 1 for the next to start. Waiting jobs start oldest first; keep polling the job, there is nothing to resubmit.
19617
19617
  */
@@ -19853,7 +19853,7 @@ export type MediaAssetReference = {
19853
19853
  strength?: number;
19854
19854
  };
19855
19855
  /**
19856
- * One edit to apply to the source asset. type selects the operation and the discriminating branch carries that operation’s fields. This release performs variations, inpaint, erase, replace_object, recolor and replace_background on images, remove_background on an image or a video, upscale, enhance_voice, reframe, redact, trim, mute and crop through Media’s processing lane (upscale on a picture or a video; enhance_voice on a recording or a video, whose audio is used; reframe, redact, trim, mute and crop on a video), erase and replace_person on a video through the same lane, and to_video, frame and resynthesize on the material each takes; every other type here describes the operation vocabulary and is refused with OPERATION_NOT_SUPPORTED. align is not an edit — it compares two assets and has its own endpoint, POST /media/v1/libraries/{library_id}/assets/{asset_id}/align.
19856
+ * One edit to apply to the source asset. type selects the operation and the discriminating branch carries that operation’s fields. This release performs variations, inpaint, erase, replace_object, recolor and replace_background on images, remove_background on an image or a video, upscale, enhance_voice, reframe, redact, trim, mute and crop through Media’s processing lane (upscale on a picture or a video; enhance_voice on a recording or a video, whose audio is used; reframe, redact, trim, mute and crop on a video), erase, replace_person, lip_sync and animate_person on a video and talking_avatar on an image through the same lane, and to_video, frame and resynthesize on the material each takes; every other type here describes the operation vocabulary and is refused with OPERATION_NOT_SUPPORTED. align is not an edit — it compares two assets and has its own endpoint, POST /media/v1/libraries/{library_id}/assets/{asset_id}/align.
19857
19857
  */
19858
19858
  export type MediaEditOperation = {
19859
19859
  /**
@@ -20095,13 +20095,17 @@ export type MediaEditOperation = {
20095
20095
  */
20096
20096
  type: 'lip_sync';
20097
20097
  /**
20098
- * Audio asset whose speech should drive the speaker’s lips.
20098
+ * Audio or voice asset in the same library whose speech the lips should follow. Anything else is refused with the field named.
20099
20099
  */
20100
20100
  audio_asset_id?: MediaAssetId;
20101
20101
  /**
20102
- * Speech to synthesize for the speaker instead of an existing audio asset.
20102
+ * Not carried out yet: synthesize the recording first with POST /media/v1/libraries/{library_id}/speech and name it in audio_asset_id.
20103
20103
  */
20104
20104
  speech?: MediaSpeechCreateInput;
20105
+ /**
20106
+ * Lip-sync model, from the models the generation capabilities publish for the lip_sync capability; omit it to use the first available.
20107
+ */
20108
+ model?: string;
20105
20109
  } | {
20106
20110
  /**
20107
20111
  * Edit operation discriminator; frame selects the frame branch of this union.
@@ -20215,6 +20219,32 @@ export type MediaEditOperation = {
20215
20219
  * Processing model that performs the replacement, which is also the tier: video-replace-person-flash (faster and cheaper) or video-replace-person-pro (smoother detail, slower and dearer), as the generation capabilities publish them for the replace_person capability with their prices; omit it to use the first available. A request that names none when the platform has published none is refused with OPERATION_NOT_SUPPORTED.
20216
20220
  */
20217
20221
  model?: string;
20222
+ } | {
20223
+ /**
20224
+ * Edit operation discriminator; animate_person selects the animate_person branch of this union.
20225
+ */
20226
+ type: 'animate_person';
20227
+ /**
20228
+ * Image asset in the same library showing the person or character to animate. A video, a sticker, the source itself or an asset outside this library is refused with the field named.
20229
+ */
20230
+ person_asset_id: MediaAssetId;
20231
+ /**
20232
+ * Which tier: video-animate-person-flash or video-animate-person-pro, as the generation capabilities publish them for animate_person with their prices; omit it to use the first available.
20233
+ */
20234
+ model?: string;
20235
+ } | {
20236
+ /**
20237
+ * Edit operation discriminator; talking_avatar selects the talking_avatar branch of this union.
20238
+ */
20239
+ type: 'talking_avatar';
20240
+ /**
20241
+ * Audio or voice asset in the same library with the speech or song, at most 20 seconds.
20242
+ */
20243
+ audio_asset_id: MediaAssetId;
20244
+ /**
20245
+ * Which tier: video-talking-avatar-flash (480P) or video-talking-avatar-pro (720P), as the generation capabilities publish them for talking_avatar with their prices; omit it to use the first available.
20246
+ */
20247
+ model?: string;
20218
20248
  } | {
20219
20249
  /**
20220
20250
  * Edit operation discriminator; voice_change selects the voice_change branch of this union.
@@ -20384,6 +20414,22 @@ export type MediaGenerationCapabilities = {
20384
20414
  speech: MediaGenerationTypeCapability;
20385
20415
  matting: MediaGenerationTypeCapability;
20386
20416
  };
20417
+ /**
20418
+ * The models each processing capability offers, for the edit operations that run on one: upscale, enhance_voice (voice_enhance), reframe, redact, align, trim, mute and crop (clip), erase on a video, replace_person, lip_sync, animate_person and talking_avatar. Name one as the operation’s model, or omit model to use the first available. A capability whose models list is empty has no model published yet, and its operation is refused with OPERATION_NOT_SUPPORTED; when the catalogue cannot be read every list is empty.
20419
+ */
20420
+ processes: {
20421
+ upscale: MediaGenerationProcessCapability;
20422
+ voice_enhance: MediaGenerationProcessCapability;
20423
+ reframe: MediaGenerationProcessCapability;
20424
+ redact: MediaGenerationProcessCapability;
20425
+ align: MediaGenerationProcessCapability;
20426
+ clip: MediaGenerationProcessCapability;
20427
+ erase: MediaGenerationProcessCapability;
20428
+ replace_person: MediaGenerationProcessCapability;
20429
+ lip_sync: MediaGenerationProcessCapability;
20430
+ animate_person: MediaGenerationProcessCapability;
20431
+ talking_avatar: MediaGenerationProcessCapability;
20432
+ };
20387
20433
  };
20388
20434
  /**
20389
20435
  * A video asset’s on-demand HLS ladder for its current version: the asset, the version, and one summary per recorded rung.
@@ -24566,6 +24612,10 @@ export type TicketComment = {
24566
24612
  * Last edit timestamp.
24567
24613
  */
24568
24614
  update_time: string;
24615
+ /**
24616
+ * Present only when something in the body could not be resolved; absent when it all resolved.
24617
+ */
24618
+ warnings?: Array<string>;
24569
24619
  };
24570
24620
  /**
24571
24621
  * A repository label.
@@ -37444,6 +37494,15 @@ export type MediaGenerationTypeCapability = {
37444
37494
  */
37445
37495
  models: Array<MediaGenerationCapabilityModel>;
37446
37496
  };
37497
+ /**
37498
+ * The models one processing capability offers.
37499
+ */
37500
+ export type MediaGenerationProcessCapability = {
37501
+ /**
37502
+ * Every model the platform catalogue offers for this processing capability, in a stable order, with available and price. A processing model is charged per second it produces (price.unit second); a model with no published rate has no price.
37503
+ */
37504
+ models: Array<MediaGenerationCapabilityModel>;
37505
+ };
37447
37506
  export type MediaHlsRendition = {
37448
37507
  /**
37449
37508
  * Clarity rung as its playlist calls it; the height with a p, so 480p is the short side at 480 pixels.
@@ -47587,7 +47646,7 @@ export type DevopsTargetPath = string;
47587
47646
  */
47588
47647
  export type DevopsLockId = string;
47589
47648
  /**
47590
- * The change's id, which is its branch name <type>/<slug> from a change list or create answer; the slash must be percent-encoded, so feat/run-page-v2 is sent as feat%2Frun-page-v2.
47649
+ * The change's id, which is its branch name <type>/<slug> from a change list or create answer. Give it as it comes back — `feat/run-page-v2`: the SDK and the CLI encode the slash themselves, and an id that is already percent-encoded is encoded a second time and answers CHANGE_NOT_FOUND. Only a caller writing the HTTP request by hand sends feat%2Frun-page-v2.
47591
47650
  */
47592
47651
  export type DevopsChangeIdPath = string;
47593
47652
  /**
@@ -49868,7 +49927,7 @@ export type ApplyAgentVersionResponses = {
49868
49927
  */
49869
49928
  note: string | null;
49870
49929
  /**
49871
- * Platform resources and services this service agent's codemode may reach, as one list of typed bindings. Only kind=service accepts a nonempty list; general agents return 400. There are two kinds. A resource binding names one resource with id and access: database (id db_..., read_only or read_write), vector_store (id vs_..., read_only or read_write), file (id file- plus 24 letters or digits, as the File API returns it; read_only), media_library (any id without ':' or whitespace, read_only or read_write), model (a model catalog id, invoke), workflow and script (id <namespace>/<name>, invoke). A service binding opens one service, or one sub-tree of one, and carries only enabled: search, browser, ticket, crm, canvas, cut, studio, feedback or workspace. workspace opens development units — list one, read one, start, stop, exec inside one, fetch, push, connect, and open a unit for a change — and opens neither publishing nor any production operation. The ticket service is bound by default: a service agent whose list has no ticket entry may call the ticket API, and {"type": "ticket", "enabled": false} removes it. Every other service stays closed until it is bound. An open service allows every public method of that service. At most 20 bindings per type, no repeated type and id, and each service type at most once. A session is authorized by the agent version it runs: newly added bindings apply only to new sessions, and a version saved with apply=false changes no access until it is applied. Applying a version that disables, removes or downgrades a binding revokes it immediately in running sessions on older versions. A resource that is not bound returns 404, a service that is not opened returns 403, and a write to a resource bound read_only returns 403 BINDING_READ_ONLY. Unknown types, fields on the wrong kind (id, access or instructions on a service binding), wrong access and malformed ids return 400. The former databases, vector_stores and files fields are removed and return 400. Omit on create for the default: the ticket service only. Saving checks added or changed database, vector_store, media_library and file bindings in the organization: unknown or deleted ids return 400. If an owner is unavailable or takes more than 3 seconds, saving succeeds with verified=false for the affected bindings. Unchanged bindings keep their previous verification result and are not rechecked. workflow and script ids are not verified at save time.
49930
+ * Platform resources and services this service agent's codemode may reach, as one list of typed bindings. Only kind=service accepts a nonempty list; general agents return 400. There are two kinds. A resource binding names one resource with id and access: database (id db_..., read_only or read_write), vector_store (id vs_..., read_only or read_write), file (id file- plus 24 letters or digits, as the File API returns it; read_only), media_library (any id without ':' or whitespace, read_only or read_write), model (a model catalog id, invoke), workflow and script (id <namespace>/<name>, invoke). A resource binding may also carry customer_access (read_only by default): it caps what a terminal customer's session (a visitor, ADR-163 §3) may do with that one resource, at the intersection of customer_access and the binding's own access — invoke (call) and read_write (change) are different axes, so only a matching pair keeps its access and any other pair falls to read_only. Its value must be one the type can grant: read_only or read_write for database, vector_store and media_library, read_only for file, and read_only or invoke for model, workflow and script. A member's session ignores it, so raising it never widens what members may do. A visitor's session never receives a whole-service binding (the default ticket service included) or an agent resource. A service binding opens one service, or one sub-tree of one, and carries only enabled: search, browser, ticket, crm, canvas, cut, studio, feedback or workspace. workspace opens development units — list one, read one, start, stop, exec inside one, fetch, push, connect, and open a unit for a change — and opens neither publishing nor any production operation. The ticket service is bound by default: a service agent whose list has no ticket entry may call the ticket API, and {"type": "ticket", "enabled": false} removes it. Every other service stays closed until it is bound. An open service allows every public method of that service. At most 20 bindings per type, no repeated type and id, and each service type at most once. A session is authorized by the agent version it runs: newly added bindings apply only to new sessions, and a version saved with apply=false changes no access until it is applied. Applying a version that disables, removes or downgrades a binding revokes it immediately in running sessions on older versions. A resource that is not bound returns 404, a service that is not opened returns 403, and a write to a resource bound read_only returns 403 BINDING_READ_ONLY. Unknown types, fields on the wrong kind (id, access, customer_access or instructions on a service binding), wrong access and malformed ids return 400. The former databases, vector_stores and files fields are removed and return 400. Omit on create for the default: the ticket service only. Saving checks added or changed database, vector_store, media_library and file bindings in the organization: unknown or deleted ids return 400. If an owner is unavailable or takes more than 3 seconds, saving succeeds with verified=false for the affected bindings. Unchanged bindings keep their previous verification result and are not rechecked. workflow and script ids are not verified at save time.
49872
49931
  */
49873
49932
  bindings: Array<{
49874
49933
  /**
@@ -49883,6 +49942,10 @@ export type ApplyAgentVersionResponses = {
49883
49942
  * database, vector_store and media_library accept read_only or read_write; file accepts read_only; model, workflow and script accept invoke. Any other combination returns 400.
49884
49943
  */
49885
49944
  access: 'read_only' | 'read_write' | 'invoke';
49945
+ /**
49946
+ * What a visitor's session (a terminal customer, ADR-163 §3) may do with this resource: read_only, read_write or invoke. Its scope is the intersection of this value and the binding's own access, so invoke needs both to be invoke. Limited to the accesses the type can grant: read_only or read_write for database, vector_store and media_library, read_only for file, read_only or invoke for model, workflow and script. Defaults to read_only. A member's session ignores it entirely; a visitor's session never receives a whole-service binding or an agent resource.
49947
+ */
49948
+ customer_access?: 'read_only' | 'read_write' | 'invoke';
49886
49949
  /**
49887
49950
  * Optional guidance for using this resource, up to 4096 characters; does not expand access.
49888
49951
  */
@@ -50307,6 +50370,10 @@ export type ApplyAgentVersionResponses = {
50307
50370
  * Channel the agent was created through (for example api or console); null for historical agents whose channel is unknown. Display only. /agent/v1 only; /anthropic neither returns it.
50308
50371
  */
50309
50372
  creation_source: string | null;
50373
+ /**
50374
+ * Application that manages this agent (for example praxis-work); null when no application does. Set when the agent is created, or claimed once by an update that sends the same value in the Praxis-Managed-By header; never changes after. Archiving a managed agent without the managing application's Praxis-Managed-By header returns 409 AGENT_MANAGED_BY_APPLICATION; configuration stays changeable. An accident guard, not a security boundary. /agent/v1 only; /anthropic neither returns it.
50375
+ */
50376
+ managed_by: string | null;
50310
50377
  /**
50311
50378
  * Platform-wide identity number of the agent (8 characters), usable wherever an agent is addressed by identity_number; null when the agent has none. /agent/v1 only; /anthropic neither returns it.
50312
50379
  */
@@ -51107,7 +51174,7 @@ export type UnarchiveAgentResponses = {
51107
51174
  */
51108
51175
  note: string | null;
51109
51176
  /**
51110
- * Platform resources and services this service agent's codemode may reach, as one list of typed bindings. Only kind=service accepts a nonempty list; general agents return 400. There are two kinds. A resource binding names one resource with id and access: database (id db_..., read_only or read_write), vector_store (id vs_..., read_only or read_write), file (id file- plus 24 letters or digits, as the File API returns it; read_only), media_library (any id without ':' or whitespace, read_only or read_write), model (a model catalog id, invoke), workflow and script (id <namespace>/<name>, invoke). A service binding opens one service, or one sub-tree of one, and carries only enabled: search, browser, ticket, crm, canvas, cut, studio, feedback or workspace. workspace opens development units — list one, read one, start, stop, exec inside one, fetch, push, connect, and open a unit for a change — and opens neither publishing nor any production operation. The ticket service is bound by default: a service agent whose list has no ticket entry may call the ticket API, and {"type": "ticket", "enabled": false} removes it. Every other service stays closed until it is bound. An open service allows every public method of that service. At most 20 bindings per type, no repeated type and id, and each service type at most once. A session is authorized by the agent version it runs: newly added bindings apply only to new sessions, and a version saved with apply=false changes no access until it is applied. Applying a version that disables, removes or downgrades a binding revokes it immediately in running sessions on older versions. A resource that is not bound returns 404, a service that is not opened returns 403, and a write to a resource bound read_only returns 403 BINDING_READ_ONLY. Unknown types, fields on the wrong kind (id, access or instructions on a service binding), wrong access and malformed ids return 400. The former databases, vector_stores and files fields are removed and return 400. Omit on create for the default: the ticket service only. Saving checks added or changed database, vector_store, media_library and file bindings in the organization: unknown or deleted ids return 400. If an owner is unavailable or takes more than 3 seconds, saving succeeds with verified=false for the affected bindings. Unchanged bindings keep their previous verification result and are not rechecked. workflow and script ids are not verified at save time.
51177
+ * Platform resources and services this service agent's codemode may reach, as one list of typed bindings. Only kind=service accepts a nonempty list; general agents return 400. There are two kinds. A resource binding names one resource with id and access: database (id db_..., read_only or read_write), vector_store (id vs_..., read_only or read_write), file (id file- plus 24 letters or digits, as the File API returns it; read_only), media_library (any id without ':' or whitespace, read_only or read_write), model (a model catalog id, invoke), workflow and script (id <namespace>/<name>, invoke). A resource binding may also carry customer_access (read_only by default): it caps what a terminal customer's session (a visitor, ADR-163 §3) may do with that one resource, at the intersection of customer_access and the binding's own access — invoke (call) and read_write (change) are different axes, so only a matching pair keeps its access and any other pair falls to read_only. Its value must be one the type can grant: read_only or read_write for database, vector_store and media_library, read_only for file, and read_only or invoke for model, workflow and script. A member's session ignores it, so raising it never widens what members may do. A visitor's session never receives a whole-service binding (the default ticket service included) or an agent resource. A service binding opens one service, or one sub-tree of one, and carries only enabled: search, browser, ticket, crm, canvas, cut, studio, feedback or workspace. workspace opens development units — list one, read one, start, stop, exec inside one, fetch, push, connect, and open a unit for a change — and opens neither publishing nor any production operation. The ticket service is bound by default: a service agent whose list has no ticket entry may call the ticket API, and {"type": "ticket", "enabled": false} removes it. Every other service stays closed until it is bound. An open service allows every public method of that service. At most 20 bindings per type, no repeated type and id, and each service type at most once. A session is authorized by the agent version it runs: newly added bindings apply only to new sessions, and a version saved with apply=false changes no access until it is applied. Applying a version that disables, removes or downgrades a binding revokes it immediately in running sessions on older versions. A resource that is not bound returns 404, a service that is not opened returns 403, and a write to a resource bound read_only returns 403 BINDING_READ_ONLY. Unknown types, fields on the wrong kind (id, access, customer_access or instructions on a service binding), wrong access and malformed ids return 400. The former databases, vector_stores and files fields are removed and return 400. Omit on create for the default: the ticket service only. Saving checks added or changed database, vector_store, media_library and file bindings in the organization: unknown or deleted ids return 400. If an owner is unavailable or takes more than 3 seconds, saving succeeds with verified=false for the affected bindings. Unchanged bindings keep their previous verification result and are not rechecked. workflow and script ids are not verified at save time.
51111
51178
  */
51112
51179
  bindings: Array<{
51113
51180
  /**
@@ -51122,6 +51189,10 @@ export type UnarchiveAgentResponses = {
51122
51189
  * database, vector_store and media_library accept read_only or read_write; file accepts read_only; model, workflow and script accept invoke. Any other combination returns 400.
51123
51190
  */
51124
51191
  access: 'read_only' | 'read_write' | 'invoke';
51192
+ /**
51193
+ * What a visitor's session (a terminal customer, ADR-163 §3) may do with this resource: read_only, read_write or invoke. Its scope is the intersection of this value and the binding's own access, so invoke needs both to be invoke. Limited to the accesses the type can grant: read_only or read_write for database, vector_store and media_library, read_only for file, read_only or invoke for model, workflow and script. Defaults to read_only. A member's session ignores it entirely; a visitor's session never receives a whole-service binding or an agent resource.
51194
+ */
51195
+ customer_access?: 'read_only' | 'read_write' | 'invoke';
51125
51196
  /**
51126
51197
  * Optional guidance for using this resource, up to 4096 characters; does not expand access.
51127
51198
  */
@@ -51546,6 +51617,10 @@ export type UnarchiveAgentResponses = {
51546
51617
  * Channel the agent was created through (for example api or console); null for historical agents whose channel is unknown. Display only. /agent/v1 only; /anthropic neither returns it.
51547
51618
  */
51548
51619
  creation_source: string | null;
51620
+ /**
51621
+ * Application that manages this agent (for example praxis-work); null when no application does. Set when the agent is created, or claimed once by an update that sends the same value in the Praxis-Managed-By header; never changes after. Archiving a managed agent without the managing application's Praxis-Managed-By header returns 409 AGENT_MANAGED_BY_APPLICATION; configuration stays changeable. An accident guard, not a security boundary. /agent/v1 only; /anthropic neither returns it.
51622
+ */
51623
+ managed_by: string | null;
51549
51624
  /**
51550
51625
  * Platform-wide identity number of the agent (8 characters), usable wherever an agent is addressed by identity_number; null when the agent has none. /agent/v1 only; /anthropic neither returns it.
51551
51626
  */
@@ -58246,28 +58321,25 @@ export type ForkSessionResponses = {
58246
58321
  };
58247
58322
  };
58248
58323
  export type ForkSessionResponse = ForkSessionResponses[keyof ForkSessionResponses];
58249
- export type UpdateSessionAgentVersionData = {
58250
- /**
58251
- * The version to move the session to; omit the body to move to the agent's active version.
58252
- */
58253
- body?: {
58324
+ export type RenameSessionData = {
58325
+ body: {
58254
58326
  /**
58255
- * An existing version of the session's agent, from agents.versions.list. Omit to use the agent's active version.
58327
+ * The session's new short name: Han characters, lowercase ASCII letters, digits and hyphens, at most 32 columns (a Han character counts as two), never the reserved word main. Surrounding whitespace is trimmed and uppercase is folded to lowercase.
58256
58328
  */
58257
- version?: number;
58329
+ name: string;
58258
58330
  };
58259
58331
  path: {
58260
58332
  /**
58261
- * Session id from session creation or listing, or the own face's session name for a main session.
58333
+ * Session id from session creation or listing. The reserved name main is not renameable.
58262
58334
  */
58263
58335
  session_id: string;
58264
58336
  };
58265
58337
  query?: never;
58266
- url: '/agent/v1/sessions/{session_id}/agent_version';
58338
+ url: '/agent/v1/sessions/{session_id}/name';
58267
58339
  };
58268
- export type UpdateSessionAgentVersionErrors = {
58340
+ export type RenameSessionErrors = {
58269
58341
  /**
58270
- * INVALID_PARAMS: version is not a positive integer.
58342
+ * INVALID_PARAMS: name is missing or empty, wider than the limit, carries a character the rule drops, or is the reserved main; the main session is always main and cannot be renamed.
58271
58343
  */
58272
58344
  400: unknown;
58273
58345
  /**
@@ -58275,17 +58347,13 @@ export type UpdateSessionAgentVersionErrors = {
58275
58347
  */
58276
58348
  401: unknown;
58277
58349
  /**
58278
- * FORBIDDEN: an embedded end user talks to an agent but never reconfigures the session it talks on, so it cannot change the agent version.
58350
+ * permission_error: the credential's role or bound resources do not allow this operation. Use a key with access to the agent domain and its resources.
58279
58351
  */
58280
- 403: unknown;
58352
+ 403: AgentError;
58281
58353
  /**
58282
- * Session not found or not writable by this caller; AGENT_VERSION_NOT_FOUND when the agent has no such version.
58354
+ * Session not found or not writable by this caller.
58283
58355
  */
58284
58356
  404: unknown;
58285
- /**
58286
- * SESSION_CONFLICT: the session is running a turn, so the version was not changed; retry once it is idle. SESSION_ARCHIVED: an archived session cannot be moved.
58287
- */
58288
- 409: unknown;
58289
58357
  /**
58290
58358
  * Agent service failed
58291
58359
  */
@@ -58295,9 +58363,10 @@ export type UpdateSessionAgentVersionErrors = {
58295
58363
  */
58296
58364
  503: unknown;
58297
58365
  };
58298
- export type UpdateSessionAgentVersionResponses = {
58366
+ export type RenameSessionError = RenameSessionErrors[keyof RenameSessionErrors];
58367
+ export type RenameSessionResponses = {
58299
58368
  /**
58300
- * The session, now on the requested version; an unchanged version answers the session as it stands and writes no event.
58369
+ * The session under its new name; a name another of this person's sessions already holds comes back with a numeric suffix.
58301
58370
  */
58302
58371
  200: {
58303
58372
  /**
@@ -59976,35 +60045,47 @@ export type UpdateSessionAgentVersionResponses = {
59976
60045
  readonly source: 'kit' | 'iframe' | 'hosted' | 'api' | 'automation' | null;
59977
60046
  };
59978
60047
  };
59979
- export type UpdateSessionAgentVersionResponse = UpdateSessionAgentVersionResponses[keyof UpdateSessionAgentVersionResponses];
59980
- export type ListSessionArtifactsData = {
59981
- body?: never;
60048
+ export type RenameSessionResponse = RenameSessionResponses[keyof RenameSessionResponses];
60049
+ export type UpdateSessionAgentVersionData = {
60050
+ /**
60051
+ * The version to move the session to; omit the body to move to the agent's active version.
60052
+ */
60053
+ body?: {
60054
+ /**
60055
+ * An existing version of the session's agent, from agents.versions.list. Omit to use the agent's active version.
60056
+ */
60057
+ version?: number;
60058
+ };
59982
60059
  path: {
59983
60060
  /**
59984
- * Session id from session creation or listing.
60061
+ * Session id from session creation or listing, or the own face's session name for a main session.
59985
60062
  */
59986
60063
  session_id: string;
59987
60064
  };
59988
60065
  query?: never;
59989
- url: '/agent/v1/sessions/{session_id}/artifacts';
60066
+ url: '/agent/v1/sessions/{session_id}/agent_version';
59990
60067
  };
59991
- export type ListSessionArtifactsErrors = {
60068
+ export type UpdateSessionAgentVersionErrors = {
59992
60069
  /**
59993
- * Invalid request: ttl_seconds outside 60 to 300, a negative part, or an unsupported field.
60070
+ * INVALID_PARAMS: version is not a positive integer.
59994
60071
  */
59995
60072
  400: unknown;
59996
60073
  /**
59997
- * Authenticate with an organization credential or a customer access token.
60074
+ * Authentication required.
59998
60075
  */
59999
60076
  401: unknown;
60000
60077
  /**
60001
- * permission_error: the credential's role or bound resources do not allow this operation. Use a key with access to the agent domain and its resources.
60078
+ * FORBIDDEN: an embedded end user talks to an agent but never reconfigures the session it talks on, so it cannot change the agent version.
60002
60079
  */
60003
- 403: AgentError;
60080
+ 403: unknown;
60004
60081
  /**
60005
- * Session not found or not readable by this caller.
60082
+ * Session not found or not writable by this caller; AGENT_VERSION_NOT_FOUND when the agent has no such version.
60006
60083
  */
60007
60084
  404: unknown;
60085
+ /**
60086
+ * SESSION_CONFLICT: the session is running a turn, so the version was not changed; retry once it is idle. SESSION_ARCHIVED: an archived session cannot be moved.
60087
+ */
60088
+ 409: unknown;
60008
60089
  /**
60009
60090
  * Agent service failed
60010
60091
  */
@@ -60014,332 +60095,2051 @@ export type ListSessionArtifactsErrors = {
60014
60095
  */
60015
60096
  503: unknown;
60016
60097
  };
60017
- export type ListSessionArtifactsError = ListSessionArtifactsErrors[keyof ListSessionArtifactsErrors];
60018
- export type ListSessionArtifactsResponses = {
60098
+ export type UpdateSessionAgentVersionResponses = {
60019
60099
  /**
60020
- * Artifacts this session delivered
60100
+ * The session, now on the requested version; an unchanged version answers the session as it stands and writes no event.
60021
60101
  */
60022
60102
  200: {
60023
60103
  /**
60024
- * Items of this page, in the order requested by the call.
60104
+ * Session id (sesn_...). Pass it as session_id in every session call.
60025
60105
  */
60026
- data: Array<{
60027
- /**
60028
- * Object type, always artifact.
60029
- */
60030
- object: 'artifact';
60106
+ id: string;
60107
+ /**
60108
+ * Resolved `agent` definition for a `session`. Snapshot of the `agent` at
60109
+ * `session` creation time.
60110
+ */
60111
+ agent: {
60031
60112
  /**
60032
- * Artifact id (art_...). Stays the same when the same path is delivered again.
60113
+ * Agent id (agent_...). Pass it as agent when creating a session and as agent_id in agent calls.
60033
60114
  */
60034
60115
  id: string;
60035
60116
  /**
60036
- * Id of the session.
60037
- */
60038
- session_id: string;
60039
- /**
60040
- * The run that produced this version; null when it cannot be told.
60041
- */
60042
- run_id: string | null;
60043
- /**
60044
- * Path of the file inside the session's outputs directory, such as report.pdf or charts/q3.png.
60045
- */
60046
- name: string;
60047
- /**
60048
- * 1 on first delivery; each later delivery of the same path with new content adds one.
60117
+ * Free-text description of what the agent is for; null when none was set.
60049
60118
  */
60050
- version: number;
60119
+ description: null | string;
60051
60120
  /**
60052
- * The files this artifact holds; the latest version's parts only.
60121
+ * Praxis extension: Streamable HTTP, SSE or trusted stdio MCP servers, persisted with the agent version. Optional fields remain omitted when not supplied.
60053
60122
  */
60054
- parts: Array<{
60123
+ mcp_servers: Array<{
60055
60124
  /**
60056
- * Part type: a file the agent placed in the session's outputs directory.
60125
+ * Streamable HTTP transport.
60057
60126
  */
60058
- kind: 'file';
60127
+ type: 'url';
60059
60128
  /**
60060
- * The file object this part points at; read its bytes through content_url, not through this id.
60129
+ * Name of the MCP server; the mcp_toolset entry that refers to it uses the same name in mcp_server_name.
60061
60130
  */
60062
- file_id: string;
60131
+ name: string;
60063
60132
  /**
60064
- * File name as stored, without the directory.
60133
+ * HTTP or HTTPS MCP server endpoint.
60065
60134
  */
60066
- filename: string;
60135
+ url: string;
60067
60136
  /**
60068
- * Media type of the file, decided from its extension.
60137
+ * Praxis extension: request headers. Platform identity headers take precedence, case-insensitively.
60069
60138
  */
60070
- mime_type: string;
60139
+ headers?: {
60140
+ [key: string]: string;
60141
+ };
60071
60142
  /**
60072
- * Size of the file in bytes; the downloaded content has exactly this length.
60143
+ * Praxis extension: timeout in milliseconds. Applied to stdio; HTTP/SSE currently use the connection SDK default.
60073
60144
  */
60074
- bytes: number;
60145
+ timeout_ms?: number;
60075
60146
  } | {
60076
60147
  /**
60077
- * Part type: a canvas or a media asset the agent's reply pointed at.
60148
+ * Legacy SSE transport.
60078
60149
  */
60079
- kind: 'object';
60150
+ type: 'sse';
60080
60151
  /**
60081
- * canvas is a design canvas, whose content_url is a snapshot picture of it; media_asset is an asset of a media library, whose content_url is its own bytes.
60152
+ * Name of the MCP server; the mcp_toolset entry that refers to it uses the same name in mcp_server_name.
60082
60153
  */
60083
- object_type: 'canvas' | 'media_asset';
60154
+ name: string;
60084
60155
  /**
60085
- * The object's id: cvs_... for a canvas, <library_id>/<asset_id> for a media asset.
60156
+ * HTTP or HTTPS MCP server endpoint.
60086
60157
  */
60087
- object_id: string;
60158
+ url: string;
60088
60159
  /**
60089
- * The address in the reply that pointed at the object, verbatim; open the object with content_url, not with this address.
60160
+ * Praxis extension: request headers. Platform identity headers take precedence, case-insensitively.
60090
60161
  */
60091
- href: string;
60162
+ headers?: {
60163
+ [key: string]: string;
60164
+ };
60092
60165
  /**
60093
- * What the reply called the object: the text of the link that carried the address, for a card to show. null when the address stood alone in the reply.
60166
+ * Praxis extension: timeout in milliseconds. Applied to stdio; HTTP/SSE currently use the connection SDK default.
60094
60167
  */
60095
- title: string | null;
60168
+ timeout_ms?: number;
60169
+ } | {
60170
+ /**
60171
+ * Run a command on the agent computer.
60172
+ */
60173
+ type: 'stdio';
60174
+ /**
60175
+ * Name of the MCP server; the mcp_toolset entry that refers to it uses the same name in mcp_server_name.
60176
+ */
60177
+ name: string;
60178
+ /**
60179
+ * Executable command on the agent computer.
60180
+ */
60181
+ command: string;
60182
+ /**
60183
+ * Command arguments; omitted means no arguments.
60184
+ */
60185
+ args?: Array<string>;
60186
+ /**
60187
+ * Praxis extension: environment variables for the command on the agent computer.
60188
+ */
60189
+ env?: {
60190
+ [key: string]: string;
60191
+ };
60192
+ /**
60193
+ * Praxis extension: timeout in milliseconds. Applied to stdio; HTTP/SSE currently use the connection SDK default.
60194
+ */
60195
+ timeout_ms?: number;
60096
60196
  }>;
60097
60197
  /**
60098
- * Link addresses from the reply text that point at this artifact, verbatim; render a link whose address equals one of these as this artifact.
60099
- */
60100
- source_hrefs: Array<string>;
60101
- /**
60102
- * When the artifact was first registered, RFC 3339; set by the service.
60103
- */
60104
- create_time: string;
60105
- /**
60106
- * When the latest version was registered, RFC 3339; equals create_time for version 1.
60107
- */
60108
- update_time: string;
60109
- }>;
60110
- };
60111
- };
60112
- export type ListSessionArtifactsResponse = ListSessionArtifactsResponses[keyof ListSessionArtifactsResponses];
60113
- export type CreateSessionArtifactContentUrlData = {
60114
- body?: {
60115
- /**
60116
- * Index into the artifact's parts; defaults to 0.
60117
- */
60118
- part?: number;
60119
- /**
60120
- * How long the address works, 60 to 300 seconds; defaults to 300.
60121
- */
60122
- ttl_seconds?: number;
60123
- };
60124
- path: {
60125
- /**
60126
- * Session id from session creation or listing.
60127
- */
60128
- session_id: string;
60129
- /**
60130
- * Artifact id (art_...) from the artifact list or an agent.artifact_delivered event.
60131
- */
60132
- artifact_id: string;
60133
- };
60134
- query?: never;
60135
- url: '/agent/v1/sessions/{session_id}/artifacts/{artifact_id}/content_url';
60136
- };
60137
- export type CreateSessionArtifactContentUrlErrors = {
60138
- /**
60139
- * Invalid request: ttl_seconds outside 60 to 300, a negative part, or an unsupported field.
60140
- */
60141
- 400: unknown;
60142
- /**
60143
- * Authenticate with an organization credential or a customer access token.
60144
- */
60145
- 401: unknown;
60146
- /**
60147
- * permission_error: the credential's role or bound resources do not allow this operation. Use a key with access to the agent domain and its resources.
60148
- */
60149
- 403: AgentError;
60150
- /**
60151
- * Session not found or not readable by this caller, or ARTIFACT_NOT_FOUND: no such artifact or part.
60152
- */
60153
- 404: unknown;
60154
- /**
60155
- * Agent service failed
60156
- */
60157
- 502: unknown;
60158
- /**
60159
- * Agent service unavailable
60160
- */
60161
- 503: unknown;
60162
- };
60163
- export type CreateSessionArtifactContentUrlError = CreateSessionArtifactContentUrlErrors[keyof CreateSessionArtifactContentUrlErrors];
60164
- export type CreateSessionArtifactContentUrlResponses = {
60165
- /**
60166
- * Short-lived download address
60167
- */
60168
- 200: {
60169
- /**
60170
- * Signed download address; fetch it within the lifetime and do not store it.
60171
- */
60172
- url: string;
60173
- /**
60174
- * When the address stops working, RFC 3339; at most 300 seconds after it was issued.
60175
- */
60176
- expire_time: string;
60177
- };
60178
- };
60179
- export type CreateSessionArtifactContentUrlResponse = CreateSessionArtifactContentUrlResponses[keyof CreateSessionArtifactContentUrlResponses];
60180
- export type ListSessionRequestsData = {
60181
- body?: never;
60182
- path: {
60183
- /**
60184
- * Session id from session creation or listing.
60185
- */
60186
- session_id: string;
60187
- };
60188
- query?: never;
60189
- url: '/agent/v1/sessions/{session_id}/requests';
60190
- };
60191
- export type ListSessionRequestsErrors = {
60192
- /**
60193
- * Unsupported query parameter.
60194
- */
60195
- 400: unknown;
60196
- /**
60197
- * Authenticate with an organization credential or a customer access token.
60198
- */
60199
- 401: unknown;
60200
- /**
60201
- * permission_error: the credential's role or bound resources do not allow this operation. Use a key with access to the agent domain and its resources.
60202
- */
60203
- 403: AgentError;
60204
- /**
60205
- * Session not found or not readable by this caller.
60206
- */
60207
- 404: unknown;
60208
- /**
60209
- * Agent service failed
60210
- */
60211
- 502: unknown;
60212
- /**
60213
- * Agent service unavailable
60214
- */
60215
- 503: unknown;
60216
- };
60217
- export type ListSessionRequestsError = ListSessionRequestsErrors[keyof ListSessionRequestsErrors];
60218
- export type ListSessionRequestsResponses = {
60219
- /**
60220
- * The requests this session waits on
60221
- */
60222
- 200: {
60223
- /**
60224
- * The requests the session waits on, oldest first; empty when it waits on nothing.
60225
- */
60226
- data: Array<{
60227
- /**
60228
- * The pending tool call's id (the tool_use id on the agent.tool_use event); answer it with a user.tool_confirmation event carrying this id as tool_use_id.
60229
- */
60230
- id: string;
60231
- /**
60232
- * Object type, always request.
60233
- */
60234
- object: 'request';
60235
- /**
60236
- * question when the agent asked through the ask_user_question tool and waits for an answer; approval when any other tool waits for permission.
60237
- */
60238
- kind: 'question' | 'approval';
60239
- /**
60240
- * Always pending: answered, expired and superseded requests are not listed.
60241
- */
60242
- status: 'pending';
60243
- /**
60244
- * The tool the agent called, such as ask_user_question or bash.
60245
- */
60246
- tool_name: string;
60247
- /**
60248
- * The tool call's input exactly as the agent.tool_use event shows it: for a question the questions and their options, for an approval the tool's arguments.
60249
- */
60250
- input: unknown;
60251
- /**
60252
- * When the call became pending, RFC 3339; the time of its agent.tool_use event.
60253
- */
60254
- create_time: string;
60255
- /**
60256
- * When the request expires and counts as declined, RFC 3339; null when it does not expire, which is every session that runs a collaboration mode and every session while the requests-v1 release is off.
60257
- */
60258
- expire_time: string | null;
60259
- }>;
60260
- };
60261
- };
60262
- export type ListSessionRequestsResponse = ListSessionRequestsResponses[keyof ListSessionRequestsResponses];
60263
- export type ListSessionBackgroundTasksData = {
60264
- body?: never;
60265
- path: {
60266
- /**
60267
- * Session id (sesn_...), as returned by sessions.create or sessions.list. In a path position the own face /agent/v1 also accepts `main` (your own main session with the agent) or a short session name, and either alias then requires the agent_id query parameter with the agent reference; /anthropic/v1 and the session_id query parameter on resource and thread calls take a real id only (the query value must equal the path value).
60268
- */
60269
- session_id: string;
60270
- };
60271
- query?: never;
60272
- url: '/agent/v1/sessions/{session_id}/background_tasks';
60273
- };
60274
- export type ListSessionBackgroundTasksErrors = {
60275
- /**
60276
- * Invalid request: this call accepts no query parameters, and any parameter that is present, unsupported or repeated returns 400. Remove the parameter and retry.
60277
- */
60278
- 400: unknown;
60279
- /**
60280
- * Authentication required
60281
- */
60282
- 401: unknown;
60283
- /**
60284
- * permission_error: the credential's role or bound resources do not allow this operation. Use a key with access to the agent domain and its resources.
60285
- */
60286
- 403: AgentError;
60287
- /**
60288
- * Session not found
60289
- */
60290
- 404: unknown;
60291
- /**
60292
- * Agent service failed
60293
- */
60294
- 502: unknown;
60295
- /**
60296
- * Agent service unavailable
60297
- */
60298
- 503: unknown;
60299
- };
60300
- export type ListSessionBackgroundTasksError = ListSessionBackgroundTasksErrors[keyof ListSessionBackgroundTasksErrors];
60301
- export type ListSessionBackgroundTasksResponses = {
60302
- /**
60303
- * Session background tasks
60304
- */
60305
- 200: {
60306
- /**
60307
- * Items of this page, in the order requested by the call.
60308
- */
60309
- data: Array<{
60310
- /**
60311
- * Identifier of the object, as returned by the API; pass it in the path of follow-up calls on the same resource.
60312
- */
60313
- id: string;
60314
- /**
60315
- * Kind of background task: bash for a command started with run_in_background, monitor for a monitor watch.
60316
- */
60317
- kind: string;
60318
- /**
60319
- * Short human-readable title of the task or object.
60320
- */
60321
- title: string;
60322
- /**
60323
- * Execution thread the task belongs to; null for the primary thread.
60324
- */
60325
- thread_id: string | null;
60326
- /**
60327
- * Current lifecycle state.
60328
- */
60329
- status: 'running' | 'result_pending' | 'completed' | 'failed' | 'cancelled' | 'lost';
60330
- /**
60331
- * RFC 3339 time at which the task started.
60332
- */
60333
- started_at: string;
60334
- /**
60335
- * RFC 3339 time at which the task ended; null while it is running.
60198
+ * Model identifier and configuration.
60336
60199
  */
60337
- ended_at: string | null;
60200
+ model: {
60201
+ /**
60202
+ * A model id from the Praxis model catalog (`praxis.model.models.list`). Unlike Anthropic, Claude model ids other than those in the catalog are rejected.
60203
+ */
60204
+ id: string;
60205
+ /**
60206
+ * How hard Claude works on each turn. Sets `output_config.effort` on every
60207
+ * Messages call the session makes.
60208
+ */
60209
+ effort?: {
60210
+ /**
60211
+ * Always `low`. Lowest reasoning effort of the supported levels.
60212
+ */
60213
+ type: 'low';
60214
+ } | {
60215
+ /**
60216
+ * Always `medium`. Middle reasoning effort.
60217
+ */
60218
+ type: 'medium';
60219
+ } | {
60220
+ /**
60221
+ * Always `high`. High reasoning effort.
60222
+ */
60223
+ type: 'high';
60224
+ } | {
60225
+ /**
60226
+ * Always `xhigh`. Extra-high reasoning effort, above high; only models that list it in thinking.efforts accept it.
60227
+ */
60228
+ type: 'xhigh';
60229
+ } | {
60230
+ /**
60231
+ * Always `max`. Maximum effort level of the Managed Agents shape, above xhigh.
60232
+ */
60233
+ type: 'max';
60234
+ };
60235
+ /**
60236
+ * Geographic region for model inference. When unset, requests fall through to the
60237
+ * workspace's default_inference_geo.
60238
+ */
60239
+ inference_geo?: string;
60240
+ /**
60241
+ * Inference speed mode. `fast` provides significantly faster output token
60242
+ * generation at premium pricing. Not all models support `fast`; invalid
60243
+ * combinations are rejected at create time.
60244
+ */
60245
+ speed?: 'standard' | 'fast';
60246
+ /**
60247
+ * Platform model settings: reasoning (default thinking level) and max_output_tokens (output cap). Other model controls return 400.
60248
+ */
60249
+ settings?: {
60250
+ /**
60251
+ * Default thinking effort for sessions without an explicit selection. Unsupported defaults fall back to the selected model default.
60252
+ */
60253
+ reasoning?: 'low' | 'medium' | 'high' | 'xhigh' | 'max' | 'none';
60254
+ /**
60255
+ * Output cap for one model request, thinking included; the counterpart of Claude Code's CLAUDE_CODE_MAX_OUTPUT_TOKENS. When unset, every request uses the output limit the model declares. When set, the runtime clamps it to the model's limit.
60256
+ */
60257
+ max_output_tokens?: number;
60258
+ };
60259
+ };
60338
60260
  /**
60339
- * Whether the task can still be stopped.
60261
+ * Resolved coordinator topology with full agent definitions for each roster
60262
+ * member.
60340
60263
  */
60341
- cancellable: boolean;
60342
- /**
60264
+ multiagent: null | {
60265
+ /**
60266
+ * Full `agent` definitions the coordinator may spawn as session threads.
60267
+ */
60268
+ agents: Array<{
60269
+ /**
60270
+ * The advisor model id.
60271
+ */
60272
+ model: string;
60273
+ /**
60274
+ * Always `advisor`. An advisor whose model is consulted for advice in a separate thread (at most one per coordinator).
60275
+ */
60276
+ type: 'advisor';
60277
+ } | {
60278
+ /**
60279
+ * Agent id (agent_...). Pass it as agent when creating a session and as agent_id in agent calls.
60280
+ */
60281
+ id: string;
60282
+ /**
60283
+ * Free-text description of what the agent is for; null when none was set.
60284
+ */
60285
+ description: null | string;
60286
+ /**
60287
+ * Praxis extension: Streamable HTTP, SSE or trusted stdio MCP servers, persisted with the agent version. Optional fields remain omitted when not supplied.
60288
+ */
60289
+ mcp_servers: Array<{
60290
+ /**
60291
+ * Streamable HTTP transport.
60292
+ */
60293
+ type: 'url';
60294
+ /**
60295
+ * Name of the MCP server; the mcp_toolset entry that refers to it uses the same name in mcp_server_name.
60296
+ */
60297
+ name: string;
60298
+ /**
60299
+ * HTTP or HTTPS MCP server endpoint.
60300
+ */
60301
+ url: string;
60302
+ /**
60303
+ * Praxis extension: request headers. Platform identity headers take precedence, case-insensitively.
60304
+ */
60305
+ headers?: {
60306
+ [key: string]: string;
60307
+ };
60308
+ /**
60309
+ * Praxis extension: timeout in milliseconds. Applied to stdio; HTTP/SSE currently use the connection SDK default.
60310
+ */
60311
+ timeout_ms?: number;
60312
+ } | {
60313
+ /**
60314
+ * Legacy SSE transport.
60315
+ */
60316
+ type: 'sse';
60317
+ /**
60318
+ * Name of the MCP server; the mcp_toolset entry that refers to it uses the same name in mcp_server_name.
60319
+ */
60320
+ name: string;
60321
+ /**
60322
+ * HTTP or HTTPS MCP server endpoint.
60323
+ */
60324
+ url: string;
60325
+ /**
60326
+ * Praxis extension: request headers. Platform identity headers take precedence, case-insensitively.
60327
+ */
60328
+ headers?: {
60329
+ [key: string]: string;
60330
+ };
60331
+ /**
60332
+ * Praxis extension: timeout in milliseconds. Applied to stdio; HTTP/SSE currently use the connection SDK default.
60333
+ */
60334
+ timeout_ms?: number;
60335
+ } | {
60336
+ /**
60337
+ * Run a command on the agent computer.
60338
+ */
60339
+ type: 'stdio';
60340
+ /**
60341
+ * Name of the MCP server; the mcp_toolset entry that refers to it uses the same name in mcp_server_name.
60342
+ */
60343
+ name: string;
60344
+ /**
60345
+ * Executable command on the agent computer.
60346
+ */
60347
+ command: string;
60348
+ /**
60349
+ * Command arguments; omitted means no arguments.
60350
+ */
60351
+ args?: Array<string>;
60352
+ /**
60353
+ * Praxis extension: environment variables for the command on the agent computer.
60354
+ */
60355
+ env?: {
60356
+ [key: string]: string;
60357
+ };
60358
+ /**
60359
+ * Praxis extension: timeout in milliseconds. Applied to stdio; HTTP/SSE currently use the connection SDK default.
60360
+ */
60361
+ timeout_ms?: number;
60362
+ }>;
60363
+ /**
60364
+ * Model identifier and configuration.
60365
+ */
60366
+ model: {
60367
+ /**
60368
+ * A model id from the Praxis model catalog (`praxis.model.models.list`). Unlike Anthropic, Claude model ids other than those in the catalog are rejected.
60369
+ */
60370
+ id: string;
60371
+ /**
60372
+ * How hard Claude works on each turn. Sets `output_config.effort` on every
60373
+ * Messages call the session makes.
60374
+ */
60375
+ effort?: {
60376
+ /**
60377
+ * Always `low`. Lowest reasoning effort of the supported levels.
60378
+ */
60379
+ type: 'low';
60380
+ } | {
60381
+ /**
60382
+ * Always `medium`. Middle reasoning effort.
60383
+ */
60384
+ type: 'medium';
60385
+ } | {
60386
+ /**
60387
+ * Always `high`. High reasoning effort.
60388
+ */
60389
+ type: 'high';
60390
+ } | {
60391
+ /**
60392
+ * Always `xhigh`. Extra-high reasoning effort, above high; only models that list it in thinking.efforts accept it.
60393
+ */
60394
+ type: 'xhigh';
60395
+ } | {
60396
+ /**
60397
+ * Always `max`. Maximum effort level of the Managed Agents shape, above xhigh.
60398
+ */
60399
+ type: 'max';
60400
+ };
60401
+ /**
60402
+ * Geographic region for model inference. When unset, requests fall through to the
60403
+ * workspace's default_inference_geo.
60404
+ */
60405
+ inference_geo?: string;
60406
+ /**
60407
+ * Inference speed mode. `fast` provides significantly faster output token
60408
+ * generation at premium pricing. Not all models support `fast`; invalid
60409
+ * combinations are rejected at create time.
60410
+ */
60411
+ speed?: 'standard' | 'fast';
60412
+ };
60413
+ /**
60414
+ * Display name of the agent, as set on create or update. It is a label, not a unique key.
60415
+ */
60416
+ name: string;
60417
+ /**
60418
+ * Custom skills attached to the agent, each {type: "custom", skill_id, version?}: skill_id comes from skills.create or skills.list, at most 20 skills, no repeated skill_id. Omit version, or send "latest", to use the skill's newest version at the moment a session starts; a pinned version stays fixed. type anthropic returns 400: upload the skill and attach it as custom. On update, omit the field to keep the list, send an array to replace it, or send [] or null to clear it.
60419
+ */
60420
+ skills: Array<{
60421
+ /**
60422
+ * Id of the skill to attach.
60423
+ */
60424
+ skill_id: string;
60425
+ /**
60426
+ * Always `anthropic`. A skill provided by Anthropic, identified by skill_id.
60427
+ */
60428
+ type: 'anthropic';
60429
+ /**
60430
+ * Version of the skill: omit or `latest` to follow the newest version at each new session; give a version id to pin it.
60431
+ */
60432
+ version: string;
60433
+ } | {
60434
+ /**
60435
+ * Id of the skill to attach.
60436
+ */
60437
+ skill_id: string;
60438
+ /**
60439
+ * Always `custom`. A skill created by you, identified by skill_id.
60440
+ */
60441
+ type: 'custom';
60442
+ /**
60443
+ * Version of the skill: omit or `latest` to follow the newest version at each new session; give a version id to pin it.
60444
+ */
60445
+ version: string;
60446
+ }>;
60447
+ /**
60448
+ * System prompt given to the model at the start of every session of this agent; null when none was set.
60449
+ */
60450
+ system: null | string;
60451
+ /**
60452
+ * Tools of the agent: one agent_toolset_20260401 entry for the native tools (all resolved settings are returned, ready to send back on update), plus mcp_toolset entries and custom tool definitions. Custom calls emit agent.custom_tool_use and wait for user.custom_tool_result. Keep bash enabled to use codemode, skill and subagents.
60453
+ */
60454
+ tools: Array<{
60455
+ /**
60456
+ * Per-tool settings that override default_config. Tools that are not listed follow default_config.
60457
+ */
60458
+ configs: Array<{
60459
+ /**
60460
+ * Whether the tool is offered to the model. Null or omitted means the toolset default applies (enabled unless default_config says otherwise).
60461
+ */
60462
+ enabled: boolean;
60463
+ /**
60464
+ * Name of the native tool this entry configures.
60465
+ */
60466
+ name: 'bash';
60467
+ /**
60468
+ * Permission policy for tool execution.
60469
+ */
60470
+ permission_policy: {
60471
+ /**
60472
+ * Always `always_allow`. Calls run without asking.
60473
+ */
60474
+ type: 'always_allow';
60475
+ } | {
60476
+ /**
60477
+ * Always `always_ask`. Calls wait for user.tool_confirmation before running.
60478
+ */
60479
+ type: 'always_ask';
60480
+ } | {
60481
+ /**
60482
+ * Always `auto`. Reserved: a server-side judgement per call. Not yet supported; sending it returns 400.
60483
+ */
60484
+ type: 'auto';
60485
+ };
60486
+ /**
60487
+ * Always `bash`. Selects the bash tool, which runs shell commands in the session's machine.
60488
+ */
60489
+ type: 'bash';
60490
+ } | {
60491
+ /**
60492
+ * Whether the tool is offered to the model. Null or omitted means the toolset default applies (enabled unless default_config says otherwise).
60493
+ */
60494
+ enabled: boolean;
60495
+ /**
60496
+ * Name of the native tool this entry configures.
60497
+ */
60498
+ name: 'edit';
60499
+ /**
60500
+ * Permission policy for tool execution.
60501
+ */
60502
+ permission_policy: {
60503
+ /**
60504
+ * Always `always_allow`. Calls run without asking.
60505
+ */
60506
+ type: 'always_allow';
60507
+ } | {
60508
+ /**
60509
+ * Always `always_ask`. Calls wait for user.tool_confirmation before running.
60510
+ */
60511
+ type: 'always_ask';
60512
+ } | {
60513
+ /**
60514
+ * Always `auto`. Reserved: a server-side judgement per call. Not yet supported; sending it returns 400.
60515
+ */
60516
+ type: 'auto';
60517
+ };
60518
+ /**
60519
+ * Always `edit`. Selects the edit tool, which changes an existing file.
60520
+ */
60521
+ type: 'edit';
60522
+ } | {
60523
+ /**
60524
+ * Whether the tool is offered to the model. Null or omitted means the toolset default applies (enabled unless default_config says otherwise).
60525
+ */
60526
+ enabled: boolean;
60527
+ /**
60528
+ * Name of the native tool this entry configures.
60529
+ */
60530
+ name: 'read';
60531
+ /**
60532
+ * Permission policy for tool execution.
60533
+ */
60534
+ permission_policy: {
60535
+ /**
60536
+ * Always `always_allow`. Calls run without asking.
60537
+ */
60538
+ type: 'always_allow';
60539
+ } | {
60540
+ /**
60541
+ * Always `always_ask`. Calls wait for user.tool_confirmation before running.
60542
+ */
60543
+ type: 'always_ask';
60544
+ } | {
60545
+ /**
60546
+ * Always `auto`. Reserved: a server-side judgement per call. Not yet supported; sending it returns 400.
60547
+ */
60548
+ type: 'auto';
60549
+ };
60550
+ /**
60551
+ * Always `read`. Selects the read tool, which reads a file.
60552
+ */
60553
+ type: 'read';
60554
+ } | {
60555
+ /**
60556
+ * Whether the tool is offered to the model. Null or omitted means the toolset default applies (enabled unless default_config says otherwise).
60557
+ */
60558
+ enabled: boolean;
60559
+ /**
60560
+ * Name of the native tool this entry configures.
60561
+ */
60562
+ name: 'write';
60563
+ /**
60564
+ * Permission policy for tool execution.
60565
+ */
60566
+ permission_policy: {
60567
+ /**
60568
+ * Always `always_allow`. Calls run without asking.
60569
+ */
60570
+ type: 'always_allow';
60571
+ } | {
60572
+ /**
60573
+ * Always `always_ask`. Calls wait for user.tool_confirmation before running.
60574
+ */
60575
+ type: 'always_ask';
60576
+ } | {
60577
+ /**
60578
+ * Always `auto`. Reserved: a server-side judgement per call. Not yet supported; sending it returns 400.
60579
+ */
60580
+ type: 'auto';
60581
+ };
60582
+ /**
60583
+ * Always `write`. Selects the write tool, which writes a file.
60584
+ */
60585
+ type: 'write';
60586
+ } | {
60587
+ /**
60588
+ * Whether the tool is offered to the model. Null or omitted means the toolset default applies (enabled unless default_config says otherwise).
60589
+ */
60590
+ enabled: boolean;
60591
+ /**
60592
+ * Name of the native tool this entry configures.
60593
+ */
60594
+ name: 'glob';
60595
+ /**
60596
+ * Permission policy for tool execution.
60597
+ */
60598
+ permission_policy: {
60599
+ /**
60600
+ * Always `always_allow`. Calls run without asking.
60601
+ */
60602
+ type: 'always_allow';
60603
+ } | {
60604
+ /**
60605
+ * Always `always_ask`. Calls wait for user.tool_confirmation before running.
60606
+ */
60607
+ type: 'always_ask';
60608
+ } | {
60609
+ /**
60610
+ * Always `auto`. Reserved: a server-side judgement per call. Not yet supported; sending it returns 400.
60611
+ */
60612
+ type: 'auto';
60613
+ };
60614
+ /**
60615
+ * Always `glob`. Selects the glob tool, which finds files by name pattern.
60616
+ */
60617
+ type: 'glob';
60618
+ } | {
60619
+ /**
60620
+ * Whether the tool is offered to the model. Null or omitted means the toolset default applies (enabled unless default_config says otherwise).
60621
+ */
60622
+ enabled: boolean;
60623
+ /**
60624
+ * Name of the native tool this entry configures.
60625
+ */
60626
+ name: 'grep';
60627
+ /**
60628
+ * Permission policy for tool execution.
60629
+ */
60630
+ permission_policy: {
60631
+ /**
60632
+ * Always `always_allow`. Calls run without asking.
60633
+ */
60634
+ type: 'always_allow';
60635
+ } | {
60636
+ /**
60637
+ * Always `always_ask`. Calls wait for user.tool_confirmation before running.
60638
+ */
60639
+ type: 'always_ask';
60640
+ } | {
60641
+ /**
60642
+ * Always `auto`. Reserved: a server-side judgement per call. Not yet supported; sending it returns 400.
60643
+ */
60644
+ type: 'auto';
60645
+ };
60646
+ /**
60647
+ * Always `grep`. Selects the grep tool, which searches file contents.
60648
+ */
60649
+ type: 'grep';
60650
+ } | {
60651
+ /**
60652
+ * Whether the tool is offered to the model. Null or omitted means the toolset default applies (enabled unless default_config says otherwise).
60653
+ */
60654
+ enabled: boolean;
60655
+ /**
60656
+ * Name of the native tool this entry configures.
60657
+ */
60658
+ name: 'web_fetch';
60659
+ /**
60660
+ * Permission policy for tool execution.
60661
+ */
60662
+ permission_policy: {
60663
+ /**
60664
+ * Always `always_allow`. Calls run without asking.
60665
+ */
60666
+ type: 'always_allow';
60667
+ } | {
60668
+ /**
60669
+ * Always `always_ask`. Calls wait for user.tool_confirmation before running.
60670
+ */
60671
+ type: 'always_ask';
60672
+ } | {
60673
+ /**
60674
+ * Always `auto`. Reserved: a server-side judgement per call. Not yet supported; sending it returns 400.
60675
+ */
60676
+ type: 'auto';
60677
+ };
60678
+ /**
60679
+ * Always `web_fetch`. Selects the web_fetch tool, which fetches a web page.
60680
+ */
60681
+ type: 'web_fetch';
60682
+ /**
60683
+ * Hosts the tool may fetch or search, as plain hostnames (no scheme, port or path); a listed domain also covers its subdomains. At most 64 entries, and it cannot be combined with blocked_domains.
60684
+ */
60685
+ allowed_domains?: Array<string>;
60686
+ /**
60687
+ * Hosts the tool must never fetch or search, as plain hostnames (no scheme, port or path); a listed domain also covers its subdomains. At most 64 entries, and it cannot be combined with allowed_domains.
60688
+ */
60689
+ blocked_domains?: Array<string>;
60690
+ /**
60691
+ * Maximum number of tokens of fetched text content included in context per call; does not apply to binary content such as PDFs. Null for no explicit limit.
60692
+ */
60693
+ max_content_tokens?: null | number;
60694
+ } | {
60695
+ /**
60696
+ * Whether the tool is offered to the model. Null or omitted means the toolset default applies (enabled unless default_config says otherwise).
60697
+ */
60698
+ enabled: boolean;
60699
+ /**
60700
+ * Name of the native tool this entry configures.
60701
+ */
60702
+ name: 'web_search';
60703
+ /**
60704
+ * Permission policy for tool execution.
60705
+ */
60706
+ permission_policy: {
60707
+ /**
60708
+ * Always `always_allow`. Calls run without asking.
60709
+ */
60710
+ type: 'always_allow';
60711
+ } | {
60712
+ /**
60713
+ * Always `always_ask`. Calls wait for user.tool_confirmation before running.
60714
+ */
60715
+ type: 'always_ask';
60716
+ } | {
60717
+ /**
60718
+ * Always `auto`. Reserved: a server-side judgement per call. Not yet supported; sending it returns 400.
60719
+ */
60720
+ type: 'auto';
60721
+ };
60722
+ /**
60723
+ * Always `web_search`. Selects the web_search tool, which searches the web.
60724
+ */
60725
+ type: 'web_search';
60726
+ /**
60727
+ * Hosts the tool may fetch or search, as plain hostnames (no scheme, port or path); a listed domain also covers its subdomains. At most 64 entries, and it cannot be combined with blocked_domains.
60728
+ */
60729
+ allowed_domains?: Array<string>;
60730
+ /**
60731
+ * Hosts the tool must never fetch or search, as plain hostnames (no scheme, port or path); a listed domain also covers its subdomains. At most 64 entries, and it cannot be combined with allowed_domains.
60732
+ */
60733
+ blocked_domains?: Array<string>;
60734
+ /**
60735
+ * Approximate user location for search result localization.
60736
+ */
60737
+ user_location?: null | {
60738
+ /**
60739
+ * Location precision. Only "approximate" is supported.
60740
+ */
60741
+ type: 'approximate';
60742
+ /**
60743
+ * City name.
60744
+ */
60745
+ city?: null | string;
60746
+ /**
60747
+ * Two-letter ISO 3166-1 country code, uppercase.
60748
+ */
60749
+ country?: null | string;
60750
+ /**
60751
+ * Region or state name.
60752
+ */
60753
+ region?: null | string;
60754
+ /**
60755
+ * IANA timezone identifier, e.g. "America/Los_Angeles".
60756
+ */
60757
+ timezone?: null | string;
60758
+ };
60759
+ } | {
60760
+ /**
60761
+ * Name of the native tool this entry configures.
60762
+ */
60763
+ name: 'task_output' | 'task_stop' | 'monitor' | 'agent' | 'send_message' | 'codemode' | 'skill';
60764
+ /**
60765
+ * Whether the tool is offered to the model. Null or omitted means the toolset default applies (enabled unless default_config says otherwise).
60766
+ */
60767
+ enabled: boolean;
60768
+ /**
60769
+ * Whether a call to this tool runs automatically (always_allow) or waits for user.tool_confirmation (always_ask). Omitted means the toolset default.
60770
+ */
60771
+ permission_policy: {
60772
+ /**
60773
+ * Permission policy kind.
60774
+ */
60775
+ type: 'always_allow' | 'always_ask';
60776
+ };
60777
+ }>;
60778
+ /**
60779
+ * Resolved default configuration for agent tools.
60780
+ */
60781
+ default_config: {
60782
+ /**
60783
+ * Whether tools of the toolset are offered to the model when configs does not name them. Null or omitted means enabled.
60784
+ */
60785
+ enabled: boolean;
60786
+ /**
60787
+ * Permission policy for tool execution.
60788
+ */
60789
+ permission_policy: {
60790
+ /**
60791
+ * Always `always_allow`. Calls run without asking.
60792
+ */
60793
+ type: 'always_allow';
60794
+ } | {
60795
+ /**
60796
+ * Always `always_ask`. Calls wait for user.tool_confirmation before running.
60797
+ */
60798
+ type: 'always_ask';
60799
+ } | {
60800
+ /**
60801
+ * Always `auto`. Reserved: a server-side judgement per call. Not yet supported; sending it returns 400.
60802
+ */
60803
+ type: 'auto';
60804
+ };
60805
+ };
60806
+ /**
60807
+ * Always `agent_toolset_20260401`. The native toolset entry (bash, edit, glob, grep, read, write, web_search, web_fetch, task_output, task_stop, monitor, agent, send_message).
60808
+ */
60809
+ type: 'agent_toolset_20260401';
60810
+ } | {
60811
+ /**
60812
+ * Always `mcp_toolset`. An entry that exposes the tools of one MCP server from mcp_servers.
60813
+ */
60814
+ type: 'mcp_toolset';
60815
+ /**
60816
+ * Name of the MCP server in mcp_servers whose tools this entry exposes.
60817
+ */
60818
+ mcp_server_name: string;
60819
+ /**
60820
+ * Settings applied to every tool of this toolset that configs does not name. When omitted, tools are enabled with the always_allow policy.
60821
+ */
60822
+ default_config?: {
60823
+ /**
60824
+ * Whether tools of the toolset are offered to the model when configs does not name them. Null or omitted means enabled.
60825
+ */
60826
+ enabled?: boolean | null;
60827
+ /**
60828
+ * Permission policy for tools that configs does not name: always_allow runs calls automatically, always_ask waits for user.tool_confirmation.
60829
+ */
60830
+ permission_policy?: null | {
60831
+ /**
60832
+ * Permission policy kind.
60833
+ */
60834
+ type: 'always_allow' | 'always_ask';
60835
+ };
60836
+ } | null;
60837
+ /**
60838
+ * Per-tool settings that override default_config. Tools that are not listed follow default_config.
60839
+ */
60840
+ configs?: Array<{
60841
+ /**
60842
+ * Bare tool name reported by the MCP server.
60843
+ */
60844
+ name: string;
60845
+ /**
60846
+ * Whether the tool is offered to the model. Null or omitted means the toolset default applies (enabled unless default_config says otherwise).
60847
+ */
60848
+ enabled?: boolean | null;
60849
+ /**
60850
+ * Whether a call to this tool runs automatically (always_allow) or waits for user.tool_confirmation (always_ask). Omitted means the toolset default.
60851
+ */
60852
+ permission_policy?: null | {
60853
+ /**
60854
+ * Permission policy kind.
60855
+ */
60856
+ type: 'always_allow' | 'always_ask';
60857
+ };
60858
+ }> | null;
60859
+ } | {
60860
+ /**
60861
+ * What the custom tool does and when the model should call it.
60862
+ */
60863
+ description: string;
60864
+ /**
60865
+ * JSON Schema for custom tool input parameters.
60866
+ */
60867
+ input_schema: {
60868
+ /**
60869
+ * Always `object`. The input is a JSON object.
60870
+ */
60871
+ type: 'object';
60872
+ /**
60873
+ * JSON Schema of each input property, keyed by property name.
60874
+ */
60875
+ properties?: null | {
60876
+ [key: string]: unknown;
60877
+ };
60878
+ /**
60879
+ * Names of the input properties the model must supply.
60880
+ */
60881
+ required?: null | Array<string>;
60882
+ [key: string]: unknown;
60883
+ };
60884
+ /**
60885
+ * Name of the custom tool, as the model sees and calls it.
60886
+ */
60887
+ name: string;
60888
+ /**
60889
+ * Always `custom`. A custom tool defined by name, description and input_schema; its calls are answered by the client with user.custom_tool_result.
60890
+ */
60891
+ type: 'custom';
60892
+ }>;
60893
+ /**
60894
+ * Always `agent`. A roster member that refers to an agent by id and pinned version.
60895
+ */
60896
+ type: 'agent';
60897
+ /**
60898
+ * The latest saved version of the agent, the editable head; it differs from active_version after a save with apply false. Starts at 1 and increments each time the agent is modified.
60899
+ */
60900
+ version: number;
60901
+ }>;
60902
+ /**
60903
+ * Always `coordinator`. The agent coordinates the roster in agents and can delegate to its members.
60904
+ */
60905
+ type: 'coordinator';
60906
+ };
60907
+ /**
60908
+ * Display name of the agent, as set on create or update. It is a label, not a unique key.
60909
+ */
60910
+ name: string;
60911
+ /**
60912
+ * Custom skills attached to the agent, each {type: "custom", skill_id, version?}: skill_id comes from skills.create or skills.list, at most 20 skills, no repeated skill_id. Omit version, or send "latest", to use the skill's newest version at the moment a session starts; a pinned version stays fixed. type anthropic returns 400: upload the skill and attach it as custom. On update, omit the field to keep the list, send an array to replace it, or send [] or null to clear it.
60913
+ */
60914
+ skills: Array<{
60915
+ /**
60916
+ * Id of the skill to attach.
60917
+ */
60918
+ skill_id: string;
60919
+ /**
60920
+ * Always `anthropic`. A skill provided by Anthropic, identified by skill_id.
60921
+ */
60922
+ type: 'anthropic';
60923
+ /**
60924
+ * Version of the skill: omit or `latest` to follow the newest version at each new session; give a version id to pin it.
60925
+ */
60926
+ version: string;
60927
+ } | {
60928
+ /**
60929
+ * Id of the skill to attach.
60930
+ */
60931
+ skill_id: string;
60932
+ /**
60933
+ * Always `custom`. A skill created by you, identified by skill_id.
60934
+ */
60935
+ type: 'custom';
60936
+ /**
60937
+ * Version of the skill: omit or `latest` to follow the newest version at each new session; give a version id to pin it.
60938
+ */
60939
+ version: string;
60940
+ }>;
60941
+ /**
60942
+ * System prompt given to the model at the start of every session of this agent; null when none was set.
60943
+ */
60944
+ system: null | string;
60945
+ /**
60946
+ * Tools of the agent: one agent_toolset_20260401 entry for the native tools (all resolved settings are returned, ready to send back on update), plus mcp_toolset entries and custom tool definitions. Custom calls emit agent.custom_tool_use and wait for user.custom_tool_result. Keep bash enabled to use codemode, skill and subagents.
60947
+ */
60948
+ tools: Array<{
60949
+ /**
60950
+ * Per-tool settings that override default_config. Tools that are not listed follow default_config.
60951
+ */
60952
+ configs: Array<{
60953
+ /**
60954
+ * Whether the tool is offered to the model. Null or omitted means the toolset default applies (enabled unless default_config says otherwise).
60955
+ */
60956
+ enabled: boolean;
60957
+ /**
60958
+ * Name of the native tool this entry configures.
60959
+ */
60960
+ name: 'bash';
60961
+ /**
60962
+ * Permission policy for tool execution.
60963
+ */
60964
+ permission_policy: {
60965
+ /**
60966
+ * Always `always_allow`. Calls run without asking.
60967
+ */
60968
+ type: 'always_allow';
60969
+ } | {
60970
+ /**
60971
+ * Always `always_ask`. Calls wait for user.tool_confirmation before running.
60972
+ */
60973
+ type: 'always_ask';
60974
+ } | {
60975
+ /**
60976
+ * Always `auto`. Reserved: a server-side judgement per call. Not yet supported; sending it returns 400.
60977
+ */
60978
+ type: 'auto';
60979
+ };
60980
+ /**
60981
+ * Always `bash`. Selects the bash tool, which runs shell commands in the session's machine.
60982
+ */
60983
+ type: 'bash';
60984
+ } | {
60985
+ /**
60986
+ * Whether the tool is offered to the model. Null or omitted means the toolset default applies (enabled unless default_config says otherwise).
60987
+ */
60988
+ enabled: boolean;
60989
+ /**
60990
+ * Name of the native tool this entry configures.
60991
+ */
60992
+ name: 'edit';
60993
+ /**
60994
+ * Permission policy for tool execution.
60995
+ */
60996
+ permission_policy: {
60997
+ /**
60998
+ * Always `always_allow`. Calls run without asking.
60999
+ */
61000
+ type: 'always_allow';
61001
+ } | {
61002
+ /**
61003
+ * Always `always_ask`. Calls wait for user.tool_confirmation before running.
61004
+ */
61005
+ type: 'always_ask';
61006
+ } | {
61007
+ /**
61008
+ * Always `auto`. Reserved: a server-side judgement per call. Not yet supported; sending it returns 400.
61009
+ */
61010
+ type: 'auto';
61011
+ };
61012
+ /**
61013
+ * Always `edit`. Selects the edit tool, which changes an existing file.
61014
+ */
61015
+ type: 'edit';
61016
+ } | {
61017
+ /**
61018
+ * Whether the tool is offered to the model. Null or omitted means the toolset default applies (enabled unless default_config says otherwise).
61019
+ */
61020
+ enabled: boolean;
61021
+ /**
61022
+ * Name of the native tool this entry configures.
61023
+ */
61024
+ name: 'read';
61025
+ /**
61026
+ * Permission policy for tool execution.
61027
+ */
61028
+ permission_policy: {
61029
+ /**
61030
+ * Always `always_allow`. Calls run without asking.
61031
+ */
61032
+ type: 'always_allow';
61033
+ } | {
61034
+ /**
61035
+ * Always `always_ask`. Calls wait for user.tool_confirmation before running.
61036
+ */
61037
+ type: 'always_ask';
61038
+ } | {
61039
+ /**
61040
+ * Always `auto`. Reserved: a server-side judgement per call. Not yet supported; sending it returns 400.
61041
+ */
61042
+ type: 'auto';
61043
+ };
61044
+ /**
61045
+ * Always `read`. Selects the read tool, which reads a file.
61046
+ */
61047
+ type: 'read';
61048
+ } | {
61049
+ /**
61050
+ * Whether the tool is offered to the model. Null or omitted means the toolset default applies (enabled unless default_config says otherwise).
61051
+ */
61052
+ enabled: boolean;
61053
+ /**
61054
+ * Name of the native tool this entry configures.
61055
+ */
61056
+ name: 'write';
61057
+ /**
61058
+ * Permission policy for tool execution.
61059
+ */
61060
+ permission_policy: {
61061
+ /**
61062
+ * Always `always_allow`. Calls run without asking.
61063
+ */
61064
+ type: 'always_allow';
61065
+ } | {
61066
+ /**
61067
+ * Always `always_ask`. Calls wait for user.tool_confirmation before running.
61068
+ */
61069
+ type: 'always_ask';
61070
+ } | {
61071
+ /**
61072
+ * Always `auto`. Reserved: a server-side judgement per call. Not yet supported; sending it returns 400.
61073
+ */
61074
+ type: 'auto';
61075
+ };
61076
+ /**
61077
+ * Always `write`. Selects the write tool, which writes a file.
61078
+ */
61079
+ type: 'write';
61080
+ } | {
61081
+ /**
61082
+ * Whether the tool is offered to the model. Null or omitted means the toolset default applies (enabled unless default_config says otherwise).
61083
+ */
61084
+ enabled: boolean;
61085
+ /**
61086
+ * Name of the native tool this entry configures.
61087
+ */
61088
+ name: 'glob';
61089
+ /**
61090
+ * Permission policy for tool execution.
61091
+ */
61092
+ permission_policy: {
61093
+ /**
61094
+ * Always `always_allow`. Calls run without asking.
61095
+ */
61096
+ type: 'always_allow';
61097
+ } | {
61098
+ /**
61099
+ * Always `always_ask`. Calls wait for user.tool_confirmation before running.
61100
+ */
61101
+ type: 'always_ask';
61102
+ } | {
61103
+ /**
61104
+ * Always `auto`. Reserved: a server-side judgement per call. Not yet supported; sending it returns 400.
61105
+ */
61106
+ type: 'auto';
61107
+ };
61108
+ /**
61109
+ * Always `glob`. Selects the glob tool, which finds files by name pattern.
61110
+ */
61111
+ type: 'glob';
61112
+ } | {
61113
+ /**
61114
+ * Whether the tool is offered to the model. Null or omitted means the toolset default applies (enabled unless default_config says otherwise).
61115
+ */
61116
+ enabled: boolean;
61117
+ /**
61118
+ * Name of the native tool this entry configures.
61119
+ */
61120
+ name: 'grep';
61121
+ /**
61122
+ * Permission policy for tool execution.
61123
+ */
61124
+ permission_policy: {
61125
+ /**
61126
+ * Always `always_allow`. Calls run without asking.
61127
+ */
61128
+ type: 'always_allow';
61129
+ } | {
61130
+ /**
61131
+ * Always `always_ask`. Calls wait for user.tool_confirmation before running.
61132
+ */
61133
+ type: 'always_ask';
61134
+ } | {
61135
+ /**
61136
+ * Always `auto`. Reserved: a server-side judgement per call. Not yet supported; sending it returns 400.
61137
+ */
61138
+ type: 'auto';
61139
+ };
61140
+ /**
61141
+ * Always `grep`. Selects the grep tool, which searches file contents.
61142
+ */
61143
+ type: 'grep';
61144
+ } | {
61145
+ /**
61146
+ * Whether the tool is offered to the model. Null or omitted means the toolset default applies (enabled unless default_config says otherwise).
61147
+ */
61148
+ enabled: boolean;
61149
+ /**
61150
+ * Name of the native tool this entry configures.
61151
+ */
61152
+ name: 'web_fetch';
61153
+ /**
61154
+ * Permission policy for tool execution.
61155
+ */
61156
+ permission_policy: {
61157
+ /**
61158
+ * Always `always_allow`. Calls run without asking.
61159
+ */
61160
+ type: 'always_allow';
61161
+ } | {
61162
+ /**
61163
+ * Always `always_ask`. Calls wait for user.tool_confirmation before running.
61164
+ */
61165
+ type: 'always_ask';
61166
+ } | {
61167
+ /**
61168
+ * Always `auto`. Reserved: a server-side judgement per call. Not yet supported; sending it returns 400.
61169
+ */
61170
+ type: 'auto';
61171
+ };
61172
+ /**
61173
+ * Always `web_fetch`. Selects the web_fetch tool, which fetches a web page.
61174
+ */
61175
+ type: 'web_fetch';
61176
+ /**
61177
+ * Hosts the tool may fetch or search, as plain hostnames (no scheme, port or path); a listed domain also covers its subdomains. At most 64 entries, and it cannot be combined with blocked_domains.
61178
+ */
61179
+ allowed_domains?: Array<string>;
61180
+ /**
61181
+ * Hosts the tool must never fetch or search, as plain hostnames (no scheme, port or path); a listed domain also covers its subdomains. At most 64 entries, and it cannot be combined with allowed_domains.
61182
+ */
61183
+ blocked_domains?: Array<string>;
61184
+ /**
61185
+ * Maximum number of tokens of fetched text content included in context per call; does not apply to binary content such as PDFs. Null for no explicit limit.
61186
+ */
61187
+ max_content_tokens?: null | number;
61188
+ } | {
61189
+ /**
61190
+ * Whether the tool is offered to the model. Null or omitted means the toolset default applies (enabled unless default_config says otherwise).
61191
+ */
61192
+ enabled: boolean;
61193
+ /**
61194
+ * Name of the native tool this entry configures.
61195
+ */
61196
+ name: 'web_search';
61197
+ /**
61198
+ * Permission policy for tool execution.
61199
+ */
61200
+ permission_policy: {
61201
+ /**
61202
+ * Always `always_allow`. Calls run without asking.
61203
+ */
61204
+ type: 'always_allow';
61205
+ } | {
61206
+ /**
61207
+ * Always `always_ask`. Calls wait for user.tool_confirmation before running.
61208
+ */
61209
+ type: 'always_ask';
61210
+ } | {
61211
+ /**
61212
+ * Always `auto`. Reserved: a server-side judgement per call. Not yet supported; sending it returns 400.
61213
+ */
61214
+ type: 'auto';
61215
+ };
61216
+ /**
61217
+ * Always `web_search`. Selects the web_search tool, which searches the web.
61218
+ */
61219
+ type: 'web_search';
61220
+ /**
61221
+ * Hosts the tool may fetch or search, as plain hostnames (no scheme, port or path); a listed domain also covers its subdomains. At most 64 entries, and it cannot be combined with blocked_domains.
61222
+ */
61223
+ allowed_domains?: Array<string>;
61224
+ /**
61225
+ * Hosts the tool must never fetch or search, as plain hostnames (no scheme, port or path); a listed domain also covers its subdomains. At most 64 entries, and it cannot be combined with allowed_domains.
61226
+ */
61227
+ blocked_domains?: Array<string>;
61228
+ /**
61229
+ * Approximate user location for search result localization.
61230
+ */
61231
+ user_location?: null | {
61232
+ /**
61233
+ * Location precision. Only "approximate" is supported.
61234
+ */
61235
+ type: 'approximate';
61236
+ /**
61237
+ * City name.
61238
+ */
61239
+ city?: null | string;
61240
+ /**
61241
+ * Two-letter ISO 3166-1 country code, uppercase.
61242
+ */
61243
+ country?: null | string;
61244
+ /**
61245
+ * Region or state name.
61246
+ */
61247
+ region?: null | string;
61248
+ /**
61249
+ * IANA timezone identifier, e.g. "America/Los_Angeles".
61250
+ */
61251
+ timezone?: null | string;
61252
+ };
61253
+ } | {
61254
+ /**
61255
+ * Name of the native tool this entry configures.
61256
+ */
61257
+ name: 'task_output' | 'task_stop' | 'monitor' | 'agent' | 'send_message' | 'codemode' | 'skill';
61258
+ /**
61259
+ * Whether the tool is offered to the model. Null or omitted means the toolset default applies (enabled unless default_config says otherwise).
61260
+ */
61261
+ enabled: boolean;
61262
+ /**
61263
+ * Whether a call to this tool runs automatically (always_allow) or waits for user.tool_confirmation (always_ask). Omitted means the toolset default.
61264
+ */
61265
+ permission_policy: {
61266
+ /**
61267
+ * Permission policy kind.
61268
+ */
61269
+ type: 'always_allow' | 'always_ask';
61270
+ };
61271
+ }>;
61272
+ /**
61273
+ * Resolved default configuration for agent tools.
61274
+ */
61275
+ default_config: {
61276
+ /**
61277
+ * Whether tools of the toolset are offered to the model when configs does not name them. Null or omitted means enabled.
61278
+ */
61279
+ enabled: boolean;
61280
+ /**
61281
+ * Permission policy for tool execution.
61282
+ */
61283
+ permission_policy: {
61284
+ /**
61285
+ * Always `always_allow`. Calls run without asking.
61286
+ */
61287
+ type: 'always_allow';
61288
+ } | {
61289
+ /**
61290
+ * Always `always_ask`. Calls wait for user.tool_confirmation before running.
61291
+ */
61292
+ type: 'always_ask';
61293
+ } | {
61294
+ /**
61295
+ * Always `auto`. Reserved: a server-side judgement per call. Not yet supported; sending it returns 400.
61296
+ */
61297
+ type: 'auto';
61298
+ };
61299
+ };
61300
+ /**
61301
+ * Always `agent_toolset_20260401`. The native toolset entry (bash, edit, glob, grep, read, write, web_search, web_fetch, task_output, task_stop, monitor, agent, send_message).
61302
+ */
61303
+ type: 'agent_toolset_20260401';
61304
+ } | {
61305
+ /**
61306
+ * Always `mcp_toolset`. An entry that exposes the tools of one MCP server from mcp_servers.
61307
+ */
61308
+ type: 'mcp_toolset';
61309
+ /**
61310
+ * Name of the MCP server in mcp_servers whose tools this entry exposes.
61311
+ */
61312
+ mcp_server_name: string;
61313
+ /**
61314
+ * Settings applied to every tool of this toolset that configs does not name. When omitted, tools are enabled with the always_allow policy.
61315
+ */
61316
+ default_config?: {
61317
+ /**
61318
+ * Whether tools of the toolset are offered to the model when configs does not name them. Null or omitted means enabled.
61319
+ */
61320
+ enabled?: boolean | null;
61321
+ /**
61322
+ * Permission policy for tools that configs does not name: always_allow runs calls automatically, always_ask waits for user.tool_confirmation.
61323
+ */
61324
+ permission_policy?: null | {
61325
+ /**
61326
+ * Permission policy kind.
61327
+ */
61328
+ type: 'always_allow' | 'always_ask';
61329
+ };
61330
+ } | null;
61331
+ /**
61332
+ * Per-tool settings that override default_config. Tools that are not listed follow default_config.
61333
+ */
61334
+ configs?: Array<{
61335
+ /**
61336
+ * Bare tool name reported by the MCP server.
61337
+ */
61338
+ name: string;
61339
+ /**
61340
+ * Whether the tool is offered to the model. Null or omitted means the toolset default applies (enabled unless default_config says otherwise).
61341
+ */
61342
+ enabled?: boolean | null;
61343
+ /**
61344
+ * Whether a call to this tool runs automatically (always_allow) or waits for user.tool_confirmation (always_ask). Omitted means the toolset default.
61345
+ */
61346
+ permission_policy?: null | {
61347
+ /**
61348
+ * Permission policy kind.
61349
+ */
61350
+ type: 'always_allow' | 'always_ask';
61351
+ };
61352
+ }> | null;
61353
+ } | {
61354
+ /**
61355
+ * What the custom tool does and when the model should call it.
61356
+ */
61357
+ description: string;
61358
+ /**
61359
+ * JSON Schema for custom tool input parameters.
61360
+ */
61361
+ input_schema: {
61362
+ /**
61363
+ * Always `object`. The input is a JSON object.
61364
+ */
61365
+ type: 'object';
61366
+ /**
61367
+ * JSON Schema of each input property, keyed by property name.
61368
+ */
61369
+ properties?: null | {
61370
+ [key: string]: unknown;
61371
+ };
61372
+ /**
61373
+ * Names of the input properties the model must supply.
61374
+ */
61375
+ required?: null | Array<string>;
61376
+ [key: string]: unknown;
61377
+ };
61378
+ /**
61379
+ * Name of the custom tool, as the model sees and calls it.
61380
+ */
61381
+ name: string;
61382
+ /**
61383
+ * Always `custom`. A custom tool defined by name, description and input_schema; its calls are answered by the client with user.custom_tool_result.
61384
+ */
61385
+ type: 'custom';
61386
+ }>;
61387
+ /**
61388
+ * Always `agent`. An agent definition.
61389
+ */
61390
+ type: 'agent';
61391
+ /**
61392
+ * The latest saved version of the agent, the editable head; it differs from active_version after a save with apply false. Starts at 1 and increments each time the agent is modified.
61393
+ */
61394
+ version: number;
61395
+ };
61396
+ /**
61397
+ * A timestamp in RFC 3339 format
61398
+ */
61399
+ archived_at: null | string;
61400
+ /**
61401
+ * A hard spend ceiling. The session stops issuing new model requests once the
61402
+ * tracked list cost reaches `max_list_cost`.
61403
+ */
61404
+ budget: null | {
61405
+ /**
61406
+ * A monetary amount in a specific currency.
61407
+ */
61408
+ max_list_cost: {
61409
+ /**
61410
+ * Amount in minor units of the currency, as an integer decimal string with no
61411
+ * leading zeros: "2500" is $25.00 and "50" is fifty cents. A string rather than a
61412
+ * number so no float rounding is ever applied.
61413
+ */
61414
+ amount: string;
61415
+ /**
61416
+ * Uppercase ISO-4217 currency code. `USD` is the only currency currently
61417
+ * supported; the accepted set is closed and grows only when a new currency is
61418
+ * priced.
61419
+ */
61420
+ currency: 'USD';
61421
+ };
61422
+ /**
61423
+ * Always `limit`. A spending limit.
61424
+ */
61425
+ type: 'limit';
61426
+ };
61427
+ /**
61428
+ * A timestamp in RFC 3339 format
61429
+ */
61430
+ created_at: string;
61431
+ /**
61432
+ * Execution environment of this session. A service session created without environment_id uses the default environment saved in the agent version (light for a new agent); null means it was created without a machine; Computer sessions may omit this field.
61433
+ */
61434
+ environment_id?: string;
61435
+ /**
61436
+ * Free-form string key/value pairs stored with the session, changed through sessions.update patch semantics.
61437
+ */
61438
+ metadata: {
61439
+ [key: string]: string;
61440
+ };
61441
+ /**
61442
+ * Per-outcome evaluation state. One entry per `define_outcome` event sent to the
61443
+ * session.
61444
+ */
61445
+ outcome_evaluations: Array<{
61446
+ /**
61447
+ * A timestamp in RFC 3339 format
61448
+ */
61449
+ completed_at: null | string;
61450
+ /**
61451
+ * What the agent should produce.
61452
+ */
61453
+ description: string;
61454
+ /**
61455
+ * Grader's verdict text from the most recent evaluation. For `satisfied`, explains
61456
+ * why criteria are met; for `needs_revision` (intermediate), what's missing; for
61457
+ * `failed`, why unrecoverable.
61458
+ */
61459
+ explanation: null | string;
61460
+ /**
61461
+ * 0-indexed revision cycle the outcome is currently on.
61462
+ */
61463
+ iteration: number;
61464
+ /**
61465
+ * Server-generated outc\_ ID for this outcome.
61466
+ */
61467
+ outcome_id: string;
61468
+ /**
61469
+ * Current evaluation state. `pending` before the agent begins work; `running`
61470
+ * while producing or revising; `evaluating` while the grader scores;
61471
+ * `satisfied`/`max_iterations_reached`/`failed`/`interrupted` are terminal.
61472
+ */
61473
+ result: string;
61474
+ /**
61475
+ * Always `outcome_evaluation`. Record of one outcome evaluation.
61476
+ */
61477
+ type: 'outcome_evaluation';
61478
+ }>;
61479
+ /**
61480
+ * Resources attached to the session, at most 500; each is a file reference mounted into the session's machine.
61481
+ */
61482
+ resources: Array<{
61483
+ /**
61484
+ * Resource id, the resource_id of sessions.resources calls.
61485
+ */
61486
+ id: string;
61487
+ /**
61488
+ * A timestamp in RFC 3339 format
61489
+ */
61490
+ created_at: string;
61491
+ /**
61492
+ * Path inside the machine where the file is mounted; defaults to /mnt/session/uploads/<file_id>, and custom paths are rooted there.
61493
+ */
61494
+ mount_path: string;
61495
+ /**
61496
+ * Always `github_repository`. A GitHub repository resource; not supported on this platform.
61497
+ */
61498
+ type: 'github_repository';
61499
+ /**
61500
+ * A timestamp in RFC 3339 format
61501
+ */
61502
+ updated_at: string;
61503
+ /**
61504
+ * Repository URL.
61505
+ */
61506
+ url: string;
61507
+ /**
61508
+ * Branch or commit to check out.
61509
+ */
61510
+ checkout?: null | {
61511
+ /**
61512
+ * Branch name to check out.
61513
+ */
61514
+ name: string;
61515
+ /**
61516
+ * Always `branch`. Check out the named branch.
61517
+ */
61518
+ type: 'branch';
61519
+ } | {
61520
+ /**
61521
+ * Full commit SHA to check out.
61522
+ */
61523
+ sha: string;
61524
+ /**
61525
+ * Always `commit`. Check out the commit with the given SHA.
61526
+ */
61527
+ type: 'commit';
61528
+ };
61529
+ } | {
61530
+ /**
61531
+ * Resource id, the resource_id of sessions.resources calls.
61532
+ */
61533
+ id: string;
61534
+ /**
61535
+ * A timestamp in RFC 3339 format
61536
+ */
61537
+ created_at: string;
61538
+ /**
61539
+ * Id of the uploaded file; it must exist and belong to your tenant.
61540
+ */
61541
+ file_id: string;
61542
+ /**
61543
+ * Path inside the machine where the file is mounted; defaults to /mnt/session/uploads/<file_id>, and custom paths are rooted there.
61544
+ */
61545
+ mount_path: string;
61546
+ /**
61547
+ * Always `file`. A file resource: an uploaded file mounted into the session's machine.
61548
+ */
61549
+ type: 'file';
61550
+ /**
61551
+ * A timestamp in RFC 3339 format
61552
+ */
61553
+ updated_at: string;
61554
+ } | {
61555
+ /**
61556
+ * The memory store ID (memstore\_...). Must belong to the caller's organization
61557
+ * and workspace.
61558
+ */
61559
+ memory_store_id: string;
61560
+ /**
61561
+ * Always `memory_store`. A memory store resource; not supported on this platform.
61562
+ */
61563
+ type: 'memory_store';
61564
+ /**
61565
+ * Access mode for an attached memory store.
61566
+ */
61567
+ access?: null | 'read_write' | 'read_only';
61568
+ /**
61569
+ * Description of the memory store, snapshotted at attach time. Rendered into the
61570
+ * agent's system prompt. Empty string when the store has no description.
61571
+ */
61572
+ description?: string;
61573
+ /**
61574
+ * Per-attachment guidance for the agent on how to use this store. Rendered into
61575
+ * the memory section of the system prompt. Max 4096 chars.
61576
+ */
61577
+ instructions?: null | string;
61578
+ /**
61579
+ * Filesystem path where the store is mounted in the session container, e.g.
61580
+ * /mnt/memory/user-preferences. Derived from the store's name. Output-only.
61581
+ */
61582
+ mount_path?: null | string;
61583
+ /**
61584
+ * Display name of the memory store, snapshotted at attach time. Later edits to the
61585
+ * store's name do not propagate to this resource.
61586
+ */
61587
+ name?: null | string;
61588
+ }>;
61589
+ /**
61590
+ * Timing statistics for a session.
61591
+ */
61592
+ stats: {
61593
+ /**
61594
+ * Cumulative time in seconds the session spent in `running` status. Excludes idle
61595
+ * time.
61596
+ */
61597
+ active_seconds?: number;
61598
+ /**
61599
+ * Elapsed time since session creation in seconds. For terminated sessions, frozen
61600
+ * at the final update.
61601
+ */
61602
+ duration_seconds?: number;
61603
+ };
61604
+ /**
61605
+ * SessionStatus enum
61606
+ *
61607
+ * - `rescheduling` - Transient error occurred, retrying automatically.
61608
+ * - `running` - Agent is actively executing.
61609
+ * - `idle` - Agent is waiting for input, including user messages or tool
61610
+ * confirmations. Sessions start in idle.
61611
+ * - `terminated` - Session has ended, either due to an error or completion.
61612
+ */
61613
+ status: 'rescheduling' | 'running' | 'idle' | 'terminated';
61614
+ /**
61615
+ * Title of the session, set on create or through sessions.update; null when none was set.
61616
+ */
61617
+ title: null | string;
61618
+ /**
61619
+ * Always `session`. A session, one conversation of an agent on a machine.
61620
+ */
61621
+ type: 'session';
61622
+ /**
61623
+ * A timestamp in RFC 3339 format
61624
+ */
61625
+ updated_at: string;
61626
+ /**
61627
+ * Cumulative token usage for a session across all turns.
61628
+ */
61629
+ usage: {
61630
+ /**
61631
+ * Cumulative time in seconds during which the session had at least one thread in
61632
+ * running status. Overlapping activity from concurrent threads is counted once,
61633
+ * unlike `stats.active_seconds`, which sums each thread's own active time. This is
61634
+ * the duration the session's runtime cost is priced on.
61635
+ */
61636
+ active_seconds?: number;
61637
+ /**
61638
+ * Prompt-cache creation token usage broken down by cache lifetime.
61639
+ */
61640
+ cache_creation?: {
61641
+ /**
61642
+ * Tokens used to create 1-hour ephemeral cache entries.
61643
+ */
61644
+ ephemeral_1h_input_tokens?: number;
61645
+ /**
61646
+ * Tokens used to create 5-minute ephemeral cache entries.
61647
+ */
61648
+ ephemeral_5m_input_tokens?: number;
61649
+ };
61650
+ /**
61651
+ * Total tokens read from prompt cache.
61652
+ */
61653
+ cache_read_input_tokens?: number;
61654
+ /**
61655
+ * Total input tokens consumed across all turns.
61656
+ */
61657
+ input_tokens?: number;
61658
+ /**
61659
+ * Session total list-price cost in USD as a decimal string with exactly 6 decimals. Includes models, runtime and all other charged products attributed to this session; child-thread model cost is already included. The budget reads the same total. In-flight work may finish after the limit is reached.
61660
+ */
61661
+ list_cost?: null | {
61662
+ /**
61663
+ * Amount in minor units of the currency, as an integer decimal string with no
61664
+ * leading zeros: "2500" is $25.00 and "50" is fifty cents. A string rather than a
61665
+ * number so no float rounding is ever applied.
61666
+ */
61667
+ amount: string;
61668
+ /**
61669
+ * Uppercase ISO-4217 currency code. `USD` is the only currency currently
61670
+ * supported; the accepted set is closed and grows only when a new currency is
61671
+ * priced.
61672
+ */
61673
+ currency: 'USD';
61674
+ };
61675
+ /**
61676
+ * Total output tokens generated across all turns.
61677
+ */
61678
+ output_tokens?: number;
61679
+ /**
61680
+ * Cumulative count of server-executed tool invocations, broken down by tool.
61681
+ */
61682
+ server_tool_use?: null | {
61683
+ /**
61684
+ * Number of server-executed web fetch requests.
61685
+ */
61686
+ web_fetch_requests?: number;
61687
+ /**
61688
+ * Number of server-executed web search requests.
61689
+ */
61690
+ web_search_requests?: number;
61691
+ };
61692
+ /**
61693
+ * USD list-price cost by product, as decimal strings with exactly 6 decimals. Values sum to list_cost.amount. router.llm is the larger of the live model meter and charged model facts; all other products use charged facts only.
61694
+ */
61695
+ cost_by_product?: {
61696
+ [key: string]: string;
61697
+ };
61698
+ /**
61699
+ * Child-thread model cost in integer micro-USD, already included in list_cost. This is a subset, not an additional charge; it excludes child-thread runtime.
61700
+ */
61701
+ subagent_cost_micro_usd?: number;
61702
+ };
61703
+ /**
61704
+ * Vault IDs attached to the session at creation. Empty when no vaults were
61705
+ * supplied.
61706
+ */
61707
+ vault_ids: Array<string>;
61708
+ /**
61709
+ * Deployment ID when the session was created from a deployment reference. Null
61710
+ * otherwise.
61711
+ */
61712
+ deployment_id?: null | string;
61713
+ /**
61714
+ * Normalized session working directory; defaults to /home/user/workspace. Forks inherit this directory.
61715
+ */
61716
+ cwd: string;
61717
+ /**
61718
+ * Praxis extension: MA only has session-scoped temporary containers and memory_stores, not durable browsable computers. computer_id selects a tenant-owned active computer. Session selection overrides the agent default; a sandbox environment_id and computer_id cannot be combined. Omitted when no computer is selected.
61719
+ */
61720
+ computer_id?: string;
61721
+ /**
61722
+ * Praxis extension: the currently selected session model.
61723
+ */
61724
+ model?: {
61725
+ /**
61726
+ * Identifier of the object, as returned by the API; pass it in the path of follow-up calls on the same resource.
61727
+ */
61728
+ id: string;
61729
+ /**
61730
+ * Supported thinking controls, or null when capability is unknown or unavailable. efforts lists selectable strengths; can_disable permits none; default_effort is nullable.
61731
+ */
61732
+ thinking: {
61733
+ /**
61734
+ * Thinking levels the model accepts as effort, in ascending order.
61735
+ */
61736
+ efforts: Array<'low' | 'medium' | 'high' | 'xhigh' | 'max'>;
61737
+ /**
61738
+ * Whether effort none (thinking off) is allowed for this model.
61739
+ */
61740
+ can_disable: boolean;
61741
+ /**
61742
+ * Thinking level used when neither the session nor the agent selects one; null when the model states no default.
61743
+ */
61744
+ default_effort: 'low' | 'medium' | 'high' | 'xhigh' | 'max' | null;
61745
+ } | null;
61746
+ };
61747
+ /**
61748
+ * Praxis extension: explicit session thinking effort; null inherits the pinned agent default, then the model default. none disables thinking only when model.thinking.can_disable is true. Unsupported efforts return 400 invalid_request_error.
61749
+ */
61750
+ thinking?: {
61751
+ /**
61752
+ * Thinking level saved for this session: low, medium, high, xhigh, max, or none to turn thinking off. Null or absent means the session inherits the agent default and then the model default.
61753
+ */
61754
+ effort: 'low' | 'medium' | 'high' | 'xhigh' | 'max' | 'none';
61755
+ } | null;
61756
+ /**
61757
+ * Praxis extension: source of a forked session; null for other sessions. Available only on /agent/v1.
61758
+ */
61759
+ forked_from?: {
61760
+ /**
61761
+ * Id of the parent session this session was forked from; it is left unchanged by the fork.
61762
+ */
61763
+ session_id: string;
61764
+ /**
61765
+ * message_id of the agent message in the parent session up to which the conversation was copied.
61766
+ */
61767
+ message_id: string;
61768
+ } | null;
61769
+ /**
61770
+ * End-user identifier associated with the session, or null when none is recorded. Own-face extension; use external_user_id on sessions.list to find this user's sessions.
61771
+ */
61772
+ readonly external_user_id: string | null;
61773
+ /**
61774
+ * Origin of the session: kit, iframe, hosted, api or automation; null when unavailable. Own-face extension; use source on sessions.list to filter by origin.
61775
+ */
61776
+ readonly source: 'kit' | 'iframe' | 'hosted' | 'api' | 'automation' | null;
61777
+ };
61778
+ };
61779
+ export type UpdateSessionAgentVersionResponse = UpdateSessionAgentVersionResponses[keyof UpdateSessionAgentVersionResponses];
61780
+ export type ListSessionArtifactsData = {
61781
+ body?: never;
61782
+ path: {
61783
+ /**
61784
+ * Session id from session creation or listing.
61785
+ */
61786
+ session_id: string;
61787
+ };
61788
+ query?: never;
61789
+ url: '/agent/v1/sessions/{session_id}/artifacts';
61790
+ };
61791
+ export type ListSessionArtifactsErrors = {
61792
+ /**
61793
+ * Invalid request: ttl_seconds outside 60 to 300, a negative part, or an unsupported field.
61794
+ */
61795
+ 400: unknown;
61796
+ /**
61797
+ * Authenticate with an organization credential or a customer access token.
61798
+ */
61799
+ 401: unknown;
61800
+ /**
61801
+ * permission_error: the credential's role or bound resources do not allow this operation. Use a key with access to the agent domain and its resources.
61802
+ */
61803
+ 403: AgentError;
61804
+ /**
61805
+ * Session not found or not readable by this caller.
61806
+ */
61807
+ 404: unknown;
61808
+ /**
61809
+ * Agent service failed
61810
+ */
61811
+ 502: unknown;
61812
+ /**
61813
+ * Agent service unavailable
61814
+ */
61815
+ 503: unknown;
61816
+ };
61817
+ export type ListSessionArtifactsError = ListSessionArtifactsErrors[keyof ListSessionArtifactsErrors];
61818
+ export type ListSessionArtifactsResponses = {
61819
+ /**
61820
+ * Artifacts this session delivered
61821
+ */
61822
+ 200: {
61823
+ /**
61824
+ * Items of this page, in the order requested by the call.
61825
+ */
61826
+ data: Array<{
61827
+ /**
61828
+ * Object type, always artifact.
61829
+ */
61830
+ object: 'artifact';
61831
+ /**
61832
+ * Artifact id (art_...). Stays the same when the same path is delivered again.
61833
+ */
61834
+ id: string;
61835
+ /**
61836
+ * Id of the session.
61837
+ */
61838
+ session_id: string;
61839
+ /**
61840
+ * The run that produced this version; null when it cannot be told.
61841
+ */
61842
+ run_id: string | null;
61843
+ /**
61844
+ * Path of the file inside the session's outputs directory, such as report.pdf or charts/q3.png.
61845
+ */
61846
+ name: string;
61847
+ /**
61848
+ * 1 on first delivery; each later delivery of the same path with new content adds one.
61849
+ */
61850
+ version: number;
61851
+ /**
61852
+ * The files this artifact holds; the latest version's parts only.
61853
+ */
61854
+ parts: Array<{
61855
+ /**
61856
+ * Part type: a file the agent placed in the session's outputs directory.
61857
+ */
61858
+ kind: 'file';
61859
+ /**
61860
+ * The file object this part points at; read its bytes through content_url, not through this id.
61861
+ */
61862
+ file_id: string;
61863
+ /**
61864
+ * File name as stored, without the directory.
61865
+ */
61866
+ filename: string;
61867
+ /**
61868
+ * Media type of the file, decided from its extension.
61869
+ */
61870
+ mime_type: string;
61871
+ /**
61872
+ * Size of the file in bytes; the downloaded content has exactly this length.
61873
+ */
61874
+ bytes: number;
61875
+ } | {
61876
+ /**
61877
+ * Part type: a canvas or a media asset the agent's reply pointed at.
61878
+ */
61879
+ kind: 'object';
61880
+ /**
61881
+ * canvas is a design canvas, whose content_url is a snapshot picture of it; media_asset is an asset of a media library, whose content_url is its own bytes.
61882
+ */
61883
+ object_type: 'canvas' | 'media_asset';
61884
+ /**
61885
+ * The object's id: cvs_... for a canvas, <library_id>/<asset_id> for a media asset.
61886
+ */
61887
+ object_id: string;
61888
+ /**
61889
+ * The address in the reply that pointed at the object, verbatim; open the object with content_url, not with this address.
61890
+ */
61891
+ href: string;
61892
+ /**
61893
+ * What the reply called the object: the text of the link that carried the address, for a card to show. null when the address stood alone in the reply.
61894
+ */
61895
+ title: string | null;
61896
+ }>;
61897
+ /**
61898
+ * Link addresses from the reply text that point at this artifact, verbatim; render a link whose address equals one of these as this artifact.
61899
+ */
61900
+ source_hrefs: Array<string>;
61901
+ /**
61902
+ * When the artifact was first registered, RFC 3339; set by the service.
61903
+ */
61904
+ create_time: string;
61905
+ /**
61906
+ * When the latest version was registered, RFC 3339; equals create_time for version 1.
61907
+ */
61908
+ update_time: string;
61909
+ }>;
61910
+ };
61911
+ };
61912
+ export type ListSessionArtifactsResponse = ListSessionArtifactsResponses[keyof ListSessionArtifactsResponses];
61913
+ export type CreateSessionArtifactContentUrlData = {
61914
+ body?: {
61915
+ /**
61916
+ * Index into the artifact's parts; defaults to 0.
61917
+ */
61918
+ part?: number;
61919
+ /**
61920
+ * How long the address works, 60 to 300 seconds; defaults to 300.
61921
+ */
61922
+ ttl_seconds?: number;
61923
+ };
61924
+ path: {
61925
+ /**
61926
+ * Session id from session creation or listing.
61927
+ */
61928
+ session_id: string;
61929
+ /**
61930
+ * Artifact id (art_...) from the artifact list or an agent.artifact_delivered event.
61931
+ */
61932
+ artifact_id: string;
61933
+ };
61934
+ query?: never;
61935
+ url: '/agent/v1/sessions/{session_id}/artifacts/{artifact_id}/content_url';
61936
+ };
61937
+ export type CreateSessionArtifactContentUrlErrors = {
61938
+ /**
61939
+ * Invalid request: ttl_seconds outside 60 to 300, a negative part, or an unsupported field.
61940
+ */
61941
+ 400: unknown;
61942
+ /**
61943
+ * Authenticate with an organization credential or a customer access token.
61944
+ */
61945
+ 401: unknown;
61946
+ /**
61947
+ * permission_error: the credential's role or bound resources do not allow this operation. Use a key with access to the agent domain and its resources.
61948
+ */
61949
+ 403: AgentError;
61950
+ /**
61951
+ * Session not found or not readable by this caller, or ARTIFACT_NOT_FOUND: no such artifact or part.
61952
+ */
61953
+ 404: unknown;
61954
+ /**
61955
+ * Agent service failed
61956
+ */
61957
+ 502: unknown;
61958
+ /**
61959
+ * Agent service unavailable
61960
+ */
61961
+ 503: unknown;
61962
+ };
61963
+ export type CreateSessionArtifactContentUrlError = CreateSessionArtifactContentUrlErrors[keyof CreateSessionArtifactContentUrlErrors];
61964
+ export type CreateSessionArtifactContentUrlResponses = {
61965
+ /**
61966
+ * Short-lived download address
61967
+ */
61968
+ 200: {
61969
+ /**
61970
+ * Signed download address; fetch it within the lifetime and do not store it.
61971
+ */
61972
+ url: string;
61973
+ /**
61974
+ * When the address stops working, RFC 3339; at most 300 seconds after it was issued.
61975
+ */
61976
+ expire_time: string;
61977
+ };
61978
+ };
61979
+ export type CreateSessionArtifactContentUrlResponse = CreateSessionArtifactContentUrlResponses[keyof CreateSessionArtifactContentUrlResponses];
61980
+ export type ListSessionRequestsData = {
61981
+ body?: never;
61982
+ path: {
61983
+ /**
61984
+ * Session id from session creation or listing.
61985
+ */
61986
+ session_id: string;
61987
+ };
61988
+ query?: never;
61989
+ url: '/agent/v1/sessions/{session_id}/requests';
61990
+ };
61991
+ export type ListSessionRequestsErrors = {
61992
+ /**
61993
+ * Unsupported query parameter.
61994
+ */
61995
+ 400: unknown;
61996
+ /**
61997
+ * Authenticate with an organization credential or a customer access token.
61998
+ */
61999
+ 401: unknown;
62000
+ /**
62001
+ * permission_error: the credential's role or bound resources do not allow this operation. Use a key with access to the agent domain and its resources.
62002
+ */
62003
+ 403: AgentError;
62004
+ /**
62005
+ * Session not found or not readable by this caller.
62006
+ */
62007
+ 404: unknown;
62008
+ /**
62009
+ * Agent service failed
62010
+ */
62011
+ 502: unknown;
62012
+ /**
62013
+ * Agent service unavailable
62014
+ */
62015
+ 503: unknown;
62016
+ };
62017
+ export type ListSessionRequestsError = ListSessionRequestsErrors[keyof ListSessionRequestsErrors];
62018
+ export type ListSessionRequestsResponses = {
62019
+ /**
62020
+ * The requests this session waits on
62021
+ */
62022
+ 200: {
62023
+ /**
62024
+ * The requests the session waits on, oldest first; empty when it waits on nothing.
62025
+ */
62026
+ data: Array<{
62027
+ /**
62028
+ * The pending tool call's id (the tool_use id on the agent.tool_use event); answer it with a user.tool_confirmation event carrying this id as tool_use_id.
62029
+ */
62030
+ id: string;
62031
+ /**
62032
+ * Object type, always request.
62033
+ */
62034
+ object: 'request';
62035
+ /**
62036
+ * question when the agent asked through the ask_user_question tool and waits for an answer; approval when any other tool waits for permission.
62037
+ */
62038
+ kind: 'question' | 'approval';
62039
+ /**
62040
+ * Always pending: answered, expired and superseded requests are not listed.
62041
+ */
62042
+ status: 'pending';
62043
+ /**
62044
+ * The tool the agent called, such as ask_user_question or bash.
62045
+ */
62046
+ tool_name: string;
62047
+ /**
62048
+ * The tool call's input exactly as the agent.tool_use event shows it: for a question the questions and their options, for an approval the tool's arguments.
62049
+ */
62050
+ input: unknown;
62051
+ /**
62052
+ * When the call became pending, RFC 3339; the time of its agent.tool_use event.
62053
+ */
62054
+ create_time: string;
62055
+ /**
62056
+ * When the request expires and counts as declined, RFC 3339; null when it does not expire, which is every session that runs a collaboration mode and every session while the requests-v1 release is off.
62057
+ */
62058
+ expire_time: string | null;
62059
+ }>;
62060
+ };
62061
+ };
62062
+ export type ListSessionRequestsResponse = ListSessionRequestsResponses[keyof ListSessionRequestsResponses];
62063
+ export type ListSessionBackgroundTasksData = {
62064
+ body?: never;
62065
+ path: {
62066
+ /**
62067
+ * Session id (sesn_...), as returned by sessions.create or sessions.list. In a path position the own face /agent/v1 also accepts `main` (your own main session with the agent) or a short session name, and either alias then requires the agent_id query parameter with the agent reference; /anthropic/v1 and the session_id query parameter on resource and thread calls take a real id only (the query value must equal the path value).
62068
+ */
62069
+ session_id: string;
62070
+ };
62071
+ query?: never;
62072
+ url: '/agent/v1/sessions/{session_id}/background_tasks';
62073
+ };
62074
+ export type ListSessionBackgroundTasksErrors = {
62075
+ /**
62076
+ * Invalid request: this call accepts no query parameters, and any parameter that is present, unsupported or repeated returns 400. Remove the parameter and retry.
62077
+ */
62078
+ 400: unknown;
62079
+ /**
62080
+ * Authentication required
62081
+ */
62082
+ 401: unknown;
62083
+ /**
62084
+ * permission_error: the credential's role or bound resources do not allow this operation. Use a key with access to the agent domain and its resources.
62085
+ */
62086
+ 403: AgentError;
62087
+ /**
62088
+ * Session not found
62089
+ */
62090
+ 404: unknown;
62091
+ /**
62092
+ * Agent service failed
62093
+ */
62094
+ 502: unknown;
62095
+ /**
62096
+ * Agent service unavailable
62097
+ */
62098
+ 503: unknown;
62099
+ };
62100
+ export type ListSessionBackgroundTasksError = ListSessionBackgroundTasksErrors[keyof ListSessionBackgroundTasksErrors];
62101
+ export type ListSessionBackgroundTasksResponses = {
62102
+ /**
62103
+ * Session background tasks
62104
+ */
62105
+ 200: {
62106
+ /**
62107
+ * Items of this page, in the order requested by the call.
62108
+ */
62109
+ data: Array<{
62110
+ /**
62111
+ * Identifier of the object, as returned by the API; pass it in the path of follow-up calls on the same resource.
62112
+ */
62113
+ id: string;
62114
+ /**
62115
+ * Kind of background task: bash for a command started with run_in_background, monitor for a monitor watch.
62116
+ */
62117
+ kind: string;
62118
+ /**
62119
+ * Short human-readable title of the task or object.
62120
+ */
62121
+ title: string;
62122
+ /**
62123
+ * Execution thread the task belongs to; null for the primary thread.
62124
+ */
62125
+ thread_id: string | null;
62126
+ /**
62127
+ * Current lifecycle state.
62128
+ */
62129
+ status: 'running' | 'result_pending' | 'completed' | 'failed' | 'cancelled' | 'lost';
62130
+ /**
62131
+ * RFC 3339 time at which the task started.
62132
+ */
62133
+ started_at: string;
62134
+ /**
62135
+ * RFC 3339 time at which the task ended; null while it is running.
62136
+ */
62137
+ ended_at: string | null;
62138
+ /**
62139
+ * Whether the task can still be stopped.
62140
+ */
62141
+ cancellable: boolean;
62142
+ /**
60343
62143
  * RFC 3339 time of the latest run that the task's notification started; null while no notification has been delivered.
60344
62144
  */
60345
62145
  notified_at: string | null;
@@ -73058,7 +74858,7 @@ export type AgentsListResponses = {
73058
74858
  */
73059
74859
  note: string | null;
73060
74860
  /**
73061
- * Platform resources and services this service agent's codemode may reach, as one list of typed bindings. Only kind=service accepts a nonempty list; general agents return 400. There are two kinds. A resource binding names one resource with id and access: database (id db_..., read_only or read_write), vector_store (id vs_..., read_only or read_write), file (id file- plus 24 letters or digits, as the File API returns it; read_only), media_library (any id without ':' or whitespace, read_only or read_write), model (a model catalog id, invoke), workflow and script (id <namespace>/<name>, invoke). A service binding opens one service, or one sub-tree of one, and carries only enabled: search, browser, ticket, crm, canvas, cut, studio, feedback or workspace. workspace opens development units — list one, read one, start, stop, exec inside one, fetch, push, connect, and open a unit for a change — and opens neither publishing nor any production operation. The ticket service is bound by default: a service agent whose list has no ticket entry may call the ticket API, and {"type": "ticket", "enabled": false} removes it. Every other service stays closed until it is bound. An open service allows every public method of that service. At most 20 bindings per type, no repeated type and id, and each service type at most once. A session is authorized by the agent version it runs: newly added bindings apply only to new sessions, and a version saved with apply=false changes no access until it is applied. Applying a version that disables, removes or downgrades a binding revokes it immediately in running sessions on older versions. A resource that is not bound returns 404, a service that is not opened returns 403, and a write to a resource bound read_only returns 403 BINDING_READ_ONLY. Unknown types, fields on the wrong kind (id, access or instructions on a service binding), wrong access and malformed ids return 400. The former databases, vector_stores and files fields are removed and return 400. Omit on create for the default: the ticket service only. Saving checks added or changed database, vector_store, media_library and file bindings in the organization: unknown or deleted ids return 400. If an owner is unavailable or takes more than 3 seconds, saving succeeds with verified=false for the affected bindings. Unchanged bindings keep their previous verification result and are not rechecked. workflow and script ids are not verified at save time.
74861
+ * Platform resources and services this service agent's codemode may reach, as one list of typed bindings. Only kind=service accepts a nonempty list; general agents return 400. There are two kinds. A resource binding names one resource with id and access: database (id db_..., read_only or read_write), vector_store (id vs_..., read_only or read_write), file (id file- plus 24 letters or digits, as the File API returns it; read_only), media_library (any id without ':' or whitespace, read_only or read_write), model (a model catalog id, invoke), workflow and script (id <namespace>/<name>, invoke). A resource binding may also carry customer_access (read_only by default): it caps what a terminal customer's session (a visitor, ADR-163 §3) may do with that one resource, at the intersection of customer_access and the binding's own access — invoke (call) and read_write (change) are different axes, so only a matching pair keeps its access and any other pair falls to read_only. Its value must be one the type can grant: read_only or read_write for database, vector_store and media_library, read_only for file, and read_only or invoke for model, workflow and script. A member's session ignores it, so raising it never widens what members may do. A visitor's session never receives a whole-service binding (the default ticket service included) or an agent resource. A service binding opens one service, or one sub-tree of one, and carries only enabled: search, browser, ticket, crm, canvas, cut, studio, feedback or workspace. workspace opens development units — list one, read one, start, stop, exec inside one, fetch, push, connect, and open a unit for a change — and opens neither publishing nor any production operation. The ticket service is bound by default: a service agent whose list has no ticket entry may call the ticket API, and {"type": "ticket", "enabled": false} removes it. Every other service stays closed until it is bound. An open service allows every public method of that service. At most 20 bindings per type, no repeated type and id, and each service type at most once. A session is authorized by the agent version it runs: newly added bindings apply only to new sessions, and a version saved with apply=false changes no access until it is applied. Applying a version that disables, removes or downgrades a binding revokes it immediately in running sessions on older versions. A resource that is not bound returns 404, a service that is not opened returns 403, and a write to a resource bound read_only returns 403 BINDING_READ_ONLY. Unknown types, fields on the wrong kind (id, access, customer_access or instructions on a service binding), wrong access and malformed ids return 400. The former databases, vector_stores and files fields are removed and return 400. Omit on create for the default: the ticket service only. Saving checks added or changed database, vector_store, media_library and file bindings in the organization: unknown or deleted ids return 400. If an owner is unavailable or takes more than 3 seconds, saving succeeds with verified=false for the affected bindings. Unchanged bindings keep their previous verification result and are not rechecked. workflow and script ids are not verified at save time.
73062
74862
  */
73063
74863
  bindings: Array<{
73064
74864
  /**
@@ -73073,6 +74873,10 @@ export type AgentsListResponses = {
73073
74873
  * database, vector_store and media_library accept read_only or read_write; file accepts read_only; model, workflow and script accept invoke. Any other combination returns 400.
73074
74874
  */
73075
74875
  access: 'read_only' | 'read_write' | 'invoke';
74876
+ /**
74877
+ * What a visitor's session (a terminal customer, ADR-163 §3) may do with this resource: read_only, read_write or invoke. Its scope is the intersection of this value and the binding's own access, so invoke needs both to be invoke. Limited to the accesses the type can grant: read_only or read_write for database, vector_store and media_library, read_only for file, read_only or invoke for model, workflow and script. Defaults to read_only. A member's session ignores it entirely; a visitor's session never receives a whole-service binding or an agent resource.
74878
+ */
74879
+ customer_access?: 'read_only' | 'read_write' | 'invoke';
73076
74880
  /**
73077
74881
  * Optional guidance for using this resource, up to 4096 characters; does not expand access.
73078
74882
  */
@@ -73497,6 +75301,10 @@ export type AgentsListResponses = {
73497
75301
  * Channel the agent was created through (for example api or console); null for historical agents whose channel is unknown. Display only. /agent/v1 only; /anthropic neither returns it.
73498
75302
  */
73499
75303
  creation_source: string | null;
75304
+ /**
75305
+ * Application that manages this agent (for example praxis-work); null when no application does. Set when the agent is created, or claimed once by an update that sends the same value in the Praxis-Managed-By header; never changes after. Archiving a managed agent without the managing application's Praxis-Managed-By header returns 409 AGENT_MANAGED_BY_APPLICATION; configuration stays changeable. An accident guard, not a security boundary. /agent/v1 only; /anthropic neither returns it.
75306
+ */
75307
+ managed_by: string | null;
73500
75308
  /**
73501
75309
  * Platform-wide identity number of the agent (8 characters), usable wherever an agent is addressed by identity_number; null when the agent has none. /agent/v1 only; /anthropic neither returns it.
73502
75310
  */
@@ -73619,7 +75427,7 @@ export type AgentsCreateData = {
73619
75427
  */
73620
75428
  tools?: Array<AgentManaged15 | AgentManaged29 | AgentManaged32>;
73621
75429
  /**
73622
- * Platform resources and services this service agent's codemode may reach, as one list of typed bindings. Only kind=service accepts a nonempty list; general agents return 400. There are two kinds. A resource binding names one resource with id and access: database (id db_..., read_only or read_write), vector_store (id vs_..., read_only or read_write), file (id file- plus 24 letters or digits, as the File API returns it; read_only), media_library (any id without ':' or whitespace, read_only or read_write), model (a model catalog id, invoke), workflow and script (id <namespace>/<name>, invoke). A service binding opens one service, or one sub-tree of one, and carries only enabled: search, browser, ticket, crm, canvas, cut, studio, feedback or workspace. workspace opens development units — list one, read one, start, stop, exec inside one, fetch, push, connect, and open a unit for a change — and opens neither publishing nor any production operation. The ticket service is bound by default: a service agent whose list has no ticket entry may call the ticket API, and {"type": "ticket", "enabled": false} removes it. Every other service stays closed until it is bound. An open service allows every public method of that service. At most 20 bindings per type, no repeated type and id, and each service type at most once. A session is authorized by the agent version it runs: newly added bindings apply only to new sessions, and a version saved with apply=false changes no access until it is applied. Applying a version that disables, removes or downgrades a binding revokes it immediately in running sessions on older versions. A resource that is not bound returns 404, a service that is not opened returns 403, and a write to a resource bound read_only returns 403 BINDING_READ_ONLY. Unknown types, fields on the wrong kind (id, access or instructions on a service binding), wrong access and malformed ids return 400. The former databases, vector_stores and files fields are removed and return 400. Omit on create for the default: the ticket service only. Saving checks added or changed database, vector_store, media_library and file bindings in the organization: unknown or deleted ids return 400. If an owner is unavailable or takes more than 3 seconds, saving succeeds with verified=false for the affected bindings. Unchanged bindings keep their previous verification result and are not rechecked. workflow and script ids are not verified at save time.
75430
+ * Platform resources and services this service agent's codemode may reach, as one list of typed bindings. Only kind=service accepts a nonempty list; general agents return 400. There are two kinds. A resource binding names one resource with id and access: database (id db_..., read_only or read_write), vector_store (id vs_..., read_only or read_write), file (id file- plus 24 letters or digits, as the File API returns it; read_only), media_library (any id without ':' or whitespace, read_only or read_write), model (a model catalog id, invoke), workflow and script (id <namespace>/<name>, invoke). A resource binding may also carry customer_access (read_only by default): it caps what a terminal customer's session (a visitor, ADR-163 §3) may do with that one resource, at the intersection of customer_access and the binding's own access — invoke (call) and read_write (change) are different axes, so only a matching pair keeps its access and any other pair falls to read_only. Its value must be one the type can grant: read_only or read_write for database, vector_store and media_library, read_only for file, and read_only or invoke for model, workflow and script. A member's session ignores it, so raising it never widens what members may do. A visitor's session never receives a whole-service binding (the default ticket service included) or an agent resource. A service binding opens one service, or one sub-tree of one, and carries only enabled: search, browser, ticket, crm, canvas, cut, studio, feedback or workspace. workspace opens development units — list one, read one, start, stop, exec inside one, fetch, push, connect, and open a unit for a change — and opens neither publishing nor any production operation. The ticket service is bound by default: a service agent whose list has no ticket entry may call the ticket API, and {"type": "ticket", "enabled": false} removes it. Every other service stays closed until it is bound. An open service allows every public method of that service. At most 20 bindings per type, no repeated type and id, and each service type at most once. A session is authorized by the agent version it runs: newly added bindings apply only to new sessions, and a version saved with apply=false changes no access until it is applied. Applying a version that disables, removes or downgrades a binding revokes it immediately in running sessions on older versions. A resource that is not bound returns 404, a service that is not opened returns 403, and a write to a resource bound read_only returns 403 BINDING_READ_ONLY. Unknown types, fields on the wrong kind (id, access, customer_access or instructions on a service binding), wrong access and malformed ids return 400. The former databases, vector_stores and files fields are removed and return 400. Omit on create for the default: the ticket service only. Saving checks added or changed database, vector_store, media_library and file bindings in the organization: unknown or deleted ids return 400. If an owner is unavailable or takes more than 3 seconds, saving succeeds with verified=false for the affected bindings. Unchanged bindings keep their previous verification result and are not rechecked. workflow and script ids are not verified at save time.
73623
75431
  */
73624
75432
  bindings?: Array<{
73625
75433
  /**
@@ -73634,6 +75442,10 @@ export type AgentsCreateData = {
73634
75442
  * database, vector_store and media_library accept read_only or read_write; file accepts read_only; model, workflow and script accept invoke. Any other combination returns 400.
73635
75443
  */
73636
75444
  access: 'read_only' | 'read_write' | 'invoke';
75445
+ /**
75446
+ * What a visitor's session (a terminal customer, ADR-163 §3) may do with this resource: read_only, read_write or invoke. Its scope is the intersection of this value and the binding's own access, so invoke needs both to be invoke. Limited to the accesses the type can grant: read_only or read_write for database, vector_store and media_library, read_only for file, read_only or invoke for model, workflow and script. Defaults to read_only. A member's session ignores it entirely; a visitor's session never receives a whole-service binding or an agent resource.
75447
+ */
75448
+ customer_access?: 'read_only' | 'read_write' | 'invoke';
73637
75449
  /**
73638
75450
  * Optional guidance for using this resource, up to 4096 characters; does not expand access.
73639
75451
  */
@@ -74246,7 +76058,7 @@ export type AgentsCreateResponses = {
74246
76058
  */
74247
76059
  note: string | null;
74248
76060
  /**
74249
- * Platform resources and services this service agent's codemode may reach, as one list of typed bindings. Only kind=service accepts a nonempty list; general agents return 400. There are two kinds. A resource binding names one resource with id and access: database (id db_..., read_only or read_write), vector_store (id vs_..., read_only or read_write), file (id file- plus 24 letters or digits, as the File API returns it; read_only), media_library (any id without ':' or whitespace, read_only or read_write), model (a model catalog id, invoke), workflow and script (id <namespace>/<name>, invoke). A service binding opens one service, or one sub-tree of one, and carries only enabled: search, browser, ticket, crm, canvas, cut, studio, feedback or workspace. workspace opens development units — list one, read one, start, stop, exec inside one, fetch, push, connect, and open a unit for a change — and opens neither publishing nor any production operation. The ticket service is bound by default: a service agent whose list has no ticket entry may call the ticket API, and {"type": "ticket", "enabled": false} removes it. Every other service stays closed until it is bound. An open service allows every public method of that service. At most 20 bindings per type, no repeated type and id, and each service type at most once. A session is authorized by the agent version it runs: newly added bindings apply only to new sessions, and a version saved with apply=false changes no access until it is applied. Applying a version that disables, removes or downgrades a binding revokes it immediately in running sessions on older versions. A resource that is not bound returns 404, a service that is not opened returns 403, and a write to a resource bound read_only returns 403 BINDING_READ_ONLY. Unknown types, fields on the wrong kind (id, access or instructions on a service binding), wrong access and malformed ids return 400. The former databases, vector_stores and files fields are removed and return 400. Omit on create for the default: the ticket service only. Saving checks added or changed database, vector_store, media_library and file bindings in the organization: unknown or deleted ids return 400. If an owner is unavailable or takes more than 3 seconds, saving succeeds with verified=false for the affected bindings. Unchanged bindings keep their previous verification result and are not rechecked. workflow and script ids are not verified at save time.
76061
+ * Platform resources and services this service agent's codemode may reach, as one list of typed bindings. Only kind=service accepts a nonempty list; general agents return 400. There are two kinds. A resource binding names one resource with id and access: database (id db_..., read_only or read_write), vector_store (id vs_..., read_only or read_write), file (id file- plus 24 letters or digits, as the File API returns it; read_only), media_library (any id without ':' or whitespace, read_only or read_write), model (a model catalog id, invoke), workflow and script (id <namespace>/<name>, invoke). A resource binding may also carry customer_access (read_only by default): it caps what a terminal customer's session (a visitor, ADR-163 §3) may do with that one resource, at the intersection of customer_access and the binding's own access — invoke (call) and read_write (change) are different axes, so only a matching pair keeps its access and any other pair falls to read_only. Its value must be one the type can grant: read_only or read_write for database, vector_store and media_library, read_only for file, and read_only or invoke for model, workflow and script. A member's session ignores it, so raising it never widens what members may do. A visitor's session never receives a whole-service binding (the default ticket service included) or an agent resource. A service binding opens one service, or one sub-tree of one, and carries only enabled: search, browser, ticket, crm, canvas, cut, studio, feedback or workspace. workspace opens development units — list one, read one, start, stop, exec inside one, fetch, push, connect, and open a unit for a change — and opens neither publishing nor any production operation. The ticket service is bound by default: a service agent whose list has no ticket entry may call the ticket API, and {"type": "ticket", "enabled": false} removes it. Every other service stays closed until it is bound. An open service allows every public method of that service. At most 20 bindings per type, no repeated type and id, and each service type at most once. A session is authorized by the agent version it runs: newly added bindings apply only to new sessions, and a version saved with apply=false changes no access until it is applied. Applying a version that disables, removes or downgrades a binding revokes it immediately in running sessions on older versions. A resource that is not bound returns 404, a service that is not opened returns 403, and a write to a resource bound read_only returns 403 BINDING_READ_ONLY. Unknown types, fields on the wrong kind (id, access, customer_access or instructions on a service binding), wrong access and malformed ids return 400. The former databases, vector_stores and files fields are removed and return 400. Omit on create for the default: the ticket service only. Saving checks added or changed database, vector_store, media_library and file bindings in the organization: unknown or deleted ids return 400. If an owner is unavailable or takes more than 3 seconds, saving succeeds with verified=false for the affected bindings. Unchanged bindings keep their previous verification result and are not rechecked. workflow and script ids are not verified at save time.
74250
76062
  */
74251
76063
  bindings: Array<{
74252
76064
  /**
@@ -74261,6 +76073,10 @@ export type AgentsCreateResponses = {
74261
76073
  * database, vector_store and media_library accept read_only or read_write; file accepts read_only; model, workflow and script accept invoke. Any other combination returns 400.
74262
76074
  */
74263
76075
  access: 'read_only' | 'read_write' | 'invoke';
76076
+ /**
76077
+ * What a visitor's session (a terminal customer, ADR-163 §3) may do with this resource: read_only, read_write or invoke. Its scope is the intersection of this value and the binding's own access, so invoke needs both to be invoke. Limited to the accesses the type can grant: read_only or read_write for database, vector_store and media_library, read_only for file, read_only or invoke for model, workflow and script. Defaults to read_only. A member's session ignores it entirely; a visitor's session never receives a whole-service binding or an agent resource.
76078
+ */
76079
+ customer_access?: 'read_only' | 'read_write' | 'invoke';
74264
76080
  /**
74265
76081
  * Optional guidance for using this resource, up to 4096 characters; does not expand access.
74266
76082
  */
@@ -74685,6 +76501,10 @@ export type AgentsCreateResponses = {
74685
76501
  * Channel the agent was created through (for example api or console); null for historical agents whose channel is unknown. Display only. /agent/v1 only; /anthropic neither returns it.
74686
76502
  */
74687
76503
  creation_source: string | null;
76504
+ /**
76505
+ * Application that manages this agent (for example praxis-work); null when no application does. Set when the agent is created, or claimed once by an update that sends the same value in the Praxis-Managed-By header; never changes after. Archiving a managed agent without the managing application's Praxis-Managed-By header returns 409 AGENT_MANAGED_BY_APPLICATION; configuration stays changeable. An accident guard, not a security boundary. /agent/v1 only; /anthropic neither returns it.
76506
+ */
76507
+ managed_by: string | null;
74688
76508
  /**
74689
76509
  * Platform-wide identity number of the agent (8 characters), usable wherever an agent is addressed by identity_number; null when the agent has none. /agent/v1 only; /anthropic neither returns it.
74690
76510
  */
@@ -74896,7 +76716,7 @@ export type AgentsRetrieveResponses = {
74896
76716
  */
74897
76717
  note: string | null;
74898
76718
  /**
74899
- * Platform resources and services this service agent's codemode may reach, as one list of typed bindings. Only kind=service accepts a nonempty list; general agents return 400. There are two kinds. A resource binding names one resource with id and access: database (id db_..., read_only or read_write), vector_store (id vs_..., read_only or read_write), file (id file- plus 24 letters or digits, as the File API returns it; read_only), media_library (any id without ':' or whitespace, read_only or read_write), model (a model catalog id, invoke), workflow and script (id <namespace>/<name>, invoke). A service binding opens one service, or one sub-tree of one, and carries only enabled: search, browser, ticket, crm, canvas, cut, studio, feedback or workspace. workspace opens development units — list one, read one, start, stop, exec inside one, fetch, push, connect, and open a unit for a change — and opens neither publishing nor any production operation. The ticket service is bound by default: a service agent whose list has no ticket entry may call the ticket API, and {"type": "ticket", "enabled": false} removes it. Every other service stays closed until it is bound. An open service allows every public method of that service. At most 20 bindings per type, no repeated type and id, and each service type at most once. A session is authorized by the agent version it runs: newly added bindings apply only to new sessions, and a version saved with apply=false changes no access until it is applied. Applying a version that disables, removes or downgrades a binding revokes it immediately in running sessions on older versions. A resource that is not bound returns 404, a service that is not opened returns 403, and a write to a resource bound read_only returns 403 BINDING_READ_ONLY. Unknown types, fields on the wrong kind (id, access or instructions on a service binding), wrong access and malformed ids return 400. The former databases, vector_stores and files fields are removed and return 400. Omit on create for the default: the ticket service only. Saving checks added or changed database, vector_store, media_library and file bindings in the organization: unknown or deleted ids return 400. If an owner is unavailable or takes more than 3 seconds, saving succeeds with verified=false for the affected bindings. Unchanged bindings keep their previous verification result and are not rechecked. workflow and script ids are not verified at save time.
76719
+ * Platform resources and services this service agent's codemode may reach, as one list of typed bindings. Only kind=service accepts a nonempty list; general agents return 400. There are two kinds. A resource binding names one resource with id and access: database (id db_..., read_only or read_write), vector_store (id vs_..., read_only or read_write), file (id file- plus 24 letters or digits, as the File API returns it; read_only), media_library (any id without ':' or whitespace, read_only or read_write), model (a model catalog id, invoke), workflow and script (id <namespace>/<name>, invoke). A resource binding may also carry customer_access (read_only by default): it caps what a terminal customer's session (a visitor, ADR-163 §3) may do with that one resource, at the intersection of customer_access and the binding's own access — invoke (call) and read_write (change) are different axes, so only a matching pair keeps its access and any other pair falls to read_only. Its value must be one the type can grant: read_only or read_write for database, vector_store and media_library, read_only for file, and read_only or invoke for model, workflow and script. A member's session ignores it, so raising it never widens what members may do. A visitor's session never receives a whole-service binding (the default ticket service included) or an agent resource. A service binding opens one service, or one sub-tree of one, and carries only enabled: search, browser, ticket, crm, canvas, cut, studio, feedback or workspace. workspace opens development units — list one, read one, start, stop, exec inside one, fetch, push, connect, and open a unit for a change — and opens neither publishing nor any production operation. The ticket service is bound by default: a service agent whose list has no ticket entry may call the ticket API, and {"type": "ticket", "enabled": false} removes it. Every other service stays closed until it is bound. An open service allows every public method of that service. At most 20 bindings per type, no repeated type and id, and each service type at most once. A session is authorized by the agent version it runs: newly added bindings apply only to new sessions, and a version saved with apply=false changes no access until it is applied. Applying a version that disables, removes or downgrades a binding revokes it immediately in running sessions on older versions. A resource that is not bound returns 404, a service that is not opened returns 403, and a write to a resource bound read_only returns 403 BINDING_READ_ONLY. Unknown types, fields on the wrong kind (id, access, customer_access or instructions on a service binding), wrong access and malformed ids return 400. The former databases, vector_stores and files fields are removed and return 400. Omit on create for the default: the ticket service only. Saving checks added or changed database, vector_store, media_library and file bindings in the organization: unknown or deleted ids return 400. If an owner is unavailable or takes more than 3 seconds, saving succeeds with verified=false for the affected bindings. Unchanged bindings keep their previous verification result and are not rechecked. workflow and script ids are not verified at save time.
74900
76720
  */
74901
76721
  bindings: Array<{
74902
76722
  /**
@@ -74911,6 +76731,10 @@ export type AgentsRetrieveResponses = {
74911
76731
  * database, vector_store and media_library accept read_only or read_write; file accepts read_only; model, workflow and script accept invoke. Any other combination returns 400.
74912
76732
  */
74913
76733
  access: 'read_only' | 'read_write' | 'invoke';
76734
+ /**
76735
+ * What a visitor's session (a terminal customer, ADR-163 §3) may do with this resource: read_only, read_write or invoke. Its scope is the intersection of this value and the binding's own access, so invoke needs both to be invoke. Limited to the accesses the type can grant: read_only or read_write for database, vector_store and media_library, read_only for file, read_only or invoke for model, workflow and script. Defaults to read_only. A member's session ignores it entirely; a visitor's session never receives a whole-service binding or an agent resource.
76736
+ */
76737
+ customer_access?: 'read_only' | 'read_write' | 'invoke';
74914
76738
  /**
74915
76739
  * Optional guidance for using this resource, up to 4096 characters; does not expand access.
74916
76740
  */
@@ -75335,6 +77159,10 @@ export type AgentsRetrieveResponses = {
75335
77159
  * Channel the agent was created through (for example api or console); null for historical agents whose channel is unknown. Display only. /agent/v1 only; /anthropic neither returns it.
75336
77160
  */
75337
77161
  creation_source: string | null;
77162
+ /**
77163
+ * Application that manages this agent (for example praxis-work); null when no application does. Set when the agent is created, or claimed once by an update that sends the same value in the Praxis-Managed-By header; never changes after. Archiving a managed agent without the managing application's Praxis-Managed-By header returns 409 AGENT_MANAGED_BY_APPLICATION; configuration stays changeable. An accident guard, not a security boundary. /agent/v1 only; /anthropic neither returns it.
77164
+ */
77165
+ managed_by: string | null;
75338
77166
  /**
75339
77167
  * Platform-wide identity number of the agent (8 characters), usable wherever an agent is addressed by identity_number; null when the agent has none. /agent/v1 only; /anthropic neither returns it.
75340
77168
  */
@@ -75481,6 +77309,10 @@ export type AgentsUpdateData = {
75481
77309
  * database, vector_store and media_library accept read_only or read_write; file accepts read_only; model, workflow and script accept invoke. Any other combination returns 400.
75482
77310
  */
75483
77311
  access: 'read_only' | 'read_write' | 'invoke';
77312
+ /**
77313
+ * What a visitor's session (a terminal customer, ADR-163 §3) may do with this resource: read_only, read_write or invoke. Its scope is the intersection of this value and the binding's own access, so invoke needs both to be invoke. Limited to the accesses the type can grant: read_only or read_write for database, vector_store and media_library, read_only for file, read_only or invoke for model, workflow and script. Defaults to read_only. A member's session ignores it entirely; a visitor's session never receives a whole-service binding or an agent resource.
77314
+ */
77315
+ customer_access?: 'read_only' | 'read_write' | 'invoke';
75484
77316
  /**
75485
77317
  * Optional guidance for using this resource, up to 4096 characters; does not expand access.
75486
77318
  */
@@ -76106,7 +77938,7 @@ export type AgentsUpdateResponses = {
76106
77938
  */
76107
77939
  note: string | null;
76108
77940
  /**
76109
- * Platform resources and services this service agent's codemode may reach, as one list of typed bindings. Only kind=service accepts a nonempty list; general agents return 400. There are two kinds. A resource binding names one resource with id and access: database (id db_..., read_only or read_write), vector_store (id vs_..., read_only or read_write), file (id file- plus 24 letters or digits, as the File API returns it; read_only), media_library (any id without ':' or whitespace, read_only or read_write), model (a model catalog id, invoke), workflow and script (id <namespace>/<name>, invoke). A service binding opens one service, or one sub-tree of one, and carries only enabled: search, browser, ticket, crm, canvas, cut, studio, feedback or workspace. workspace opens development units — list one, read one, start, stop, exec inside one, fetch, push, connect, and open a unit for a change — and opens neither publishing nor any production operation. The ticket service is bound by default: a service agent whose list has no ticket entry may call the ticket API, and {"type": "ticket", "enabled": false} removes it. Every other service stays closed until it is bound. An open service allows every public method of that service. At most 20 bindings per type, no repeated type and id, and each service type at most once. A session is authorized by the agent version it runs: newly added bindings apply only to new sessions, and a version saved with apply=false changes no access until it is applied. Applying a version that disables, removes or downgrades a binding revokes it immediately in running sessions on older versions. A resource that is not bound returns 404, a service that is not opened returns 403, and a write to a resource bound read_only returns 403 BINDING_READ_ONLY. Unknown types, fields on the wrong kind (id, access or instructions on a service binding), wrong access and malformed ids return 400. The former databases, vector_stores and files fields are removed and return 400. Omit on create for the default: the ticket service only. Saving checks added or changed database, vector_store, media_library and file bindings in the organization: unknown or deleted ids return 400. If an owner is unavailable or takes more than 3 seconds, saving succeeds with verified=false for the affected bindings. Unchanged bindings keep their previous verification result and are not rechecked. workflow and script ids are not verified at save time.
77941
+ * Platform resources and services this service agent's codemode may reach, as one list of typed bindings. Only kind=service accepts a nonempty list; general agents return 400. There are two kinds. A resource binding names one resource with id and access: database (id db_..., read_only or read_write), vector_store (id vs_..., read_only or read_write), file (id file- plus 24 letters or digits, as the File API returns it; read_only), media_library (any id without ':' or whitespace, read_only or read_write), model (a model catalog id, invoke), workflow and script (id <namespace>/<name>, invoke). A resource binding may also carry customer_access (read_only by default): it caps what a terminal customer's session (a visitor, ADR-163 §3) may do with that one resource, at the intersection of customer_access and the binding's own access — invoke (call) and read_write (change) are different axes, so only a matching pair keeps its access and any other pair falls to read_only. Its value must be one the type can grant: read_only or read_write for database, vector_store and media_library, read_only for file, and read_only or invoke for model, workflow and script. A member's session ignores it, so raising it never widens what members may do. A visitor's session never receives a whole-service binding (the default ticket service included) or an agent resource. A service binding opens one service, or one sub-tree of one, and carries only enabled: search, browser, ticket, crm, canvas, cut, studio, feedback or workspace. workspace opens development units — list one, read one, start, stop, exec inside one, fetch, push, connect, and open a unit for a change — and opens neither publishing nor any production operation. The ticket service is bound by default: a service agent whose list has no ticket entry may call the ticket API, and {"type": "ticket", "enabled": false} removes it. Every other service stays closed until it is bound. An open service allows every public method of that service. At most 20 bindings per type, no repeated type and id, and each service type at most once. A session is authorized by the agent version it runs: newly added bindings apply only to new sessions, and a version saved with apply=false changes no access until it is applied. Applying a version that disables, removes or downgrades a binding revokes it immediately in running sessions on older versions. A resource that is not bound returns 404, a service that is not opened returns 403, and a write to a resource bound read_only returns 403 BINDING_READ_ONLY. Unknown types, fields on the wrong kind (id, access, customer_access or instructions on a service binding), wrong access and malformed ids return 400. The former databases, vector_stores and files fields are removed and return 400. Omit on create for the default: the ticket service only. Saving checks added or changed database, vector_store, media_library and file bindings in the organization: unknown or deleted ids return 400. If an owner is unavailable or takes more than 3 seconds, saving succeeds with verified=false for the affected bindings. Unchanged bindings keep their previous verification result and are not rechecked. workflow and script ids are not verified at save time.
76110
77942
  */
76111
77943
  bindings: Array<{
76112
77944
  /**
@@ -76121,6 +77953,10 @@ export type AgentsUpdateResponses = {
76121
77953
  * database, vector_store and media_library accept read_only or read_write; file accepts read_only; model, workflow and script accept invoke. Any other combination returns 400.
76122
77954
  */
76123
77955
  access: 'read_only' | 'read_write' | 'invoke';
77956
+ /**
77957
+ * What a visitor's session (a terminal customer, ADR-163 §3) may do with this resource: read_only, read_write or invoke. Its scope is the intersection of this value and the binding's own access, so invoke needs both to be invoke. Limited to the accesses the type can grant: read_only or read_write for database, vector_store and media_library, read_only for file, read_only or invoke for model, workflow and script. Defaults to read_only. A member's session ignores it entirely; a visitor's session never receives a whole-service binding or an agent resource.
77958
+ */
77959
+ customer_access?: 'read_only' | 'read_write' | 'invoke';
76124
77960
  /**
76125
77961
  * Optional guidance for using this resource, up to 4096 characters; does not expand access.
76126
77962
  */
@@ -76545,6 +78381,10 @@ export type AgentsUpdateResponses = {
76545
78381
  * Channel the agent was created through (for example api or console); null for historical agents whose channel is unknown. Display only. /agent/v1 only; /anthropic neither returns it.
76546
78382
  */
76547
78383
  creation_source: string | null;
78384
+ /**
78385
+ * Application that manages this agent (for example praxis-work); null when no application does. Set when the agent is created, or claimed once by an update that sends the same value in the Praxis-Managed-By header; never changes after. Archiving a managed agent without the managing application's Praxis-Managed-By header returns 409 AGENT_MANAGED_BY_APPLICATION; configuration stays changeable. An accident guard, not a security boundary. /agent/v1 only; /anthropic neither returns it.
78386
+ */
78387
+ managed_by: string | null;
76548
78388
  /**
76549
78389
  * Platform-wide identity number of the agent (8 characters), usable wherever an agent is addressed by identity_number; null when the agent has none. /agent/v1 only; /anthropic neither returns it.
76550
78390
  */
@@ -76742,7 +78582,7 @@ export type AgentsArchiveResponses = {
76742
78582
  */
76743
78583
  note: string | null;
76744
78584
  /**
76745
- * Platform resources and services this service agent's codemode may reach, as one list of typed bindings. Only kind=service accepts a nonempty list; general agents return 400. There are two kinds. A resource binding names one resource with id and access: database (id db_..., read_only or read_write), vector_store (id vs_..., read_only or read_write), file (id file- plus 24 letters or digits, as the File API returns it; read_only), media_library (any id without ':' or whitespace, read_only or read_write), model (a model catalog id, invoke), workflow and script (id <namespace>/<name>, invoke). A service binding opens one service, or one sub-tree of one, and carries only enabled: search, browser, ticket, crm, canvas, cut, studio, feedback or workspace. workspace opens development units — list one, read one, start, stop, exec inside one, fetch, push, connect, and open a unit for a change — and opens neither publishing nor any production operation. The ticket service is bound by default: a service agent whose list has no ticket entry may call the ticket API, and {"type": "ticket", "enabled": false} removes it. Every other service stays closed until it is bound. An open service allows every public method of that service. At most 20 bindings per type, no repeated type and id, and each service type at most once. A session is authorized by the agent version it runs: newly added bindings apply only to new sessions, and a version saved with apply=false changes no access until it is applied. Applying a version that disables, removes or downgrades a binding revokes it immediately in running sessions on older versions. A resource that is not bound returns 404, a service that is not opened returns 403, and a write to a resource bound read_only returns 403 BINDING_READ_ONLY. Unknown types, fields on the wrong kind (id, access or instructions on a service binding), wrong access and malformed ids return 400. The former databases, vector_stores and files fields are removed and return 400. Omit on create for the default: the ticket service only. Saving checks added or changed database, vector_store, media_library and file bindings in the organization: unknown or deleted ids return 400. If an owner is unavailable or takes more than 3 seconds, saving succeeds with verified=false for the affected bindings. Unchanged bindings keep their previous verification result and are not rechecked. workflow and script ids are not verified at save time.
78585
+ * Platform resources and services this service agent's codemode may reach, as one list of typed bindings. Only kind=service accepts a nonempty list; general agents return 400. There are two kinds. A resource binding names one resource with id and access: database (id db_..., read_only or read_write), vector_store (id vs_..., read_only or read_write), file (id file- plus 24 letters or digits, as the File API returns it; read_only), media_library (any id without ':' or whitespace, read_only or read_write), model (a model catalog id, invoke), workflow and script (id <namespace>/<name>, invoke). A resource binding may also carry customer_access (read_only by default): it caps what a terminal customer's session (a visitor, ADR-163 §3) may do with that one resource, at the intersection of customer_access and the binding's own access — invoke (call) and read_write (change) are different axes, so only a matching pair keeps its access and any other pair falls to read_only. Its value must be one the type can grant: read_only or read_write for database, vector_store and media_library, read_only for file, and read_only or invoke for model, workflow and script. A member's session ignores it, so raising it never widens what members may do. A visitor's session never receives a whole-service binding (the default ticket service included) or an agent resource. A service binding opens one service, or one sub-tree of one, and carries only enabled: search, browser, ticket, crm, canvas, cut, studio, feedback or workspace. workspace opens development units — list one, read one, start, stop, exec inside one, fetch, push, connect, and open a unit for a change — and opens neither publishing nor any production operation. The ticket service is bound by default: a service agent whose list has no ticket entry may call the ticket API, and {"type": "ticket", "enabled": false} removes it. Every other service stays closed until it is bound. An open service allows every public method of that service. At most 20 bindings per type, no repeated type and id, and each service type at most once. A session is authorized by the agent version it runs: newly added bindings apply only to new sessions, and a version saved with apply=false changes no access until it is applied. Applying a version that disables, removes or downgrades a binding revokes it immediately in running sessions on older versions. A resource that is not bound returns 404, a service that is not opened returns 403, and a write to a resource bound read_only returns 403 BINDING_READ_ONLY. Unknown types, fields on the wrong kind (id, access, customer_access or instructions on a service binding), wrong access and malformed ids return 400. The former databases, vector_stores and files fields are removed and return 400. Omit on create for the default: the ticket service only. Saving checks added or changed database, vector_store, media_library and file bindings in the organization: unknown or deleted ids return 400. If an owner is unavailable or takes more than 3 seconds, saving succeeds with verified=false for the affected bindings. Unchanged bindings keep their previous verification result and are not rechecked. workflow and script ids are not verified at save time.
76746
78586
  */
76747
78587
  bindings: Array<{
76748
78588
  /**
@@ -76757,6 +78597,10 @@ export type AgentsArchiveResponses = {
76757
78597
  * database, vector_store and media_library accept read_only or read_write; file accepts read_only; model, workflow and script accept invoke. Any other combination returns 400.
76758
78598
  */
76759
78599
  access: 'read_only' | 'read_write' | 'invoke';
78600
+ /**
78601
+ * What a visitor's session (a terminal customer, ADR-163 §3) may do with this resource: read_only, read_write or invoke. Its scope is the intersection of this value and the binding's own access, so invoke needs both to be invoke. Limited to the accesses the type can grant: read_only or read_write for database, vector_store and media_library, read_only for file, read_only or invoke for model, workflow and script. Defaults to read_only. A member's session ignores it entirely; a visitor's session never receives a whole-service binding or an agent resource.
78602
+ */
78603
+ customer_access?: 'read_only' | 'read_write' | 'invoke';
76760
78604
  /**
76761
78605
  * Optional guidance for using this resource, up to 4096 characters; does not expand access.
76762
78606
  */
@@ -77159,6 +79003,10 @@ export type AgentsArchiveResponses = {
77159
79003
  * Channel the agent was created through (for example api or console); null for historical agents whose channel is unknown. Display only. /agent/v1 only; /anthropic neither returns it.
77160
79004
  */
77161
79005
  creation_source: string | null;
79006
+ /**
79007
+ * Application that manages this agent (for example praxis-work); null when no application does. Set when the agent is created, or claimed once by an update that sends the same value in the Praxis-Managed-By header; never changes after. Archiving a managed agent without the managing application's Praxis-Managed-By header returns 409 AGENT_MANAGED_BY_APPLICATION; configuration stays changeable. An accident guard, not a security boundary. /agent/v1 only; /anthropic neither returns it.
79008
+ */
79009
+ managed_by: string | null;
77162
79010
  /**
77163
79011
  * Platform-wide identity number of the agent (8 characters), usable wherever an agent is addressed by identity_number; null when the agent has none. /agent/v1 only; /anthropic neither returns it.
77164
79012
  */
@@ -77374,7 +79222,7 @@ export type AgentsVersionsListResponses = {
77374
79222
  */
77375
79223
  note: string | null;
77376
79224
  /**
77377
- * Platform resources and services this service agent's codemode may reach, as one list of typed bindings. Only kind=service accepts a nonempty list; general agents return 400. There are two kinds. A resource binding names one resource with id and access: database (id db_..., read_only or read_write), vector_store (id vs_..., read_only or read_write), file (id file- plus 24 letters or digits, as the File API returns it; read_only), media_library (any id without ':' or whitespace, read_only or read_write), model (a model catalog id, invoke), workflow and script (id <namespace>/<name>, invoke). A service binding opens one service, or one sub-tree of one, and carries only enabled: search, browser, ticket, crm, canvas, cut, studio, feedback or workspace. workspace opens development units — list one, read one, start, stop, exec inside one, fetch, push, connect, and open a unit for a change — and opens neither publishing nor any production operation. The ticket service is bound by default: a service agent whose list has no ticket entry may call the ticket API, and {"type": "ticket", "enabled": false} removes it. Every other service stays closed until it is bound. An open service allows every public method of that service. At most 20 bindings per type, no repeated type and id, and each service type at most once. A session is authorized by the agent version it runs: newly added bindings apply only to new sessions, and a version saved with apply=false changes no access until it is applied. Applying a version that disables, removes or downgrades a binding revokes it immediately in running sessions on older versions. A resource that is not bound returns 404, a service that is not opened returns 403, and a write to a resource bound read_only returns 403 BINDING_READ_ONLY. Unknown types, fields on the wrong kind (id, access or instructions on a service binding), wrong access and malformed ids return 400. The former databases, vector_stores and files fields are removed and return 400. Omit on create for the default: the ticket service only. Saving checks added or changed database, vector_store, media_library and file bindings in the organization: unknown or deleted ids return 400. If an owner is unavailable or takes more than 3 seconds, saving succeeds with verified=false for the affected bindings. Unchanged bindings keep their previous verification result and are not rechecked. workflow and script ids are not verified at save time.
79225
+ * Platform resources and services this service agent's codemode may reach, as one list of typed bindings. Only kind=service accepts a nonempty list; general agents return 400. There are two kinds. A resource binding names one resource with id and access: database (id db_..., read_only or read_write), vector_store (id vs_..., read_only or read_write), file (id file- plus 24 letters or digits, as the File API returns it; read_only), media_library (any id without ':' or whitespace, read_only or read_write), model (a model catalog id, invoke), workflow and script (id <namespace>/<name>, invoke). A resource binding may also carry customer_access (read_only by default): it caps what a terminal customer's session (a visitor, ADR-163 §3) may do with that one resource, at the intersection of customer_access and the binding's own access — invoke (call) and read_write (change) are different axes, so only a matching pair keeps its access and any other pair falls to read_only. Its value must be one the type can grant: read_only or read_write for database, vector_store and media_library, read_only for file, and read_only or invoke for model, workflow and script. A member's session ignores it, so raising it never widens what members may do. A visitor's session never receives a whole-service binding (the default ticket service included) or an agent resource. A service binding opens one service, or one sub-tree of one, and carries only enabled: search, browser, ticket, crm, canvas, cut, studio, feedback or workspace. workspace opens development units — list one, read one, start, stop, exec inside one, fetch, push, connect, and open a unit for a change — and opens neither publishing nor any production operation. The ticket service is bound by default: a service agent whose list has no ticket entry may call the ticket API, and {"type": "ticket", "enabled": false} removes it. Every other service stays closed until it is bound. An open service allows every public method of that service. At most 20 bindings per type, no repeated type and id, and each service type at most once. A session is authorized by the agent version it runs: newly added bindings apply only to new sessions, and a version saved with apply=false changes no access until it is applied. Applying a version that disables, removes or downgrades a binding revokes it immediately in running sessions on older versions. A resource that is not bound returns 404, a service that is not opened returns 403, and a write to a resource bound read_only returns 403 BINDING_READ_ONLY. Unknown types, fields on the wrong kind (id, access, customer_access or instructions on a service binding), wrong access and malformed ids return 400. The former databases, vector_stores and files fields are removed and return 400. Omit on create for the default: the ticket service only. Saving checks added or changed database, vector_store, media_library and file bindings in the organization: unknown or deleted ids return 400. If an owner is unavailable or takes more than 3 seconds, saving succeeds with verified=false for the affected bindings. Unchanged bindings keep their previous verification result and are not rechecked. workflow and script ids are not verified at save time.
77378
79226
  */
77379
79227
  bindings: Array<{
77380
79228
  /**
@@ -77389,6 +79237,10 @@ export type AgentsVersionsListResponses = {
77389
79237
  * database, vector_store and media_library accept read_only or read_write; file accepts read_only; model, workflow and script accept invoke. Any other combination returns 400.
77390
79238
  */
77391
79239
  access: 'read_only' | 'read_write' | 'invoke';
79240
+ /**
79241
+ * What a visitor's session (a terminal customer, ADR-163 §3) may do with this resource: read_only, read_write or invoke. Its scope is the intersection of this value and the binding's own access, so invoke needs both to be invoke. Limited to the accesses the type can grant: read_only or read_write for database, vector_store and media_library, read_only for file, read_only or invoke for model, workflow and script. Defaults to read_only. A member's session ignores it entirely; a visitor's session never receives a whole-service binding or an agent resource.
79242
+ */
79243
+ customer_access?: 'read_only' | 'read_write' | 'invoke';
77392
79244
  /**
77393
79245
  * Optional guidance for using this resource, up to 4096 characters; does not expand access.
77394
79246
  */
@@ -77813,6 +79665,10 @@ export type AgentsVersionsListResponses = {
77813
79665
  * Channel the agent was created through (for example api or console); null for historical agents whose channel is unknown. Display only. /agent/v1 only; /anthropic neither returns it.
77814
79666
  */
77815
79667
  creation_source: string | null;
79668
+ /**
79669
+ * Application that manages this agent (for example praxis-work); null when no application does. Set when the agent is created, or claimed once by an update that sends the same value in the Praxis-Managed-By header; never changes after. Archiving a managed agent without the managing application's Praxis-Managed-By header returns 409 AGENT_MANAGED_BY_APPLICATION; configuration stays changeable. An accident guard, not a security boundary. /agent/v1 only; /anthropic neither returns it.
79670
+ */
79671
+ managed_by: string | null;
77816
79672
  /**
77817
79673
  * Platform-wide identity number of the agent (8 characters), usable wherever an agent is addressed by identity_number; null when the agent has none. /agent/v1 only; /anthropic neither returns it.
77818
79674
  */
@@ -97055,7 +98911,7 @@ export type DevopsChangesGetData = {
97055
98911
  body?: never;
97056
98912
  path: {
97057
98913
  /**
97058
- * The change's id, which is its branch name <type>/<slug> from a change list or create answer; the slash must be percent-encoded, so feat/run-page-v2 is sent as feat%2Frun-page-v2.
98914
+ * The change's id, which is its branch name <type>/<slug> from a change list or create answer. Give it as it comes back — `feat/run-page-v2`: the SDK and the CLI encode the slash themselves, and an id that is already percent-encoded is encoded a second time and answers CHANGE_NOT_FOUND. Only a caller writing the HTTP request by hand sends feat%2Frun-page-v2.
97059
98915
  */
97060
98916
  id: string;
97061
98917
  };
@@ -97092,7 +98948,7 @@ export type DevopsChangesAbandonData = {
97092
98948
  body: DevopsChangeAbandonRequest;
97093
98949
  path: {
97094
98950
  /**
97095
- * The change's id, which is its branch name <type>/<slug> from a change list or create answer; the slash must be percent-encoded, so feat/run-page-v2 is sent as feat%2Frun-page-v2.
98951
+ * The change's id, which is its branch name <type>/<slug> from a change list or create answer. Give it as it comes back — `feat/run-page-v2`: the SDK and the CLI encode the slash themselves, and an id that is already percent-encoded is encoded a second time and answers CHANGE_NOT_FOUND. Only a caller writing the HTTP request by hand sends feat%2Frun-page-v2.
97096
98952
  */
97097
98953
  id: string;
97098
98954
  };
@@ -97133,7 +98989,7 @@ export type DevopsChangesMarkLastSliceData = {
97133
98989
  body: DevopsChangeMarkLastSliceRequest;
97134
98990
  path: {
97135
98991
  /**
97136
- * The change's id, which is its branch name <type>/<slug> from a change list or create answer; the slash must be percent-encoded, so feat/run-page-v2 is sent as feat%2Frun-page-v2.
98992
+ * The change's id, which is its branch name <type>/<slug> from a change list or create answer. Give it as it comes back — `feat/run-page-v2`: the SDK and the CLI encode the slash themselves, and an id that is already percent-encoded is encoded a second time and answers CHANGE_NOT_FOUND. Only a caller writing the HTTP request by hand sends feat%2Frun-page-v2.
97137
98993
  */
97138
98994
  id: string;
97139
98995
  };
@@ -97174,7 +99030,7 @@ export type DevopsChangesOpenPullRequestData = {
97174
99030
  body?: DevopsChangeOpenPullRequestRequest;
97175
99031
  path: {
97176
99032
  /**
97177
- * The change's id, which is its branch name <type>/<slug> from a change list or create answer; the slash must be percent-encoded, so feat/run-page-v2 is sent as feat%2Frun-page-v2.
99033
+ * The change's id, which is its branch name <type>/<slug> from a change list or create answer. Give it as it comes back — `feat/run-page-v2`: the SDK and the CLI encode the slash themselves, and an id that is already percent-encoded is encoded a second time and answers CHANGE_NOT_FOUND. Only a caller writing the HTTP request by hand sends feat%2Frun-page-v2.
97178
99034
  */
97179
99035
  id: string;
97180
99036
  };
@@ -97199,7 +99055,7 @@ export type DevopsChangesOpenPullRequestErrors = {
97199
99055
  */
97200
99056
  404: DevopsDevOpsError;
97201
99057
  /**
97202
- * PULL_REQUEST_REFUSED when GitHub would not open it and the branch has no open pull request (most often nothing has been pushed yet); the message carries GitHub's words.
99058
+ * PULL_REQUEST_REFUSED when GitHub would not open it and the head has no pull request at all (most often nothing has been pushed yet); the message carries GitHub's words. PULL_REQUEST_NOT_OPEN when the head's pull request is merged or closed — a description written for a pull request that already landed — with that pull request's number, its state and the branch in the message.
97203
99059
  */
97204
99060
  409: DevopsDevOpsError;
97205
99061
  /**
@@ -97219,7 +99075,7 @@ export type DevopsChangesGitCredentialData = {
97219
99075
  body?: never;
97220
99076
  path: {
97221
99077
  /**
97222
- * The change's id, which is its branch name <type>/<slug> from a change list or create answer; the slash must be percent-encoded, so feat/run-page-v2 is sent as feat%2Frun-page-v2.
99078
+ * The change's id, which is its branch name <type>/<slug> from a change list or create answer. Give it as it comes back — `feat/run-page-v2`: the SDK and the CLI encode the slash themselves, and an id that is already percent-encoded is encoded a second time and answers CHANGE_NOT_FOUND. Only a caller writing the HTTP request by hand sends feat%2Frun-page-v2.
97223
99079
  */
97224
99080
  id: string;
97225
99081
  };
@@ -102893,7 +104749,7 @@ export type MediaEditAssetData = {
102893
104749
  };
102894
104750
  export type MediaEditAssetErrors = {
102895
104751
  /**
102896
- * OPERATION_NOT_SUPPORTED: the requested operation type is not performed on this asset type in this release — image edits support variations, inpaint, erase, replace_object, recolor and replace_background, video and image remove_background are supported, and upscale, enhance_voice, reframe, redact, trim, mute and crop run through Media’s processing lane (upscale on a picture or a video, enhance_voice on a recording or a video’s audio, reframe, redact, trim, mute and crop on a video), as do erase and replace_person on a video. An operation whose model list is empty — matting included — is refused with the model field named. REFERENCE_TYPE_MISMATCH: the source asset or a referenced asset has a material type the chosen model cannot edit, or the edit’s mask is not a PNG file identifier; INVALID_PARAMS: the operation is missing a field it requires, names an enum value outside the accepted set, is given an output or model on an image source, or names a matting model the capabilities do not offer. Select a supported operation and correct the reported field.
104752
+ * OPERATION_NOT_SUPPORTED: the requested operation type is not performed on this asset type in this release — image edits support variations, inpaint, erase, replace_object, recolor and replace_background, video and image remove_background are supported, and upscale, enhance_voice, reframe, redact, trim, mute and crop run through Media’s processing lane (upscale on a picture or a video, enhance_voice on a recording or a video’s audio, reframe, redact, trim, mute and crop on a video), as do erase, replace_person, lip_sync and animate_person on a video and talking_avatar on an image. An operation whose model list is empty — matting included — is refused with the model field named. REFERENCE_TYPE_MISMATCH: the source asset or a referenced asset has a material type the chosen model cannot edit, or the edit’s mask is not a PNG file identifier; INVALID_PARAMS: the operation is missing a field it requires, names an enum value outside the accepted set, is given an output or model on an image source, or names a matting model the capabilities do not offer. Select a supported operation and correct the reported field.
102897
104753
  */
102898
104754
  400: MediaMediaError;
102899
104755
  /**