@deepraxis/cli 0.1.0-dev.723d9cb → 0.1.0-dev.7ec6f84
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.
- package/COMMANDS.md +19 -5
- package/dist/praxis.js +787 -181
- package/package.json +1 -1
package/dist/praxis.js
CHANGED
|
@@ -68,7 +68,7 @@ var operations = [
|
|
|
68
68
|
resource: "agent.agents",
|
|
69
69
|
method: "create",
|
|
70
70
|
summary: "Create agent",
|
|
71
|
-
description:
|
|
71
|
+
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"}]}.`,
|
|
72
72
|
http: "POST",
|
|
73
73
|
path: "/agent/v1/agents",
|
|
74
74
|
streaming: "no",
|
|
@@ -82,13 +82,13 @@ var operations = [
|
|
|
82
82
|
name: "model",
|
|
83
83
|
type: "object",
|
|
84
84
|
required: true,
|
|
85
|
-
description: "
|
|
85
|
+
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."
|
|
86
86
|
},
|
|
87
87
|
{
|
|
88
88
|
name: "name",
|
|
89
89
|
type: "string",
|
|
90
90
|
required: true,
|
|
91
|
-
description: "
|
|
91
|
+
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."
|
|
92
92
|
},
|
|
93
93
|
{
|
|
94
94
|
name: "description",
|
|
@@ -120,7 +120,7 @@ var operations = [
|
|
|
120
120
|
type: "array",
|
|
121
121
|
itemType: "object",
|
|
122
122
|
required: false,
|
|
123
|
-
description:
|
|
123
|
+
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.`
|
|
124
124
|
},
|
|
125
125
|
{
|
|
126
126
|
name: "system",
|
|
@@ -137,25 +137,11 @@ var operations = [
|
|
|
137
137
|
across all toolsets allowed.`
|
|
138
138
|
},
|
|
139
139
|
{
|
|
140
|
-
name: "
|
|
141
|
-
type: "array",
|
|
142
|
-
itemType: "object",
|
|
143
|
-
required: false,
|
|
144
|
-
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."
|
|
145
|
-
},
|
|
146
|
-
{
|
|
147
|
-
name: "vector_stores",
|
|
148
|
-
type: "array",
|
|
149
|
-
itemType: "object",
|
|
150
|
-
required: false,
|
|
151
|
-
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."
|
|
152
|
-
},
|
|
153
|
-
{
|
|
154
|
-
name: "files",
|
|
140
|
+
name: "bindings",
|
|
155
141
|
type: "array",
|
|
156
142
|
itemType: "object",
|
|
157
143
|
required: false,
|
|
158
|
-
description: "
|
|
144
|
+
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."
|
|
159
145
|
},
|
|
160
146
|
{
|
|
161
147
|
name: "kind",
|
|
@@ -205,6 +191,25 @@ across all toolsets allowed.`
|
|
|
205
191
|
required: false,
|
|
206
192
|
description: "Praxis extension: switchable model ids on /agent/v1 only. The default model must be included. When omitted, only the default model is selectable."
|
|
207
193
|
},
|
|
194
|
+
{
|
|
195
|
+
name: "avatar",
|
|
196
|
+
type: "string",
|
|
197
|
+
required: false,
|
|
198
|
+
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."
|
|
199
|
+
},
|
|
200
|
+
{
|
|
201
|
+
name: "environment_id",
|
|
202
|
+
type: "string",
|
|
203
|
+
required: false,
|
|
204
|
+
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."
|
|
205
|
+
},
|
|
206
|
+
{
|
|
207
|
+
name: "vault_ids",
|
|
208
|
+
type: "array",
|
|
209
|
+
itemType: "string",
|
|
210
|
+
required: false,
|
|
211
|
+
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."
|
|
212
|
+
},
|
|
208
213
|
{
|
|
209
214
|
name: "preset",
|
|
210
215
|
type: "string",
|
|
@@ -223,7 +228,7 @@ across all toolsets allowed.`
|
|
|
223
228
|
resource: "agent.agents",
|
|
224
229
|
method: "retrieve",
|
|
225
230
|
summary: "Get agent",
|
|
226
|
-
description: "Read one agent by id
|
|
231
|
+
description: "Read one agent by id. The top level is the latest saved version, the editable head whose version you send back for optimistic concurrency; after a save with apply false it differs from active_version, and new sessions use active_version, which you read with version=active. With version, read a specific saved version. The response lists every native tool with its resolved configuration in one agent_toolset_20260401 entry, so it can be sent back unchanged to agents.update. Use agents.versions.list to enumerate versions.",
|
|
227
232
|
http: "GET",
|
|
228
233
|
path: "/agent/v1/agents/{agent_id}",
|
|
229
234
|
streaming: "no",
|
|
@@ -239,7 +244,7 @@ across all toolsets allowed.`
|
|
|
239
244
|
name: "version",
|
|
240
245
|
type: "number",
|
|
241
246
|
required: false,
|
|
242
|
-
description: "Agent version to read; omit for the latest.
|
|
247
|
+
description: "Agent version to read; omit for the latest saved version. An integer of at least 1 (versions are listed by agents.versions.list), or the string active for the version new sessions use."
|
|
243
248
|
}
|
|
244
249
|
]
|
|
245
250
|
},
|
|
@@ -247,7 +252,7 @@ across all toolsets allowed.`
|
|
|
247
252
|
resource: "agent.agents",
|
|
248
253
|
method: "update",
|
|
249
254
|
summary: "Update agent",
|
|
250
|
-
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
|
|
255
|
+
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; null means no note, and a note sent when the request changes nothing else returns 400 because a note is stored only with a new 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.",
|
|
251
256
|
http: "POST",
|
|
252
257
|
path: "/agent/v1/agents/{agent_id}",
|
|
253
258
|
streaming: "no",
|
|
@@ -287,7 +292,7 @@ to 64 chars each) with values up to 512 chars.`
|
|
|
287
292
|
name: "model",
|
|
288
293
|
type: "object",
|
|
289
294
|
required: false,
|
|
290
|
-
description: "
|
|
295
|
+
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."
|
|
291
296
|
},
|
|
292
297
|
{
|
|
293
298
|
name: "multiagent",
|
|
@@ -299,15 +304,14 @@ to 64 chars each) with values up to 512 chars.`
|
|
|
299
304
|
name: "name",
|
|
300
305
|
type: "string",
|
|
301
306
|
required: false,
|
|
302
|
-
description:
|
|
303
|
-
cleared.`
|
|
307
|
+
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."
|
|
304
308
|
},
|
|
305
309
|
{
|
|
306
310
|
name: "skills",
|
|
307
311
|
type: "array",
|
|
308
312
|
itemType: "object",
|
|
309
313
|
required: false,
|
|
310
|
-
description:
|
|
314
|
+
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.`
|
|
311
315
|
},
|
|
312
316
|
{
|
|
313
317
|
name: "system",
|
|
@@ -334,25 +338,23 @@ specified. When supplied, the request fails if it does not match the server's
|
|
|
334
338
|
current version; omit to apply the update unconditionally.`
|
|
335
339
|
},
|
|
336
340
|
{
|
|
337
|
-
name: "
|
|
338
|
-
type: "
|
|
339
|
-
itemType: "object",
|
|
341
|
+
name: "apply",
|
|
342
|
+
type: "boolean",
|
|
340
343
|
required: false,
|
|
341
|
-
description: "
|
|
344
|
+
description: "Defaults to true: apply the newly saved version, or the latest version when configuration is unchanged. Set false to save without changing active_version. Unlike Managed Agents, saving and applying can be separate."
|
|
342
345
|
},
|
|
343
346
|
{
|
|
344
|
-
name: "
|
|
345
|
-
type: "
|
|
346
|
-
itemType: "object",
|
|
347
|
+
name: "version_note",
|
|
348
|
+
type: "string",
|
|
347
349
|
required: false,
|
|
348
|
-
description: "
|
|
350
|
+
description: "Optional change explanation stored as note on the new immutable version, up to 280 characters. Omission or null stores no note. A note sent when nothing else changes returns 400 (nothing to save), because a note is stored only with a new version."
|
|
349
351
|
},
|
|
350
352
|
{
|
|
351
|
-
name: "
|
|
353
|
+
name: "bindings",
|
|
352
354
|
type: "array",
|
|
353
355
|
itemType: "object",
|
|
354
356
|
required: false,
|
|
355
|
-
description: "Replace
|
|
357
|
+
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."
|
|
356
358
|
},
|
|
357
359
|
{
|
|
358
360
|
name: "kind",
|
|
@@ -402,6 +404,25 @@ current version; omit to apply the update unconditionally.`
|
|
|
402
404
|
required: false,
|
|
403
405
|
description: "Praxis extension: switchable model ids on /agent/v1 only. The default model must be included. When omitted, only the default model is selectable."
|
|
404
406
|
},
|
|
407
|
+
{
|
|
408
|
+
name: "avatar",
|
|
409
|
+
type: "string",
|
|
410
|
+
required: false,
|
|
411
|
+
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."
|
|
412
|
+
},
|
|
413
|
+
{
|
|
414
|
+
name: "environment_id",
|
|
415
|
+
type: "string",
|
|
416
|
+
required: false,
|
|
417
|
+
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."
|
|
418
|
+
},
|
|
419
|
+
{
|
|
420
|
+
name: "vault_ids",
|
|
421
|
+
type: "array",
|
|
422
|
+
itemType: "string",
|
|
423
|
+
required: false,
|
|
424
|
+
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."
|
|
425
|
+
},
|
|
405
426
|
{
|
|
406
427
|
name: "preset",
|
|
407
428
|
type: "string",
|
|
@@ -433,6 +454,152 @@ current version; omit to apply the update unconditionally.`
|
|
|
433
454
|
],
|
|
434
455
|
query: []
|
|
435
456
|
},
|
|
457
|
+
{
|
|
458
|
+
resource: "agent.agents.customers.auth.accessTokens",
|
|
459
|
+
method: "create",
|
|
460
|
+
summary: "Create customer access token",
|
|
461
|
+
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.
|
|
462
|
+
|
|
463
|
+
No 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_…"}.`,
|
|
464
|
+
http: "POST",
|
|
465
|
+
path: "/agent/v1/agents/{agent_id}/customers/auth/access_tokens",
|
|
466
|
+
streaming: "no",
|
|
467
|
+
pagination: false,
|
|
468
|
+
pathParams: [
|
|
469
|
+
{
|
|
470
|
+
name: "agent_id",
|
|
471
|
+
sdkName: "agent_id"
|
|
472
|
+
}
|
|
473
|
+
],
|
|
474
|
+
query: [],
|
|
475
|
+
body: {
|
|
476
|
+
required: true,
|
|
477
|
+
fields: []
|
|
478
|
+
}
|
|
479
|
+
},
|
|
480
|
+
{
|
|
481
|
+
resource: "agent.agents.customers.auth.accessTokens",
|
|
482
|
+
method: "deleteCurrent",
|
|
483
|
+
summary: "Log out customer",
|
|
484
|
+
description: `Log the customer out by revoking the sign-in of the presented access token and every token issued in it.
|
|
485
|
+
|
|
486
|
+
Send 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.`,
|
|
487
|
+
http: "DELETE",
|
|
488
|
+
path: "/agent/v1/agents/{agent_id}/customers/auth/access_tokens/current",
|
|
489
|
+
streaming: "no",
|
|
490
|
+
pagination: false,
|
|
491
|
+
pathParams: [
|
|
492
|
+
{
|
|
493
|
+
name: "agent_id",
|
|
494
|
+
sdkName: "agent_id"
|
|
495
|
+
}
|
|
496
|
+
],
|
|
497
|
+
query: []
|
|
498
|
+
},
|
|
499
|
+
{
|
|
500
|
+
resource: "agent.agents.customers.auth.accessTokens.renew",
|
|
501
|
+
method: "create",
|
|
502
|
+
summary: "Renew customer access token",
|
|
503
|
+
description: `Get a fresh customer access token in the same sign-in, authenticated with the current one.
|
|
504
|
+
|
|
505
|
+
Send 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.`,
|
|
506
|
+
http: "POST",
|
|
507
|
+
path: "/agent/v1/agents/{agent_id}/customers/auth/access_tokens/renew",
|
|
508
|
+
streaming: "no",
|
|
509
|
+
pagination: false,
|
|
510
|
+
pathParams: [
|
|
511
|
+
{
|
|
512
|
+
name: "agent_id",
|
|
513
|
+
sdkName: "agent_id"
|
|
514
|
+
}
|
|
515
|
+
],
|
|
516
|
+
query: []
|
|
517
|
+
},
|
|
518
|
+
{
|
|
519
|
+
resource: "agent.agents.customers.auth.grantCodes",
|
|
520
|
+
method: "create",
|
|
521
|
+
summary: "Create customer grant code",
|
|
522
|
+
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.
|
|
523
|
+
|
|
524
|
+
Call 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"}.`,
|
|
525
|
+
http: "POST",
|
|
526
|
+
path: "/agent/v1/agents/{agent_id}/customers/auth/grant_codes",
|
|
527
|
+
streaming: "no",
|
|
528
|
+
pagination: false,
|
|
529
|
+
pathParams: [
|
|
530
|
+
{
|
|
531
|
+
name: "agent_id",
|
|
532
|
+
sdkName: "agent_id"
|
|
533
|
+
}
|
|
534
|
+
],
|
|
535
|
+
query: [],
|
|
536
|
+
body: {
|
|
537
|
+
required: true,
|
|
538
|
+
fields: [
|
|
539
|
+
{
|
|
540
|
+
name: "customer_id",
|
|
541
|
+
type: "string",
|
|
542
|
+
required: true,
|
|
543
|
+
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.'
|
|
544
|
+
},
|
|
545
|
+
{
|
|
546
|
+
name: "version",
|
|
547
|
+
type: "integer",
|
|
548
|
+
required: false,
|
|
549
|
+
description: "Existing agent version that every token of this sign-in pins. Defaults to the agent's active_version when the code is issued."
|
|
550
|
+
},
|
|
551
|
+
{
|
|
552
|
+
name: "budget_cents",
|
|
553
|
+
type: "integer",
|
|
554
|
+
required: false,
|
|
555
|
+
description: "Budget in cents for each session the customer starts. Defaults to the embed policy session budget and cannot exceed its maximum."
|
|
556
|
+
},
|
|
557
|
+
{
|
|
558
|
+
name: "system_message",
|
|
559
|
+
type: "array",
|
|
560
|
+
itemType: "object",
|
|
561
|
+
required: false,
|
|
562
|
+
description: "Optional context the agent receives at the start of each session, as text blocks, limited to 8192 UTF-8 bytes in total."
|
|
563
|
+
},
|
|
564
|
+
{
|
|
565
|
+
name: "agent_override",
|
|
566
|
+
type: "object",
|
|
567
|
+
required: false,
|
|
568
|
+
description: "Optional system prompt override, accepted only when the embed policy allows agent overrides."
|
|
569
|
+
},
|
|
570
|
+
{
|
|
571
|
+
name: "metadata",
|
|
572
|
+
type: "object",
|
|
573
|
+
required: false,
|
|
574
|
+
description: "Up to 16 string pairs copied onto every session the customer starts. The playground key is reserved."
|
|
575
|
+
},
|
|
576
|
+
{
|
|
577
|
+
name: "origin",
|
|
578
|
+
type: "string",
|
|
579
|
+
required: false,
|
|
580
|
+
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."
|
|
581
|
+
},
|
|
582
|
+
{
|
|
583
|
+
name: "expires_in",
|
|
584
|
+
type: "integer",
|
|
585
|
+
required: false,
|
|
586
|
+
description: "Seconds the code stays redeemable, from 60 to 86400. Defaults to 900."
|
|
587
|
+
},
|
|
588
|
+
{
|
|
589
|
+
name: "max_session_seconds",
|
|
590
|
+
type: "integer",
|
|
591
|
+
required: false,
|
|
592
|
+
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."
|
|
593
|
+
},
|
|
594
|
+
{
|
|
595
|
+
name: "anonymous_access_token",
|
|
596
|
+
type: "string",
|
|
597
|
+
required: false,
|
|
598
|
+
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."
|
|
599
|
+
}
|
|
600
|
+
]
|
|
601
|
+
}
|
|
602
|
+
},
|
|
436
603
|
{
|
|
437
604
|
resource: "agent.agents.endUsers",
|
|
438
605
|
method: "list",
|
|
@@ -637,7 +804,7 @@ Removes the user from the blocklist; previously revoked tokens stay revoked. Ide
|
|
|
637
804
|
resource: "agent.agents.versions",
|
|
638
805
|
method: "list",
|
|
639
806
|
summary: "List agent versions",
|
|
640
|
-
description: "List the saved versions of one agent, in pages of at most 100 (default 20). Each item is the full agent definition at that version, so you can compare what changed between versions. Use agents.retrieve with version to read a single one; agent_id comes from agents.list or agents.create.",
|
|
807
|
+
description: "List the saved versions of one agent, in pages of at most 100 (default 20). Each item is the full agent definition at that version, so you can compare what changed between versions. active is true only for the item that new sessions use; active_version on each item is the agent-level value, kept for compatibility. Use agents.retrieve with version to read a single one; agent_id comes from agents.list or agents.create.",
|
|
641
808
|
http: "GET",
|
|
642
809
|
path: "/agent/v1/agents/{agent_id}/versions",
|
|
643
810
|
streaming: "no",
|
|
@@ -663,11 +830,32 @@ Removes the user from the blocklist; previously revoked tokens stay revoked. Ide
|
|
|
663
830
|
}
|
|
664
831
|
]
|
|
665
832
|
},
|
|
833
|
+
{
|
|
834
|
+
resource: "agent.agents.versions",
|
|
835
|
+
method: "apply",
|
|
836
|
+
summary: "Apply Agent Version",
|
|
837
|
+
description: "Apply a version from agents.versions.list by its version number. This idempotent operation changes active_version without creating a version; existing sessions and tokens keep their version. The response is the latest saved agent with its current active_version. Missing versions return 404 Agent version not found; archived agents return 409 Agent is archived. For example, POST /agent/v1/agents/{agent_id}/versions/2/apply with no body.",
|
|
838
|
+
http: "POST",
|
|
839
|
+
path: "/agent/v1/agents/{agent_id}/versions/{version}/apply",
|
|
840
|
+
streaming: "no",
|
|
841
|
+
pagination: false,
|
|
842
|
+
pathParams: [
|
|
843
|
+
{
|
|
844
|
+
name: "agent_id",
|
|
845
|
+
sdkName: "agent_id"
|
|
846
|
+
},
|
|
847
|
+
{
|
|
848
|
+
name: "version",
|
|
849
|
+
sdkName: "version"
|
|
850
|
+
}
|
|
851
|
+
],
|
|
852
|
+
query: []
|
|
853
|
+
},
|
|
666
854
|
{
|
|
667
855
|
resource: "agent.computers",
|
|
668
856
|
method: "list",
|
|
669
|
-
summary: "
|
|
670
|
-
description: `
|
|
857
|
+
summary: "List Computers",
|
|
858
|
+
description: `List the computers of your organization, archived ones included.
|
|
671
859
|
|
|
672
860
|
Praxis 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.`,
|
|
673
861
|
http: "GET",
|
|
@@ -693,8 +881,8 @@ Praxis extension: MA only has session-scoped temporary containers and memory_sto
|
|
|
693
881
|
{
|
|
694
882
|
resource: "agent.computers",
|
|
695
883
|
method: "create",
|
|
696
|
-
summary: "
|
|
697
|
-
description: `
|
|
884
|
+
summary: "Create Computer",
|
|
885
|
+
description: `Create a durable computer: a named machine whose files outlive sessions, for personal agents.
|
|
698
886
|
|
|
699
887
|
Praxis 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.`,
|
|
700
888
|
http: "POST",
|
|
@@ -743,8 +931,8 @@ Own-face superset: Managed Agents has no persistent Computer deletion lifecycle.
|
|
|
743
931
|
{
|
|
744
932
|
resource: "agent.computers",
|
|
745
933
|
method: "retrieve",
|
|
746
|
-
summary: "
|
|
747
|
-
description: `
|
|
934
|
+
summary: "Get Computer",
|
|
935
|
+
description: `Read one computer's status, storage use and sandbox id.
|
|
748
936
|
|
|
749
937
|
Praxis 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.`,
|
|
750
938
|
http: "GET",
|
|
@@ -762,8 +950,8 @@ Praxis extension: MA only has session-scoped temporary containers and memory_sto
|
|
|
762
950
|
{
|
|
763
951
|
resource: "agent.computers",
|
|
764
952
|
method: "update",
|
|
765
|
-
summary: "
|
|
766
|
-
description: `
|
|
953
|
+
summary: "Update Computer",
|
|
954
|
+
description: `Rename a computer.
|
|
767
955
|
|
|
768
956
|
Praxis 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.`,
|
|
769
957
|
http: "POST",
|
|
@@ -792,8 +980,8 @@ Praxis extension: MA only has session-scoped temporary containers and memory_sto
|
|
|
792
980
|
{
|
|
793
981
|
resource: "agent.computers",
|
|
794
982
|
method: "archive",
|
|
795
|
-
summary: "
|
|
796
|
-
description: `
|
|
983
|
+
summary: "Archive Computer",
|
|
984
|
+
description: `Archive a computer: its files stay readable but new sessions cannot use it.
|
|
797
985
|
|
|
798
986
|
Praxis 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.`,
|
|
799
987
|
http: "POST",
|
|
@@ -877,8 +1065,8 @@ Connect to a computer with a caller-held lease. Omit the body or send {} to requ
|
|
|
877
1065
|
{
|
|
878
1066
|
resource: "agent.computers.files",
|
|
879
1067
|
method: "list",
|
|
880
|
-
summary: "
|
|
881
|
-
description: `
|
|
1068
|
+
summary: "List Computer Files",
|
|
1069
|
+
description: `List the entries of one directory on a computer.
|
|
882
1070
|
|
|
883
1071
|
Praxis 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.`,
|
|
884
1072
|
http: "GET",
|
|
@@ -903,8 +1091,8 @@ Praxis extension: MA only has session-scoped temporary containers and memory_sto
|
|
|
903
1091
|
{
|
|
904
1092
|
resource: "agent.computers.files",
|
|
905
1093
|
method: "retrieveContent",
|
|
906
|
-
summary: "
|
|
907
|
-
description: `
|
|
1094
|
+
summary: "Get Computer File Content",
|
|
1095
|
+
description: `Download the bytes of one file on a computer, up to 16 MiB, with single-range support.
|
|
908
1096
|
|
|
909
1097
|
Praxis 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.`,
|
|
910
1098
|
http: "GET",
|
|
@@ -1647,7 +1835,7 @@ Use an id from issuance or listing. Revokes the credential before setting revoke
|
|
|
1647
1835
|
resource: "agent.environments",
|
|
1648
1836
|
method: "create",
|
|
1649
1837
|
summary: "Create environment",
|
|
1650
|
-
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.",
|
|
1838
|
+
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.",
|
|
1651
1839
|
http: "POST",
|
|
1652
1840
|
path: "/agent/v1/environments",
|
|
1653
1841
|
streaming: "no",
|
|
@@ -1680,19 +1868,6 @@ Use an id from issuance or listing. Revokes the credential before setting revoke
|
|
|
1680
1868
|
type: "object",
|
|
1681
1869
|
required: false,
|
|
1682
1870
|
description: "Free-form string key/value pairs."
|
|
1683
|
-
},
|
|
1684
|
-
{
|
|
1685
|
-
name: "scope",
|
|
1686
|
-
type: "string",
|
|
1687
|
-
enum: [
|
|
1688
|
-
"organization",
|
|
1689
|
-
"account"
|
|
1690
|
-
],
|
|
1691
|
-
required: false,
|
|
1692
|
-
description: `The visibility scope for this environment. 'organization' makes the
|
|
1693
|
-
environment visible to all accounts. 'account' restricts visibility to the
|
|
1694
|
-
owning account only. API organizations support only 'organization'; 'account' is
|
|
1695
|
-
rejected. If not specified, defaults based on organization type.`
|
|
1696
1871
|
}
|
|
1697
1872
|
]
|
|
1698
1873
|
}
|
|
@@ -1718,7 +1893,7 @@ rejected. If not specified, defaults based on organization type.`
|
|
|
1718
1893
|
resource: "agent.environments",
|
|
1719
1894
|
method: "update",
|
|
1720
1895
|
summary: "Update environment",
|
|
1721
|
-
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.",
|
|
1896
|
+
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.",
|
|
1722
1897
|
http: "POST",
|
|
1723
1898
|
path: "/agent/v1/environments/{environment_id}",
|
|
1724
1899
|
streaming: "no",
|
|
@@ -1757,18 +1932,6 @@ clears to null; an empty string is stored as an empty string.`
|
|
|
1757
1932
|
type: "string",
|
|
1758
1933
|
required: false,
|
|
1759
1934
|
description: "Updated name for the environment"
|
|
1760
|
-
},
|
|
1761
|
-
{
|
|
1762
|
-
name: "scope",
|
|
1763
|
-
type: "string",
|
|
1764
|
-
enum: [
|
|
1765
|
-
"organization",
|
|
1766
|
-
"account"
|
|
1767
|
-
],
|
|
1768
|
-
required: false,
|
|
1769
|
-
description: `The visibility scope for this environment. 'organization' makes the
|
|
1770
|
-
environment visible to all accounts. 'account' restricts visibility to the
|
|
1771
|
-
owning account only.`
|
|
1772
1935
|
}
|
|
1773
1936
|
]
|
|
1774
1937
|
}
|
|
@@ -1777,7 +1940,7 @@ owning account only.`
|
|
|
1777
1940
|
resource: "agent.environments",
|
|
1778
1941
|
method: "archive",
|
|
1779
1942
|
summary: "Archive environment",
|
|
1780
|
-
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.",
|
|
1943
|
+
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.",
|
|
1781
1944
|
http: "POST",
|
|
1782
1945
|
path: "/agent/v1/environments/{environment_id}/archive",
|
|
1783
1946
|
streaming: "no",
|
|
@@ -1794,7 +1957,7 @@ owning account only.`
|
|
|
1794
1957
|
resource: "agent.sessions",
|
|
1795
1958
|
method: "list",
|
|
1796
1959
|
summary: "List sessions",
|
|
1797
|
-
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
|
|
1960
|
+
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.",
|
|
1798
1961
|
http: "GET",
|
|
1799
1962
|
path: "/agent/v1/sessions",
|
|
1800
1963
|
streaming: "no",
|
|
@@ -1823,7 +1986,7 @@ owning account only.`
|
|
|
1823
1986
|
name: "created_at[gte]",
|
|
1824
1987
|
type: "string",
|
|
1825
1988
|
required: false,
|
|
1826
|
-
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
|
|
1989
|
+
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."
|
|
1827
1990
|
},
|
|
1828
1991
|
{
|
|
1829
1992
|
name: "created_at[lt]",
|
|
@@ -1835,7 +1998,7 @@ owning account only.`
|
|
|
1835
1998
|
name: "created_at[lte]",
|
|
1836
1999
|
type: "string",
|
|
1837
2000
|
required: false,
|
|
1838
|
-
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
|
|
2001
|
+
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."
|
|
1839
2002
|
},
|
|
1840
2003
|
{
|
|
1841
2004
|
name: "deployment_id",
|
|
@@ -1851,7 +2014,7 @@ owning account only.`
|
|
|
1851
2014
|
true
|
|
1852
2015
|
],
|
|
1853
2016
|
required: false,
|
|
1854
|
-
description: "
|
|
2017
|
+
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."
|
|
1855
2018
|
},
|
|
1856
2019
|
{
|
|
1857
2020
|
name: "memory_store_id",
|
|
@@ -1919,7 +2082,7 @@ owning account only.`
|
|
|
1919
2082
|
resource: "agent.sessions",
|
|
1920
2083
|
method: "create",
|
|
1921
2084
|
summary: "Create session",
|
|
1922
|
-
description: `Create a session: one conversation with an agent. Pass agent as an agent id
|
|
2085
|
+
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.`,
|
|
1923
2086
|
http: "POST",
|
|
1924
2087
|
path: "/agent/v1/sessions",
|
|
1925
2088
|
streaming: "no",
|
|
@@ -1933,19 +2096,19 @@ owning account only.`
|
|
|
1933
2096
|
name: "agent",
|
|
1934
2097
|
type: "object",
|
|
1935
2098
|
required: true,
|
|
1936
|
-
description:
|
|
2099
|
+
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.`
|
|
1937
2100
|
},
|
|
1938
2101
|
{
|
|
1939
2102
|
name: "environment_id",
|
|
1940
2103
|
type: "string",
|
|
1941
2104
|
required: false,
|
|
1942
|
-
description: "Execution environment id from agent.environments.list or agent.environments.create. For a service agent, omission
|
|
2105
|
+
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."
|
|
1943
2106
|
},
|
|
1944
2107
|
{
|
|
1945
2108
|
name: "budget",
|
|
1946
2109
|
type: "object",
|
|
1947
2110
|
required: false,
|
|
1948
|
-
description:
|
|
2111
|
+
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.'
|
|
1949
2112
|
},
|
|
1950
2113
|
{
|
|
1951
2114
|
name: "initial_events",
|
|
@@ -2072,12 +2235,6 @@ offsets ("+08:00") and unknown names return 400. Never stored in
|
|
|
2072
2235
|
body: {
|
|
2073
2236
|
required: true,
|
|
2074
2237
|
fields: [
|
|
2075
|
-
{
|
|
2076
|
-
name: "agent",
|
|
2077
|
-
type: "object",
|
|
2078
|
-
required: false,
|
|
2079
|
-
description: "Agent definition the session uses after the change; null when unchanged."
|
|
2080
|
-
},
|
|
2081
2238
|
{
|
|
2082
2239
|
name: "budget",
|
|
2083
2240
|
type: "object",
|
|
@@ -2733,104 +2890,334 @@ Own-face extension. Use a readable session and a run_id from its events. Each su
|
|
|
2733
2890
|
pagination: false,
|
|
2734
2891
|
pathParams: [
|
|
2735
2892
|
{
|
|
2736
|
-
name: "session_id",
|
|
2737
|
-
sdkName: "session_id"
|
|
2893
|
+
name: "session_id",
|
|
2894
|
+
sdkName: "session_id"
|
|
2895
|
+
},
|
|
2896
|
+
{
|
|
2897
|
+
name: "thread_id",
|
|
2898
|
+
sdkName: "thread_id"
|
|
2899
|
+
}
|
|
2900
|
+
],
|
|
2901
|
+
query: [
|
|
2902
|
+
{
|
|
2903
|
+
name: "session_id",
|
|
2904
|
+
sdkName: "query_session_id",
|
|
2905
|
+
type: "string",
|
|
2906
|
+
required: true,
|
|
2907
|
+
description: "Session id (sesn_...), as returned by sessions.create or sessions.list. The same id is also accepted as the session_id query parameter on resource and thread calls, where it must equal the path value."
|
|
2908
|
+
}
|
|
2909
|
+
]
|
|
2910
|
+
},
|
|
2911
|
+
{
|
|
2912
|
+
resource: "agent.sessions.threads.events",
|
|
2913
|
+
method: "list",
|
|
2914
|
+
summary: "List session thread events",
|
|
2915
|
+
description: "Read the event history of one execution thread: the session itself for the primary thread, or the child session for a child thread. It accepts the same filters, ordering and paging as sessions.events.list and returns the same data + next_page envelope. Child approvals carry session_thread_id so you can route a confirmation to the owning thread.",
|
|
2916
|
+
http: "GET",
|
|
2917
|
+
path: "/agent/v1/sessions/{session_id}/threads/{thread_id}/events",
|
|
2918
|
+
streaming: "no",
|
|
2919
|
+
pagination: false,
|
|
2920
|
+
pathParams: [
|
|
2921
|
+
{
|
|
2922
|
+
name: "session_id",
|
|
2923
|
+
sdkName: "session_id"
|
|
2924
|
+
},
|
|
2925
|
+
{
|
|
2926
|
+
name: "thread_id",
|
|
2927
|
+
sdkName: "thread_id"
|
|
2928
|
+
}
|
|
2929
|
+
],
|
|
2930
|
+
query: [
|
|
2931
|
+
{
|
|
2932
|
+
name: "session_id",
|
|
2933
|
+
sdkName: "query_session_id",
|
|
2934
|
+
type: "string",
|
|
2935
|
+
required: true,
|
|
2936
|
+
description: "Session id (sesn_...), as returned by sessions.create or sessions.list. The same id is also accepted as the session_id query parameter on resource and thread calls, where it must equal the path value."
|
|
2937
|
+
},
|
|
2938
|
+
{
|
|
2939
|
+
name: "limit",
|
|
2940
|
+
type: "number",
|
|
2941
|
+
required: false,
|
|
2942
|
+
description: "Number of items per page."
|
|
2943
|
+
},
|
|
2944
|
+
{
|
|
2945
|
+
name: "page",
|
|
2946
|
+
type: "string",
|
|
2947
|
+
required: false,
|
|
2948
|
+
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."
|
|
2949
|
+
}
|
|
2950
|
+
]
|
|
2951
|
+
},
|
|
2952
|
+
{
|
|
2953
|
+
resource: "agent.sessions.threads",
|
|
2954
|
+
method: "stream",
|
|
2955
|
+
summary: "Stream session thread events",
|
|
2956
|
+
description: "Open a Server-Sent Events stream of one execution thread's live events, using the same implementation as sessions.events.stream; a read-only WebSocket is also available on this path. The parent session stream additionally carries child creation, status and message events. Pass event_deltas[]=agent.message, agent.thinking or agent.tool_use for incremental previews.",
|
|
2957
|
+
http: "GET",
|
|
2958
|
+
path: "/agent/v1/sessions/{session_id}/threads/{thread_id}/stream",
|
|
2959
|
+
streaming: "always",
|
|
2960
|
+
pagination: false,
|
|
2961
|
+
pathParams: [
|
|
2962
|
+
{
|
|
2963
|
+
name: "session_id",
|
|
2964
|
+
sdkName: "session_id"
|
|
2965
|
+
},
|
|
2966
|
+
{
|
|
2967
|
+
name: "thread_id",
|
|
2968
|
+
sdkName: "thread_id"
|
|
2969
|
+
}
|
|
2970
|
+
],
|
|
2971
|
+
query: [
|
|
2972
|
+
{
|
|
2973
|
+
name: "session_id",
|
|
2974
|
+
sdkName: "query_session_id",
|
|
2975
|
+
type: "string",
|
|
2976
|
+
required: true,
|
|
2977
|
+
description: "Session id (sesn_...), as returned by sessions.create or sessions.list. The same id is also accepted as the session_id query parameter on resource and thread calls, where it must equal the path value."
|
|
2978
|
+
},
|
|
2979
|
+
{
|
|
2980
|
+
name: "event_deltas",
|
|
2981
|
+
type: "array",
|
|
2982
|
+
itemType: "string",
|
|
2983
|
+
enum: [
|
|
2984
|
+
"agent.message",
|
|
2985
|
+
"agent.thinking"
|
|
2986
|
+
],
|
|
2987
|
+
required: false,
|
|
2988
|
+
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."
|
|
2989
|
+
}
|
|
2990
|
+
]
|
|
2991
|
+
},
|
|
2992
|
+
{
|
|
2993
|
+
resource: "agent.skills",
|
|
2994
|
+
method: "list",
|
|
2995
|
+
summary: "List skills",
|
|
2996
|
+
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.",
|
|
2997
|
+
http: "GET",
|
|
2998
|
+
path: "/agent/v1/skills",
|
|
2999
|
+
streaming: "no",
|
|
3000
|
+
pagination: false,
|
|
3001
|
+
pathParams: [],
|
|
3002
|
+
query: [
|
|
3003
|
+
{
|
|
3004
|
+
name: "source",
|
|
3005
|
+
type: "string",
|
|
3006
|
+
required: false,
|
|
3007
|
+
description: `Filter skills by source.
|
|
3008
|
+
|
|
3009
|
+
If provided, only skills from the specified source will be returned:
|
|
3010
|
+
|
|
3011
|
+
- \`"custom"\`: only return user-created skills
|
|
3012
|
+
- \`"anthropic"\`: only return Anthropic-created skills`
|
|
3013
|
+
},
|
|
3014
|
+
{
|
|
3015
|
+
name: "limit",
|
|
3016
|
+
type: "number",
|
|
3017
|
+
required: false,
|
|
3018
|
+
description: "Number of items per page."
|
|
3019
|
+
},
|
|
3020
|
+
{
|
|
3021
|
+
name: "page",
|
|
3022
|
+
type: "string",
|
|
3023
|
+
required: false,
|
|
3024
|
+
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."
|
|
3025
|
+
}
|
|
3026
|
+
]
|
|
3027
|
+
},
|
|
3028
|
+
{
|
|
3029
|
+
resource: "agent.skills",
|
|
3030
|
+
method: "create",
|
|
3031
|
+
summary: "Create skill",
|
|
3032
|
+
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.',
|
|
3033
|
+
http: "POST",
|
|
3034
|
+
path: "/agent/v1/skills",
|
|
3035
|
+
streaming: "no",
|
|
3036
|
+
pagination: false,
|
|
3037
|
+
multipart: true,
|
|
3038
|
+
pathParams: [],
|
|
3039
|
+
query: [],
|
|
3040
|
+
body: {
|
|
3041
|
+
required: true,
|
|
3042
|
+
fields: [
|
|
3043
|
+
{
|
|
3044
|
+
name: "files",
|
|
3045
|
+
type: "array",
|
|
3046
|
+
itemType: "string",
|
|
3047
|
+
required: true,
|
|
3048
|
+
description: `Files to upload for the skill.
|
|
3049
|
+
|
|
3050
|
+
All files must be in the same top-level directory and must include a SKILL.md
|
|
3051
|
+
file at the root of that directory.`
|
|
3052
|
+
},
|
|
3053
|
+
{
|
|
3054
|
+
name: "display_name",
|
|
3055
|
+
type: "string",
|
|
3056
|
+
required: false,
|
|
3057
|
+
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."
|
|
3058
|
+
}
|
|
3059
|
+
]
|
|
3060
|
+
}
|
|
3061
|
+
},
|
|
3062
|
+
{
|
|
3063
|
+
resource: "agent.skills",
|
|
3064
|
+
method: "delete",
|
|
3065
|
+
summary: "Delete skill",
|
|
3066
|
+
description: "Delete a skill together with all of its 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. Returns {id, type: skill_deleted}. skill_id comes from skills.create or skills.list.",
|
|
3067
|
+
http: "DELETE",
|
|
3068
|
+
path: "/agent/v1/skills/{skill_id}",
|
|
3069
|
+
streaming: "no",
|
|
3070
|
+
pagination: false,
|
|
3071
|
+
pathParams: [
|
|
3072
|
+
{
|
|
3073
|
+
name: "skill_id",
|
|
3074
|
+
sdkName: "skill_id"
|
|
3075
|
+
}
|
|
3076
|
+
],
|
|
3077
|
+
query: []
|
|
3078
|
+
},
|
|
3079
|
+
{
|
|
3080
|
+
resource: "agent.skills",
|
|
3081
|
+
method: "retrieve",
|
|
3082
|
+
summary: "Get skill",
|
|
3083
|
+
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.",
|
|
3084
|
+
http: "GET",
|
|
3085
|
+
path: "/agent/v1/skills/{skill_id}",
|
|
3086
|
+
streaming: "no",
|
|
3087
|
+
pagination: false,
|
|
3088
|
+
pathParams: [
|
|
3089
|
+
{
|
|
3090
|
+
name: "skill_id",
|
|
3091
|
+
sdkName: "skill_id"
|
|
3092
|
+
}
|
|
3093
|
+
],
|
|
3094
|
+
query: []
|
|
3095
|
+
},
|
|
3096
|
+
{
|
|
3097
|
+
resource: "agent.skills.versions",
|
|
3098
|
+
method: "list",
|
|
3099
|
+
summary: "List skill versions",
|
|
3100
|
+
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.",
|
|
3101
|
+
http: "GET",
|
|
3102
|
+
path: "/agent/v1/skills/{skill_id}/versions",
|
|
3103
|
+
streaming: "no",
|
|
3104
|
+
pagination: false,
|
|
3105
|
+
pathParams: [
|
|
3106
|
+
{
|
|
3107
|
+
name: "skill_id",
|
|
3108
|
+
sdkName: "skill_id"
|
|
3109
|
+
}
|
|
3110
|
+
],
|
|
3111
|
+
query: [
|
|
3112
|
+
{
|
|
3113
|
+
name: "limit",
|
|
3114
|
+
type: "number",
|
|
3115
|
+
required: false,
|
|
3116
|
+
description: "Number of items per page."
|
|
3117
|
+
},
|
|
3118
|
+
{
|
|
3119
|
+
name: "page",
|
|
3120
|
+
type: "string",
|
|
3121
|
+
required: false,
|
|
3122
|
+
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."
|
|
3123
|
+
}
|
|
3124
|
+
]
|
|
3125
|
+
},
|
|
3126
|
+
{
|
|
3127
|
+
resource: "agent.skills.versions",
|
|
3128
|
+
method: "create",
|
|
3129
|
+
summary: "Create skill version",
|
|
3130
|
+
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.",
|
|
3131
|
+
http: "POST",
|
|
3132
|
+
path: "/agent/v1/skills/{skill_id}/versions",
|
|
3133
|
+
streaming: "no",
|
|
3134
|
+
pagination: false,
|
|
3135
|
+
multipart: true,
|
|
3136
|
+
pathParams: [
|
|
3137
|
+
{
|
|
3138
|
+
name: "skill_id",
|
|
3139
|
+
sdkName: "skill_id"
|
|
3140
|
+
}
|
|
3141
|
+
],
|
|
3142
|
+
query: [],
|
|
3143
|
+
body: {
|
|
3144
|
+
required: true,
|
|
3145
|
+
fields: [
|
|
3146
|
+
{
|
|
3147
|
+
name: "files",
|
|
3148
|
+
type: "array",
|
|
3149
|
+
itemType: "string",
|
|
3150
|
+
required: true,
|
|
3151
|
+
description: `Files to upload for the skill.
|
|
3152
|
+
|
|
3153
|
+
All files must be in the same top-level directory and must include a SKILL.md
|
|
3154
|
+
file at the root of that directory.`
|
|
3155
|
+
}
|
|
3156
|
+
]
|
|
3157
|
+
}
|
|
3158
|
+
},
|
|
3159
|
+
{
|
|
3160
|
+
resource: "agent.skills.versions",
|
|
3161
|
+
method: "delete",
|
|
3162
|
+
summary: "Delete skill version",
|
|
3163
|
+
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 keeps at least one version: deleting the last remaining version returns 409 SKILL_LAST_VERSION (delete the skill instead), so latest_version_id is never null. A version that a non-archived agent pins returns 409 RESOURCE_IN_USE naming the agents.",
|
|
3164
|
+
http: "DELETE",
|
|
3165
|
+
path: "/agent/v1/skills/{skill_id}/versions/{version}",
|
|
3166
|
+
streaming: "no",
|
|
3167
|
+
pagination: false,
|
|
3168
|
+
pathParams: [
|
|
3169
|
+
{
|
|
3170
|
+
name: "skill_id",
|
|
3171
|
+
sdkName: "skill_id"
|
|
2738
3172
|
},
|
|
2739
3173
|
{
|
|
2740
|
-
name: "
|
|
2741
|
-
sdkName: "
|
|
3174
|
+
name: "version",
|
|
3175
|
+
sdkName: "version"
|
|
2742
3176
|
}
|
|
2743
3177
|
],
|
|
2744
|
-
query: [
|
|
2745
|
-
{
|
|
2746
|
-
name: "session_id",
|
|
2747
|
-
sdkName: "query_session_id",
|
|
2748
|
-
type: "string",
|
|
2749
|
-
required: true,
|
|
2750
|
-
description: "Session id (sesn_...), as returned by sessions.create or sessions.list. The same id is also accepted as the session_id query parameter on resource and thread calls, where it must equal the path value."
|
|
2751
|
-
}
|
|
2752
|
-
]
|
|
3178
|
+
query: []
|
|
2753
3179
|
},
|
|
2754
3180
|
{
|
|
2755
|
-
resource: "agent.
|
|
2756
|
-
method: "
|
|
2757
|
-
summary: "
|
|
2758
|
-
description: "Read
|
|
3181
|
+
resource: "agent.skills.versions",
|
|
3182
|
+
method: "retrieve",
|
|
3183
|
+
summary: "Get skill version",
|
|
3184
|
+
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.",
|
|
2759
3185
|
http: "GET",
|
|
2760
|
-
path: "/agent/v1/
|
|
3186
|
+
path: "/agent/v1/skills/{skill_id}/versions/{version}",
|
|
2761
3187
|
streaming: "no",
|
|
2762
3188
|
pagination: false,
|
|
2763
3189
|
pathParams: [
|
|
2764
3190
|
{
|
|
2765
|
-
name: "
|
|
2766
|
-
sdkName: "
|
|
3191
|
+
name: "skill_id",
|
|
3192
|
+
sdkName: "skill_id"
|
|
2767
3193
|
},
|
|
2768
3194
|
{
|
|
2769
|
-
name: "
|
|
2770
|
-
sdkName: "
|
|
3195
|
+
name: "version",
|
|
3196
|
+
sdkName: "version"
|
|
2771
3197
|
}
|
|
2772
3198
|
],
|
|
2773
|
-
query: [
|
|
2774
|
-
{
|
|
2775
|
-
name: "session_id",
|
|
2776
|
-
sdkName: "query_session_id",
|
|
2777
|
-
type: "string",
|
|
2778
|
-
required: true,
|
|
2779
|
-
description: "Session id (sesn_...), as returned by sessions.create or sessions.list. The same id is also accepted as the session_id query parameter on resource and thread calls, where it must equal the path value."
|
|
2780
|
-
},
|
|
2781
|
-
{
|
|
2782
|
-
name: "limit",
|
|
2783
|
-
type: "number",
|
|
2784
|
-
required: false,
|
|
2785
|
-
description: "Number of items per page."
|
|
2786
|
-
},
|
|
2787
|
-
{
|
|
2788
|
-
name: "page",
|
|
2789
|
-
type: "string",
|
|
2790
|
-
required: false,
|
|
2791
|
-
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."
|
|
2792
|
-
}
|
|
2793
|
-
]
|
|
3199
|
+
query: []
|
|
2794
3200
|
},
|
|
2795
3201
|
{
|
|
2796
|
-
resource: "agent.
|
|
2797
|
-
method: "
|
|
2798
|
-
summary: "
|
|
2799
|
-
description: "
|
|
3202
|
+
resource: "agent.skills.versions",
|
|
3203
|
+
method: "retrieveContent",
|
|
3204
|
+
summary: "Download skill version",
|
|
3205
|
+
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.",
|
|
2800
3206
|
http: "GET",
|
|
2801
|
-
path: "/agent/v1/
|
|
2802
|
-
streaming: "
|
|
3207
|
+
path: "/agent/v1/skills/{skill_id}/versions/{version}/content",
|
|
3208
|
+
streaming: "no",
|
|
2803
3209
|
pagination: false,
|
|
2804
3210
|
pathParams: [
|
|
2805
3211
|
{
|
|
2806
|
-
name: "
|
|
2807
|
-
sdkName: "
|
|
3212
|
+
name: "skill_id",
|
|
3213
|
+
sdkName: "skill_id"
|
|
2808
3214
|
},
|
|
2809
3215
|
{
|
|
2810
|
-
name: "
|
|
2811
|
-
sdkName: "
|
|
3216
|
+
name: "version",
|
|
3217
|
+
sdkName: "version"
|
|
2812
3218
|
}
|
|
2813
3219
|
],
|
|
2814
|
-
query: [
|
|
2815
|
-
{
|
|
2816
|
-
name: "session_id",
|
|
2817
|
-
sdkName: "query_session_id",
|
|
2818
|
-
type: "string",
|
|
2819
|
-
required: true,
|
|
2820
|
-
description: "Session id (sesn_...), as returned by sessions.create or sessions.list. The same id is also accepted as the session_id query parameter on resource and thread calls, where it must equal the path value."
|
|
2821
|
-
},
|
|
2822
|
-
{
|
|
2823
|
-
name: "event_deltas",
|
|
2824
|
-
type: "array",
|
|
2825
|
-
itemType: "string",
|
|
2826
|
-
enum: [
|
|
2827
|
-
"agent.message",
|
|
2828
|
-
"agent.thinking"
|
|
2829
|
-
],
|
|
2830
|
-
required: false,
|
|
2831
|
-
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."
|
|
2832
|
-
}
|
|
2833
|
-
]
|
|
3220
|
+
query: []
|
|
2834
3221
|
},
|
|
2835
3222
|
{
|
|
2836
3223
|
resource: "agent.toolsets",
|
|
@@ -3674,13 +4061,13 @@ Own-face extension. Use a readable session and a run_id from its events. Each su
|
|
|
3674
4061
|
name: "namespace",
|
|
3675
4062
|
type: "string",
|
|
3676
4063
|
required: true,
|
|
3677
|
-
description: "Choose a namespace without prior registration; praxis is
|
|
4064
|
+
description: "Choose a namespace without prior registration; praxis is reserved for built-in Actions. Folded to lowercase; matches [a-z0-9][a-z0-9_-]{0,63}."
|
|
3678
4065
|
},
|
|
3679
4066
|
{
|
|
3680
4067
|
name: "name",
|
|
3681
4068
|
type: "string",
|
|
3682
4069
|
required: true,
|
|
3683
|
-
description: "Name, folded to lowercase; matches [a-z0-9][a-z0-
|
|
4070
|
+
description: "Name, folded to lowercase; matches [a-z0-9][a-z0-9_-]{0,63}."
|
|
3684
4071
|
},
|
|
3685
4072
|
{
|
|
3686
4073
|
name: "description",
|
|
@@ -3743,8 +4130,8 @@ Own-face extension. Use a readable session and a run_id from its events. Each su
|
|
|
3743
4130
|
{
|
|
3744
4131
|
resource: "automation.actions",
|
|
3745
4132
|
method: "retrieve",
|
|
3746
|
-
summary: "Get an
|
|
3747
|
-
description:
|
|
4133
|
+
summary: "Get an Action with its current input and output JSON Schemas",
|
|
4134
|
+
description: 'Read the Action and its full current implementation, with input and output JSON Schemas at current_revision.input_schema and current_revision.output_schema. To read a built-in Action, use ns=praxis and name=<bare name>, for example name=ocr; invoke it in a script with call("ocr", input). The response ETag is the current revision ID for conditional updates.',
|
|
3748
4135
|
http: "GET",
|
|
3749
4136
|
path: "/automation/v1/actions/{ns}/{name}",
|
|
3750
4137
|
streaming: "no",
|
|
@@ -4318,8 +4705,8 @@ Own-face extension. Use a readable session and a run_id from its events. Each su
|
|
|
4318
4705
|
{
|
|
4319
4706
|
resource: "automation.runs",
|
|
4320
4707
|
method: "create",
|
|
4321
|
-
summary: "
|
|
4322
|
-
description:
|
|
4708
|
+
summary: "Run a published target or execute draft source",
|
|
4709
|
+
description: 'Execute a published script or workflow with target, or test unpublished code directly with source and language (ts for TypeScript, yaml for workflow YAML), without first saving or publishing a definition. Minimal script: `export default async ({ file_id }: { file_id: string }) => { const result = await call("ocr", { document: { type: "file", file_id } }); return result; }`; send it as source with language="ts", input={"file_id":"<uploaded file ID>"} and wait=0, using a PDF or image already uploaded to your account. To call a platform API directly in the same script, use the praxis SDK object, for example `praxis.model.ocr.create({ body: { model: "glm-ocr", document: { type: "file", file_id } } })`; Action IDs are strings passed to call(), not SDK methods such as praxis.ocr(...). praxis, call, invoke, console and codemode are module-scope bindings, not on globalThis, and need no import; invoke("namespace/name", input) starts a child run. target and source are mutually exclusive; target accepts ns/name@version, @tag or @range and defaults to latest when @ is omitted. Source/input validation precedes run creation, so a separate validate call is optional. input defaults to {} and must match the input schema and fit within 1 MiB. wait is 0–60 seconds (default 0): a terminal run returns 200, otherwise 202. Use the returned id with praxis.automation.runs.retrieve and inspect status, output and error; acceptance does not mean successful completion. For long-running, background or batch work, use wait: 0 and poll the run, or split work into child runs or a workflow; wait only controls the response wait and does not extend execution limits. Actions time out after 30 s (run-sandbox after 10 min); scripts have a 5 min wall-clock limit and a 30 s CPU limit; workflows default to 24 h and allow up to 7 days. Each run can start at most 100 child runs, with at most 20 active at once; nesting depth is limited to 10. Idempotency-Key is scoped to tenant, method and path for 24 hours, excluding wait from the fingerprint; replay returns the current run with Idempotent-Replayed: true, changed contents return 422 and an in-flight request returns 409. New non-deterministic run IDs contain 78 characters, compared with 46 for legacy random IDs; treat IDs as opaque strings. Historical and deterministic IDs remain valid; same-millisecond order is not guaranteed.',
|
|
4323
4710
|
http: "POST",
|
|
4324
4711
|
path: "/automation/v1/runs",
|
|
4325
4712
|
streaming: "no",
|
|
@@ -4797,7 +5184,7 @@ Own-face extension. Use a readable session and a run_id from its events. Each su
|
|
|
4797
5184
|
resource: "automation.scripts",
|
|
4798
5185
|
method: "create",
|
|
4799
5186
|
summary: "Create a script",
|
|
4800
|
-
description: 'Save a TypeScript script as an editable draft for later reuse; this does not publish or start a run. Choose your own namespace without registering it first; praxis is
|
|
5187
|
+
description: 'Save a TypeScript script as an editable draft for later reuse; this does not publish or start a run. Choose your own namespace without registering it first; praxis is reserved for built-in Actions. Scripts and workflows share names within the tenant; a duplicate returns NAME_TAKEN. The draft is a source string with a default-exported function, for example `export default async (input: {name: string}) => ({greeting: "Hello, " + input.name});`. Scripts provide praxis, call, invoke, console and codemode as module-scope bindings, not on globalThis, with no import needed: praxis.<domain>.<resource>.<method>(...) calls a platform API, call("ocr", input) calls a built-in Action, and invoke("namespace/name", input) starts a child run. Action IDs are strings (bare names for built-ins, namespace/name for your own Actions); praxis.ocr(...) does not exist. To test it, pass that source and language=ts to praxis.automation.runs.create without publishing. To publish later, use the returned draft.revision as expected_draft_revision.',
|
|
4801
5188
|
http: "POST",
|
|
4802
5189
|
path: "/automation/v1/scripts",
|
|
4803
5190
|
streaming: "no",
|
|
@@ -4811,13 +5198,13 @@ Own-face extension. Use a readable session and a run_id from its events. Each su
|
|
|
4811
5198
|
name: "namespace",
|
|
4812
5199
|
type: "string",
|
|
4813
5200
|
required: true,
|
|
4814
|
-
description: "Choose a namespace without prior registration; praxis is
|
|
5201
|
+
description: "Choose a namespace without prior registration; praxis is reserved for built-in Actions. Folded to lowercase; matches [a-z0-9][a-z0-9_-]{0,63}."
|
|
4815
5202
|
},
|
|
4816
5203
|
{
|
|
4817
5204
|
name: "name",
|
|
4818
5205
|
type: "string",
|
|
4819
5206
|
required: true,
|
|
4820
|
-
description: "Name, folded to lowercase; matches [a-z0-9][a-z0-
|
|
5207
|
+
description: "Name, folded to lowercase; matches [a-z0-9][a-z0-9_-]{0,63}."
|
|
4821
5208
|
},
|
|
4822
5209
|
{
|
|
4823
5210
|
name: "description",
|
|
@@ -4865,7 +5252,7 @@ Own-face extension. Use a readable session and a run_id from its events. Each su
|
|
|
4865
5252
|
resource: "automation.scripts",
|
|
4866
5253
|
method: "update",
|
|
4867
5254
|
summary: "Update a script draft",
|
|
4868
|
-
description:
|
|
5255
|
+
description: 'Update description, labels or draft with the current draft revision in If-Match. Even metadata-only updates create a new draft revision. Scripts provide praxis, call, invoke, console and codemode as module-scope bindings, not on globalThis, with no import needed: praxis.<domain>.<resource>.<method>(...) calls a platform API, call("ocr", input) calls a built-in Action, and invoke("namespace/name", input) starts a child run. Action IDs are strings (bare names for built-ins, namespace/name for your own Actions); praxis.ocr(...) does not exist.',
|
|
4869
5256
|
http: "PATCH",
|
|
4870
5257
|
path: "/automation/v1/scripts/{ns}/{name}",
|
|
4871
5258
|
streaming: "no",
|
|
@@ -5819,7 +6206,7 @@ Own-face extension. Use a readable session and a run_id from its events. Each su
|
|
|
5819
6206
|
resource: "automation.workflows",
|
|
5820
6207
|
method: "create",
|
|
5821
6208
|
summary: "Create a workflow",
|
|
5822
|
-
description: "Save a YAML workflow as an editable draft without publishing or starting a run. Choose your own namespace without registering it first; praxis is
|
|
6209
|
+
description: "Save a YAML workflow as an editable draft without publishing or starting a run. Choose your own namespace without registering it first; praxis is reserved for built-in Actions. To test the draft, send its source and language=yaml to praxis.automation.runs.create. Scripts and workflows share names within the tenant; a duplicate returns NAME_TAKEN. run.workflow accepts ns/name@range or {namespace, name, version, input}; run.script uses the same reference shape as a platform extension. Object namespace, name and version are required; version accepts an exact version, dist-tag or range, locked at publication. Object input defaults to {} and supports expressions; string references retain task-level with. run.await defaults to true and returns the child output. With false, the child uses detach and the task immediately returns {run_id}; parent cancellation does not cascade. Inline script.code returns DEFINITION_INVALID with a detail asking you to save a script and reference it first. raise.error retains its type URI, status, title and detail in the run error.",
|
|
5823
6210
|
http: "POST",
|
|
5824
6211
|
path: "/automation/v1/workflows",
|
|
5825
6212
|
streaming: "no",
|
|
@@ -5833,13 +6220,13 @@ Own-face extension. Use a readable session and a run_id from its events. Each su
|
|
|
5833
6220
|
name: "namespace",
|
|
5834
6221
|
type: "string",
|
|
5835
6222
|
required: true,
|
|
5836
|
-
description: "Choose a namespace without prior registration; praxis is
|
|
6223
|
+
description: "Choose a namespace without prior registration; praxis is reserved for built-in Actions. Folded to lowercase; matches [a-z0-9][a-z0-9_-]{0,63}."
|
|
5837
6224
|
},
|
|
5838
6225
|
{
|
|
5839
6226
|
name: "name",
|
|
5840
6227
|
type: "string",
|
|
5841
6228
|
required: true,
|
|
5842
|
-
description: "Name, folded to lowercase; matches [a-z0-9][a-z0-
|
|
6229
|
+
description: "Name, folded to lowercase; matches [a-z0-9][a-z0-9_-]{0,63}."
|
|
5843
6230
|
},
|
|
5844
6231
|
{
|
|
5845
6232
|
name: "description",
|
|
@@ -17397,6 +17784,19 @@ var createClient = (config = {}) => {
|
|
|
17397
17784
|
var client = createClient(createConfig({ baseUrl: "https://api.deepraxis.com" }));
|
|
17398
17785
|
|
|
17399
17786
|
// ../../packages/sdk/typescript/src/generated/sdk.gen.ts
|
|
17787
|
+
var applyAgentVersion = (options) => (options.client ?? client).post({
|
|
17788
|
+
security: [{
|
|
17789
|
+
key: "BearerAuth",
|
|
17790
|
+
scheme: "bearer",
|
|
17791
|
+
type: "http"
|
|
17792
|
+
}, {
|
|
17793
|
+
key: "ApiKeyAuth",
|
|
17794
|
+
name: "X-API-Key",
|
|
17795
|
+
type: "apiKey"
|
|
17796
|
+
}],
|
|
17797
|
+
url: "/agent/v1/agents/{agent_id}/versions/{version}/apply",
|
|
17798
|
+
...options
|
|
17799
|
+
});
|
|
17400
17800
|
var unarchiveAgent = (options) => (options.client ?? client).post({
|
|
17401
17801
|
security: [{
|
|
17402
17802
|
key: "BearerAuth",
|
|
@@ -17531,6 +17931,57 @@ var unblockEndUser = (options) => (options.client ?? client).post({
|
|
|
17531
17931
|
url: "/agent/v1/agents/{agent_id}/end_users/{external_user_id}/unblock",
|
|
17532
17932
|
...options
|
|
17533
17933
|
});
|
|
17934
|
+
var createCustomerGrantCode = (options) => (options.client ?? client).post({
|
|
17935
|
+
security: [{
|
|
17936
|
+
key: "BearerAuth",
|
|
17937
|
+
scheme: "bearer",
|
|
17938
|
+
type: "http"
|
|
17939
|
+
}, {
|
|
17940
|
+
key: "ApiKeyAuth",
|
|
17941
|
+
name: "X-API-Key",
|
|
17942
|
+
type: "apiKey"
|
|
17943
|
+
}],
|
|
17944
|
+
url: "/agent/v1/agents/{agent_id}/customers/auth/grant_codes",
|
|
17945
|
+
...options,
|
|
17946
|
+
headers: {
|
|
17947
|
+
"Content-Type": "application/json",
|
|
17948
|
+
...options.headers
|
|
17949
|
+
}
|
|
17950
|
+
});
|
|
17951
|
+
var createCustomerAccessToken = (options) => (options.client ?? client).post({
|
|
17952
|
+
url: "/agent/v1/agents/{agent_id}/customers/auth/access_tokens",
|
|
17953
|
+
...options,
|
|
17954
|
+
headers: {
|
|
17955
|
+
"Content-Type": "application/json",
|
|
17956
|
+
...options.headers
|
|
17957
|
+
}
|
|
17958
|
+
});
|
|
17959
|
+
var renewCustomerAccessToken = (options) => (options.client ?? client).post({
|
|
17960
|
+
security: [{
|
|
17961
|
+
key: "BearerAuth",
|
|
17962
|
+
scheme: "bearer",
|
|
17963
|
+
type: "http"
|
|
17964
|
+
}, {
|
|
17965
|
+
key: "ApiKeyAuth",
|
|
17966
|
+
name: "X-API-Key",
|
|
17967
|
+
type: "apiKey"
|
|
17968
|
+
}],
|
|
17969
|
+
url: "/agent/v1/agents/{agent_id}/customers/auth/access_tokens/renew",
|
|
17970
|
+
...options
|
|
17971
|
+
});
|
|
17972
|
+
var deleteCurrentCustomerAccessToken = (options) => (options.client ?? client).delete({
|
|
17973
|
+
security: [{
|
|
17974
|
+
key: "BearerAuth",
|
|
17975
|
+
scheme: "bearer",
|
|
17976
|
+
type: "http"
|
|
17977
|
+
}, {
|
|
17978
|
+
key: "ApiKeyAuth",
|
|
17979
|
+
name: "X-API-Key",
|
|
17980
|
+
type: "apiKey"
|
|
17981
|
+
}],
|
|
17982
|
+
url: "/agent/v1/agents/{agent_id}/customers/auth/access_tokens/current",
|
|
17983
|
+
...options
|
|
17984
|
+
});
|
|
17534
17985
|
var exchangeEmbedCode = (options) => (options.client ?? client).post({
|
|
17535
17986
|
url: "/agent/v1/embed/exchange",
|
|
17536
17987
|
...options,
|
|
@@ -19609,6 +20060,133 @@ var deploymentsRun = (options) => (options.client ?? client).post({
|
|
|
19609
20060
|
url: "/agent/v1/deployments/{deployment_id}/run",
|
|
19610
20061
|
...options
|
|
19611
20062
|
});
|
|
20063
|
+
var skillsList = (options) => (options?.client ?? client).get({
|
|
20064
|
+
security: [{
|
|
20065
|
+
key: "BearerAuth",
|
|
20066
|
+
scheme: "bearer",
|
|
20067
|
+
type: "http"
|
|
20068
|
+
}, {
|
|
20069
|
+
key: "ApiKeyAuth",
|
|
20070
|
+
name: "X-API-Key",
|
|
20071
|
+
type: "apiKey"
|
|
20072
|
+
}],
|
|
20073
|
+
url: "/agent/v1/skills",
|
|
20074
|
+
...options
|
|
20075
|
+
});
|
|
20076
|
+
var skillsCreate = (options) => (options.client ?? client).post({
|
|
20077
|
+
...formDataBodySerializer,
|
|
20078
|
+
security: [{
|
|
20079
|
+
key: "BearerAuth",
|
|
20080
|
+
scheme: "bearer",
|
|
20081
|
+
type: "http"
|
|
20082
|
+
}, {
|
|
20083
|
+
key: "ApiKeyAuth",
|
|
20084
|
+
name: "X-API-Key",
|
|
20085
|
+
type: "apiKey"
|
|
20086
|
+
}],
|
|
20087
|
+
url: "/agent/v1/skills",
|
|
20088
|
+
...options,
|
|
20089
|
+
headers: {
|
|
20090
|
+
"Content-Type": null,
|
|
20091
|
+
...options.headers
|
|
20092
|
+
}
|
|
20093
|
+
});
|
|
20094
|
+
var skillsDelete = (options) => (options.client ?? client).delete({
|
|
20095
|
+
security: [{
|
|
20096
|
+
key: "BearerAuth",
|
|
20097
|
+
scheme: "bearer",
|
|
20098
|
+
type: "http"
|
|
20099
|
+
}, {
|
|
20100
|
+
key: "ApiKeyAuth",
|
|
20101
|
+
name: "X-API-Key",
|
|
20102
|
+
type: "apiKey"
|
|
20103
|
+
}],
|
|
20104
|
+
url: "/agent/v1/skills/{skill_id}",
|
|
20105
|
+
...options
|
|
20106
|
+
});
|
|
20107
|
+
var skillsRetrieve = (options) => (options.client ?? client).get({
|
|
20108
|
+
security: [{
|
|
20109
|
+
key: "BearerAuth",
|
|
20110
|
+
scheme: "bearer",
|
|
20111
|
+
type: "http"
|
|
20112
|
+
}, {
|
|
20113
|
+
key: "ApiKeyAuth",
|
|
20114
|
+
name: "X-API-Key",
|
|
20115
|
+
type: "apiKey"
|
|
20116
|
+
}],
|
|
20117
|
+
url: "/agent/v1/skills/{skill_id}",
|
|
20118
|
+
...options
|
|
20119
|
+
});
|
|
20120
|
+
var skillsVersionsList = (options) => (options.client ?? client).get({
|
|
20121
|
+
security: [{
|
|
20122
|
+
key: "BearerAuth",
|
|
20123
|
+
scheme: "bearer",
|
|
20124
|
+
type: "http"
|
|
20125
|
+
}, {
|
|
20126
|
+
key: "ApiKeyAuth",
|
|
20127
|
+
name: "X-API-Key",
|
|
20128
|
+
type: "apiKey"
|
|
20129
|
+
}],
|
|
20130
|
+
url: "/agent/v1/skills/{skill_id}/versions",
|
|
20131
|
+
...options
|
|
20132
|
+
});
|
|
20133
|
+
var skillsVersionsCreate = (options) => (options.client ?? client).post({
|
|
20134
|
+
...formDataBodySerializer,
|
|
20135
|
+
security: [{
|
|
20136
|
+
key: "BearerAuth",
|
|
20137
|
+
scheme: "bearer",
|
|
20138
|
+
type: "http"
|
|
20139
|
+
}, {
|
|
20140
|
+
key: "ApiKeyAuth",
|
|
20141
|
+
name: "X-API-Key",
|
|
20142
|
+
type: "apiKey"
|
|
20143
|
+
}],
|
|
20144
|
+
url: "/agent/v1/skills/{skill_id}/versions",
|
|
20145
|
+
...options,
|
|
20146
|
+
headers: {
|
|
20147
|
+
"Content-Type": null,
|
|
20148
|
+
...options.headers
|
|
20149
|
+
}
|
|
20150
|
+
});
|
|
20151
|
+
var skillsVersionsDelete = (options) => (options.client ?? client).delete({
|
|
20152
|
+
security: [{
|
|
20153
|
+
key: "BearerAuth",
|
|
20154
|
+
scheme: "bearer",
|
|
20155
|
+
type: "http"
|
|
20156
|
+
}, {
|
|
20157
|
+
key: "ApiKeyAuth",
|
|
20158
|
+
name: "X-API-Key",
|
|
20159
|
+
type: "apiKey"
|
|
20160
|
+
}],
|
|
20161
|
+
url: "/agent/v1/skills/{skill_id}/versions/{version}",
|
|
20162
|
+
...options
|
|
20163
|
+
});
|
|
20164
|
+
var skillsVersionsRetrieve = (options) => (options.client ?? client).get({
|
|
20165
|
+
security: [{
|
|
20166
|
+
key: "BearerAuth",
|
|
20167
|
+
scheme: "bearer",
|
|
20168
|
+
type: "http"
|
|
20169
|
+
}, {
|
|
20170
|
+
key: "ApiKeyAuth",
|
|
20171
|
+
name: "X-API-Key",
|
|
20172
|
+
type: "apiKey"
|
|
20173
|
+
}],
|
|
20174
|
+
url: "/agent/v1/skills/{skill_id}/versions/{version}",
|
|
20175
|
+
...options
|
|
20176
|
+
});
|
|
20177
|
+
var skillsVersionsDownload = (options) => (options.client ?? client).get({
|
|
20178
|
+
security: [{
|
|
20179
|
+
key: "BearerAuth",
|
|
20180
|
+
scheme: "bearer",
|
|
20181
|
+
type: "http"
|
|
20182
|
+
}, {
|
|
20183
|
+
key: "ApiKeyAuth",
|
|
20184
|
+
name: "X-API-Key",
|
|
20185
|
+
type: "apiKey"
|
|
20186
|
+
}],
|
|
20187
|
+
url: "/agent/v1/skills/{skill_id}/versions/{version}/content",
|
|
20188
|
+
...options
|
|
20189
|
+
});
|
|
19612
20190
|
var applicationGetSubdomain = (options) => (options?.client ?? client).get({
|
|
19613
20191
|
security: [{
|
|
19614
20192
|
key: "application-bearerAuth",
|
|
@@ -23120,6 +23698,20 @@ function createAgent(transport) {
|
|
|
23120
23698
|
agents: {
|
|
23121
23699
|
archive: bind(transport, agentsArchive),
|
|
23122
23700
|
create: bind(transport, agentsCreate),
|
|
23701
|
+
customers: {
|
|
23702
|
+
auth: {
|
|
23703
|
+
accessTokens: {
|
|
23704
|
+
create: bind(transport, createCustomerAccessToken),
|
|
23705
|
+
deleteCurrent: bind(transport, deleteCurrentCustomerAccessToken),
|
|
23706
|
+
renew: {
|
|
23707
|
+
create: bind(transport, renewCustomerAccessToken)
|
|
23708
|
+
}
|
|
23709
|
+
},
|
|
23710
|
+
grantCodes: {
|
|
23711
|
+
create: bind(transport, createCustomerGrantCode)
|
|
23712
|
+
}
|
|
23713
|
+
}
|
|
23714
|
+
},
|
|
23123
23715
|
endUsers: {
|
|
23124
23716
|
block: {
|
|
23125
23717
|
create: bind(transport, blockEndUser)
|
|
@@ -23142,6 +23734,7 @@ function createAgent(transport) {
|
|
|
23142
23734
|
},
|
|
23143
23735
|
update: bind(transport, agentsUpdate),
|
|
23144
23736
|
versions: {
|
|
23737
|
+
apply: bind(transport, applyAgentVersion),
|
|
23145
23738
|
list: bind(transport, agentsVersionsList)
|
|
23146
23739
|
}
|
|
23147
23740
|
},
|
|
@@ -23254,6 +23847,19 @@ function createAgent(transport) {
|
|
|
23254
23847
|
},
|
|
23255
23848
|
update: bind(transport, sessionsUpdate)
|
|
23256
23849
|
},
|
|
23850
|
+
skills: {
|
|
23851
|
+
create: bind(transport, (options) => skillsCreate({ ...options, bodySerializer: multipartBodySerializer, headers: { "Content-Type": null, ...options.headers } })),
|
|
23852
|
+
delete: bind(transport, skillsDelete),
|
|
23853
|
+
list: bind(transport, skillsList),
|
|
23854
|
+
retrieve: bind(transport, skillsRetrieve),
|
|
23855
|
+
versions: {
|
|
23856
|
+
create: bind(transport, (options) => skillsVersionsCreate({ ...options, bodySerializer: multipartBodySerializer, headers: { "Content-Type": null, ...options.headers } })),
|
|
23857
|
+
delete: bind(transport, skillsVersionsDelete),
|
|
23858
|
+
list: bind(transport, skillsVersionsList),
|
|
23859
|
+
retrieve: bind(transport, skillsVersionsRetrieve),
|
|
23860
|
+
retrieveContent: bind(transport, skillsVersionsDownload)
|
|
23861
|
+
}
|
|
23862
|
+
},
|
|
23257
23863
|
toolsets: {
|
|
23258
23864
|
list: bind(transport, listToolsets)
|
|
23259
23865
|
}
|
|
@@ -25950,7 +26556,7 @@ function startProgress(ctx, write = (text) => writeOutput({ stderr: text })) {
|
|
|
25950
26556
|
}
|
|
25951
26557
|
|
|
25952
26558
|
// src/main.ts
|
|
25953
|
-
var version = "0.1.0-dev.
|
|
26559
|
+
var version = "0.1.0-dev.7ec6f84";
|
|
25954
26560
|
var commands = commandTree(operations);
|
|
25955
26561
|
var manual = [["login"], ["logout"], ["whoami"], ["org", "list"], ["org", "switch"], ["api"], ["skill"]];
|
|
25956
26562
|
function route(argv) {
|