@deepraxis/sdk 0.1.0-dev.331f4e7 → 0.1.0-dev.3a7324b

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.
@@ -45,7 +45,7 @@ export declare const operations: readonly [{
45
45
  readonly resource: "agent.agents";
46
46
  readonly method: "create";
47
47
  readonly summary: "Create agent";
48
- readonly description: "Create a reusable agent definition, then pass its returned id to sessions.create to start a conversation. The definition includes model, system prompt, tools, MCP servers and an optional multiagent roster. It is saved as version 1; real updates create new versions. Unlike Anthropic Managed Agents, nonempty skills attachments return 400; the native skill tool is separate from the skills field. Use tools: [{type: \"agent_toolset_20260401\"}] for built-in tools including codemode, skill and agent; inspect toolsets.list for names and schemas, and keep bash enabled for native additions. To offer only some tools, set default_config: {enabled: false} and list the tools to keep in configs, e.g. tools: [{type: \"agent_toolset_20260401\", default_config: {enabled: false}, configs: [{name: \"codemode\", enabled: true}, {name: \"bash\", enabled: true, permission_policy: {type: \"always_ask\"}}]}]; every tool not listed, including todo_write, enter_plan_mode, ask_user_question and goal_read, follows default_config, and the response echoes it. codemode runs through bash, so enabling codemode while bash is disabled returns 400. Optional mcp_toolset entries pair with mcp_servers. model accepts platform model IDs such as deepseek-flash, not only the Claude IDs in the protocol examples. model.settings.reasoning sets default thinking; other extra model controls return 400. Example: {\"name\":\"helper\",\"model\":{\"id\":\"deepseek-flash\"},\"tools\":[{\"type\":\"agent_toolset_20260401\"}]}.";
48
+ readonly description: "Create a reusable agent definition, then pass its returned id to sessions.create to start a conversation. The definition includes model, system prompt, tools, MCP servers and an optional multiagent roster. It is saved as version 1; real updates create new versions. skills attaches uploaded custom skills as [{type: \"custom\", skill_id, version?}] (skill_id from skills.create or skills.list; at most 20, no repeated skill_id). Omit version, or send \"latest\", to use the skill's newest version when a session starts. type anthropic returns 400. Use tools: [{type: \"agent_toolset_20260401\"}] for built-in tools including codemode, skill and agent; inspect toolsets.list for names and schemas, and keep bash enabled for native additions. To offer only some tools, set default_config: {enabled: false} and list the tools to keep in configs, e.g. tools: [{type: \"agent_toolset_20260401\", default_config: {enabled: false}, configs: [{name: \"codemode\", enabled: true}, {name: \"bash\", enabled: true, permission_policy: {type: \"always_ask\"}}]}]; every tool not listed, including todo_write, enter_plan_mode, ask_user_question and goal_read, follows default_config, and the response echoes it. codemode runs through bash, so enabling codemode while bash is disabled returns 400. Optional mcp_toolset entries pair with mcp_servers. model accepts platform model IDs such as deepseek-flash, not only the Claude IDs in the protocol examples. model.settings.reasoning sets default thinking; other extra model controls return 400. model and every models.allowed entry must be a catalog model that can run an agent: an unknown id returns 400 \"model <id> is not in the model catalog\" and an embedding, image or speech model returns 400 \"model <id> cannot run an agent\". name is a label, not a unique key: 1 to 256 characters after trimming, no NUL or line breaks. avatar is trimmed, must not contain spaces or point at a loopback, private or internal host, and its scheme is stored in lowercase. script and workflow binding ids are stored in lowercase, the form automation matches; bindings together with environment_id null return 400 because bindings need a machine. Example: {\"name\":\"helper\",\"model\":{\"id\":\"deepseek-flash\"},\"tools\":[{\"type\":\"agent_toolset_20260401\"}]}.";
49
49
  readonly http: "POST";
50
50
  readonly path: "/agent/v1/agents";
51
51
  readonly streaming: "no";
@@ -58,12 +58,12 @@ export declare const operations: readonly [{
58
58
  readonly name: "model";
59
59
  readonly type: "object";
60
60
  readonly required: true;
61
- readonly description: "Model identifier. Accepts the\n[model string](https://platform.claude.com/docs/en/about-claude/models/overview#latest-models-comparison),\ne.g. `claude-opus-5`, or a `model_config` object for additional configuration\ncontrol";
61
+ readonly description: "A model id from the Praxis model catalog (`praxis.model.models.list`), or a `model_config` object for additional configuration control. Unlike Anthropic, Claude model ids other than those in the catalog are rejected.";
62
62
  }, {
63
63
  readonly name: "name";
64
64
  readonly type: "string";
65
65
  readonly required: true;
66
- readonly description: "Human-readable name for the agent.";
66
+ readonly description: "Display name of the agent, 1 to 256 characters after trimming, with no NUL or line breaks. A label, not a unique key: two agents may share a name.";
67
67
  }, {
68
68
  readonly name: "description";
69
69
  readonly type: "string";
@@ -90,7 +90,7 @@ export declare const operations: readonly [{
90
90
  readonly type: "array";
91
91
  readonly itemType: "object";
92
92
  readonly required: false;
93
- readonly description: "Skill attachments are not supported: a nonempty array returns 400. Omit this field or send an empty array; the native skill tool is configured separately through tools.";
93
+ readonly description: "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.";
94
94
  }, {
95
95
  readonly name: "system";
96
96
  readonly type: "string";
@@ -103,23 +103,11 @@ export declare const operations: readonly [{
103
103
  readonly required: false;
104
104
  readonly description: "Tool configurations available to the agent. Maximum of 128 tools\nacross all toolsets allowed.";
105
105
  }, {
106
- readonly name: "databases";
107
- readonly type: "array";
108
- readonly itemType: "object";
109
- readonly required: false;
110
- readonly description: "Database allowlist for platform resources accessible through service-agent codemode. Only kind=service accepts nonempty bindings; personal agents return 400. At most 20 bindings per resource type, with no duplicate ids. Newly added bindings apply only to new sessions; disabling or removing a binding immediately revokes access in running sessions. Unbound resources return 404; writes to read_only resources are refused. Other platform APIs return 403, except public API discovery. Invalid bindings and unknown item fields return 400. Omit on create for no bindings.";
111
- }, {
112
- readonly name: "vector_stores";
113
- readonly type: "array";
114
- readonly itemType: "object";
115
- readonly required: false;
116
- readonly description: "Knowledge vector store allowlist for platform resources accessible through service-agent codemode. Only kind=service accepts nonempty bindings; personal agents return 400. At most 20 bindings per resource type, with no duplicate ids. Newly added bindings apply only to new sessions; disabling or removing a binding immediately revokes access in running sessions. Unbound resources return 404; writes to read_only resources are refused. Other platform APIs return 403, except public API discovery. Invalid bindings and unknown item fields return 400. Omit on create for no bindings.";
117
- }, {
118
- readonly name: "files";
106
+ readonly name: "bindings";
119
107
  readonly type: "array";
120
108
  readonly itemType: "object";
121
109
  readonly required: false;
122
- readonly description: "File allowlist for platform resources accessible through service-agent codemode. Only kind=service accepts nonempty bindings; personal agents return 400. At most 20 bindings per resource type, with no duplicate ids. Newly added bindings apply only to new sessions; disabling or removing a binding immediately revokes access in running sessions. Unbound resources return 404; writes to read_only resources are refused. Other platform APIs return 403, except public API discovery. Invalid bindings and unknown item fields return 400. Omit on create for no bindings.";
110
+ readonly description: "Platform resources and services this service agent's codemode may reach, as one list of typed bindings. Only kind=service accepts a nonempty list; personal 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 a whole service and carries only enabled: search or browser. 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 no bindings.";
123
111
  }, {
124
112
  readonly name: "kind";
125
113
  readonly type: "string";
@@ -158,6 +146,22 @@ export declare const operations: readonly [{
158
146
  readonly type: "object";
159
147
  readonly required: false;
160
148
  readonly description: "Praxis extension: switchable model ids on /agent/v1 only. The default model must be included. When omitted, only the default model is selectable.";
149
+ }, {
150
+ readonly name: "avatar";
151
+ readonly type: "string";
152
+ readonly required: false;
153
+ readonly description: "Avatar image of the agent: an absolute https URL of at most 2048 characters, without credentials; any other value returns 400 avatar must be an https URL. It is the default picture in agent lists, the agent detail, the chat header and embedded chat when the embed appearance sets none. Saved with the agent version like other configuration, so apply=false keeps the previous avatar in effect until that version is applied. Omit on create for no avatar; on update, omit to keep it and send null to clear it. Both personal and service agents accept it. /agent/v1 only; /anthropic neither accepts nor returns it.";
154
+ }, {
155
+ readonly name: "environment_id";
156
+ readonly type: "string";
157
+ readonly required: false;
158
+ readonly description: "Default environment of a service agent: the environment_id a new session gets when it names none. Use light, node22 or the env_ id of an active environment of your organization; any other value returns 400 environment_id <id> was not found. null means no environment, so sessions are plain conversation without codemode or bash. Saved with the agent version like other configuration, so apply=false keeps the previous environment in effect for new sessions until that version is applied; a session that sets environment_id itself, null included, overrides it. Omit on create for light; on update, omit to keep it. Versions saved before this field existed read as light. Personal agents use a Computer: a non-null value returns 400 and the field is not returned. /agent/v1 only; /anthropic neither accepts nor returns it.";
159
+ }, {
160
+ readonly name: "vault_ids";
161
+ readonly type: "array";
162
+ readonly itemType: "string";
163
+ readonly required: false;
164
+ readonly description: "Default vaults of a service agent: the vault_ids a new session gets when it names none, so the agent's credentials follow the version. At most 50 ids without duplicates; each must be a vault of your organization that is not archived, otherwise 400 vault_ids[<index>] <id> was not found. Saved with the agent version like other configuration, so apply=false keeps the previous vaults in effect for new sessions until that version is applied; a session that sets vault_ids itself, [] included, overrides it. Omit on create for []; on update, omit to keep the list and send an array to replace it as a whole. Versions saved before this field existed read as []. Embed tokens use the vault_ids of the version they pin; vault_ids on the embed policy is deprecated, still accepted and ignored. Personal agents get no default vaults: a non-empty value returns 400 and the field is not returned. /agent/v1 only; /anthropic neither accepts nor returns it.";
161
165
  }, {
162
166
  readonly name: "preset";
163
167
  readonly type: "string";
@@ -189,7 +193,7 @@ export declare const operations: readonly [{
189
193
  readonly resource: "agent.agents";
190
194
  readonly method: "update";
191
195
  readonly summary: "Update agent";
192
- readonly description: "Update an agent. Send the current version in the body for optimistic concurrency: a stale version returns 409, and an update that changes nothing keeps the version number. Any real change saves a new version. apply defaults to true and moves active_version to the new version, or to the latest when configuration is unchanged; apply false saves without applying. version_note optionally records up to 280 characters on a newly created version. Existing sessions and tokens keep their version. Omitted fields keep their value. multiagent takes null or a coordinator roster; subagent_model keeps its value when omitted and is cleared by null. Archived agents cannot be updated. Unlike Anthropic Managed Agents, nonempty skills attachments return 400; use the native skill tool for available runtime skills.";
196
+ readonly description: "Update an agent. Send the current version in the body for optimistic concurrency: a stale version returns 409, and an update that changes nothing keeps the version number. Any real change saves a new version. apply defaults to true and moves active_version to the new version, or to the latest when configuration is unchanged; apply false saves without applying. version_note optionally records up to 280 characters on a newly created version. Existing sessions and tokens keep their version. Omitted fields keep their value. multiagent takes null or a coordinator roster; subagent_model keeps its value when omitted and is cleared by null. Archived agents cannot be updated. tools: [] removes every tool, while tools: null returns 400 (tools cannot be null; send [] to remove every tool). On update, omit skills to keep them, send an array to replace them, or send [] or null to clear them. skills attaches uploaded custom skills as [{type: \"custom\", skill_id, version?}] (skill_id from skills.create or skills.list; at most 20, no repeated skill_id). Omit version, or send \"latest\", to use the skill's newest version when a session starts. type anthropic returns 400.";
193
197
  readonly http: "POST";
194
198
  readonly path: "/agent/v1/agents/{agent_id}";
195
199
  readonly streaming: "no";
@@ -221,7 +225,7 @@ export declare const operations: readonly [{
221
225
  readonly name: "model";
222
226
  readonly type: "object";
223
227
  readonly required: false;
224
- readonly description: "Model identifier. Accepts the\n[model string](https://platform.claude.com/docs/en/about-claude/models/overview#latest-models-comparison),\ne.g. `claude-opus-5`, or a `model_config` object for additional configuration\ncontrol. Omit to preserve. Cannot be cleared.";
228
+ readonly description: "A model id from the Praxis model catalog (`praxis.model.models.list`), or a `model_config` object for additional configuration control. Unlike Anthropic, Claude model ids other than those in the catalog are rejected.";
225
229
  }, {
226
230
  readonly name: "multiagent";
227
231
  readonly type: "object";
@@ -231,13 +235,13 @@ export declare const operations: readonly [{
231
235
  readonly name: "name";
232
236
  readonly type: "string";
233
237
  readonly required: false;
234
- readonly description: "Human-readable name. Must be non-empty. Omit to preserve. Cannot be\ncleared.";
238
+ readonly description: "New display name, 1 to 256 characters after trimming, with no NUL or line breaks. A label, not a unique key; omit to keep the current name.";
235
239
  }, {
236
240
  readonly name: "skills";
237
241
  readonly type: "array";
238
242
  readonly itemType: "object";
239
243
  readonly required: false;
240
- readonly description: "Skill attachments are not supported: a nonempty array returns 400. Omit this field or send an empty array; the native skill tool is configured separately through tools.";
244
+ readonly description: "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.";
241
245
  }, {
242
246
  readonly name: "system";
243
247
  readonly type: "string";
@@ -265,23 +269,11 @@ export declare const operations: readonly [{
265
269
  readonly required: false;
266
270
  readonly description: "Optional change explanation stored as note on the new immutable version, up to 280 characters. Omission stores null. A note alone does not create a version or rewrite an existing note.";
267
271
  }, {
268
- readonly name: "databases";
269
- readonly type: "array";
270
- readonly itemType: "object";
271
- readonly required: false;
272
- readonly description: "Replace this resource allowlist; omission preserves it, and null or [] clears it. Additions apply only to new sessions; disabling or removing a binding immediately revokes access in running sessions. Only service agents accept nonempty bindings.";
273
- }, {
274
- readonly name: "vector_stores";
275
- readonly type: "array";
276
- readonly itemType: "object";
277
- readonly required: false;
278
- readonly description: "Replace this resource allowlist; omission preserves it, and null or [] clears it. Additions apply only to new sessions; disabling or removing a binding immediately revokes access in running sessions. Only service agents accept nonempty bindings.";
279
- }, {
280
- readonly name: "files";
272
+ readonly name: "bindings";
281
273
  readonly type: "array";
282
274
  readonly itemType: "object";
283
275
  readonly required: false;
284
- readonly description: "Replace this resource allowlist; omission preserves it, and null or [] clears it. Additions apply only to new sessions; disabling or removing a binding immediately revokes access in running sessions. Only service agents accept nonempty bindings.";
276
+ readonly description: "Replace the whole bindings list; omission preserves it, and null or [] clears it. Additions apply only to new sessions; once this version is applied, disabling, removing or downgrading a binding revokes it immediately in running sessions on older versions, while apply=false changes no access. Only service agents accept a nonempty list.";
285
277
  }, {
286
278
  readonly name: "kind";
287
279
  readonly type: "string";
@@ -320,6 +312,22 @@ export declare const operations: readonly [{
320
312
  readonly type: "object";
321
313
  readonly required: false;
322
314
  readonly description: "Praxis extension: switchable model ids on /agent/v1 only. The default model must be included. When omitted, only the default model is selectable.";
315
+ }, {
316
+ readonly name: "avatar";
317
+ readonly type: "string";
318
+ readonly required: false;
319
+ readonly description: "Avatar image of the agent: an absolute https URL of at most 2048 characters, without credentials; any other value returns 400 avatar must be an https URL. It is the default picture in agent lists, the agent detail, the chat header and embedded chat when the embed appearance sets none. Saved with the agent version like other configuration, so apply=false keeps the previous avatar in effect until that version is applied. Omit on create for no avatar; on update, omit to keep it and send null to clear it. Both personal and service agents accept it. /agent/v1 only; /anthropic neither accepts nor returns it.";
320
+ }, {
321
+ readonly name: "environment_id";
322
+ readonly type: "string";
323
+ readonly required: false;
324
+ readonly description: "Default environment of a service agent: the environment_id a new session gets when it names none. Use light, node22 or the env_ id of an active environment of your organization; any other value returns 400 environment_id <id> was not found. null means no environment, so sessions are plain conversation without codemode or bash. Saved with the agent version like other configuration, so apply=false keeps the previous environment in effect for new sessions until that version is applied; a session that sets environment_id itself, null included, overrides it. Omit on create for light; on update, omit to keep it. Versions saved before this field existed read as light. Personal agents use a Computer: a non-null value returns 400 and the field is not returned. /agent/v1 only; /anthropic neither accepts nor returns it.";
325
+ }, {
326
+ readonly name: "vault_ids";
327
+ readonly type: "array";
328
+ readonly itemType: "string";
329
+ readonly required: false;
330
+ readonly description: "Default vaults of a service agent: the vault_ids a new session gets when it names none, so the agent's credentials follow the version. At most 50 ids without duplicates; each must be a vault of your organization that is not archived, otherwise 400 vault_ids[<index>] <id> was not found. Saved with the agent version like other configuration, so apply=false keeps the previous vaults in effect for new sessions until that version is applied; a session that sets vault_ids itself, [] included, overrides it. Omit on create for []; on update, omit to keep the list and send an array to replace it as a whole. Versions saved before this field existed read as []. Embed tokens use the vault_ids of the version they pin; vault_ids on the embed policy is deprecated, still accepted and ignored. Personal agents get no default vaults: a non-empty value returns 400 and the field is not returned. /agent/v1 only; /anthropic neither accepts nor returns it.";
323
331
  }, {
324
332
  readonly name: "preset";
325
333
  readonly type: "string";
@@ -342,6 +350,121 @@ export declare const operations: readonly [{
342
350
  readonly sdkName: "agent_id";
343
351
  }];
344
352
  readonly query: readonly [];
353
+ }, {
354
+ readonly resource: "agent.agents.customers.auth.accessTokens";
355
+ readonly method: "create";
356
+ readonly summary: "Create customer access token";
357
+ readonly description: "Exchange a grant code, or the agent's publishable key for an anonymous visitor, for a customer access token that authorizes the agent's embedded sessions.\n\nNo Authorization header is required: the grant code or the publishable key is the credential. Agent Kit calls this from the browser, so send the page Origin. With grant_code, the code is consumed atomically: concurrent attempts have exactly one winner, and unknown, used, expired and other-agent codes all return the same 401 GRANT_CODE_INVALID. The sign-in starts now and lasts the code's max_session_seconds. Unlike Shopify, a visitor without an account gets a token too: send publishable_key instead and a new anonymous customer (anon_…) is created, bound to the request Origin, for 7 days. The access token lasts at most two hours and never outlives the sign-in; renew it with access_tokens/renew before expires_at. Both forms share the per-IP minute limit of anonymous issuance (default 20). Example body: {\"grant_code\":\"cgc_…\"}.";
358
+ readonly http: "POST";
359
+ readonly path: "/agent/v1/agents/{agent_id}/customers/auth/access_tokens";
360
+ readonly streaming: "no";
361
+ readonly pagination: false;
362
+ readonly pathParams: readonly [{
363
+ readonly name: "agent_id";
364
+ readonly sdkName: "agent_id";
365
+ }];
366
+ readonly query: readonly [];
367
+ readonly body: {
368
+ readonly required: true;
369
+ readonly fields: readonly [];
370
+ };
371
+ }, {
372
+ readonly resource: "agent.agents.customers.auth.accessTokens";
373
+ readonly method: "deleteCurrent";
374
+ readonly summary: "Log out customer";
375
+ readonly description: "Log the customer out by revoking the sign-in of the presented access token and every token issued in it.\n\nSend the current customer access token as the Bearer credential, with no body, when the customer logs out of your site. Every token of the sign-in, including renewed ones, stops working, and their live event streams close; the customer's conversations are kept. Returns 204. Calling it again with the same token returns 401 ACCESS_TOKEN_REVOKED, so treat that as already logged out.";
376
+ readonly http: "DELETE";
377
+ readonly path: "/agent/v1/agents/{agent_id}/customers/auth/access_tokens/current";
378
+ readonly streaming: "no";
379
+ readonly pagination: false;
380
+ readonly pathParams: readonly [{
381
+ readonly name: "agent_id";
382
+ readonly sdkName: "agent_id";
383
+ }];
384
+ readonly query: readonly [];
385
+ }, {
386
+ readonly resource: "agent.agents.customers.auth.accessTokens.renew";
387
+ readonly method: "create";
388
+ readonly summary: "Renew customer access token";
389
+ readonly description: "Get a fresh customer access token in the same sign-in, authenticated with the current one.\n\nSend the current customer access token as the Bearer credential, with no body, a few minutes before expires_at. The new token keeps the version, budget, context, metadata and origin binding of the sign-in and lasts at most two hours, never past session_expires_at. Unlike Shopify, renewal does not revoke the presented token: it stays valid until its own expiry, so a reply that is streaming on it is not cut off. When less than 60 seconds of the sign-in remain, renewal returns 401 CUSTOMER_SESSION_EXPIRED; sign the customer in again with a new grant code from your backend. A token that was logged out or merged returns 401 ACCESS_TOKEN_REVOKED.";
390
+ readonly http: "POST";
391
+ readonly path: "/agent/v1/agents/{agent_id}/customers/auth/access_tokens/renew";
392
+ readonly streaming: "no";
393
+ readonly pagination: false;
394
+ readonly pathParams: readonly [{
395
+ readonly name: "agent_id";
396
+ readonly sdkName: "agent_id";
397
+ }];
398
+ readonly query: readonly [];
399
+ }, {
400
+ readonly resource: "agent.agents.customers.auth.grantCodes";
401
+ readonly method: "create";
402
+ readonly summary: "Create customer grant code";
403
+ readonly description: "Sign your logged-in customer in to a service agent from your backend with a one-time grant code that Agent Kit exchanges for a customer access token.\n\nCall this from your backend with your API key after your own login succeeds, then pass the returned code to Agent Kit in the browser; never call it from the browser. Customer authorization follows Shopify Storefront customer access tokens (Multipass-style sign-in, a short-lived token, renewal and logout), so that experience applies. customer_id is your own identifier for the customer: use an opaque id such as your database user id, not an email address or phone number. The value auth is reserved, and ids starting with anon_ are reserved for anonymous customers. The code works once and expires after expires_in seconds (default 900). The sign-in it starts lasts max_session_seconds (default 7 days); version, budget_cents, system_message, agent_override and metadata apply to every token of the sign-in. Unlike Shopify, origin binds the whole sign-in to one page origin, and anonymous_access_token merges the conversations of the anonymous visitor who chatted before signing in into this customer. Example body: {\"customer_id\":\"cus_8f2a91\",\"origin\":\"https://shop.example.com\"}.";
404
+ readonly http: "POST";
405
+ readonly path: "/agent/v1/agents/{agent_id}/customers/auth/grant_codes";
406
+ readonly streaming: "no";
407
+ readonly pagination: false;
408
+ readonly pathParams: readonly [{
409
+ readonly name: "agent_id";
410
+ readonly sdkName: "agent_id";
411
+ }];
412
+ readonly query: readonly [];
413
+ readonly body: {
414
+ readonly required: true;
415
+ readonly fields: readonly [{
416
+ readonly name: "customer_id";
417
+ readonly type: "string";
418
+ readonly required: true;
419
+ readonly description: "Your stable, opaque identifier for the signed-in customer, such as your database user id. Do not use an email address or phone number. \"auth\" is reserved, and ids starting with anon_ are reserved for anonymous customers.";
420
+ }, {
421
+ readonly name: "version";
422
+ readonly type: "integer";
423
+ readonly required: false;
424
+ readonly description: "Existing agent version that every token of this sign-in pins. Defaults to the agent's active_version when the code is issued.";
425
+ }, {
426
+ readonly name: "budget_cents";
427
+ readonly type: "integer";
428
+ readonly required: false;
429
+ readonly description: "Budget in cents for each session the customer starts. Defaults to the embed policy session budget and cannot exceed its maximum.";
430
+ }, {
431
+ readonly name: "system_message";
432
+ readonly type: "array";
433
+ readonly itemType: "object";
434
+ readonly required: false;
435
+ readonly description: "Optional context the agent receives at the start of each session, as text blocks, limited to 8192 UTF-8 bytes in total.";
436
+ }, {
437
+ readonly name: "agent_override";
438
+ readonly type: "object";
439
+ readonly required: false;
440
+ readonly description: "Optional system prompt override, accepted only when the embed policy allows agent overrides.";
441
+ }, {
442
+ readonly name: "metadata";
443
+ readonly type: "object";
444
+ readonly required: false;
445
+ readonly description: "Up to 16 string pairs copied onto every session the customer starts. The playground key is reserved.";
446
+ }, {
447
+ readonly name: "origin";
448
+ readonly type: "string";
449
+ readonly required: false;
450
+ readonly description: "Page origin, such as https://shop.example.com, that must be one of the agent policy's allowed_origins (or localhost when the policy allows it). When set, every token of this sign-in works only from exactly this origin. Omit to accept any policy origin.";
451
+ }, {
452
+ readonly name: "expires_in";
453
+ readonly type: "integer";
454
+ readonly required: false;
455
+ readonly description: "Seconds the code stays redeemable, from 60 to 86400. Defaults to 900.";
456
+ }, {
457
+ readonly name: "max_session_seconds";
458
+ readonly type: "integer";
459
+ readonly required: false;
460
+ readonly description: "Total lifetime of the sign-in in seconds, from 3600 to 604800 (7 days). Tokens renew within it; after it the customer signs in again. Defaults to 604800.";
461
+ }, {
462
+ readonly name: "anonymous_access_token";
463
+ readonly type: "string";
464
+ readonly required: false;
465
+ readonly description: "The current access token of the anonymous customer who used this agent before signing in. Their conversations become visible to the identified customer, and the anonymous sign-in ends at exchange.";
466
+ }];
467
+ };
345
468
  }, {
346
469
  readonly resource: "agent.agents.endUsers";
347
470
  readonly method: "list";
@@ -536,8 +659,8 @@ export declare const operations: readonly [{
536
659
  }, {
537
660
  readonly resource: "agent.computers";
538
661
  readonly method: "list";
539
- readonly summary: "ComputersList";
540
- readonly description: "Tenant-owned durable computer resource.\n\nPraxis extension: MA only has session-scoped temporary containers and memory_stores, not durable browsable computers. Archived files remain readable, but new sessions cannot bind them. environment_id is an optional recipe reference; computers start with a light sandbox and expose the public SDK sandbox_id. Lists include archived computers.";
662
+ readonly summary: "List Computers";
663
+ readonly description: "List the computers of your organization, archived ones included.\n\nPraxis extension: MA only has session-scoped temporary containers and memory_stores, not durable browsable computers. Archived files remain readable, but new sessions cannot bind them. environment_id is an optional recipe reference; computers start with a light sandbox and expose the public SDK sandbox_id. Lists include archived computers.";
541
664
  readonly http: "GET";
542
665
  readonly path: "/agent/v1/computers";
543
666
  readonly streaming: "no";
@@ -557,8 +680,8 @@ export declare const operations: readonly [{
557
680
  }, {
558
681
  readonly resource: "agent.computers";
559
682
  readonly method: "create";
560
- readonly summary: "ComputersCreate";
561
- readonly description: "Tenant-owned durable computer resource.\n\nPraxis extension: MA only has session-scoped temporary containers and memory_stores, not durable browsable computers. Archived files remain readable, but new sessions cannot bind them. environment_id is an optional recipe reference; computers start with a light sandbox and expose the public SDK sandbox_id. Lists include archived computers.";
683
+ readonly summary: "Create Computer";
684
+ readonly description: "Create a durable computer: a named machine whose files outlive sessions, for personal agents.\n\nPraxis extension: MA only has session-scoped temporary containers and memory_stores, not durable browsable computers. Archived files remain readable, but new sessions cannot bind them. environment_id is an optional recipe reference; computers start with a light sandbox and expose the public SDK sandbox_id. Lists include archived computers.";
562
685
  readonly http: "POST";
563
686
  readonly path: "/agent/v1/computers";
564
687
  readonly streaming: "no";
@@ -596,8 +719,8 @@ export declare const operations: readonly [{
596
719
  }, {
597
720
  readonly resource: "agent.computers";
598
721
  readonly method: "retrieve";
599
- readonly summary: "ComputersRetrieve";
600
- readonly description: "Tenant-owned durable computer resource.\n\nPraxis extension: MA only has session-scoped temporary containers and memory_stores, not durable browsable computers. Archived files remain readable, but new sessions cannot bind them. environment_id is an optional recipe reference; computers start with a light sandbox and expose the public SDK sandbox_id. Lists include archived computers.";
722
+ readonly summary: "Get Computer";
723
+ readonly description: "Read one computer's status, storage use and sandbox id.\n\nPraxis extension: MA only has session-scoped temporary containers and memory_stores, not durable browsable computers. Archived files remain readable, but new sessions cannot bind them. environment_id is an optional recipe reference; computers start with a light sandbox and expose the public SDK sandbox_id. Lists include archived computers.";
601
724
  readonly http: "GET";
602
725
  readonly path: "/agent/v1/computers/{computer_id}";
603
726
  readonly streaming: "no";
@@ -610,8 +733,8 @@ export declare const operations: readonly [{
610
733
  }, {
611
734
  readonly resource: "agent.computers";
612
735
  readonly method: "update";
613
- readonly summary: "ComputersUpdate";
614
- readonly description: "Tenant-owned durable computer resource.\n\nPraxis extension: MA only has session-scoped temporary containers and memory_stores, not durable browsable computers. Archived files remain readable, but new sessions cannot bind them. environment_id is an optional recipe reference; computers start with a light sandbox and expose the public SDK sandbox_id. Lists include archived computers.";
736
+ readonly summary: "Update Computer";
737
+ readonly description: "Rename a computer.\n\nPraxis extension: MA only has session-scoped temporary containers and memory_stores, not durable browsable computers. Archived files remain readable, but new sessions cannot bind them. environment_id is an optional recipe reference; computers start with a light sandbox and expose the public SDK sandbox_id. Lists include archived computers.";
615
738
  readonly http: "POST";
616
739
  readonly path: "/agent/v1/computers/{computer_id}";
617
740
  readonly streaming: "no";
@@ -633,8 +756,8 @@ export declare const operations: readonly [{
633
756
  }, {
634
757
  readonly resource: "agent.computers";
635
758
  readonly method: "archive";
636
- readonly summary: "ComputersArchive";
637
- readonly description: "Tenant-owned durable computer resource.\n\nPraxis extension: MA only has session-scoped temporary containers and memory_stores, not durable browsable computers. Archived files remain readable, but new sessions cannot bind them. environment_id is an optional recipe reference; computers start with a light sandbox and expose the public SDK sandbox_id. Lists include archived computers.";
759
+ readonly summary: "Archive Computer";
760
+ readonly description: "Archive a computer: its files stay readable but new sessions cannot use it.\n\nPraxis extension: MA only has session-scoped temporary containers and memory_stores, not durable browsable computers. Archived files remain readable, but new sessions cannot bind them. environment_id is an optional recipe reference; computers start with a light sandbox and expose the public SDK sandbox_id. Lists include archived computers.";
638
761
  readonly http: "POST";
639
762
  readonly path: "/agent/v1/computers/{computer_id}/archive";
640
763
  readonly streaming: "no";
@@ -694,8 +817,8 @@ export declare const operations: readonly [{
694
817
  }, {
695
818
  readonly resource: "agent.computers.files";
696
819
  readonly method: "list";
697
- readonly summary: "ComputersFilesList";
698
- readonly description: "Tenant-owned durable computer resource.\n\nPraxis extension: MA only has session-scoped temporary containers and memory_stores, not durable browsable computers. Archived files remain readable, but new sessions cannot bind them. environment_id is an optional recipe reference; computers start with a light sandbox and expose the public SDK sandbox_id. Lists include archived computers.";
820
+ readonly summary: "List Computer Files";
821
+ readonly description: "List the entries of one directory on a computer.\n\nPraxis extension: MA only has session-scoped temporary containers and memory_stores, not durable browsable computers. Archived files remain readable, but new sessions cannot bind them. environment_id is an optional recipe reference; computers start with a light sandbox and expose the public SDK sandbox_id. Lists include archived computers.";
699
822
  readonly http: "GET";
700
823
  readonly path: "/agent/v1/computers/{computer_id}/files";
701
824
  readonly streaming: "no";
@@ -713,8 +836,8 @@ export declare const operations: readonly [{
713
836
  }, {
714
837
  readonly resource: "agent.computers.files";
715
838
  readonly method: "retrieveContent";
716
- readonly summary: "ComputersFilesContent";
717
- readonly description: "Tenant-owned durable computer resource.\n\nPraxis extension: MA only has session-scoped temporary containers and memory_stores, not durable browsable computers. Archived files remain readable, but new sessions cannot bind them. environment_id is an optional recipe reference; computers start with a light sandbox and expose the public SDK sandbox_id. Lists include archived computers.";
839
+ readonly summary: "Get Computer File Content";
840
+ readonly description: "Download the bytes of one file on a computer, up to 16 MiB, with single-range support.\n\nPraxis extension: MA only has session-scoped temporary containers and memory_stores, not durable browsable computers. Archived files remain readable, but new sessions cannot bind them. environment_id is an optional recipe reference; computers start with a light sandbox and expose the public SDK sandbox_id. Lists include archived computers.";
718
841
  readonly http: "GET";
719
842
  readonly path: "/agent/v1/computers/{computer_id}/files/content";
720
843
  readonly streaming: "no";
@@ -1301,7 +1424,7 @@ export declare const operations: readonly [{
1301
1424
  readonly resource: "agent.environments";
1302
1425
  readonly method: "create";
1303
1426
  readonly summary: "Create environment";
1304
- readonly description: "Create a tenant-owned cloud environment: a sandbox recipe (packages to install and networking policy) that sessions can select through environment_id. Package installation happens when the session's sandbox is created; a failed install terminates that session with ENVIRONMENT_PACKAGE_INSTALL_FAILED. Limited networking is applied at sandbox creation. Unlike Anthropic Managed Agents, self_hosted environments, scope and cross-session package caching are not supported.";
1427
+ readonly description: "Create a tenant-owned cloud environment: a sandbox recipe (packages to install and networking policy) that sessions can select through environment_id. Package installation happens when the session's sandbox is created; a failed install terminates that session with ENVIRONMENT_PACKAGE_INSTALL_FAILED. Limited networking is applied at sandbox creation. Unlike Anthropic Managed Agents, self_hosted environments, scope and cross-session package caching are not supported. config.template must name an available sandbox template, otherwise 400 lists the available ones.";
1305
1428
  readonly http: "POST";
1306
1429
  readonly path: "/agent/v1/environments";
1307
1430
  readonly streaming: "no";
@@ -1330,12 +1453,6 @@ export declare const operations: readonly [{
1330
1453
  readonly type: "object";
1331
1454
  readonly required: false;
1332
1455
  readonly description: "Free-form string key/value pairs.";
1333
- }, {
1334
- readonly name: "scope";
1335
- readonly type: "string";
1336
- readonly enum: readonly ["organization", "account"];
1337
- readonly required: false;
1338
- readonly description: "The visibility scope for this environment. 'organization' makes the\nenvironment visible to all accounts. 'account' restricts visibility to the\nowning account only. API organizations support only 'organization'; 'account' is\nrejected. If not specified, defaults based on organization type.";
1339
1456
  }];
1340
1457
  };
1341
1458
  }, {
@@ -1356,7 +1473,7 @@ export declare const operations: readonly [{
1356
1473
  readonly resource: "agent.environments";
1357
1474
  readonly method: "update";
1358
1475
  readonly summary: "Update environment";
1359
- readonly description: "Update the configuration of a tenant-owned cloud environment. Built-in environments are read-only. Package installation and limited networking are applied when a session's sandbox is created. Omitted fields keep their value.";
1476
+ readonly description: "Update the configuration of a tenant-owned cloud environment. Built-in environments are read-only. Package installation and limited networking are applied when a session's sandbox is created. Omitted fields keep their value. A changed config.template must name an available sandbox template, otherwise 400 lists the available ones.";
1360
1477
  readonly http: "POST";
1361
1478
  readonly path: "/agent/v1/environments/{environment_id}";
1362
1479
  readonly streaming: "no";
@@ -1388,19 +1505,13 @@ export declare const operations: readonly [{
1388
1505
  readonly type: "string";
1389
1506
  readonly required: false;
1390
1507
  readonly description: "Updated name for the environment";
1391
- }, {
1392
- readonly name: "scope";
1393
- readonly type: "string";
1394
- readonly enum: readonly ["organization", "account"];
1395
- readonly required: false;
1396
- readonly description: "The visibility scope for this environment. 'organization' makes the\nenvironment visible to all accounts. 'account' restricts visibility to the\nowning account only.";
1397
1508
  }];
1398
1509
  };
1399
1510
  }, {
1400
1511
  readonly resource: "agent.environments";
1401
1512
  readonly method: "archive";
1402
1513
  readonly summary: "Archive environment";
1403
- readonly description: "Soft-archive a tenant-owned cloud environment so it can no longer be used to create new sessions. Built-in environments are read-only and cannot be archived.";
1514
+ readonly description: "Soft-archive a tenant-owned cloud environment so it can no longer be used to create new sessions. Built-in environments are read-only and cannot be archived. An environment that the active version of a non-archived agent uses as environment_id returns 409 RESOURCE_IN_USE naming the agents; point them at another environment first.";
1404
1515
  readonly http: "POST";
1405
1516
  readonly path: "/agent/v1/environments/{environment_id}/archive";
1406
1517
  readonly streaming: "no";
@@ -1414,7 +1525,7 @@ export declare const operations: readonly [{
1414
1525
  readonly resource: "agent.sessions";
1415
1526
  readonly method: "list";
1416
1527
  readonly summary: "List sessions";
1417
- readonly description: "List sessions of the workspace behind your API key, newest first, in pages of at most 100 (default 20). Unlike Anthropic Managed Agents, only limit, page, agent_id and deployment_id are honored; the other filters declared here (agent_version, created_at ranges, memory_store_id, include_archived, order, statuses) are not supported and return 400. Use the returned id with sessions.retrieve or sessions.events.list; pass next_page as page for the next page.";
1528
+ readonly description: "List sessions of the workspace behind your API key, newest first, in pages of at most 100 (default 20). Archived sessions are hidden unless include_archived is true. Unlike Anthropic Managed Agents, only limit, page, agent_id, deployment_id and include_archived are honored; the other filters declared here (agent_version, created_at ranges, memory_store_id, order, statuses) are not supported and return 400. Use the returned id with sessions.retrieve or sessions.events.list; pass next_page as page for the next page.";
1418
1529
  readonly http: "GET";
1419
1530
  readonly path: "/agent/v1/sessions";
1420
1531
  readonly streaming: "no";
@@ -1439,7 +1550,7 @@ export declare const operations: readonly [{
1439
1550
  readonly name: "created_at[gte]";
1440
1551
  readonly type: "string";
1441
1552
  readonly required: false;
1442
- readonly description: "Created-at lower bound for sessions. Declared by the Managed Agents shape but not supported here: sessions.list honors only limit, page, agent_id and deployment_id, and other filters return 400.";
1553
+ readonly description: "Created-at lower bound for sessions. Declared by the Managed Agents shape but not supported here: sessions.list honors only limit, page, agent_id, deployment_id and include_archived, and other filters return 400.";
1443
1554
  }, {
1444
1555
  readonly name: "created_at[lt]";
1445
1556
  readonly type: "string";
@@ -1449,7 +1560,7 @@ export declare const operations: readonly [{
1449
1560
  readonly name: "created_at[lte]";
1450
1561
  readonly type: "string";
1451
1562
  readonly required: false;
1452
- readonly description: "Created-at upper bound for sessions. Declared by the Managed Agents shape but not supported here: sessions.list honors only limit, page, agent_id and deployment_id, and other filters return 400.";
1563
+ readonly description: "Created-at upper bound for sessions. Declared by the Managed Agents shape but not supported here: sessions.list honors only limit, page, agent_id, deployment_id and include_archived, and other filters return 400.";
1453
1564
  }, {
1454
1565
  readonly name: "deployment_id";
1455
1566
  readonly type: "string";
@@ -1460,7 +1571,7 @@ export declare const operations: readonly [{
1460
1571
  readonly type: "boolean";
1461
1572
  readonly enum: readonly [false, true];
1462
1573
  readonly required: false;
1463
- readonly description: "Declared by the Managed Agents shape but not supported by sessions.list; sending it returns 400. Archived sessions are retrievable by id.";
1574
+ readonly description: "Whether archived sessions are listed: true includes them, false (the default) hides them. A value other than true or false returns 400. Archived sessions stay retrievable by id either way.";
1464
1575
  }, {
1465
1576
  readonly name: "memory_store_id";
1466
1577
  readonly type: "string";
@@ -1505,7 +1616,7 @@ export declare const operations: readonly [{
1505
1616
  readonly resource: "agent.sessions";
1506
1617
  readonly method: "create";
1507
1618
  readonly summary: "Create session";
1508
- readonly description: "Create a session: one conversation with an agent. Pass agent as an agent id (active_version) or {id, version, type:\"agent\"}. Unlike Anthropic Managed Agents, omit environment_id to get a light machine, unless computer_id (explicit, or the agent's default) selects a Computer; pass an environment id for a sandbox recipe. For service agents, omission returns environment_id=light; explicit null allocates no machine, so codemode, bash and other machine tools are unavailable. Optional model must be one of the agent's allowed models; optional thinking is {effort: low|medium|high|xhigh|max|none} or null, where null inherits the agent default and then the model default (none requires the model to allow disabling thinking). Selections are saved before initial_events run; invalid ones return 400 invalid_request_error. Inline agent overrides are not supported. Supports vault_ids, up to 50, owned by the current organization and not archived; credential injection is deferred to a later version. Omitted budget defaults to USD 20; null removes the limit, and a limit object uses a positive integer string of USD cents. Up to 500 file resources can be attached. Use initial_events to send a first user.message in this request, or send messages afterwards with sessions.events.send. The returned status can still be idle before initial events run; read agent.message and the subsequent session.status_idle event to confirm completion.";
1619
+ readonly description: "Create a session: one conversation with an agent. Pass agent as an agent id or {type:\"agent\", id, version?}; an id alone, or an object without version, pins the agent's active_version (the version chosen with agents.versions.apply, not necessarily the newest saved one). Unlike Anthropic Managed Agents, omit environment_id to use the default environment saved in the agent version (light for a new agent), unless computer_id (explicit, or the agent's default) selects a Computer; pass an environment id for a sandbox recipe. For service agents, explicit null allocates no machine, so codemode, bash and other machine tools are unavailable. Optional model must be one of the agent's allowed models; optional thinking is {effort: low|medium|high|xhigh|max|none} or null, where null inherits the agent default and then the model default (none requires the model to allow disabling thinking). Selections are saved before initial_events run; invalid ones return 400 invalid_request_error. Unlike Anthropic Managed Agents, the only inline agent override is system ({type:\"agent_with_overrides\", id, system}); to change the model, tools, MCP servers or skills, save a version instead. Supports vault_ids, up to 50, owned by the current organization and not archived; credential injection is deferred to a later version. budget is {type:\"limit\", max_list_cost:{amount, currency:\"USD\"}} where amount is a positive integer string of US cents (\"2000\" is USD 20.00); omitted budget defaults to \"2000\" and null removes the limit. Up to 500 file resources can be attached. Use initial_events to send a first user.message in this request, or send messages afterwards with sessions.events.send. The returned status can still be idle before initial events run; read agent.message and the subsequent session.status_idle event to confirm completion.";
1509
1620
  readonly http: "POST";
1510
1621
  readonly path: "/agent/v1/sessions";
1511
1622
  readonly streaming: "no";
@@ -1518,17 +1629,17 @@ export declare const operations: readonly [{
1518
1629
  readonly name: "agent";
1519
1630
  readonly type: "object";
1520
1631
  readonly required: true;
1521
- readonly description: "Agent identifier. Accepts the `agent` ID string, which pins the\nlatest version for the session, or an `agent` object with both id and version\nspecified.";
1632
+ readonly description: "The agent to run: an agent id string, or {type: \"agent\", id, version?}. An id alone, or an object without version, pins the agent's active_version at the moment the session is created (the version chosen with agents.versions.apply, not necessarily the newest saved one); version pins that exact version. Unlike Managed Agents, the only inline override is a system prompt ({type: \"agent_with_overrides\", id, system}); to change the model, tools, MCP servers or skills, save a version instead.";
1522
1633
  }, {
1523
1634
  readonly name: "environment_id";
1524
1635
  readonly type: "string";
1525
1636
  readonly required: false;
1526
- readonly description: "Execution environment id from agent.environments.list or agent.environments.create. For a service agent, omission selects the built-in light environment and returns session.environment_id=light; explicit null allocates no machine and makes machine tools, including codemode and bash, unavailable. Personal agents use their selected Computer.";
1637
+ readonly description: "Execution environment id from agent.environments.list or agent.environments.create. For a service agent, omission uses the default environment saved in the agent version (light for a new agent) and returns it as session.environment_id; explicit null allocates no machine and makes machine tools, including codemode and bash, unavailable. Personal agents use their selected Computer.";
1527
1638
  }, {
1528
1639
  readonly name: "budget";
1529
1640
  readonly type: "object";
1530
1641
  readonly required: false;
1531
- readonly description: "Session spending limit in USD cents; null when unlimited. Creation defaults to USD 20 when omitted. A limit amount is a positive integer string; removing a limit with null prevents setting it again for that session.";
1642
+ readonly description: "Session spending limit, {type: \"limit\", max_list_cost: {amount, currency}}; null when unlimited. Creation defaults to a limit of 2000 US cents (USD 20.00) when omitted. amount is a positive integer string of US cents; removing the limit with null prevents setting it again for that session.";
1532
1643
  }, {
1533
1644
  readonly name: "initial_events";
1534
1645
  readonly type: "array";
@@ -1629,11 +1740,6 @@ export declare const operations: readonly [{
1629
1740
  readonly body: {
1630
1741
  readonly required: true;
1631
1742
  readonly fields: readonly [{
1632
- readonly name: "agent";
1633
- readonly type: "object";
1634
- readonly required: false;
1635
- readonly description: "Agent definition the session uses after the change; null when unchanged.";
1636
- }, {
1637
1743
  readonly name: "budget";
1638
1744
  readonly type: "object";
1639
1745
  readonly required: false;
@@ -2216,6 +2322,187 @@ export declare const operations: readonly [{
2216
2322
  readonly required: false;
2217
2323
  readonly description: "When set, this connection also receives streaming deltas\n(`event_start`, `event_delta`) while an event is being produced, before the\nevent itself arrives. Deltas are best-effort; when the final event is produced\nit carries the complete content. A model request that ends early (an error or\ninterrupt) produces no final event — its terminal `span.model_request_end`\ncloses the preview. Accepts one or more event types to preview and may be\nrepeated: `agent.message` streams `content_delta` fragments; `agent.thinking` is\nstart-only — a signal that the agent has begun extended thinking, concluded by\nthe `agent.thinking` event itself. Only previews of the requested event types\nare sent.";
2218
2324
  }];
2325
+ }, {
2326
+ readonly resource: "agent.skills";
2327
+ readonly method: "list";
2328
+ readonly summary: "List skills";
2329
+ readonly description: "List the skills uploaded to your organization, newest first, in pages of at most 100 (default 20). Use it to find a skill id before reading, versioning or deleting it. Only source=custom has content; source=anthropic returns an empty list. Pass next_page from the response as page to read the next page; a null next_page means the end.";
2330
+ readonly http: "GET";
2331
+ readonly path: "/agent/v1/skills";
2332
+ readonly streaming: "no";
2333
+ readonly pagination: false;
2334
+ readonly pathParams: readonly [];
2335
+ readonly query: readonly [{
2336
+ readonly name: "source";
2337
+ readonly type: "string";
2338
+ readonly required: false;
2339
+ readonly description: "Filter skills by source.\n\nIf provided, only skills from the specified source will be returned:\n\n- `\"custom\"`: only return user-created skills\n- `\"anthropic\"`: only return Anthropic-created skills";
2340
+ }, {
2341
+ readonly name: "limit";
2342
+ readonly type: "number";
2343
+ readonly required: false;
2344
+ readonly description: "Number of items per page.";
2345
+ }, {
2346
+ readonly name: "page";
2347
+ readonly type: "string";
2348
+ readonly required: false;
2349
+ readonly description: "Opaque pagination cursor: pass the next_page value of the previous response unchanged. Omit it for the first page. A cursor from a different query or a malformed one returns 400.";
2350
+ }];
2351
+ }, {
2352
+ readonly resource: "agent.skills";
2353
+ readonly method: "create";
2354
+ readonly summary: "Create skill";
2355
+ readonly description: "Upload a skill: a directory that contains SKILL.md, which the agent reads when it needs the skill. Send multipart/form-data with one files part per file, each file name being its path under one top-level directory (pdf/SKILL.md, pdf/scripts/run.py), and an optional display_name. SKILL.md frontmatter needs a description; name defaults to the directory name and must be one folder name (1-255 characters, no \"/\", backslash or NUL, not \".\" or \"..\"), otherwise the upload returns 400 stating the allowed form. Limits: 8 MB in total, at most 200 files, no .. segments, absolute paths or empty names; a violation returns 400 naming the path or field. The upload creates the skill and its first version, and versions are immutable. Attach the skill to an agent with `skills` on the agent.";
2356
+ readonly http: "POST";
2357
+ readonly path: "/agent/v1/skills";
2358
+ readonly streaming: "no";
2359
+ readonly pagination: false;
2360
+ readonly multipart: true;
2361
+ readonly pathParams: readonly [];
2362
+ readonly query: readonly [];
2363
+ readonly body: {
2364
+ readonly required: true;
2365
+ readonly fields: readonly [{
2366
+ readonly name: "files";
2367
+ readonly type: "array";
2368
+ readonly itemType: "string";
2369
+ readonly required: true;
2370
+ readonly description: "Files to upload for the skill.\n\nAll files must be in the same top-level directory and must include a SKILL.md\nfile at the root of that directory.";
2371
+ }, {
2372
+ readonly name: "display_name";
2373
+ readonly type: "string";
2374
+ readonly required: false;
2375
+ readonly description: "Human-readable, single-line label for the Skill. Maximum 255\ncharacters. Always set: derived from the SKILL.md frontmatter `name` when\nomitted at creation. Not unique.";
2376
+ }];
2377
+ };
2378
+ }, {
2379
+ readonly resource: "agent.skills";
2380
+ readonly method: "delete";
2381
+ readonly summary: "Delete skill";
2382
+ readonly description: "Delete a skill that has no live versions. A skill that is still attached to an agent returns 409 RESOURCE_IN_USE naming up to 10 agent ids (the active or latest version of a non-archived agent counts); remove it from those agents first. A skill that still has versions returns 409 Delete all versions first; remove each with skills.versions.delete, then call this. Returns {id, type: skill_deleted}. skill_id comes from skills.create or skills.list.";
2383
+ readonly http: "DELETE";
2384
+ readonly path: "/agent/v1/skills/{skill_id}";
2385
+ readonly streaming: "no";
2386
+ readonly pagination: false;
2387
+ readonly pathParams: readonly [{
2388
+ readonly name: "skill_id";
2389
+ readonly sdkName: "skill_id";
2390
+ }];
2391
+ readonly query: readonly [];
2392
+ }, {
2393
+ readonly resource: "agent.skills";
2394
+ readonly method: "retrieve";
2395
+ readonly summary: "Get skill";
2396
+ readonly description: "Read one skill by id: its display_name, source and latest_version_id. skill_id comes from skills.create or skills.list. A skill of another organization, or a deleted one, returns 404 Skill not found.";
2397
+ readonly http: "GET";
2398
+ readonly path: "/agent/v1/skills/{skill_id}";
2399
+ readonly streaming: "no";
2400
+ readonly pagination: false;
2401
+ readonly pathParams: readonly [{
2402
+ readonly name: "skill_id";
2403
+ readonly sdkName: "skill_id";
2404
+ }];
2405
+ readonly query: readonly [];
2406
+ }, {
2407
+ readonly resource: "agent.skills.versions";
2408
+ readonly method: "list";
2409
+ readonly summary: "List skill versions";
2410
+ readonly description: "List the live versions of one skill, newest first, in pages of at most 100 (default 20). Each item carries the name and description read from the SKILL.md of that version. Pass next_page from the response as page to read the next page; a null next_page means the end.";
2411
+ readonly http: "GET";
2412
+ readonly path: "/agent/v1/skills/{skill_id}/versions";
2413
+ readonly streaming: "no";
2414
+ readonly pagination: false;
2415
+ readonly pathParams: readonly [{
2416
+ readonly name: "skill_id";
2417
+ readonly sdkName: "skill_id";
2418
+ }];
2419
+ readonly query: readonly [{
2420
+ readonly name: "limit";
2421
+ readonly type: "number";
2422
+ readonly required: false;
2423
+ readonly description: "Number of items per page.";
2424
+ }, {
2425
+ readonly name: "page";
2426
+ readonly type: "string";
2427
+ readonly required: false;
2428
+ readonly description: "Opaque pagination cursor: pass the next_page value of the previous response unchanged. Omit it for the first page. A cursor from a different query or a malformed one returns 400.";
2429
+ }];
2430
+ }, {
2431
+ readonly resource: "agent.skills.versions";
2432
+ readonly method: "create";
2433
+ readonly summary: "Create skill version";
2434
+ readonly description: "Upload a new version of a skill with the same multipart/form-data shape and limits as skills.create (8 MB, 200 files, one top-level directory containing SKILL.md). The SKILL.md name must equal the name of the skill; a different name returns 400. The new version becomes latest_version_id of the skill, and earlier versions stay unchanged because versions are immutable. Attach it to an agent with `skills` on the agent.";
2435
+ readonly http: "POST";
2436
+ readonly path: "/agent/v1/skills/{skill_id}/versions";
2437
+ readonly streaming: "no";
2438
+ readonly pagination: false;
2439
+ readonly multipart: true;
2440
+ readonly pathParams: readonly [{
2441
+ readonly name: "skill_id";
2442
+ readonly sdkName: "skill_id";
2443
+ }];
2444
+ readonly query: readonly [];
2445
+ readonly body: {
2446
+ readonly required: true;
2447
+ readonly fields: readonly [{
2448
+ readonly name: "files";
2449
+ readonly type: "array";
2450
+ readonly itemType: "string";
2451
+ readonly required: true;
2452
+ readonly description: "Files to upload for the skill.\n\nAll files must be in the same top-level directory and must include a SKILL.md\nfile at the root of that directory.";
2453
+ }];
2454
+ };
2455
+ }, {
2456
+ readonly resource: "agent.skills.versions";
2457
+ readonly method: "delete";
2458
+ readonly summary: "Delete skill version";
2459
+ readonly description: "Soft-delete one version of a skill so it can no longer be read or downloaded; latest_version_id of the skill falls back to the newest remaining version. Returns {id, type: skill_version_deleted}. A skill can be deleted only after all of its versions are deleted. A version that a non-archived agent pins, or the last version of a skill an agent attaches without a pin, returns 409 RESOURCE_IN_USE naming the agents.";
2460
+ readonly http: "DELETE";
2461
+ readonly path: "/agent/v1/skills/{skill_id}/versions/{version}";
2462
+ readonly streaming: "no";
2463
+ readonly pagination: false;
2464
+ readonly pathParams: readonly [{
2465
+ readonly name: "skill_id";
2466
+ readonly sdkName: "skill_id";
2467
+ }, {
2468
+ readonly name: "version";
2469
+ readonly sdkName: "version";
2470
+ }];
2471
+ readonly query: readonly [];
2472
+ }, {
2473
+ readonly resource: "agent.skills.versions";
2474
+ readonly method: "retrieve";
2475
+ readonly summary: "Get skill version";
2476
+ readonly description: "Read one version of a skill: its name, description and created_at as read from SKILL.md. version is the id returned by skills.versions.create or skills.versions.list. A deleted or unknown version returns 404 Skill version not found.";
2477
+ readonly http: "GET";
2478
+ readonly path: "/agent/v1/skills/{skill_id}/versions/{version}";
2479
+ readonly streaming: "no";
2480
+ readonly pagination: false;
2481
+ readonly pathParams: readonly [{
2482
+ readonly name: "skill_id";
2483
+ readonly sdkName: "skill_id";
2484
+ }, {
2485
+ readonly name: "version";
2486
+ readonly sdkName: "version";
2487
+ }];
2488
+ readonly query: readonly [];
2489
+ }, {
2490
+ readonly resource: "agent.skills.versions";
2491
+ readonly method: "retrieveContent";
2492
+ readonly summary: "Download skill version";
2493
+ readonly description: "Download the content of one version as a zip archive (application/zip): the uploaded directory with its top-level folder and every file. version is the id returned by skills.versions.create or skills.versions.list; a deleted version returns 404.";
2494
+ readonly http: "GET";
2495
+ readonly path: "/agent/v1/skills/{skill_id}/versions/{version}/content";
2496
+ readonly streaming: "no";
2497
+ readonly pagination: false;
2498
+ readonly pathParams: readonly [{
2499
+ readonly name: "skill_id";
2500
+ readonly sdkName: "skill_id";
2501
+ }, {
2502
+ readonly name: "version";
2503
+ readonly sdkName: "version";
2504
+ }];
2505
+ readonly query: readonly [];
2219
2506
  }, {
2220
2507
  readonly resource: "agent.toolsets";
2221
2508
  readonly method: "list";