@deepraxis/sdk 0.1.1-dev.98b62a1 → 0.1.1-dev.9932035

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.
@@ -3,7 +3,7 @@ export const operations = [
3
3
  "resource": "agent.agents",
4
4
  "method": "list",
5
5
  "summary": "List agents",
6
- "description": "List the agents of the workspace behind your API key, newest first, in pages of at most 100 (default 20). Use it to find an agent id before creating a session; to read one agent use agents.retrieve, to see its history use agents.versions.list. Archived agents are hidden unless include_archived is true. Filter kind=general or kind=personal for durable-computer agents, kind=service for per-session environments, or kind=assume for external MCP clients. Pass next_page from the response as page to read the next page; a null next_page means the end.",
6
+ "description": "List the agents of the workspace behind your API key, newest first, in pages of at most 100 (default 20). Use it to find an agent id before creating a session; to read one agent use agents.retrieve, to see its history use agents.versions.list. Archived agents are hidden unless include_archived is true. Filter kind=general for durable-computer agents, kind=service for per-session environments, or kind=assume for external MCP clients. Pass next_page from the response as page to read the next page; a null next_page means the end.",
7
7
  "http": "GET",
8
8
  "path": "/agent/v1/agents",
9
9
  "streaming": "no",
@@ -49,7 +49,6 @@ export const operations = [
49
49
  "type": "string",
50
50
  "enum": [
51
51
  "general",
52
- "personal",
53
52
  "service",
54
53
  "assume"
55
54
  ],
@@ -134,19 +133,18 @@ export const operations = [
134
133
  "type": "array",
135
134
  "itemType": "object",
136
135
  "required": false,
137
- "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; general and 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 one service, or one sub-tree of one, and carries only enabled: search, browser, ticket, crm, canvas, cut, studio, feedback or workspace. workspace opens development units — list one, read one, start, stop, exec inside one, fetch, push, connect, and open a unit for a change — and opens neither publishing nor any production operation. The ticket service is bound by default: a service agent whose list has no ticket entry may call the ticket API, and {\"type\": \"ticket\", \"enabled\": false} removes it. Every other service stays closed until it is bound. An open service allows every public method of that service. At most 20 bindings per type, no repeated type and id, and each service type at most once. A session is authorized by the agent version it runs: newly added bindings apply only to new sessions, and a version saved with apply=false changes no access until it is applied. Applying a version that disables, removes or downgrades a binding revokes it immediately in running sessions on older versions. A resource that is not bound returns 404, a service that is not opened returns 403, and a write to a resource bound read_only returns 403 BINDING_READ_ONLY. Unknown types, fields on the wrong kind (id, access or instructions on a service binding), wrong access and malformed ids return 400. The former databases, vector_stores and files fields are removed and return 400. Omit on create for the default: the ticket service only. Saving checks added or changed database, vector_store, media_library and file bindings in the organization: unknown or deleted ids return 400. If an owner is unavailable or takes more than 3 seconds, saving succeeds with verified=false for the affected bindings. Unchanged bindings keep their previous verification result and are not rechecked. workflow and script ids are not verified at save time."
136
+ "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; general agents return 400. There are two kinds. A resource binding names one resource with id and access: database (id db_..., read_only or read_write), vector_store (id vs_..., read_only or read_write), file (id file- plus 24 letters or digits, as the File API returns it; read_only), media_library (any id without ':' or whitespace, read_only or read_write), model (a model catalog id, invoke), workflow and script (id <namespace>/<name>, invoke). A service binding opens one service, or one sub-tree of one, and carries only enabled: search, browser, ticket, crm, canvas, cut, studio, feedback or workspace. workspace opens development units — list one, read one, start, stop, exec inside one, fetch, push, connect, and open a unit for a change — and opens neither publishing nor any production operation. The ticket service is bound by default: a service agent whose list has no ticket entry may call the ticket API, and {\"type\": \"ticket\", \"enabled\": false} removes it. Every other service stays closed until it is bound. An open service allows every public method of that service. At most 20 bindings per type, no repeated type and id, and each service type at most once. A session is authorized by the agent version it runs: newly added bindings apply only to new sessions, and a version saved with apply=false changes no access until it is applied. Applying a version that disables, removes or downgrades a binding revokes it immediately in running sessions on older versions. A resource that is not bound returns 404, a service that is not opened returns 403, and a write to a resource bound read_only returns 403 BINDING_READ_ONLY. Unknown types, fields on the wrong kind (id, access or instructions on a service binding), wrong access and malformed ids return 400. The former databases, vector_stores and files fields are removed and return 400. Omit on create for the default: the ticket service only. Saving checks added or changed database, vector_store, media_library and file bindings in the organization: unknown or deleted ids return 400. If an owner is unavailable or takes more than 3 seconds, saving succeeds with verified=false for the affected bindings. Unchanged bindings keep their previous verification result and are not rechecked. workflow and script ids are not verified at save time."
138
137
  },
139
138
  {
140
139
  "name": "kind",
141
140
  "type": "string",
142
141
  "enum": [
143
142
  "general",
144
- "personal",
145
143
  "service",
146
144
  "assume"
147
145
  ],
148
146
  "required": false,
149
- "description": "Immutable agent kind. general and personal require computer_id; service cannot bind a computer. Omit on create to infer from computer_id (general with a computer, service without). On update, the same kind is ignored; changing kind or crossing its computer binding returns 400 invalid_request_error. Assume agents use a durable computer driven over MCP without a conversation model; model, models, subagent_model, subagents and multiagent are forbidden and omitted."
147
+ "description": "Immutable agent kind. general requires computer_id; service cannot bind a computer. Omit on create to infer from computer_id (general with a computer, service without). On update, the same kind is ignored; changing kind or crossing its computer binding returns 400 invalid_request_error. Assume agents use a durable computer driven over MCP without a conversation model; model, models, subagent_model, subagents and multiagent are forbidden and omitted."
150
148
  },
151
149
  {
152
150
  "name": "computer_id",
@@ -196,7 +194,7 @@ export const operations = [
196
194
  "name": "avatar",
197
195
  "type": "string",
198
196
  "required": false,
199
- "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. General, personal and service agents accept it. /agent/v1 only; /anthropic neither accepts nor returns it."
197
+ "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. General and service agents accept it. /agent/v1 only; /anthropic neither accepts nor returns it."
200
198
  },
201
199
  {
202
200
  "name": "environment_id",
@@ -364,12 +362,11 @@ export const operations = [
364
362
  "type": "string",
365
363
  "enum": [
366
364
  "general",
367
- "personal",
368
365
  "service",
369
366
  "assume"
370
367
  ],
371
368
  "required": false,
372
- "description": "Immutable agent kind. general and personal require computer_id; service cannot bind a computer. Omit on create to infer from computer_id (general with a computer, service without). On update, the same kind is ignored; changing kind or crossing its computer binding returns 400 invalid_request_error. Assume agents use a durable computer driven over MCP without a conversation model; model, models, subagent_model, subagents and multiagent are forbidden and omitted."
369
+ "description": "Immutable agent kind. general requires computer_id; service cannot bind a computer. Omit on create to infer from computer_id (general with a computer, service without). On update, the same kind is ignored; changing kind or crossing its computer binding returns 400 invalid_request_error. Assume agents use a durable computer driven over MCP without a conversation model; model, models, subagent_model, subagents and multiagent are forbidden and omitted."
373
370
  },
374
371
  {
375
372
  "name": "computer_id",
@@ -419,7 +416,7 @@ export const operations = [
419
416
  "name": "avatar",
420
417
  "type": "string",
421
418
  "required": false,
422
- "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. General, personal and service agents accept it. /agent/v1 only; /anthropic neither accepts nor returns it."
419
+ "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. General and service agents accept it. /agent/v1 only; /anthropic neither accepts nor returns it."
423
420
  },
424
421
  {
425
422
  "name": "environment_id",
@@ -919,7 +916,7 @@ export const operations = [
919
916
  "resource": "agent.agents.events",
920
917
  "method": "list",
921
918
  "summary": "Read your conversation with an agent",
922
- "description": "Read your conversation with a personal or general agent: the events of your own main session with that agent, the same page sessions.events.list returns — same query parameters, same data + next_page envelope, same event shapes. {agent_id} takes the agent_… id, the eight character identity number or the handle; a service or assume agent answers 400. Use it to collect a reply, to find tool calls waiting for approval, or to learn the real session id without ever asking for one.",
919
+ "description": "Read your conversation with a general agent: the events of your own main session with that agent, the same page sessions.events.list returns — same query parameters, same data + next_page envelope, same event shapes. {agent_id} takes the agent_… id, the eight character identity number or the handle; a service or assume agent answers 400. Use it to collect a reply, to find tool calls waiting for approval, or to learn the real session id without ever asking for one.",
923
920
  "http": "GET",
924
921
  "path": "/agent/v1/agents/{agent_id}/events",
925
922
  "streaming": "no",
@@ -991,7 +988,7 @@ export const operations = [
991
988
  "resource": "agent.agents.events",
992
989
  "method": "send",
993
990
  "summary": "Send events to an agent",
994
- "description": "Talk to a personal or general agent: the message goes to your own main session with that agent — one entry per person, created on first use and the same every time after — so no session id is needed. This is sessions.events.send addressed by the agent instead of the session: the same body (user.message with exactly one nonempty text block, user.interrupt, user.tool_confirmation, user.custom_tool_result, user.steer, user.withdraw), the same acknowledgement and the same billing. {agent_id} takes the agent_… id, the eight character identity number or the handle. A service or assume agent answers 400 — it has no main session: reach a service agent over A2A, or open a session explicitly with sessions.create. Read the reply with agents.events.list, or follow it while it is produced with agents.events.stream. Example: POST /agent/v1/agents/agent_example/events with {\"events\":[{\"type\":\"user.message\",\"content\":[{\"type\":\"text\",\"text\":\"你好\"}]}]}.",
991
+ "description": "Talk to a general agent: the message goes to your own main session with that agent — one entry per person, created on first use and the same every time after — so no session id is needed. This is sessions.events.send addressed by the agent instead of the session: the same body (user.message with exactly one nonempty text block, user.interrupt, user.tool_confirmation, user.custom_tool_result, user.steer, user.withdraw), the same acknowledgement and the same billing. {agent_id} takes the agent_… id, the eight character identity number or the handle. A service or assume agent answers 400 — it has no main session: reach a service agent over A2A, or open a session explicitly with sessions.create. Read the reply with agents.events.list, or follow it while it is produced with agents.events.stream. Example: POST /agent/v1/agents/agent_example/events with {\"events\":[{\"type\":\"user.message\",\"content\":[{\"type\":\"text\",\"text\":\"你好\"}]}]}.",
995
992
  "http": "POST",
996
993
  "path": "/agent/v1/agents/{agent_id}/events",
997
994
  "streaming": "no",
@@ -1021,7 +1018,7 @@ export const operations = [
1021
1018
  "resource": "agent.agents.events",
1022
1019
  "method": "stream",
1023
1020
  "summary": "Follow an agent live",
1024
- "description": "Follow an agent live over Server-Sent Events. For a personal or general agent it is the stream of your own main session with that agent, the same stream sessions.events.stream opens, event_deltas[] previews included; read past events with agents.events.list. An assume agent has no main session: its body is its MCP connections, and this stream is its broadcast point, which every live connection of the agent hears at once. It carries two events, each with an SSE id: inbox.letter_delivered { letter_id, sender, sender_name, summary, thread, create_time } when a letter arrives (the letter stays unread; take it with the agent's inbox tool, the body is not in the event), and cognition.ritual_held { ritual, owner, title, engram, create_time } when a domain gives the agent a memory. Reconnect with the Last-Event-ID header to receive what you missed from a short recent buffer (about an hour); a first connection replays nothing, so read agents.inbox.letters.list for mail already waiting. {agent_id} takes the agent_… id, the eight character identity number or the handle; a service agent answers 400. Closing the stream only drops your subscription and does not stop the agent.",
1021
+ "description": "Follow an agent live over Server-Sent Events. For a general agent it is the stream of your own main session with that agent, the same stream sessions.events.stream opens, event_deltas[] previews included; read past events with agents.events.list. An assume agent has no main session: its body is its MCP connections, and this stream is its broadcast point, which every live connection of the agent hears at once. It carries two events, each with an SSE id: inbox.letter_delivered { letter_id, sender, sender_name, summary, thread, create_time } when a letter arrives (the letter stays unread; take it with the agent's inbox tool, the body is not in the event), and cognition.ritual_held { ritual, owner, title, engram, create_time } when a domain gives the agent a memory. Reconnect with the Last-Event-ID header to receive what you missed from a short recent buffer (about an hour); a first connection replays nothing, so read agents.inbox.letters.list for mail already waiting. {agent_id} takes the agent_… id, the eight character identity number or the handle; a service agent answers 400. Closing the stream only drops your subscription and does not stop the agent.",
1025
1022
  "http": "GET",
1026
1023
  "path": "/agent/v1/agents/{agent_id}/events/stream",
1027
1024
  "streaming": "always",
@@ -1183,7 +1180,7 @@ export const operations = [
1183
1180
  "resource": "agent.computers",
1184
1181
  "method": "create",
1185
1182
  "summary": "Create Computer",
1186
- "description": "Create a durable computer: a named machine whose files outlive sessions, for general and 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.",
1183
+ "description": "Create a durable computer: a named machine whose files outlive sessions, for general 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.",
1187
1184
  "http": "POST",
1188
1185
  "path": "/agent/v1/computers",
1189
1186
  "streaming": "no",
@@ -1634,7 +1631,7 @@ export const operations = [
1634
1631
  "resource": "agent.deployments",
1635
1632
  "method": "create",
1636
1633
  "summary": "Create deployment",
1637
- "description": "Freeze session parameters as a deployment; this operation does not open a session. Pass an agent id or versioned reference, a name, 1–50 user.message initial events and an environment_id from environments.list. Unlike Anthropic Managed Agents, /agent/v1 also accepts agent_with_overrides (model, permission_mode and cwd) and target=computer for general and personal agents, with environment_id omitted. Cron schedules use five POSIX fields and an IANA timezone. File resources are accepted. Supports vault_ids, up to 50, owned by the current organization and not archived; credential injection is deferred to a later version. Active schedules run every minute when due; session creation errors pause the deployment. Unsupported tools, mcp_servers, system and skills overrides return 400.",
1634
+ "description": "Freeze session parameters as a deployment; this operation does not open a session. Pass an agent id or versioned reference, a name, 1–50 user.message initial events and an environment_id from environments.list. Unlike Anthropic Managed Agents, /agent/v1 also accepts agent_with_overrides (model, permission_mode and cwd) and target=computer for general agents, with environment_id omitted. Cron schedules use five POSIX fields and an IANA timezone. File resources are accepted. Supports vault_ids, up to 50, owned by the current organization and not archived; credential injection is deferred to a later version. Active schedules run every minute when due; session creation errors pause the deployment. Unsupported tools, mcp_servers, system and skills overrides return 400.",
1638
1635
  "http": "POST",
1639
1636
  "path": "/agent/v1/deployments",
1640
1637
  "streaming": "no",
@@ -1711,7 +1708,7 @@ export const operations = [
1711
1708
  "name": "target",
1712
1709
  "type": "object",
1713
1710
  "required": false,
1714
- "description": "Execution target. environment (default) requires an existing, unarchived environment_id. computer is available only for general and personal agents and permits environment_id to be omitted."
1711
+ "description": "Execution target. environment (default) requires an existing, unarchived environment_id. computer is available only for general agents and permits environment_id to be omitted."
1715
1712
  }
1716
1713
  ]
1717
1714
  }
@@ -1821,7 +1818,7 @@ export const operations = [
1821
1818
  "name": "target",
1822
1819
  "type": "object",
1823
1820
  "required": false,
1824
- "description": "Execution target. environment (default) requires an existing, unarchived environment_id. computer is available only for general and personal agents and permits environment_id to be omitted."
1821
+ "description": "Execution target. environment (default) requires an existing, unarchived environment_id. computer is available only for general agents and permits environment_id to be omitted."
1825
1822
  }
1826
1823
  ]
1827
1824
  }
@@ -2621,7 +2618,7 @@ export const operations = [
2621
2618
  "resource": "agent.sessions.events",
2622
2619
  "method": "list",
2623
2620
  "summary": "List session events",
2624
- "description": "Read the event history of a session as a page of events, oldest first by default (order=desc for newest first). Use it after sending a message to collect the reply, to find tool calls that wait for approval or client custom tool results (session.status_idle with stop_reason requires_action lists their event_ids; a request nobody answered within 24 hours is settled as unanswered and the session goes idle with stop_reason request_expired, which the /anthropic/v1 face shows as end_turn), or to audit a run; to follow a running session live use sessions.events.stream instead. Filter by types and by a created_at range on processed_at; pages hold at most 100 events (default 20) and next_page continues. A failed run emits session.error before session.status_terminated. Native history also includes user.steer, user.withdraw, system.notification, system.notification_suppressed (pending background notifications that hit the wake quota and started no run), system.notification_recorded, session.forked, session.goal_changed and session.goal_verification; these are not accepted by the /anthropic/v1 event-type filter. This operation addresses one session — normally a worker session an agent dispatched; to talk to a personal or general agent itself, use agents.events.list instead. In the path, session_id may also be `main` (your own main session with that agent) or a short session name, and either alias then requires agent_id with the agent_… id, the eight character identity number or the handle; only the own face /agent/v1 accepts an alias, /anthropic/v1 requires a real sesn_… id.",
2621
+ "description": "Read the event history of a session as a page of events, oldest first by default (order=desc for newest first). Use it after sending a message to collect the reply, to find tool calls that wait for approval or client custom tool results (session.status_idle with stop_reason requires_action lists their event_ids; a request nobody answered within 24 hours is settled as unanswered and the session goes idle with stop_reason request_expired, which the /anthropic/v1 face shows as end_turn), or to audit a run; to follow a running session live use sessions.events.stream instead. Filter by types and by a created_at range on processed_at; pages hold at most 100 events (default 20) and next_page continues. A failed run emits session.error before session.status_terminated. Native history also includes user.steer, user.withdraw, system.notification, system.notification_suppressed (pending background notifications that hit the wake quota and started no run), system.notification_recorded, session.forked, session.goal_changed and session.goal_verification; these are not accepted by the /anthropic/v1 event-type filter. This operation addresses one session — normally a worker session an agent dispatched; to talk to a general agent itself, use agents.events.list instead. In the path, session_id may also be `main` (your own main session with that agent) or a short session name, and either alias then requires agent_id with the agent_… id, the eight character identity number or the handle; only the own face /agent/v1 accepts an alias, /anthropic/v1 requires a real sesn_… id.",
2625
2622
  "http": "GET",
2626
2623
  "path": "/agent/v1/sessions/{session_id}/events",
2627
2624
  "streaming": "no",
@@ -2693,7 +2690,7 @@ export const operations = [
2693
2690
  "resource": "agent.sessions.events",
2694
2691
  "method": "send",
2695
2692
  "summary": "Send session events",
2696
- "description": "Attach optional praxis_context={items:[{name,value}]} to user.message for untrusted page context on this turn only (maximum 32 items, 4096 UTF-8 JSON bytes). /anthropic/v1 rejects this field. Send events to a session: user.message (exactly one nonempty text block), user.interrupt, user.tool_confirmation to allow or deny a pending tool call, user.custom_tool_result to return a custom tool result, user.steer to inject a queued user.message into a turn that is still running, and user.withdraw to retract a queued message. The response only acknowledges the inputs; read replies with sessions.events.list or sessions.events.stream. A message sent while the session waits for tool approval is queued (processed_at null) and runs in order after the approval is resolved. Archived sessions reject new messages. To approve, read a pending agent.tool_use or agent.mcp_tool_use event and send {type: \"user.tool_confirmation\", tool_use_id: <that event id>, result: \"allow\"} (or deny); include session_thread_id for a child approval. Native confirmations also accept updated_permissions, answers and annotations, which /anthropic/v1 rejects. Both faces accept user.custom_tool_result with custom_tool_use_id from agent.custom_tool_use.id or the requires_action stop_reason.event_ids. Unlike Anthropic, result content accepts only text blocks (omit it for an empty array). Omitted or null is_error means false. The server routes child calls by id; session_thread_id is rejected in this input. Unknown call ids return 400; duplicate results or calls no longer waiting return 409. This operation addresses one session — normally a worker session an agent dispatched; to talk to a personal or general agent itself, use agents.events.send instead. In the path, session_id may also be `main` (your own main session with the agent) or a short session name, and either alias then requires agent_id with the agent_… id, the eight character identity number or the handle; only the own face /agent/v1 accepts an alias, /anthropic/v1 requires a real sesn_… id.",
2693
+ "description": "Attach optional praxis_context={items:[{name,value}]} to user.message for untrusted page context on this turn only (maximum 32 items, 4096 UTF-8 JSON bytes). /anthropic/v1 rejects this field. Send events to a session: user.message (exactly one nonempty text block), user.interrupt, user.tool_confirmation to allow or deny a pending tool call, user.custom_tool_result to return a custom tool result, user.steer to inject a queued user.message into a turn that is still running, and user.withdraw to retract a queued message. The response only acknowledges the inputs; read replies with sessions.events.list or sessions.events.stream. A message sent while the session waits for tool approval is queued (processed_at null) and runs in order after the approval is resolved. Archived sessions reject new messages. To approve, read a pending agent.tool_use or agent.mcp_tool_use event and send {type: \"user.tool_confirmation\", tool_use_id: <that event id>, result: \"allow\"} (or deny); include session_thread_id for a child approval. Native confirmations also accept updated_permissions, answers and annotations, which /anthropic/v1 rejects. Both faces accept user.custom_tool_result with custom_tool_use_id from agent.custom_tool_use.id or the requires_action stop_reason.event_ids. Unlike Anthropic, result content accepts only text blocks (omit it for an empty array). Omitted or null is_error means false. The server routes child calls by id; session_thread_id is rejected in this input. Unknown call ids return 400; duplicate results or calls no longer waiting return 409. This operation addresses one session — normally a worker session an agent dispatched; to talk to a general agent itself, use agents.events.send instead. In the path, session_id may also be `main` (your own main session with the agent) or a short session name, and either alias then requires agent_id with the agent_… id, the eight character identity number or the handle; only the own face /agent/v1 accepts an alias, /anthropic/v1 requires a real sesn_… id.",
2697
2694
  "http": "POST",
2698
2695
  "path": "/agent/v1/sessions/{session_id}/events",
2699
2696
  "streaming": "no",
@@ -2723,7 +2720,7 @@ export const operations = [
2723
2720
  "resource": "agent.sessions.events",
2724
2721
  "method": "stream",
2725
2722
  "summary": "Stream session events",
2726
- "description": "Open a Server-Sent Events stream of a session's events in real time. Use it to show a reply as it is produced; to read past events use sessions.events.list. Send a message through sessions.events.send in another request while the stream is open. Closing the stream only drops your subscription and does not stop the agent. Pass event_deltas[]=agent.message, agent.thinking or agent.tool_use to also receive event_start / event_delta previews before the final event. This operation addresses one session — normally a worker session an agent dispatched; to follow a personal or general agent itself, use agents.events.stream instead. In the path, session_id may also be `main` (your own main session with the agent) or a short session name, and either alias then requires agent_id with the agent_… id, the eight character identity number or the handle; only the own face /agent/v1 accepts an alias, /anthropic/v1 requires a real sesn_… id.",
2723
+ "description": "Open a Server-Sent Events stream of a session's events in real time. Use it to show a reply as it is produced; to read past events use sessions.events.list. Send a message through sessions.events.send in another request while the stream is open. Closing the stream only drops your subscription and does not stop the agent. Pass event_deltas[]=agent.message, agent.thinking or agent.tool_use to also receive event_start / event_delta previews before the final event. This operation addresses one session — normally a worker session an agent dispatched; to follow a general agent itself, use agents.events.stream instead. In the path, session_id may also be `main` (your own main session with the agent) or a short session name, and either alias then requires agent_id with the agent_… id, the eight character identity number or the handle; only the own face /agent/v1 accepts an alias, /anthropic/v1 requires a real sesn_… id.",
2727
2724
  "http": "GET",
2728
2725
  "path": "/agent/v1/sessions/{session_id}/events/stream",
2729
2726
  "streaming": "always",
@@ -15450,7 +15447,7 @@ export const operations = [
15450
15447
  "resource": "file.uploads",
15451
15448
  "method": "createSigned",
15452
15449
  "summary": "Create a one-time upload URL",
15453
- "description": "Upload a local file of up to 20 GiB from a coding agent without sending bytes through the model. Provide filename (the stored basename), exact byte count and MIME type. Up to 104857600 bytes, PUT the file to url with curl -T photo.png -H 'Content-Type: image/png' '<url>'; success returns 201 with the file object, and reuse returns 410 CAPABILITY_USED. Above that threshold, split the file into part_size chunks (default 64000000 bytes) and PUT each chunk to its numbered parts[].url in any order; an interrupted client GETs status_url to see the received parts and resends only what is missing, then POSTs complete_url without a body. Part PUTs return 200; completion returns 201 with the file object, including its state, or 400 if a part is missing. A processing file can be polled with files.retrieve until active. Identical part bytes may be retried; changed bytes at the same number return 400. Completion reuse returns 410 CAPABILITY_USED. Each PUT requires the exact signed Content-Length; single-PUT Content-Type must match content_type or be omitted. Expired, revoked, invalid, wrong-action or cross-organization URLs return 404. URL lifetime defaults to 900 seconds for single PUT or 604800 (7 days) for multipart, at most 604800; all multipart URLs, including status_url, share an expiry. Multipart creation reserves storage quota. Issuance requires the same unscoped credential as direct file creation. Each issuance creates a new upload and is not idempotent. Example body: {\"filename\":\"photo.png\",\"bytes\":2048,\"content_type\":\"image/png\"}.",
15450
+ "description": "Upload a local file of up to 20 GiB from a coding agent without sending bytes through the model. Provide filename (the stored basename), exact byte count and MIME type. Up to 104857600 bytes, PUT the file to url with curl -T photo.png -H 'Content-Type: image/png' '<url>'; success returns 201 with the file object, and reuse returns 410 CAPABILITY_USED. Above that threshold, split the file into part_size chunks (default 64000000 bytes) and PUT each chunk to its numbered parts[].url in any order; an interrupted client GETs status_url to see the received parts and resends only what is missing, then POSTs complete_url without a body. Part PUTs return 200; completion returns 201 with the file object, including its state, or 400 if a part is missing. A processing file can be polled with files.retrieve until active. Identical part bytes may be retried; changed bytes at the same number return 400. Completion reuse returns 410 CAPABILITY_USED. Each PUT requires the exact signed Content-Length; single-PUT Content-Type must match content_type or be omitted. Expired, revoked, invalid or cross-organization URLs return 404, and so does a link whose upload record no longer exists. A URL that is authentic but names another action returns 403 CAPABILITY_MISMATCH: a status link posted to complete_url answers it, and so does a completion link fetched as status_url. URL lifetime defaults to 900 seconds for single PUT or 604800 (7 days) for multipart, at most 604800; all multipart URLs, including status_url, share an expiry. Multipart creation reserves storage quota. Issuance requires the same unscoped credential as direct file creation. Each issuance creates a new upload and is not idempotent. Example body: {\"filename\":\"photo.png\",\"bytes\":2048,\"content_type\":\"image/png\"}.",
15454
15451
  "http": "POST",
15455
15452
  "path": "/file/v1/uploads/signed",
15456
15453
  "streaming": "no",
@@ -17174,6 +17171,69 @@ export const operations = [
17174
17171
  ]
17175
17172
  }
17176
17173
  },
17174
+ {
17175
+ "resource": "media.libraries.assets.hls",
17176
+ "method": "list",
17177
+ "summary": "Get HLS renditions",
17178
+ "description": "Read how ready a video asset’s on-demand ladder is, rung by rung, without building anything. Use library_id and asset_id as everywhere else. The answer names the asset, its current version, the asset’s own facts (resource_type, is_audio and duration) and one entry per recorded rung — name, height, the first indexed piece’s width, the rung’s bitrate and stored bytes, and its state (processing while pieces run, ready when every piece is ready, failed when a piece gave up). A ladder that was never requested, and an asset that is not a video, answer an empty renditions rather than an error. This read mints no capability and signs nothing, so play the ladder through the content service, which issues the short-lived play address for the current version. Example: GET /media/v1/libraries/lib_example/assets/9dfa312ef9bc4b00816339b598b1152c/hls.",
17179
+ "http": "GET",
17180
+ "path": "/media/v1/libraries/{library_id}/assets/{asset_id}/hls",
17181
+ "streaming": "no",
17182
+ "pagination": false,
17183
+ "pathParams": [
17184
+ {
17185
+ "name": "library_id",
17186
+ "sdkName": "library_id",
17187
+ "description": "Library ID returned by creation."
17188
+ },
17189
+ {
17190
+ "name": "asset_id",
17191
+ "sdkName": "asset_id",
17192
+ "description": "32-character asset ID."
17193
+ }
17194
+ ],
17195
+ "query": []
17196
+ },
17197
+ {
17198
+ "resource": "media.libraries.assets.hls",
17199
+ "method": "create",
17200
+ "summary": "Request HLS renditions",
17201
+ "description": "Build a video asset’s adaptive HLS ladder for its current version, so one asset plays at several clarities on an ordinary player. Use library_id from creation or listing and the asset_id of a video asset; the ladder belongs to the version the asset has now, and a later version gets its own. heights names the rungs to build: a non-empty subset of 480, 720 and 1080 with no repeats, or omitted to build all three. The ladder never upscales — a rung above the source’s short side is dropped, and a list entirely above it keeps its lowest rung. The call is asynchronous and starts paid transcoding: the work runs as the video-transcode-hls model, one piece per rung per ten minutes of source, and it is charged per output minute at that model’s published price to the organization that owns the asset (ADR-146 §5) — a rung the source cannot carry, and a failed rung, are not charged. A source longer than eight hours (28800 seconds) is refused with SOURCE_TOO_LONG before anything is planned. Repeating the call is safe: a rung already processing, ready or failed is left as it is and is never encoded twice. The response is 202 with the asset_id, its current version and one entry per rung — name, height, width, bitrate, bytes and state, where processing means the rung is still being encoded, ready means it plays and failed means it gave up and can be retried by asking again. Poll GET /media/v1/libraries/{library_id}/assets/{asset_id}/hls until every rung is ready, then play the ladder through the content service, which mints the short-lived play address. Example: POST /media/v1/libraries/lib_example/assets/9dfa312ef9bc4b00816339b598b1152c/hls with {\"heights\":[480,720,1080]}.",
17202
+ "http": "POST",
17203
+ "path": "/media/v1/libraries/{library_id}/assets/{asset_id}/hls",
17204
+ "streaming": "no",
17205
+ "pagination": false,
17206
+ "pathParams": [
17207
+ {
17208
+ "name": "library_id",
17209
+ "sdkName": "library_id",
17210
+ "description": "Library ID returned by creation."
17211
+ },
17212
+ {
17213
+ "name": "asset_id",
17214
+ "sdkName": "asset_id",
17215
+ "description": "32-character asset ID."
17216
+ }
17217
+ ],
17218
+ "query": [],
17219
+ "body": {
17220
+ "required": true,
17221
+ "fields": [
17222
+ {
17223
+ "name": "heights",
17224
+ "type": "array",
17225
+ "itemType": "integer",
17226
+ "enum": [
17227
+ 480,
17228
+ 720,
17229
+ 1080
17230
+ ],
17231
+ "required": false,
17232
+ "description": "The clarity rungs to build: a non-empty subset of 480, 720 and 1080 with no repeats. Omitted or empty builds all three. The ladder never upscales, so a rung above the source’s short side is dropped."
17233
+ }
17234
+ ]
17235
+ }
17236
+ },
17177
17237
  {
17178
17238
  "resource": "media.assets",
17179
17239
  "method": "lineage",
@@ -23459,6 +23519,570 @@ export const operations = [
23459
23519
  }
23460
23520
  ]
23461
23521
  },
23522
+ {
23523
+ "resource": "registry.installations",
23524
+ "method": "delete",
23525
+ "summary": "Remove an installation",
23526
+ "description": "把包从目标上卸下来,并删掉这条安装记录:技能从智能体的技能列表里移除,插件从电脑上卸载。目标那边已经没有它时也算完成。包本身和它的版本不受影响,之后可以重新安装。记录删除后重发会 404,所以删除前先用 installations.list 确认。",
23527
+ "http": "DELETE",
23528
+ "path": "/registry/v1/installations/{installation_id}",
23529
+ "streaming": "no",
23530
+ "pagination": false,
23531
+ "pathParams": [
23532
+ {
23533
+ "name": "installation_id",
23534
+ "sdkName": "installation_id",
23535
+ "description": "安装记录的标识,来自 packages.installations.list 或 packages.installations.create 返回的 id(ins_ 开头);不要传包或目标的 id。"
23536
+ }
23537
+ ],
23538
+ "query": []
23539
+ },
23540
+ {
23541
+ "resource": "registry.installations",
23542
+ "method": "update",
23543
+ "summary": "Update an installation",
23544
+ "description": "把一条安装记录换到另一个版本。技能可以换到任何未撤回的版本(升级或回退),version 省略时换到最新版;插件只能换到库里的最新版本,version 给了也必须等于最新版。撤回的版本不能换过去。对账为 missing 的记录用它可以重新装回去。同名冲突和 20 个技能上限的规则与安装时相同。",
23545
+ "http": "POST",
23546
+ "path": "/registry/v1/installations/{installation_id}:update",
23547
+ "streaming": "no",
23548
+ "pagination": false,
23549
+ "pathParams": [
23550
+ {
23551
+ "name": "installation_id",
23552
+ "sdkName": "installation_id",
23553
+ "description": "安装记录的标识,来自 packages.installations.list 或 packages.installations.create 返回的 id(ins_ 开头);不要传包或目标的 id。"
23554
+ }
23555
+ ],
23556
+ "query": [],
23557
+ "body": {
23558
+ "required": true,
23559
+ "fields": [
23560
+ {
23561
+ "name": "version",
23562
+ "type": "string",
23563
+ "required": false,
23564
+ "description": "要换到的版本号,完整 semver;省略时换到最新版;插件给了也必须等于最新版,撤回的版本不能换。"
23565
+ }
23566
+ ]
23567
+ }
23568
+ },
23569
+ {
23570
+ "resource": "registry.packages",
23571
+ "method": "retrieve",
23572
+ "summary": "Retrieve package",
23573
+ "description": "读一个包的元数据:种类、所属库、当前 latest_version、作者、标签和累计下载量。package_id 来自 packages.list 或 packages.create;另一个组织或不存在都返回 404。",
23574
+ "http": "GET",
23575
+ "path": "/registry/v1/packages/{package_id}",
23576
+ "streaming": "no",
23577
+ "pagination": false,
23578
+ "pathParams": [
23579
+ {
23580
+ "name": "package_id",
23581
+ "sdkName": "package_id",
23582
+ "description": "包的标识,来自 repositories.packages.list 或 repositories.packages.create 返回的 id;不要传包名。"
23583
+ }
23584
+ ],
23585
+ "query": []
23586
+ },
23587
+ {
23588
+ "resource": "registry.packages.installations",
23589
+ "method": "list",
23590
+ "summary": "List installations",
23591
+ "description": "列出这个包装在哪些智能体和电脑上。每次读取都会和目标那边对账,以目标现在的实际情况为准,所以每条记录的 state 是读取这一刻的结论:installed 表示目标上有它且版本与记录一致;drifted 表示目标上有它但版本不同,此时 version 显示目标上的版本;missing 表示目标上已经没有它(被人在智能体或电脑那边删掉了),记录仍保留,可以用 installations.delete 清掉,或用 installations.update 重新装回;unknown 表示这次问不到目标,不代表没装,稍后重读。withdrawn 表示这条记录的版本已被撤回。一次返回全部记录,没有分页,按创建时间排序。",
23592
+ "http": "GET",
23593
+ "path": "/registry/v1/packages/{package_id}/installations",
23594
+ "streaming": "no",
23595
+ "pagination": false,
23596
+ "pathParams": [
23597
+ {
23598
+ "name": "package_id",
23599
+ "sdkName": "package_id",
23600
+ "description": "包的标识,来自 repositories.packages.list 或 repositories.packages.create 返回的 id;不要传包名。"
23601
+ }
23602
+ ],
23603
+ "query": []
23604
+ },
23605
+ {
23606
+ "resource": "registry.packages.installations",
23607
+ "method": "create",
23608
+ "summary": "Install a package",
23609
+ "description": "把一个包装到目标上:技能装到智能体(agent_ids),插件装到电脑(computer_ids),一次最多 50 个目标;目标种类给错会被拒(400),包的种类可从 packages.retrieve 的 kind 得知。技能装的是具体版本,version 省略时装最新版,之后不会自动升级,要换版本用 installations.update。插件只能装库里的最新版本,version 若给了就必须等于最新版,否则 FAILED_PRECONDITION。撤回的版本不能新装。同一目标重复装同一个包不会报错,而是把它移到这个版本。技能被拒的情形:智能体上已有同名的另一个技能(名字冲突),或这个智能体已经有 20 个技能。各目标独立处理:只要有一个成功就返回 201,成功的在 data 里,失败的目标在 errors 里逐个列出 target_id、code 和 message,按消息修正后只对失败的目标重发;全部失败时不返回 201,而是按第一个失败返回错误状态。装到智能体或电脑上要求调用者本人有权限,权限不足会出现在该目标的 errors 里。",
23610
+ "http": "POST",
23611
+ "path": "/registry/v1/packages/{package_id}/installations",
23612
+ "streaming": "no",
23613
+ "pagination": false,
23614
+ "pathParams": [
23615
+ {
23616
+ "name": "package_id",
23617
+ "sdkName": "package_id",
23618
+ "description": "包的标识,来自 repositories.packages.list 或 repositories.packages.create 返回的 id;不要传包名。"
23619
+ }
23620
+ ],
23621
+ "query": [],
23622
+ "body": {
23623
+ "required": true,
23624
+ "fields": [
23625
+ {
23626
+ "name": "agent_ids",
23627
+ "type": "array",
23628
+ "itemType": "string",
23629
+ "required": false,
23630
+ "description": "要装到的智能体标识,1 到 50 个,重复的会合并;只用于技能,来自智能体列表的 id。"
23631
+ },
23632
+ {
23633
+ "name": "computer_ids",
23634
+ "type": "array",
23635
+ "itemType": "string",
23636
+ "required": false,
23637
+ "description": "要装到的电脑标识,1 到 50 个,重复的会合并;只用于插件,来自电脑列表的 id。"
23638
+ },
23639
+ {
23640
+ "name": "version",
23641
+ "type": "string",
23642
+ "required": false,
23643
+ "description": "要装的版本号,完整 semver;省略时装最新版;插件给了也必须等于最新版,撤回的版本不能装。"
23644
+ }
23645
+ ]
23646
+ }
23647
+ },
23648
+ {
23649
+ "resource": "registry.packages.versions",
23650
+ "method": "list",
23651
+ "summary": "List versions",
23652
+ "description": "列出一个包的所有版本,含已撤回的。撤回的版本仍在列表里(它占着版本号),withdrawn 为 true,并带 withdraw_time。按发布顺序返回。",
23653
+ "http": "GET",
23654
+ "path": "/registry/v1/packages/{package_id}/versions",
23655
+ "streaming": "no",
23656
+ "pagination": true,
23657
+ "pathParams": [
23658
+ {
23659
+ "name": "package_id",
23660
+ "sdkName": "package_id",
23661
+ "description": "包的标识,来自 repositories.packages.list 或 repositories.packages.create 返回的 id;不要传包名。"
23662
+ }
23663
+ ],
23664
+ "query": [
23665
+ {
23666
+ "name": "page_size",
23667
+ "type": "integer",
23668
+ "required": false,
23669
+ "description": "每页返回多少条,1 到 100;省略时默认 20。超过 100 会被截到 100。"
23670
+ },
23671
+ {
23672
+ "name": "cursor",
23673
+ "type": "string",
23674
+ "required": false,
23675
+ "description": "上一页返回的 next_cursor,用来取下一页;第一页省略它,next_cursor 为 null 时停止翻页。"
23676
+ }
23677
+ ]
23678
+ },
23679
+ {
23680
+ "resource": "registry.packages.versions",
23681
+ "method": "create",
23682
+ "summary": "Publish a version",
23683
+ "description": "给一个已有的包发新版本。请求体与 packages.create 相同(multipart:version 必填,archive 或 files 给内容),但种类和名字沿用这个包,不再从上传内容重判。version 必须比已发布的最高版本高(撤回的版本也占号,不能复用);比它低或相等返回 FAILED_PRECONDITION。title、description、tags 不填就沿用这个包现在显示的,不会被新版本里 SKILL.md 或 plugin.json 的描述覆盖;要改就在这次请求里给。作者不随新版本改变。",
23684
+ "http": "POST",
23685
+ "path": "/registry/v1/packages/{package_id}/versions",
23686
+ "streaming": "no",
23687
+ "pagination": false,
23688
+ "multipart": true,
23689
+ "pathParams": [
23690
+ {
23691
+ "name": "package_id",
23692
+ "sdkName": "package_id",
23693
+ "description": "包的标识,来自 repositories.packages.list 或 repositories.packages.create 返回的 id;不要传包名。"
23694
+ }
23695
+ ],
23696
+ "query": [],
23697
+ "body": {
23698
+ "required": true,
23699
+ "fields": [
23700
+ {
23701
+ "name": "version",
23702
+ "type": "string",
23703
+ "required": true,
23704
+ "description": "要发布的版本号,完整 semver,例如 1.2.0;每个包内必须严格递增,撤回的版本也占号。"
23705
+ },
23706
+ {
23707
+ "name": "archive",
23708
+ "type": "string",
23709
+ "required": false,
23710
+ "description": "一个 zip 文件,内含包的内容;与 files 二选一。单个顶层目录会被剥掉。"
23711
+ },
23712
+ {
23713
+ "name": "files",
23714
+ "type": "array",
23715
+ "itemType": "string",
23716
+ "required": false,
23717
+ "description": "直接上传的一组文件,每个 part 的 filename 是相对路径;与 archive 二选一。"
23718
+ },
23719
+ {
23720
+ "name": "title",
23721
+ "type": "string",
23722
+ "required": false,
23723
+ "description": "给人看的标题;省略时从包内容里取。"
23724
+ },
23725
+ {
23726
+ "name": "description",
23727
+ "type": "string",
23728
+ "required": false,
23729
+ "description": "包说明;省略时从包内容里取。"
23730
+ },
23731
+ {
23732
+ "name": "tags",
23733
+ "type": "string",
23734
+ "required": false,
23735
+ "description": "逗号分隔的标签,例如 review,quality;省略时没有标签。"
23736
+ }
23737
+ ]
23738
+ }
23739
+ },
23740
+ {
23741
+ "resource": "registry.packages.versions",
23742
+ "method": "retrieveArchive",
23743
+ "summary": "Download version archive",
23744
+ "description": "下载一个版本的完整 zip 归档,用来整包安装或转存。每次调用都计入这个包的 downloads,所以不要为了看内容而反复拉 archive——先读 contents,只取需要的文件用 files 下载。",
23745
+ "http": "GET",
23746
+ "path": "/registry/v1/packages/{package_id}/versions/{version}/archive",
23747
+ "streaming": "no",
23748
+ "pagination": false,
23749
+ "pathParams": [
23750
+ {
23751
+ "name": "package_id",
23752
+ "sdkName": "package_id",
23753
+ "description": "包的标识,来自 repositories.packages.list 或 repositories.packages.create 返回的 id;不要传包名。"
23754
+ },
23755
+ {
23756
+ "name": "version",
23757
+ "sdkName": "version",
23758
+ "description": "要读的版本号,来自 versions.list 或 versions.create 返回的 version;必须是完整 semver,形如 1.2.0,不接受 latest 或范围。"
23759
+ }
23760
+ ],
23761
+ "query": []
23762
+ },
23763
+ {
23764
+ "resource": "registry.packages.versions.contents",
23765
+ "method": "list",
23766
+ "summary": "List version contents",
23767
+ "description": "列出一个版本解压后的文件清单(路径和大小),用来在不下载整个包的前提下看它包含什么。路径是相对包根的,例如 SKILL.md 或 plugin/skills/review.md。已撤回的版本仍可读清单。",
23768
+ "http": "GET",
23769
+ "path": "/registry/v1/packages/{package_id}/versions/{version}/contents",
23770
+ "streaming": "no",
23771
+ "pagination": false,
23772
+ "pathParams": [
23773
+ {
23774
+ "name": "package_id",
23775
+ "sdkName": "package_id",
23776
+ "description": "包的标识,来自 repositories.packages.list 或 repositories.packages.create 返回的 id;不要传包名。"
23777
+ },
23778
+ {
23779
+ "name": "version",
23780
+ "sdkName": "version",
23781
+ "description": "要读的版本号,来自 versions.list 或 versions.create 返回的 version;必须是完整 semver,形如 1.2.0,不接受 latest 或范围。"
23782
+ }
23783
+ ],
23784
+ "query": []
23785
+ },
23786
+ {
23787
+ "resource": "registry.packages.versions.files",
23788
+ "method": "retrieve",
23789
+ "summary": "Download a file",
23790
+ "description": "下载一个版本里的单个文件,返回原始字节。path 是 contents 给出的路径,可以含斜杠(例如 plugin/skills/review.md)。用它按文件取内容,装到磁盘上时保留这个相对路径。不计入 downloads。",
23791
+ "http": "GET",
23792
+ "path": "/registry/v1/packages/{package_id}/versions/{version}/files/{path}",
23793
+ "streaming": "no",
23794
+ "pagination": false,
23795
+ "pathParams": [
23796
+ {
23797
+ "name": "package_id",
23798
+ "sdkName": "package_id",
23799
+ "description": "包的标识,来自 repositories.packages.list 或 repositories.packages.create 返回的 id;不要传包名。"
23800
+ },
23801
+ {
23802
+ "name": "version",
23803
+ "sdkName": "version",
23804
+ "description": "要读的版本号,来自 versions.list 或 versions.create 返回的 version;必须是完整 semver,形如 1.2.0,不接受 latest 或范围。"
23805
+ },
23806
+ {
23807
+ "name": "path",
23808
+ "sdkName": "path",
23809
+ "description": "版本内的相对文件路径,取自 contents 返回的 path,可以含斜杠(例如 plugin/skills/review.md);不要以 / 开头。"
23810
+ }
23811
+ ],
23812
+ "query": []
23813
+ },
23814
+ {
23815
+ "resource": "registry.packages.versions",
23816
+ "method": "withdraw",
23817
+ "summary": "Withdraw a version",
23818
+ "description": "撤回一个版本。撤回后它不再是 latest、不能被新装;已经装好的照常可用。版本号仍被占着,不能再用它发新版本。已经撤回的版本再撤回会返回 FAILED_PRECONDITION。撤回是不可逆的:要重新提供这个版本,用更高的版本号重新发布。",
23819
+ "http": "POST",
23820
+ "path": "/registry/v1/packages/{package_id}/versions/{version}:withdraw",
23821
+ "streaming": "no",
23822
+ "pagination": false,
23823
+ "pathParams": [
23824
+ {
23825
+ "name": "package_id",
23826
+ "sdkName": "package_id",
23827
+ "description": "包的标识,来自 repositories.packages.list 或 repositories.packages.create 返回的 id;不要传包名。"
23828
+ },
23829
+ {
23830
+ "name": "version",
23831
+ "sdkName": "version",
23832
+ "description": "要读的版本号,来自 versions.list 或 versions.create 返回的 version;必须是完整 semver,形如 1.2.0,不接受 latest 或范围。"
23833
+ }
23834
+ ],
23835
+ "query": []
23836
+ },
23837
+ {
23838
+ "resource": "registry.repositories",
23839
+ "method": "list",
23840
+ "summary": "List repositories",
23841
+ "description": "列出这个组织现有的库,默认库也在其中。库很少,一页通常装得下;用 next_cursor 翻页。先在这里拿到 repository_id,再用它列出或发布包。",
23842
+ "http": "GET",
23843
+ "path": "/registry/v1/repositories",
23844
+ "streaming": "no",
23845
+ "pagination": true,
23846
+ "pathParams": [],
23847
+ "query": [
23848
+ {
23849
+ "name": "page_size",
23850
+ "type": "integer",
23851
+ "required": false,
23852
+ "description": "每页返回多少条,1 到 100;省略时默认 20。超过 100 会被截到 100。"
23853
+ },
23854
+ {
23855
+ "name": "cursor",
23856
+ "type": "string",
23857
+ "required": false,
23858
+ "description": "上一页返回的 next_cursor,用来取下一页;第一页省略它,next_cursor 为 null 时停止翻页。"
23859
+ }
23860
+ ]
23861
+ },
23862
+ {
23863
+ "resource": "registry.repositories",
23864
+ "method": "create",
23865
+ "summary": "Create repository",
23866
+ "description": "新建一个库来分类存放包。name 是库的唯一标识,小写字母、数字和连字符,最多 63 个字符,且不能和已有的库重名;display_name 和 description 是给人看的。每个组织本来就有一个默认库,需要新分类时才建;一个库非空时不能删除,所以不要用库来临时隔离一次上传。",
23867
+ "http": "POST",
23868
+ "path": "/registry/v1/repositories",
23869
+ "streaming": "no",
23870
+ "pagination": false,
23871
+ "pathParams": [],
23872
+ "query": [],
23873
+ "body": {
23874
+ "required": true,
23875
+ "fields": [
23876
+ {
23877
+ "name": "name",
23878
+ "type": "string",
23879
+ "required": true,
23880
+ "description": "新库的唯一标识,小写字母、数字和连字符,最多 63 个字符,且在这个组织里未被使用;不能只有一个连字符结尾。"
23881
+ },
23882
+ {
23883
+ "name": "display_name",
23884
+ "type": "string",
23885
+ "required": false,
23886
+ "description": "给人看的库名;省略时后续显示 name。"
23887
+ },
23888
+ {
23889
+ "name": "description",
23890
+ "type": "string",
23891
+ "required": false,
23892
+ "description": "库的说明;省略时不写。"
23893
+ }
23894
+ ]
23895
+ }
23896
+ },
23897
+ {
23898
+ "resource": "registry.repositories",
23899
+ "method": "delete",
23900
+ "summary": "Delete repository",
23901
+ "description": "删一个空的库。默认库不能删(FAILED_PRECONDITION);库里还有包时也不能删,先把包删掉或改用别的库。删除请求重发会 404,所以删除前先读一次确认。",
23902
+ "http": "DELETE",
23903
+ "path": "/registry/v1/repositories/{repository_id}",
23904
+ "streaming": "no",
23905
+ "pagination": false,
23906
+ "pathParams": [
23907
+ {
23908
+ "name": "repository_id",
23909
+ "sdkName": "repository_id",
23910
+ "description": "库的标识,来自 repositories.list 或 repositories.create 返回的 id;不要传库的 name 或显示名。"
23911
+ }
23912
+ ],
23913
+ "query": []
23914
+ },
23915
+ {
23916
+ "resource": "registry.repositories",
23917
+ "method": "retrieve",
23918
+ "summary": "Retrieve repository",
23919
+ "description": "读一个库的名称、说明、包数量和默认标记。repository_id 来自 repositories.list 或 repositories.create;另一个组织的库或不存在的库一律 404,不区分两者。",
23920
+ "http": "GET",
23921
+ "path": "/registry/v1/repositories/{repository_id}",
23922
+ "streaming": "no",
23923
+ "pagination": false,
23924
+ "pathParams": [
23925
+ {
23926
+ "name": "repository_id",
23927
+ "sdkName": "repository_id",
23928
+ "description": "库的标识,来自 repositories.list 或 repositories.create 返回的 id;不要传库的 name 或显示名。"
23929
+ }
23930
+ ],
23931
+ "query": []
23932
+ },
23933
+ {
23934
+ "resource": "registry.repositories",
23935
+ "method": "update",
23936
+ "summary": "Update repository",
23937
+ "description": "改库的 display_name 或 description。只送要改的字段,省略的保持原值;name 建库之后不能改,它标识库。一个字段都不送会 400。",
23938
+ "http": "PATCH",
23939
+ "path": "/registry/v1/repositories/{repository_id}",
23940
+ "streaming": "no",
23941
+ "pagination": false,
23942
+ "pathParams": [
23943
+ {
23944
+ "name": "repository_id",
23945
+ "sdkName": "repository_id",
23946
+ "description": "库的标识,来自 repositories.list 或 repositories.create 返回的 id;不要传库的 name 或显示名。"
23947
+ }
23948
+ ],
23949
+ "query": [],
23950
+ "body": {
23951
+ "required": true,
23952
+ "fields": [
23953
+ {
23954
+ "name": "display_name",
23955
+ "type": "string",
23956
+ "required": false,
23957
+ "description": "新的显示名;显式传 null 会清空它。"
23958
+ },
23959
+ {
23960
+ "name": "description",
23961
+ "type": "string",
23962
+ "required": false,
23963
+ "description": "新的说明;显式传 null 会清空它。"
23964
+ }
23965
+ ]
23966
+ }
23967
+ },
23968
+ {
23969
+ "resource": "registry.repositories.packages",
23970
+ "method": "list",
23971
+ "summary": "List packages",
23972
+ "description": "列出一个库里的包,可按种类筛、按名字搜、按最近更新或下载量排序。kind=skill 只看技能,kind=plugin 只看插件,省略则两类都返回。q 在 name、title 和 description 上做子串匹配。sort 默认 updated;downloads 按累计下载量降序,用来找这个库最常用的资源。",
23973
+ "http": "GET",
23974
+ "path": "/registry/v1/repositories/{repository_id}/packages",
23975
+ "streaming": "no",
23976
+ "pagination": true,
23977
+ "pathParams": [
23978
+ {
23979
+ "name": "repository_id",
23980
+ "sdkName": "repository_id",
23981
+ "description": "库的标识,来自 repositories.list 或 repositories.create 返回的 id;不要传库的 name 或显示名。"
23982
+ }
23983
+ ],
23984
+ "query": [
23985
+ {
23986
+ "name": "kind",
23987
+ "type": "string",
23988
+ "enum": [
23989
+ "skill",
23990
+ "plugin"
23991
+ ],
23992
+ "required": false,
23993
+ "description": "只看某一类包;省略时技能和插件都返回。"
23994
+ },
23995
+ {
23996
+ "name": "q",
23997
+ "type": "string",
23998
+ "required": false,
23999
+ "description": "按子串搜索包,匹配 name、title 和 description;省略时不过滤。不区分大小写。"
24000
+ },
24001
+ {
24002
+ "name": "sort",
24003
+ "type": "string",
24004
+ "enum": [
24005
+ "updated",
24006
+ "downloads"
24007
+ ],
24008
+ "required": false,
24009
+ "description": "结果排序方式;省略时按 updated。"
24010
+ },
24011
+ {
24012
+ "name": "page_size",
24013
+ "type": "integer",
24014
+ "required": false,
24015
+ "description": "每页返回多少条,1 到 100;省略时默认 20。超过 100 会被截到 100。"
24016
+ },
24017
+ {
24018
+ "name": "cursor",
24019
+ "type": "string",
24020
+ "required": false,
24021
+ "description": "上一页返回的 next_cursor,用来取下一页;第一页省略它,next_cursor 为 null 时停止翻页。"
24022
+ }
24023
+ ]
24024
+ },
24025
+ {
24026
+ "resource": "registry.repositories.packages",
24027
+ "method": "create",
24028
+ "summary": "Publish a package",
24029
+ "description": "把一个新包发布进这个库,一次调用建立包并上传它的第一个版本。发布内容是 multipart:version 必填,archive 给一个 zip,或者 files 给一组文件(每个文件的 filename 是相对上传根的路径,例如 pdf/SKILL.md)。单个顶层目录会被剥掉。种类按根上有什么判:有 SKILL.md 就是 skill,有 .claude-plugin/plugin.json 就是 plugin;两者都没有、或都有,会被拒。名字从 SKILL.md 或 plugin.json 里读,不从路径或 query 猜。限额:上传 ≤25 MiB,解压后 ≤50 MiB,≤1000 个文件。版本必须是 semver 且严格递增;第一个版本可以是任意合法 semver,之后每个新版本都要比已发布的最高版本高。把已有智能体的技能搬过来时,先用 GET /agent/v1/skills/{id}/versions/{v}/content 导出 zip,再在这里作为 archive 发布。",
24030
+ "http": "POST",
24031
+ "path": "/registry/v1/repositories/{repository_id}/packages",
24032
+ "streaming": "no",
24033
+ "pagination": false,
24034
+ "multipart": true,
24035
+ "pathParams": [
24036
+ {
24037
+ "name": "repository_id",
24038
+ "sdkName": "repository_id",
24039
+ "description": "库的标识,来自 repositories.list 或 repositories.create 返回的 id;不要传库的 name 或显示名。"
24040
+ }
24041
+ ],
24042
+ "query": [],
24043
+ "body": {
24044
+ "required": true,
24045
+ "fields": [
24046
+ {
24047
+ "name": "version",
24048
+ "type": "string",
24049
+ "required": true,
24050
+ "description": "要发布的版本号,完整 semver,例如 1.2.0;每个包内必须严格递增,撤回的版本也占号。"
24051
+ },
24052
+ {
24053
+ "name": "archive",
24054
+ "type": "string",
24055
+ "required": false,
24056
+ "description": "一个 zip 文件,内含包的内容;与 files 二选一。单个顶层目录会被剥掉。"
24057
+ },
24058
+ {
24059
+ "name": "files",
24060
+ "type": "array",
24061
+ "itemType": "string",
24062
+ "required": false,
24063
+ "description": "直接上传的一组文件,每个 part 的 filename 是相对路径;与 archive 二选一。"
24064
+ },
24065
+ {
24066
+ "name": "title",
24067
+ "type": "string",
24068
+ "required": false,
24069
+ "description": "给人看的标题;省略时从包内容里取。"
24070
+ },
24071
+ {
24072
+ "name": "description",
24073
+ "type": "string",
24074
+ "required": false,
24075
+ "description": "包说明;省略时从包内容里取。"
24076
+ },
24077
+ {
24078
+ "name": "tags",
24079
+ "type": "string",
24080
+ "required": false,
24081
+ "description": "逗号分隔的标签,例如 review,quality;省略时没有标签。"
24082
+ }
24083
+ ]
24084
+ }
24085
+ },
23462
24086
  {
23463
24087
  "resource": "sandbox.events.sandboxes",
23464
24088
  "method": "retrieve",