@sema-agent/sdk 43.0.0 → 45.0.0
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/README.md +164 -0
- package/dist/errors.d.ts +22 -5
- package/dist/errors.d.ts.map +1 -1
- package/dist/errors.js +13 -3
- package/dist/errors.js.map +1 -1
- package/dist/events.d.ts +14 -8
- package/dist/events.d.ts.map +1 -1
- package/dist/events.js.map +1 -1
- package/dist/index.d.ts +7 -3
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +5 -2
- package/dist/index.js.map +1 -1
- package/dist/resources/approvals.d.ts +27 -9
- package/dist/resources/approvals.d.ts.map +1 -1
- package/dist/resources/approvals.js +12 -2
- package/dist/resources/approvals.js.map +1 -1
- package/dist/resources/tool-approvals.d.ts +22 -6
- package/dist/resources/tool-approvals.d.ts.map +1 -1
- package/dist/resources/tool-approvals.js +3 -2
- package/dist/resources/tool-approvals.js.map +1 -1
- package/dist/transport.d.ts +9 -1
- package/dist/transport.d.ts.map +1 -1
- package/dist/transport.js +11 -1
- package/dist/transport.js.map +1 -1
- package/dist/types.d.ts +135 -27
- package/dist/types.d.ts.map +1 -1
- package/dist/types.js +27 -4
- package/dist/types.js.map +1 -1
- package/openapi.yaml +169 -38
- package/package.json +1 -1
package/dist/types.js
CHANGED
|
@@ -1,8 +1,12 @@
|
|
|
1
|
-
/** Builtin scenarios of a stock `@sema-agent/server` that this SDK offers as known names — **
|
|
2
|
-
*
|
|
1
|
+
/** Builtin scenarios of a stock `@sema-agent/server` that this SDK offers as known names — **seven**, all in the server's builtin table
|
|
2
|
+
* (`BUILTIN_SCENARIO_NAMES` in `src/capabilities/scenarios.ts`; the table `createScenarios()` returns, called `buildScenarios()` on servers ≤7.154.x). `code` is the factory default ([891]); `default` is the
|
|
3
3
|
* domain-neutral assistant face; `scan` is the neutral read-only repo lane; `code-review` is the multi-lens review lane;
|
|
4
4
|
* `cowork` (server ≥7.133.0) is the office-oriented face (`default`'s tool surface without the coding tools — file read / browsing / connector mounts — on the engine's Cowork role base;
|
|
5
5
|
* its detail card reads `toolset: "office"`). A server ≤7.132.x answers `cowork` 400 `scenario_unknown` — gate on `capabilities.scenarios` (the live vocabulary), not on this list.
|
|
6
|
+
* `chat` (server ≥7.155.0) is chat: no hands, a FIXED tool face (web fetch / web search, the skill tool when skills ride, the connectors and A2A peers that reach `chat`), the engine's minimal prompt form;
|
|
7
|
+
* its card reads `toolset: "chat"` and carries {@link ScenarioDetail.allowTools}. `chat-folders` (server ≥7.155.0) is the same fixed face plus a read-only file hand (`Read` / `Grep` / `Glob` over this run's read roots —
|
|
8
|
+
* the folders the request attaches, the caller's `cwd` or the leg's temporary working directory, and read directories the same person allowed long-term before; a read outside them is refused without asking); its card reads `toolset: "folder-read"`, carries `allowTools` and `handsReadOnly: true`, and is runnable only on a deployment that
|
|
9
|
+
* honors caller host paths (otherwise `available: false` + `unavailableReason: "caller_paths_unhonored"`, and submitting answers 501). A server ≤7.154.x answers either name 400 `scenario_unknown`.
|
|
6
10
|
* ⚠️ Servers ≤7.125.x list ONE more name, `discuss` (the multi-agent discussion round-table); **server 7.126.0 retired it with the whole team-orchestration
|
|
7
11
|
* surface (no alias)** — a 7.126.0+ server answers it 400 `scenario_unknown`. It was never listed here. (`Scenario` is open, so `scenario: "discuss"` still compiles; the 400 is the notice.)
|
|
8
12
|
* 🔴 CHECKED AGAINST THE SERVER, not hand-kept (K-20): `test/scenario-capabilities.test.ts` ① reads the builtin table out of
|
|
@@ -18,7 +22,7 @@
|
|
|
18
22
|
* answers it 400 today. Removed here in K-20.
|
|
19
23
|
* Sending a retired name to a ≥5.1.0 server is a LOUD typed 400 `scenario_unknown` (the response carries the
|
|
20
24
|
* deployment's live vocabulary), not a silent fold to `default`. */
|
|
21
|
-
export const KNOWN_SCENARIOS = ["code", "default", "code-review", "scan", "cowork"];
|
|
25
|
+
export const KNOWN_SCENARIOS = ["code", "default", "code-review", "scan", "cowork", "chat", "chat-folders"];
|
|
22
26
|
/** 会话**种类**词(server ≥7.151.0;server 同名常量 `SESSION_KINDS`):今天一词 `sidechain` = 客户端自己放的子对话(默认不在 `GET /v1/sessions` 里列,要 `?sessionKind=sidechain` 视图)。写一次、不变。 */
|
|
23
27
|
export const SESSION_KINDS = Object.freeze(["sidechain"]);
|
|
24
28
|
/**
|
|
@@ -149,7 +153,8 @@ export const ENGINE_CAPABILITY_WORDS = Object.freeze(["inherit_env.own_credentia
|
|
|
149
153
|
export const STORE_DURABILITIES = Object.freeze(["durable", "ephemeral", "unknown"]);
|
|
150
154
|
/** One scenario's detail card (`GET /v1/capabilities/scenarios/:name` — server handler = the
|
|
151
155
|
* `url.startsWith("/v1/capabilities/scenarios/")` branch in `src/http/routes/capabilities.ts`,
|
|
152
|
-
* shape = capabilities/scenarios.d.ts `ScenarioDetail` verbatim
|
|
156
|
+
* shape = capabilities/scenarios.d.ts `ScenarioDetail` verbatim — server ≥7.155.0: `ScenarioCard` = that row plus the two machine bits `allowTools` / `handsReadOnly`, minted only
|
|
157
|
+
* by `scenarioCardOf`; the LIST of names rides `capabilities.scenarios`).
|
|
153
158
|
* `source`/`builtin` = builtin vs center-config overlay; `toolset` names the tool bundle, `tools` the resolved
|
|
154
159
|
* tool names; `promptSummary` is a human-readable prompt digest (NOT the full prompt); `enabled` = a center
|
|
155
160
|
* scenario can be declared-but-disabled.
|
|
@@ -165,6 +170,12 @@ export const STORE_DURABILITIES = Object.freeze(["durable", "ephemeral", "unknow
|
|
|
165
170
|
* · `deployment` —— 这台部署的缺省场景(`DEFAULT_SCENARIO`)。
|
|
166
171
|
* 新词随 server 加 ⇒ 按它分支的 `switch` 留 default 臂。 */
|
|
167
172
|
export const SCENARIO_SOURCES = Object.freeze(["request", "ruling", "deployment"]);
|
|
173
|
+
/** 场景不可用的机读原因词(server 的闭集 `ScenarioUnavailableReason`,自铸词表 `scenarioUnavailableReason`,逐词同序):场景卡 {@link ScenarioDetail.unavailableReason} 与
|
|
174
|
+
* 提交这个场景答的 501 `capability.unavailable` 体根(server ≥7.155.0)同一只词。
|
|
175
|
+
* · `git_client_unconfigured` —— 仓库型场景(scan / code-review / 中心声明的仓库只读工具集)要部署配好 git 后端(`GIT_API_BASEURL`);
|
|
176
|
+
* · `caller_paths_unhonored`(server ≥7.155.0)—— 场景要读调用方按宿主路径交来的文件夹(`chat-folders`),而这台部署不兑现调用方的宿主路径。
|
|
177
|
+
* 读侧开集(未知词 = 「不可用、原因未知」);对本表穷举的 `switch` 留 default 臂。 */
|
|
178
|
+
export const SCENARIO_UNAVAILABLE_REASONS = Object.freeze(["git_client_unconfigured", "caller_paths_unhonored"]);
|
|
168
179
|
/**
|
|
169
180
|
* `credentialPlane.sandboxGit` 平面关闭的原因(server ≥7.137.0,自铸词表 `credentialPlaneSandboxGitOffReason`,九词闭集)—— **取第一个不成立的前提,判序固定 = 数组序**:
|
|
170
181
|
* `single_user`(不是多租户部署)→ `lane_without_boundary`(执行车道不是 k8s 沙箱 pod)→ `no_caller_credential`(本 worker 没有控制台凭据库认的取值凭据)→ `center_not_https`(中心地址不是 https)→
|
|
@@ -264,6 +275,18 @@ export const CROSS_BOUNDARY_TAINT_BITS = Object.freeze(["targetExecutionArmed",
|
|
|
264
275
|
* · `clearanceCustody`(server ≥7.148.0 / 引擎 7.66.0,插在 `quarantineCopy` 之后,引擎序)—— 来源清标留在托管里的那份条目正文(抹除时一并抹掉,清标行带 `custodyErased: true`)。
|
|
265
276
|
*/
|
|
266
277
|
export const MEMORY_ERASURE_CARRIER_CLASSES = Object.freeze(["projection", "shadow", "indexLine", "quarantineCopy", "clearanceCustody", "planArchive", "planWorkbook", "evidenceBinding", "backendDerived"]);
|
|
278
|
+
/**
|
|
279
|
+
* **工作流成员停驻卡**上「决定行写成了」的那一类 200 的两个词(闭集,server ≥7.155.0;按 `status` 判别,两臂见 {@link WorkflowParkDecisionReceipt})。
|
|
280
|
+
* 两扇决断口同一张体:`POST /v1/approvals/{sessionId}/decide`,与按问决断口的停驻形(那一口把体里的 `taskId` 改放 `carrierTaskId`,见
|
|
281
|
+
* {@link import("./resources/tool-approvals.js").AskDecisionParkedRedeemed})。
|
|
282
|
+
* · `recorded` —— 这只决定已作为这张卡的决定记在部署的决定店里、寄给 `runId`(持有这张卡的那条 workflow run);**没有**一条在跑的宿主那一跑带着它
|
|
283
|
+
* (持有它的 run 还在跑、由它自己的进程交付;或带着它的那一跑在受理之前就停了 —— 宿主会话的下一跑会带上它);
|
|
284
|
+
* · `delivered` —— 记下了,**并且**宿主会话上一条在跑的那一跑(`taskId`,run 店里那一跑,`GET /v1/runs/:taskId` 读得到)已带着它起跑 / 续上。
|
|
285
|
+
* 词只说**答话那一刻**服务端这边成立的事:引擎之后怎么处置这只决定(续上了 / 没用上)不在回执上,回执的词也从不随它改写 —— 两个词都**不是**「门已解决」,
|
|
286
|
+
* 那张卡在 200 之后仍可能列在 `/v1/approvals` 上。老服务端(< 7.155.0)在这类卡上答 `resuming`,形见 {@link import("./resources/approvals.js").ParkedDecideAccepted}。
|
|
287
|
+
* 冻结(`Object.freeze`):开集读者对它 `satisfies Record<WorkflowParkDecisionReceiptStatus, …>` 做两向穷举。
|
|
288
|
+
*/
|
|
289
|
+
export const WORKFLOW_PARK_DECISION_RECEIPT_STATUSES = Object.freeze(["recorded", "delivered"]);
|
|
267
290
|
// ═══════════════════════════════════════════════════════════════════════════════════════════════
|
|
268
291
|
// server ≥7.147.0 · 项目登记簿读面({@link import("./resources/projects.js").ProjectsResource})
|
|
269
292
|
// ═══════════════════════════════════════════════════════════════════════════════════════════════
|
package/dist/types.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAyEA
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAyEA;;;;;;;;;;;;;;;;;;;;;;;qEAuBqE;AACrE,MAAM,CAAC,MAAM,eAAe,GAAG,CAAC,M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M,CAAC,MAAM,gBAAgB,GAAG,MAAM,CAAC,MAAM,CAAC,CAAC,WAAW,EAAE,QAAQ,EAAE,QAAQ,EAAE,MAAM,EAAE,SAAS,EAAE,UAAU,CAAU,CAAC,CAAC"}
|
package/openapi.yaml
CHANGED
|
@@ -3765,7 +3765,8 @@ paths:
|
|
|
3765
3765
|
description: >-
|
|
3766
3766
|
Decision accepted. Usually the run (or the parked background agent) resumes; on the two parked-agent forms that can never revive,
|
|
3767
3767
|
a DENY (server >= 7.136.0) is answered `{ taskId, status: "failed", decision: "deny" }` instead — the card is voided and nothing resumes
|
|
3768
|
-
(see `ParkedDecideAccepted`, `ApprovalDecisionResult`).
|
|
3768
|
+
(see `ParkedDecideAccepted`, `ApprovalDecisionResult`). On a parked workflow-member card (server >= 7.155.0) the receipt is
|
|
3769
|
+
`recorded` or `delivered` (`WorkflowParkDecisionReceipt`): the decision is recorded; neither word means the gate is resolved.
|
|
3769
3770
|
content:
|
|
3770
3771
|
application/json:
|
|
3771
3772
|
schema:
|
|
@@ -7730,14 +7731,15 @@ components:
|
|
|
7730
7731
|
type: string
|
|
7731
7732
|
description: >
|
|
7732
7733
|
Primary routing axis (one image serves many). Selects model/tools/skills/prompt. OPEN: a stock server's builtin
|
|
7733
|
-
table is `code` (factory default) / `default` / `code-review` / `scan` / `cowork` (SDK `KNOWN_SCENARIOS`, checked against the
|
|
7734
|
-
published server's `
|
|
7734
|
+
table is `code` (factory default) / `default` / `code-review` / `scan` / `cowork` / `chat` / `chat-folders` (SDK `KNOWN_SCENARIOS`, checked against the
|
|
7735
|
+
published server's builtin table — `createScenarios()` on server >= 7.155.0, `buildScenarios()` before; `chat` and `chat-folders` are server >= 7.155.0,
|
|
7736
|
+
an older server answers them 400 `scenario_unknown`; servers <= 7.125.x also listed `discuss`, retired with the whole team-orchestration surface at
|
|
7735
7737
|
7.126.0, no alias) — and a deployment may register more through the registry. A name
|
|
7736
7738
|
the caller SENDS that the deployment does not serve is a loud 400 `scenario_unknown` (server >= 5.1.0, the body
|
|
7737
7739
|
carries the live vocabulary) — the silent fold to `default` exists only on the server-side ASSIGNMENT chain.
|
|
7738
7740
|
Retired, no alias: `oa` (5.0.0), `autonomous` ([2400] CAPS-OPS-11), `team` (renamed `discuss`, server #273 / C-R14;
|
|
7739
7741
|
alias withdrawn at #342).
|
|
7740
|
-
examples: ['code', 'default', 'code-review', 'scan', 'cowork']
|
|
7742
|
+
examples: ['code', 'default', 'code-review', 'scan', 'cowork', 'chat', 'chat-folders']
|
|
7741
7743
|
|
|
7742
7744
|
ScenarioSource:
|
|
7743
7745
|
type: string
|
|
@@ -7766,6 +7768,7 @@ components:
|
|
|
7766
7768
|
# server 7.7.0([C132]/[3235]):+available/unavailableReason 两键——运行面可用性投影,与请求该
|
|
7767
7769
|
# 场景时的 501 拒绝臂同一谓词(server `scenarioAvailability()` 单一属主);`enabled`=声明面、
|
|
7768
7770
|
# `available`=运行面,两轴独立。封闭集从 8 键升 9 必填+1 条件键。
|
|
7771
|
+
# server 7.155.0:200 体 = server `ScenarioCard`(详情行 + `scenarioCardOf` 多铸的两只条件键 `allowTools` / `handsReadOnly`;自铸登记表 `scenarioCardKey`)。
|
|
7769
7772
|
required: [name, source, builtin, summary, toolset, tools, promptSummary, enabled, available]
|
|
7770
7773
|
additionalProperties: false
|
|
7771
7774
|
properties:
|
|
@@ -7787,7 +7790,25 @@ components:
|
|
|
7787
7790
|
included) — the same single filter that feeds `TaskSpec`, same group, same order. A client's `/skill-name` completion reads it; naming one goes through `userInvokedSkills`. Entries carry no body and none of a skill's tool lists. On the card
|
|
7788
7791
|
but not in the run: `disableSkills: true` (nothing mounted) and a skill whose body exceeds the engine's load cap (naming it answers `config.user_invoked_skill_unknown`). ABSENT = an older server: the list cannot be read —
|
|
7789
7792
|
NOT "no skills" (that is `[]`). Bit: `capabilities.scenarioSkills`.
|
|
7790
|
-
unavailableReason: { type: string, description: 'machine-readable reason, present ONLY when available:false (absent = no reason).
|
|
7793
|
+
unavailableReason: { type: string, description: 'machine-readable reason, present ONLY when available:false (absent = no reason). The server''s closed set (SDK `SCENARIO_UNAVAILABLE_REASONS`): `git_client_unconfigured` (a repo-type scenario without `GIT_API_BASEURL`) / `caller_paths_unhonored` (server >= 7.155.0: `chat-folders` reads folders the caller names by host path, and this deployment does not honor caller host paths — multi-tenant, sandbox lanes, device lane, no hands); branch on the key, never match the English prose. Additive-open: treat an unknown word as "unavailable, reason unknown". Server >= 7.155.0: submitting that scenario answers 501 `capability.unavailable` with the SAME word at the body root (`unavailableReason`).' }
|
|
7794
|
+
allowTools:
|
|
7795
|
+
type: array
|
|
7796
|
+
items: { type: string }
|
|
7797
|
+
description: >-
|
|
7798
|
+
server >= 7.155.0: present ONLY when the scenario's effective definition fixes the run's tool face (built-in `chat` / `chat-folders`; other built-in cards and
|
|
7799
|
+
center-declared scenarios never carry it — a center scenario shadowing a built-in name reads `source: "center"` without it). Value = the selection THIS deployment declares for the
|
|
7800
|
+
scenario: its host tool names, the skill tool when skills ride, the hand's tools, one whole-peer selector per connector / A2A peer the deployment tags into it (`mcp__<name>__*` /
|
|
7801
|
+
`a2a__<name>__*`); nothing request-supplied, and the caller's `excludeTools` is not subtracted. Three states: absent = the face is not fixed (or an older server — check
|
|
7802
|
+
`capabilities.scenarios`); `[]` = this deployment gives the scenario no tools; non-empty = a subset. `tools` answers a different question (the host tools the definition brings).
|
|
7803
|
+
What a run actually mounted is its `wiring_manifest`. While present, a submit body that also carries `allowTools` is 400 `request.field_conflict` (`reason: "scenario_tool_face"`).
|
|
7804
|
+
handsReadOnly:
|
|
7805
|
+
type: boolean
|
|
7806
|
+
enum: [true]
|
|
7807
|
+
description: >-
|
|
7808
|
+
server >= 7.155.0: the scenario's runs get the engine's read-only file hand (no write tools, no hand tools whose effect is not a file read, a read outside the run's read
|
|
7809
|
+
roots refused without asking under every permission mode). The read roots are not only the attached folders: the request's read-only additional directories, the caller's `cwd`
|
|
7810
|
+
(else the leg's temporary working directory), and read directories the same person allowed long-term before. Always `true` when present, present ONLY when the scenario
|
|
7811
|
+
declares it (built-in `chat-folders` today); absent = it does not.
|
|
7791
7812
|
|
|
7792
7813
|
ScenarioSkill:
|
|
7793
7814
|
type: object
|
|
@@ -8708,7 +8729,9 @@ components:
|
|
|
8708
8729
|
decide tool availability are `excludeTools`, `allowTools` and `excludeAllTools`. Wrong shape (not a string array) =>
|
|
8709
8730
|
400 `request.field_invalid`, the same gate as `excludeTools` / `deferTools`. An engine older than 7.49.0 rejects loudly (400 `request.field_invalid` naming `allowTools`) —
|
|
8710
8731
|
never silently dropped (dropping a narrowing key widens). No capability bit: probe by key closure (<= 7.125.x answers `400 request.body_shape` with the name in
|
|
8711
|
-
`unknownKeys`). The A2A inbound face (`message/send`) does not carry this key.
|
|
8732
|
+
`unknownKeys`). The A2A inbound face (`message/send`) does not carry this key. Server >= 7.155.0: NOT accepted on a scenario whose tool face is fixed (the scenario
|
|
8733
|
+
card carries `allowTools`: built-in `chat` / `chat-folders`) => 400 `request.field_conflict` (`reason: "scenario_tool_face"`, `fields: ["allowTools"]`, plus `"scenario"` when the
|
|
8734
|
+
body named it), refused before any side effect; narrow such a face with `excludeTools` (it only removes), or send `excludeAllTools: true` for no tools.
|
|
8712
8735
|
excludeAllTools:
|
|
8713
8736
|
type: boolean
|
|
8714
8737
|
enum: [true]
|
|
@@ -15337,13 +15360,25 @@ components:
|
|
|
15337
15360
|
decision}`, an ACCEPTED (not completed) receipt; the revive drives asynchronously. Since server >= 7.136.0 this
|
|
15338
15361
|
shape has a SECOND ARM, the VOIDED receipt `{taskId, status:"failed", decision:"deny"}` — a DENY on a parked row that can
|
|
15339
15362
|
never revive (no agent name / no root-session anchor) voids the card; nothing resumes (see `ParkedDecideAccepted`).
|
|
15363
|
+
🔴 Server >= 7.155.0: a decide on a PARKED WORKFLOW-MEMBER card whose decision row was written answers its own two
|
|
15364
|
+
closed words, two more arms of `ParkedDecideAccepted` (schema `WorkflowParkDecisionReceipt`): `recorded`
|
|
15365
|
+
`{status, runId, decisionId, decision, bindingEnforced}` (the decision is recorded and addressed to `runId`, the workflow run
|
|
15366
|
+
holding the card; no running host turn carries it) and `delivered` `{status, taskId, sessionId, runId, decisionId, decision,
|
|
15367
|
+
bindingEnforced}` (a running host-session turn, `taskId`, in the run store, carries it). Each word has a FIXED key set.
|
|
15368
|
+
Both say only what held when the answer was given; neither means the gate is resolved.
|
|
15340
15369
|
A FOURTH shape, the #368 IDEMPOTENT REPLAY (server >= 7.4x; declared 2026-09-08 — it shipped without
|
|
15341
15370
|
ever reaching this schema): `{sessionId, idempotent:true, decision, bindingEnforced:true,
|
|
15342
15371
|
executionOutcome?}` — it carries NO `status` and NO `taskId` (nothing was accepted this time). So no key
|
|
15343
|
-
is guaranteed by all four shapes; discriminate: `idempotent` -> replay; `decision`
|
|
15344
|
-
parked receipt
|
|
15372
|
+
is guaranteed by all four shapes; discriminate: `idempotent` -> replay; otherwise `decision` present ->
|
|
15373
|
+
parked receipt (`ParkedDecideAccepted`, four arms, read `status`: `resuming` / `failed` / `recorded` / `delivered`);
|
|
15374
|
+
no `decision` -> task-level acceptance / terminal. (The older reading "`decision` without `sessionId`" fails on
|
|
15375
|
+
the server >= 7.155.0 `delivered` arm, which carries `sessionId`.)
|
|
15345
15376
|
`taskId` rides `getActiveTaskId` on the terminal leg (omitted when there is no active row).
|
|
15346
|
-
|
|
15377
|
+
The next two paragraphs describe what a server OLDER THAN 7.155.0 answers on the workflow-member lane (this package
|
|
15378
|
+
still holds against them): `status:"resuming"` — the host acceptance shape below once the holding run had ended
|
|
15379
|
+
(server [7.69.0, 7.155.0)), or `{taskId: <workflow run id>, status:"resuming", decision}` while it was still running
|
|
15380
|
+
(server [7.148.0, 7.155.0); that `taskId` is not in the run store).
|
|
15381
|
+
🔴 A FIFTH PROVENANCE, not a fifth key set (server >= 7.69.0 / S-185, until 7.155.0 — the PARKED WORKFLOW-CHILD lane):
|
|
15347
15382
|
when the pending belongs to a workflow child, the success body is byte-identically the TASK-LEVEL
|
|
15348
15383
|
ACCEPTANCE shape, but it is a wake of the workflow's **HOST session** — `taskId` is the host's FRESHLY
|
|
15349
15384
|
MINTED run id, not the child's. Two readings a consumer MUST get right:
|
|
@@ -15389,9 +15424,12 @@ components:
|
|
|
15389
15424
|
[2400] HITL-12 (server >=5.4.0, clay ruling: no legacy tolerance): generation-probe bit — this
|
|
15390
15425
|
server REQUIRES the decision-action binding (a decide without `checkpointToken` and without
|
|
15391
15426
|
`boundCallId` is refused 400 `decide_requires_binding`; the silent current-pending fallback is gone).
|
|
15392
|
-
Always true on the resumed-leg 200; the parked receipt does not carry it
|
|
15393
|
-
|
|
15394
|
-
|
|
15427
|
+
Always true on the resumed-leg 200; the parked background-agent receipt does not carry it; the two workflow-member arms
|
|
15428
|
+
(server >= 7.155.0, `recorded` / `delivered`) always carry it.
|
|
15429
|
+
taskId: { type: string, description: 'Resumed leg: the active run id (OMITTED when no active row). Parked background-agent leg: the agent handle (`a*`), always present. Workflow-member card, server >= 7.155.0: ONLY on `delivered` — the running host-session turn that carries the decision (in the run store); `recorded` has no `taskId`. Older servers on that lane: the host turn (record ended, [7.69.0, 7.155.0)) or the workflow run id (holding run still running, [7.148.0, 7.155.0); not in the run store).' }
|
|
15430
|
+
sessionId: { type: string, description: 'Resumed leg, and the workflow-member `delivered` arm (server >= 7.155.0: the host session of `taskId`) — absent from the parked background-agent receipt and from `recorded`.' }
|
|
15431
|
+
runId: { type: string, description: 'server >= 7.155.0 - workflow-member parked-card receipt only (both arms, `recorded` / `delivered`): the workflow run the decision is addressed to (the run holding the card; read it with GET /v1/workflows/{runId}). It appears ONLY on that parked receipt; narrow by `status` (`ParkedDecideAccepted`), never by whether this key is present.' }
|
|
15432
|
+
decisionId: { type: string, description: 'server >= 7.155.0 - workflow-member parked-card receipt only (both arms): the opaque id of this decision (a replay of the same decision carries the same value; every new human decision gets a new one), the same id as the engine notice `workflow.parked_decision_unused` `detail.decisionIds`. It appears ONLY on that parked receipt; narrow by `status`, never by whether this key is present.' }
|
|
15395
15433
|
decisionCommitted: { type: boolean, enum: [true], description: 'server >= 7.138.0 - SETTLEMENT EVIDENCE: `true` = the gate this request named was durably settled with THIS request''s decision (historical evidence, not the card''s current state). Always the literal `true`, never `false`. Absent = unprovable or deliberately omitted => read as "not committed" (fail-closed); do not infer it from the absence of `errorCode`. It coexists with `errorCode: cancelled` / `retriable: true`; `retriable: true` only says the run re-parked.' }
|
|
15396
15434
|
checkpointId: { type: string, description: 'server >= 7.138.0 - only alongside `decisionCommitted`: the gate identity of the row selected before execution (same name and value as the operator queue / inbox row / park ledger row). Absent when the identity is unreadable or not applicable (an idempotent replay carries none); absence infers nothing.' }
|
|
15397
15435
|
checkpointIdMissing: { $ref: '#/components/schemas/CheckpointIdMissingWord' }
|
|
@@ -15400,11 +15438,12 @@ components:
|
|
|
15400
15438
|
description: >
|
|
15401
15439
|
OPEN string — do NOT narrow. Task-level acceptance (server >= 7.37): the literal `resuming` (= accepted,
|
|
15402
15440
|
resume in flight — follow the run stream). Terminal leg: the run's resulting status (`completed`/`failed`/
|
|
15403
|
-
`suspended`/`needs_review`). Parked leg: the literal `resuming` (= accepted, revive in flight) — or, server >= 7.136.0, the literal `failed` on the VOIDED receipt (a deny that closed a card which could never revive; nothing resumes)
|
|
15441
|
+
`suspended`/`needs_review`). Parked leg: the literal `resuming` (= accepted, revive in flight) — or, server >= 7.136.0, the literal `failed` on the VOIDED receipt (a deny that closed a card which could never revive; nothing resumes) —
|
|
15442
|
+
or, server >= 7.155.0 on a workflow-member card, `recorded` / `delivered` (closed; see `WorkflowParkDecisionReceipt`). The parked receipt's words are a closed set of four (`ParkedDecideAccepted`).
|
|
15404
15443
|
decision:
|
|
15405
15444
|
type: string
|
|
15406
15445
|
enum: [approve, deny]
|
|
15407
|
-
description: 'Parked leg ONLY — echo of the decision that was accepted
|
|
15446
|
+
description: 'Parked leg ONLY (all four `ParkedDecideAccepted` arms) — echo of the decision that was accepted; the replay shape carries it too, beside `idempotent: true`.'
|
|
15408
15447
|
errorCode: { type: string, description: 'Resumed leg — failure code (e.g. `cancelled`, `checkpoint.reopen_failed`). Always emitted alongside a failure since server 1.309 (errorCode is single-track).' }
|
|
15409
15448
|
errorMessage: { type: string, description: 'Resumed leg — human-readable failure detail (server-side secret-redacted).' }
|
|
15410
15449
|
retriable: { type: boolean, description: 'Resumed leg — `true` = the park is STILL pending (the server re-parked it); refetch and decide again. Emitted only when the store CONFIRMED the reopen.' }
|
|
@@ -15502,8 +15541,11 @@ components:
|
|
|
15502
15541
|
(`judgeCheckpointRow`) on the row's stored bytes. The same type on the operator queue row (`PendingCheckpoint.rowVerdict`), the `/v1/approvals/stream` `pending` frame and the
|
|
15503
15542
|
assistant inbox row (`InboxRow.rowVerdict`). ONE JUDGE, TWO FACES: the first-stage resume / decide refusal (409, body carries `reason`) comes from the same judge, so a row
|
|
15504
15543
|
listed with a non-`ok` verdict is refused for the same reason when decided — present it as NOT APPROVABLE; the way out is cancelling the run or leaving the row to a
|
|
15505
|
-
replica / version that can resume it. `ok` carries only `kind`; `lacking` / `damaged` carry `code` (the engine's checkpoint error code), `reason` (which arm of a multi-arm code), `
|
|
15506
|
-
|
|
15544
|
+
replica / version that can resume it. `ok` carries only `kind`; `lacking` / `damaged` carry `code` (the engine's checkpoint error code), `reason` (which arm of a multi-arm code), `field` and `blockedBy` (server >= 7.153.0, core 7.67.0: only on a row whose recorded
|
|
15545
|
+
permission mode, run origin or frozen tool names this engine does not read, which answers `code: checkpoint.config_refused`; of those three arms only the frozen-tool-names one (`blockedBy: config.tool_face_control`) carries a `reason` (engine 7.68.2 mints `not_a_list`, `not_a_string` or `unsupported_pattern` there),
|
|
15546
|
+
the permission-mode (`config.permission_mode_invalid`) and run-origin (`config.run_origin_invalid`) arms carry none — `field` is the refusal's own `detail.field`, `blockedBy` the admission code a fresh run of the same bad value reports,
|
|
15547
|
+
the same two words, under the same names, when a resume refusal body carries them (on server 7.154.0 the refusal body a decision door builds for the parked row's own refusal is rebuilt from this verdict and does not carry them yet: only the queue row and the inbox row do); every other arm omits both), `requires` (capabilities the row needs and this engine lacks) and `sentence` (the engine's human line —
|
|
15548
|
+
display only, never a match key); `code` / `reason` / `field` / `blockedBy` are open strings (owned by core). server >= 7.147.0: the two faces match on `code` EQUALITY — every decision-class resume door (`/decide`, `/plan_review`, `/resume`, `/wake`)
|
|
15507
15549
|
answers the row's OWN refusal with the engine's original code (`checkpoint.invalid_outcome`, e.g. `requirements_damaged`; `checkpoint.unsupported_version` likewise), the same judge's same code as this verdict's `code`, and the refusal's
|
|
15508
15550
|
`error` starts with this verdict's `sentence`; a cause code (`approval_binding_mismatch` for a binding seat, `resume_outcome_invalid` for a body cell / content reject) is given only to a refusal that really has a cause, and that is not the row's own refusal.
|
|
15509
15551
|
Servers <= 7.146.x translate by gate instead (`checkpoint.invalid_outcome` becomes `approval_binding_mismatch` on a `policy_ask` gate and `resume_outcome_invalid` on other gates, with no `blockedBy`): against those, match the two faces on `reason`, not on `code`.
|
|
@@ -15525,6 +15567,8 @@ components:
|
|
|
15525
15567
|
kind: { type: string, enum: [lacking, damaged] }
|
|
15526
15568
|
code: { type: string }
|
|
15527
15569
|
reason: { type: string }
|
|
15570
|
+
field: { type: string }
|
|
15571
|
+
blockedBy: { type: string }
|
|
15528
15572
|
requires: { type: array, items: { type: string } }
|
|
15529
15573
|
sentence: { type: string }
|
|
15530
15574
|
|
|
@@ -17415,6 +17459,14 @@ components:
|
|
|
17415
17459
|
`approvals.read_corrupt` (500, server >= 7.134.0 on `GET /v1/approvals` — a queue row's stored body cannot be read; an operator has to repair or
|
|
17416
17460
|
delete the row; server >= 7.135.0 the same judge answers `GET /v1/assistant/inbox` and `GET /v1/assistant/tasks` too) and `workflow.journal_incompatible`
|
|
17417
17461
|
(500, server >= 7.135.0 on `GET /v1/workflows/{id}/journal` — a journal row the engine's judge rejects; the body carries `ordinal`; repair the row from the retained copy, never by deleting it).
|
|
17462
|
+
Two more are exempt the same way: `internal.org_delivery_quota_unreadable` (500, server >= 7.149.0 — the cross-principal delivery door cannot read the server's quota state file, so every delivery is refused
|
|
17463
|
+
until an operator repairs it; the same door's 429 `org_delivery.rate_limited` is a different thing: not in this table, yet the SDK never resends it — `principalInbox.send` is a non-submit POST, so whether to send again after the fixed hourly window is the caller's call) and `rewind.restore_failed` (503, server >= 7.153.0 — the file-history store failed the restore;
|
|
17464
|
+
from 7.154.0 the synchronous submit leg does not occupy the idempotency key on this refusal, so an automatic resend would run the restore again; exempt by code, whatever `permanence` says).
|
|
17465
|
+
Two further 503 codes, whose server code family is also `deterministic`: `auth.service_token_required` (the credential gate: the request carried no credential the gate admits — a service token or an auth-bridge-verified sign-in token —
|
|
17466
|
+
and the deployment has anonymous writes off; task submissions and the rewrite doors always answered it, and server >= 7.154.3 also answers an operator's read of the all-tenants / another-owner view with it;
|
|
17467
|
+
the same request sent again gets the same sentence, only the request (send the credential) or the deployment (configure one) changes it) and `state.no_sandbox_base` (`POST /v1/images/bakes` has no usable
|
|
17468
|
+
`sandbox-base` to build FROM; only an operator pinning `SANDBOX_BASE_REF` or publishing one changes it; a non-submit POST, so the SDK's own retry arm never resends it either way — what changes is
|
|
17469
|
+
the answer of the exported `resendIsMeaningless`).
|
|
17418
17470
|
`invalid_session` (500 on servers 7.137.0–7.143.x for the structurally broken form) is RETIRED at server 7.144.0 and no longer exempt: against those older servers the SDK retries it by status.
|
|
17419
17471
|
Every other 5xx code keeps the status-based retry.
|
|
17420
17472
|
🔴 server >= 7.135.0 read-failure and store-fault codes (all additive; branch on the code, never the sentence): `503 approvals.read_unavailable` on `GET /v1/approvals`, `/v1/assistant/inbox` and
|
|
@@ -18077,9 +18129,9 @@ components:
|
|
|
18077
18129
|
`released.mandate` on a GATE RECORD (archive read, server >= 7.129.0): today's seven `PersistedRuleMandate` words (`cross_boundary_taint` from server >= 7.134.0) PLUS the retired `write_protection_unresolved` (core 7.49.0 rename). Same reading as `GateRecordAskClass`.
|
|
18078
18130
|
GateRecordAskOrigin:
|
|
18079
18131
|
type: string
|
|
18080
|
-
enum: [content_question, plan_review, ancestor_marked, org_unavailable, org_rule, rule_store_unavailable, hook, ask_rule, denial_limit_fallback, shell_gate_tighten, safety_tighten, policy, unresolvable]
|
|
18132
|
+
enum: [content_question, plan_review, ancestor_marked, org_unavailable, org_rule, rule_store_unavailable, hook, ask_rule, denial_limit_fallback, integrity_guard, shell_gate_tighten, safety_tighten, policy, unresolvable]
|
|
18081
18133
|
description: >-
|
|
18082
|
-
`origin` on a GATE RECORD (`GateOutcome.origin`, `ModeRelease.origin`; archive read, server >= 7.129.0): core's
|
|
18134
|
+
`origin` on a GATE RECORD (`GateOutcome.origin`, `ModeRelease.origin`; archive read, server >= 7.129.0): core's `ASK_ORIGINS` (today's list, `integrity_guard` from server >= 7.153.0) PLUS the retired `unresolvable` (core 7.14.0 renamed it `ancestor_marked`).
|
|
18083
18135
|
🔴 CLOSED on this face — the engine judges membership here — unlike the OPEN `AskOrigin` of the approval-card faces (the server only checks a non-empty string there). Same reading as `GateRecordAskClass`.
|
|
18084
18136
|
|
|
18085
18137
|
Settlement:
|
|
@@ -18492,7 +18544,7 @@ components:
|
|
|
18492
18544
|
description: 'Present only when THIS pass settled an ask. Same-present/same-absent as `origin` (I1).'
|
|
18493
18545
|
origin:
|
|
18494
18546
|
allOf: [{ $ref: '#/components/schemas/GateRecordAskOrigin' }]
|
|
18495
|
-
# 🔴 闭集**执法**只在门记录这一面:引擎的 `screenGateOutcome` 对 `origin` 判成员(server >= 7.129.0
|
|
18547
|
+
# 🔴 闭集**执法**只在门记录这一面:引擎的 `screenGateOutcome` 对 `origin` 判成员(server >= 7.129.0 按**档案**读:今天的 `ASK_ORIGINS` ∪ 退役词 `unresolvable`),
|
|
18496
18548
|
# 任何一代引擎都没铸过的词即记录缺陷,服务对缺陷记录是整条不上帧。审批帧那一面不判成员,所以 `AskOrigin` 本体保持真开(见该 schema 的长注)。
|
|
18497
18549
|
# 闭集执法点 = `GateRecordAskOrigin` 这一张 enum(门记录的两个引用点 `GateOutcome.origin` / `ModeRelease.origin` 共用);core 加词时改这一处。
|
|
18498
18550
|
description: >
|
|
@@ -18774,8 +18826,8 @@ components:
|
|
|
18774
18826
|
stays `readonly_out_of_root`).
|
|
18775
18827
|
🔴 core >= 7.6.0 — the MCP family within this open set is now the CLOSED `McpFailureKind` word list
|
|
18776
18828
|
(`connect_refused` / `connection_failed` / `connection_closed` / `unauthorized` / `http_status` / `not_mcp_response` /
|
|
18777
|
-
`spawn_failed` / `timeout` / `protocol` / `invalid_config` / `credential_unavailable` / `host_refused` / `unknown` — `credential_unavailable` from core 7.58.0 and
|
|
18778
|
-
`unauthorized` from core 7.59.0, server >= 7.138.0; `host_refused` from core 7.60.0, server >= 7.139.0); the retired
|
|
18829
|
+
`spawn_failed` / `timeout` / `protocol` / `invalid_config` / `credential_unavailable` / `host_refused` / `revoked` / `unknown` — `credential_unavailable` from core 7.58.0 and
|
|
18830
|
+
`unauthorized` from core 7.59.0, server >= 7.138.0; `host_refused` from core 7.60.0, server >= 7.139.0; `revoked` from core 7.67.0, i.e. servers embedding that engine, >= 7.153.0 - read on `wiring_manifest.mcp[].errorCode`, not on a call: see below); the retired
|
|
18779
18831
|
`MCP_FAILURE_CODES` spellings — including `network` and the `http_<status>` encoding — are gone,
|
|
18780
18832
|
and an HTTP status now rides the structured `httpStatus` seat on `wiring_manifest.mcp[]` instead of
|
|
18781
18833
|
being baked into the code. The set as a WHOLE stays open (a tool owns its own codes).
|
|
@@ -18783,6 +18835,9 @@ components:
|
|
|
18783
18835
|
server that LOST its session, `mcp.tool_declaration_changed` (the server now declares the tool differently — safety axis / read-only reading / the "a person must answer" mark / task support — or no longer lists it) and
|
|
18784
18836
|
`mcp.tool_listing_unreached` (the post-redial listing walk stopped before reaching the tool, so its new declaration cannot be proved). Every later call to that tool is refused the same way until a listing of the connection
|
|
18785
18837
|
reaches it — the way out is `POST /v1/sessions/{id}/mcp/reconnect` (or the engine's refresh); do not resend as-is. The lost-session failure itself stays `http_status` + `httpStatus: 404` + `delivered: "unknown"`.
|
|
18838
|
+
🔴 A CALL that the revocation ledger refuses before its request leaves reads `mcp.server_revoked`, not the word `revoked` (an engine code since core 5.50.0, passed through verbatim - the server has no mint point): the deployment's
|
|
18839
|
+
revocation ledger answered that the server is withdrawn. (When the revocation lands before a 401 or lost-session RE-SEND, the call answers its first attempt's failure code instead.) `revoked` is the failure class of a revoked DIAL and rides `wiring_manifest.mcp[].errorCode`. Read `delivered` together with the code: `no` = no hop was sent;
|
|
18840
|
+
`unknown` = a first hop was sent and a later redirect hop was revoked (in engine 7.68.2 only the A2A peer's redirect loop mints that form, with `a2a.peer_revoked`).
|
|
18786
18841
|
Consumers MUST branch with a `default` arm and MUST NOT exhaustively switch on known values.
|
|
18787
18842
|
The service enforces only a length bound (>128 chars = malformed, the whole key is DROPPED rather
|
|
18788
18843
|
than truncated — truncating would mint a code core never sent). NOTE: this is a DIFFERENT
|
|
@@ -19880,8 +19935,9 @@ components:
|
|
|
19880
19935
|
`insufficient_scope`) / `none` (the authorization seat holds no authorization for this user), the engine's closed set, echoed by the server (read OPEN); `authorizeUrl` only ever comes from the deployment's authorization seat (this deployment
|
|
19881
19936
|
has none, so it is always absent and the sentence points at connector settings); `principal` is the run's principal when it has one. Once per leg per server (a resume is a new leg and may announce again). The same fact on the status faces is
|
|
19882
19937
|
`errorCode: "unauthorized"` + `authorization`. server >= 7.150.0: `reason` / `authorizeUrl` are members of the MCP authorization record and leave through the same disposition table as the status faces (structural slots: they do not pass the
|
|
19883
|
-
detail's free-text redaction and truncation); a `reason` word outside the closed set drops the pair as a whole, so `reason` is PRESENT IFF its word is in the closed set (read `reason` as optional; servers before 7.150.0 always carry it), and `authorizeUrl` is not let through today (always absent). `server` / `principal` / `sessionId` / `runId` stay as they were. NOT on the user whitelist, though core
|
|
19884
|
-
|
|
19938
|
+
detail's free-text redaction and truncation); a `reason` word outside the closed set drops the pair as a whole, so `reason` is PRESENT IFF its word is in the closed set (read `reason` as optional; servers before 7.150.0 always carry it), and `authorizeUrl` is not let through today (always absent). `server` / `principal` / `sessionId` / `runId` stay as they were. NOT on the user whitelist, though core's register holds it: `route.credential_rebound` (the HOST moved a per-model credential's binding, outside any run) is audience `operator` (core 7.59.0 through 7.68.2) — it never reaches this stream.
|
|
19939
|
+
`model.role_defaulted` (a role seat names a model word the catalog does not hold, so the role reads as unset and the run goes on) was audience `operator` in core 7.59.0 - 7.66.x and is `user` since core 7.67.0:
|
|
19940
|
+
server >= 7.153.0 puts it on the stream, `{ seat, role, model, reason, fallback, sessionId, runId? }` (`reason` is `unknown_model_ref` today; read it OPEN).
|
|
19885
19941
|
Value change: `permission.rule_row_dropped`'s `detail.rows[].rule` is, since core 7.53.0, the rule's original text (the same reading as
|
|
19886
19942
|
`allowed_tool_not_granted`'s `entries[].entry`: at most 1 024 code points, longer cut to 1 024 + a truncation mark, CONTROL CHARACTERS RIDE AS DATA —
|
|
19887
19943
|
neutralize at render); before it was the engine-neutralized single-line form (at most 201 code points). Same keys.
|
|
@@ -19961,8 +20017,8 @@ components:
|
|
|
19961
20017
|
with a finish reason the engine does not understand, so the text above may be cut short (`finishReason` = the provider's own word, an OPEN string, passed through verbatim; once per run per word); and
|
|
19962
20018
|
`route.stream_end_ignored` `{statement, word, frames, sessionId, runId}` — the provider had already ended the turn and its stream sent more (`statement` in {`ending`, `error`, `content`}, `word` = the late first
|
|
19963
20019
|
frame's ending reason / error word / content kind, `frames` = how many frames came after the end; the first ending counts, anything later never entered the turn; once per run per (statement, word)).
|
|
19964
|
-
server 7.149.0 (the user-visible whitelist grows 51 -> 52 codes; contract appendix D.3): `config.read_deny_floor_unkept` (the engine's code, passed through;
|
|
19965
|
-
|
|
20020
|
+
server 7.149.0 (the user-visible whitelist grows 51 -> 52 codes; contract appendix D.3): `config.read_deny_floor_unkept` (the engine's code, passed through; core's code book listed audience `operator`
|
|
20021
|
+
through core 7.66.x - this server put it on the run event stream anyway - and lists `user` since core 7.67.0, which server >= 7.153.0 carries) - this run WENT AHEAD while its read-deny rules are not byte-enforced (the read-deny table has rows, the execution environment does not
|
|
19966
20022
|
keep the byte floor, `READ_DENY_FLOOR_REQUIRED` is not set; when it is set the run does not go: the synchronous `POST /v1/tasks` answers 409 with the same code). `detail` =
|
|
19967
20023
|
`{ rowCount, sessionId, runId }` - the table's row count and the run it speaks of (a ladder level / verifier / subagent leg is its own run id); `message` is rewritten by the server per lane.
|
|
19968
20024
|
The same `{ code, message }` pair lands once more on the terminal result as `readDenyFloor` (`TaskResult.readDenyFloor`).
|
|
@@ -20983,7 +21039,7 @@ components:
|
|
|
20983
21039
|
# 当天,一个**合法**的审批卡就会被严格消费端拒收。`x-open-enum` 只是意图标记,不解除 enum 的执法 ——
|
|
20984
21040
|
# 这正是本车刚从 `CheckpointGate` 拆掉的那个假开集,不在这里换个地方重犯。
|
|
20985
21041
|
# 闭集**执法**只属于**筛过的**那一面(`GateOutcome.origin`:引擎的 `screenGateOutcome` 判成员,
|
|
20986
|
-
# 出集即整条不上帧),所以那张 enum
|
|
21042
|
+
# 出集即整条不上帧),所以那张 enum 落在**那个引用点**,恰一处。已知词见下面的描述。
|
|
20987
21043
|
description: >
|
|
20988
21044
|
WHO raised an ask (`ApprovalRequestLiveFacts.origin`; server >= 7.57.0 / core 7.5.0) — core's
|
|
20989
21045
|
`ASK_ORIGINS`, ENGINE-STAMPED at the gate (core's words: "engine-stamped at the gate, never a policy's
|
|
@@ -21016,13 +21072,19 @@ components:
|
|
|
21016
21072
|
and it never reaches an approver as an `AskRequest`); only the plan pause's decide lane stamps it, so the decided row's record
|
|
21017
21073
|
names the ask it settled.
|
|
21018
21074
|
|
|
21075
|
+
🔴 core 7.67.0 ADDS A THIRTEENTH WORD (server >= 7.153.0), between `denial_limit_fallback` and `shell_gate_tighten`: `integrity_guard` = an
|
|
21076
|
+
always-on engine integrity guard put the question in its own words — a removal of a protected location, an unverifiable recursive delete,
|
|
21077
|
+
shell text the engine cannot read, a write to the session transcript. The same ask carries one `askReasons` entry `{ by: "integrity_guard", words }`
|
|
21078
|
+
with the card's sentence. The engine pins the real-approval bit on these asks at the guard's two mint sites; this word is a transcription,
|
|
21079
|
+
not a permission rule.
|
|
21080
|
+
|
|
21019
21081
|
The SAME type is the `origin` member of `GateOutcome` on `tool_end` — one vocabulary, two faces.
|
|
21020
21082
|
|
|
21021
21083
|
server >= 7.102.0 (S-755 / cli L-695 / C-R111): the word now also rides the `livePending` row top level
|
|
21022
21084
|
(read once with the frame's) and the operator queue row (`GET /v1/approvals` `pending[]` + the `/stream`
|
|
21023
21085
|
`pending` frame — the park-row twin seat, screened by core's `isAskOrigin`), besides the frame and the inbox
|
|
21024
21086
|
row — five faces, one word. `card_json` / the `approval_request` frame still do not carry it (the card is
|
|
21025
|
-
`.strict()`). The known words (
|
|
21087
|
+
`.strict()`). The known words (thirteen from core 7.67.0) are exported at runtime as the SDK's `ASK_ORIGINS` (core
|
|
21026
21088
|
`ASK_ORIGINS`, verbatim and in order) — known words, NOT an enforcement table.
|
|
21027
21089
|
|
|
21028
21090
|
AllowRuleMember:
|
|
@@ -21926,7 +21988,7 @@ components:
|
|
|
21926
21988
|
additionalProperties: false
|
|
21927
21989
|
required: [by, words]
|
|
21928
21990
|
properties:
|
|
21929
|
-
by: { type: string, enum: [content_question, plan_review, ancestor_marked, org_unavailable, org_rule, rule_store_unavailable, ask_rule, denial_limit_fallback, shell_gate_tighten, safety_tighten, policy], description: 'AskOrigin words minus `hook` (the server card schema''s table; an entry outside it withholds the whole seat).' }
|
|
21991
|
+
by: { type: string, enum: [content_question, plan_review, ancestor_marked, org_unavailable, org_rule, rule_store_unavailable, ask_rule, denial_limit_fallback, integrity_guard, shell_gate_tighten, safety_tighten, policy], description: 'AskOrigin words minus `hook` (the server card schema''s table; an entry outside it withholds the whole seat).' }
|
|
21930
21992
|
words: { type: string }
|
|
21931
21993
|
|
|
21932
21994
|
HookQuestionCause:
|
|
@@ -22074,18 +22136,25 @@ components:
|
|
|
22074
22136
|
server >= 7.152.0 — the 200 of the decision door on a PARKED ask (the card's window ended and it moved to background standby): the answer goes through the durable redemption leg (the same CAS as
|
|
22075
22137
|
POST /v1/approvals/{sessionId}/decide) and the body is that leg's receipt (ApprovalDecisionResult keys, e.g. `status` / `taskId` / `sessionId`) plus this door's keys. Discriminant: `accepted: "parked_redeemed"`.
|
|
22076
22138
|
`idempotent: true` only on a replay (the same redeemed card answered again).
|
|
22139
|
+
Server >= 7.155.0: this door's `taskId` stays the path's turn, and the receipt's own `taskId` (the run / handle carrying the decision:
|
|
22140
|
+
the task-level run resumed / the revived background-agent handle / the running host turn carrying a workflow-member decision) moves to
|
|
22141
|
+
`carrierTaskId` (absent when the receipt has none — the workflow-member `recorded` word). It is not evidence that anything resumed. On a workflow-member card `status` is
|
|
22142
|
+
`recorded` / `delivered` with `runId` / `decisionId` (the same receipt as /decide; `WorkflowParkDecisionReceipt`).
|
|
22077
22143
|
required: [askId, taskId, decision, decidedAtMs, actor, accepted]
|
|
22078
22144
|
additionalProperties: false # closed like its sibling arm: the key set is ApprovalDecisionResult's own keys (by $ref) plus this door's keys
|
|
22079
22145
|
properties:
|
|
22080
22146
|
askId: { type: string }
|
|
22081
|
-
taskId: { type: string }
|
|
22147
|
+
taskId: { type: string, description: 'This door''s echo key: the turn the ask (the path) belongs to — on every server version. The run / handle carrying the decision is `carrierTaskId`.' }
|
|
22148
|
+
carrierTaskId: { type: string, description: 'server >= 7.155.0 - the redemption receipt''s own `taskId`, i.e. the run / handle carrying this decision: the task-level run resumed / the revived background-agent handle (`a*`) / on a workflow-member `delivered`, the running host turn carrying it (in the run store). It can appear on all three redemption lanes. It is NOT evidence that anything resumed: it only names where the decision was handed. Absent when the receipt has no `taskId` (workflow-member `recorded`); older servers never send it (this door''s `taskId` overwrote it).' }
|
|
22149
|
+
runId: { $ref: '#/components/schemas/ApprovalDecisionResult/properties/runId' }
|
|
22150
|
+
decisionId: { $ref: '#/components/schemas/ApprovalDecisionResult/properties/decisionId' }
|
|
22082
22151
|
decision: { $ref: '#/components/schemas/ApprovalAskDecision' }
|
|
22083
22152
|
decidedAtMs: { type: integer }
|
|
22084
22153
|
actor: { $ref: '#/components/schemas/ActorAssertion' }
|
|
22085
22154
|
accepted: { type: string, enum: [parked_redeemed] }
|
|
22086
22155
|
decisionNote: { type: string }
|
|
22087
22156
|
noteRecorded: { type: boolean }
|
|
22088
|
-
rememberApplied: { type: boolean, description: 'server >= 7.152.0: only when the request carried `remember` and this was the FIRST redemption.' }
|
|
22157
|
+
rememberApplied: { type: boolean, description: 'server >= 7.152.0: only when the request carried `remember` and this was the FIRST redemption. Always `false` on a workflow-member card (the `recorded` / `delivered` receipts of server >= 7.155.0): that lane cannot record the grant, so this door takes the decision and allows this once; no exemption is stored. (The same request on POST /v1/approvals/{sessionId}/decide is answered 400 `decide.workflow_remember_unsupported` on a workflow-member card, so the /decide workflow-member arms never carry this key.)' }
|
|
22089
22158
|
rulePersisted: { type: boolean }
|
|
22090
22159
|
ruleRefusal: { $ref: '#/components/schemas/RuleRefusalReason' }
|
|
22091
22160
|
persistedRule: { type: string }
|
|
@@ -22900,9 +22969,10 @@ components:
|
|
|
22900
22969
|
ParkedDecideAccepted:
|
|
22901
22970
|
description: >
|
|
22902
22971
|
The 200 body of POST /v1/approvals/{sessionId}/decide when the pending checkpoint belongs to a
|
|
22903
|
-
PARKED background agent (server 1.267, ASSISTANT-WIRE-CONTRACT §4a parked variant; server
|
|
22904
|
-
parked-decide.ts — exact literal shapes).
|
|
22905
|
-
(1)
|
|
22972
|
+
PARKED child: a background agent (server 1.267, ASSISTANT-WIRE-CONTRACT §4a parked variant; server
|
|
22973
|
+
parked-decide.ts — exact literal shapes) or, server >= 7.155.0, a workflow member. FOUR ARMS, read by `status` (the SDK type
|
|
22974
|
+
`ParkedDecideAccepted` is their union; arms (1) / (2) are the background agent's, arms (3) / (4) the workflow member's):
|
|
22975
|
+
(1) `status: "resuming"` — the background agent's ACCEPTANCE receipt. The revive drives ASYNCHRONOUSLY — 200 means accepted,
|
|
22906
22976
|
not completed; a failed drive honestly re-parks the row and the pending re-appears on the list.
|
|
22907
22977
|
(2) `status: "failed"` (server >= 7.136.0; `decision` is always `deny`) — the VOIDED receipt: on the two forms that can
|
|
22908
22978
|
never revive (a parked child whose row carries no agent name — an unnamed `Agent` call — or no root-session anchor)
|
|
@@ -22910,8 +22980,15 @@ components:
|
|
|
22910
22980
|
the child ends `failed` (the engine's reconcile), the gated tool never runs, no `remember` is granted — and NOTHING is
|
|
22911
22981
|
resuming. Do not wait for a revive that never comes. APPROVE on those forms stays `409 decide.row_unrevivable`; a lost
|
|
22912
22982
|
void CAS is the existing `409 decide.gate_moved`.
|
|
22913
|
-
|
|
22914
|
-
|
|
22983
|
+
(3) / (4) server >= 7.155.0, a PARKED WORKFLOW-MEMBER card: `status: "recorded"` / `"delivered"` — the two arms of
|
|
22984
|
+
`WorkflowParkDecisionReceipt` (fixed key sets; `recorded` has no `taskId` / `sessionId`). Both cards look the same on the queue
|
|
22985
|
+
(no origin mark), so this is one union over four words. SERVER-VERSION RANGES: servers [7.148.0, 7.155.0) answered a
|
|
22986
|
+
workflow-member card whose holding run was still running with arm (1)'s exact key set, `taskId` then being the workflow run id
|
|
22987
|
+
(not in the run store); servers [7.69.0, 7.155.0) answered one whose run had ended with the task-level acceptance shape
|
|
22988
|
+
(no `decision`; not an arm of this union — read it on `ApprovalDecisionResult`). From 7.155.0 arm (1) is background agents only.
|
|
22989
|
+
Task-level suspends answer their own shapes (see `ApprovalDecisionResult`): outside the replay shape, a parked receipt is
|
|
22990
|
+
the one with `decision` present; then read `status`. (The older reading "`decision` present and `sessionId` absent" fails
|
|
22991
|
+
on the `delivered` arm, which carries `sessionId`.)
|
|
22915
22992
|
oneOf:
|
|
22916
22993
|
- type: object
|
|
22917
22994
|
required: [taskId, status, decision]
|
|
@@ -22933,6 +23010,59 @@ components:
|
|
|
22933
23010
|
decisionCommitted: { type: boolean, enum: [true], description: 'server >= 7.138.0 - SETTLEMENT EVIDENCE: `true` = the gate this request named was durably settled with THIS request''s decision (historical evidence, not the card''s current state). Always the literal `true`, never `false`. Absent = unprovable or deliberately omitted => read as "not committed" (fail-closed); do not infer it from the absence of `errorCode`. It coexists with `errorCode: cancelled` / `retriable: true`; `retriable: true` only says the run re-parked.' }
|
|
22934
23011
|
checkpointId: { type: string, description: 'server >= 7.138.0 - only alongside `decisionCommitted`: the gate identity of the row selected before execution (same name and value as the operator queue / inbox row / park ledger row). Absent when the identity is unreadable or not applicable (an idempotent replay carries none); absence infers nothing.' }
|
|
22935
23012
|
checkpointIdMissing: { $ref: '#/components/schemas/CheckpointIdMissingWord' }
|
|
23013
|
+
- $ref: '#/components/schemas/WorkflowParkDecisionRecorded'
|
|
23014
|
+
- $ref: '#/components/schemas/WorkflowParkDecisionDelivered'
|
|
23015
|
+
|
|
23016
|
+
WorkflowParkDecisionReceipt:
|
|
23017
|
+
description: >
|
|
23018
|
+
server >= 7.155.0 — the 200 of POST /v1/approvals/{sessionId}/decide on a PARKED WORKFLOW-MEMBER card whose decision row was
|
|
23019
|
+
written (the per-ask decision door answers the same receipt on its parked form, with its own `taskId` and the receipt's
|
|
23020
|
+
`taskId` moved to `carrierTaskId`). TWO ARMS, closed, read by `status` (words: the SDK constant
|
|
23021
|
+
`WORKFLOW_PARK_DECISION_RECEIPT_STATUSES`); each arm has a FIXED key set. The words say only what held on the server when it
|
|
23022
|
+
answered: `recorded` = the decision is recorded as this card's decision and addressed to `runId`, and no running host turn
|
|
23023
|
+
carries it; `delivered` = recorded, AND a running host-session turn (`taskId`, in the run store) carries it. Neither means the
|
|
23024
|
+
gate is resolved: the card can still be listed after the 200. Whether the engine used the decision is not on the receipt —
|
|
23025
|
+
match `decisionId` against the engine notice `workflow.parked_decision_unused` `detail.decisionIds`. A 200 where nothing was
|
|
23026
|
+
recorded (the carrying turn was cancelled before the row landed: `{status:"failed", errorCode:"cancelled", …}`) and the replay
|
|
23027
|
+
shape after the card settled (`idempotent: true`) are not arms of this union. Also arms (3) / (4) of `ParkedDecideAccepted`.
|
|
23028
|
+
oneOf:
|
|
23029
|
+
- $ref: '#/components/schemas/WorkflowParkDecisionRecorded'
|
|
23030
|
+
- $ref: '#/components/schemas/WorkflowParkDecisionDelivered'
|
|
23031
|
+
|
|
23032
|
+
WorkflowParkDecisionReceiptStatus:
|
|
23033
|
+
type: string
|
|
23034
|
+
enum: [recorded, delivered]
|
|
23035
|
+
description: 'server >= 7.155.0 — the closed word set of `WorkflowParkDecisionReceipt.status` (SDK constant `WORKFLOW_PARK_DECISION_RECEIPT_STATUSES`, in this order).'
|
|
23036
|
+
|
|
23037
|
+
WorkflowParkDecisionRecorded:
|
|
23038
|
+
type: object
|
|
23039
|
+
description: 'server >= 7.155.0 — the `recorded` arm of `WorkflowParkDecisionReceipt`: exactly five receipt keys, all required; NO `taskId` / `sessionId` (not "unreadable": this word''s key set has none). The only optional keys are the request-conditioned rule slot (`rulePersisted` / `ruleRefusal`, present only when the request carried `persistRule`).'
|
|
23040
|
+
required: [status, runId, decisionId, decision, bindingEnforced]
|
|
23041
|
+
additionalProperties: false
|
|
23042
|
+
properties:
|
|
23043
|
+
status: { type: string, enum: [recorded] }
|
|
23044
|
+
runId: { type: string, description: 'The workflow run the decision is addressed to (the run holding the card; GET /v1/workflows/{runId} — it is not in the run store).' }
|
|
23045
|
+
decisionId: { type: string, description: 'Opaque id of this decision (same value on a replay of the same decision; a new one for every new human decision) — the same id as the engine notice `workflow.parked_decision_unused` `detail.decisionIds`.' }
|
|
23046
|
+
decision: { type: string, enum: [approve, deny] }
|
|
23047
|
+
bindingEnforced: { type: boolean, enum: [true] }
|
|
23048
|
+
rulePersisted: { type: boolean, enum: [false], description: 'Request-conditioned rule slot: present only when the request carried `persistRule`; always `false` on this lane (the server cannot prove the engine committed the decision when it answers, so the rule is not stored). The verdict itself stands. Not a discriminant.' }
|
|
23049
|
+
ruleRefusal: { type: string, enum: [rule_lane_unavailable], description: 'Present with `rulePersisted` (and only then): always `rule_lane_unavailable` on this lane.' }
|
|
23050
|
+
|
|
23051
|
+
WorkflowParkDecisionDelivered:
|
|
23052
|
+
type: object
|
|
23053
|
+
description: 'server >= 7.155.0 — the `delivered` arm of `WorkflowParkDecisionReceipt`: the five `recorded` receipt keys plus `taskId` and `sessionId`, exactly seven receipt keys, all required; the only optional keys are the same request-conditioned rule slot as on `recorded`.'
|
|
23054
|
+
required: [status, taskId, sessionId, runId, decisionId, decision, bindingEnforced]
|
|
23055
|
+
additionalProperties: false
|
|
23056
|
+
properties:
|
|
23057
|
+
status: { type: string, enum: [delivered] }
|
|
23058
|
+
taskId: { type: string, description: 'The running host-session turn that carries the decision — always a run in the run store (GET /v1/runs/{taskId} / events).' }
|
|
23059
|
+
sessionId: { type: string, description: 'The session of `taskId` (the host session).' }
|
|
23060
|
+
runId: { type: string, description: 'The workflow run the decision is addressed to (as on `recorded`).' }
|
|
23061
|
+
decisionId: { type: string, description: 'As on `recorded`.' }
|
|
23062
|
+
decision: { type: string, enum: [approve, deny] }
|
|
23063
|
+
bindingEnforced: { type: boolean, enum: [true] }
|
|
23064
|
+
rulePersisted: { type: boolean, enum: [false], description: 'As on `recorded`: request-conditioned, always `false` on this lane.' }
|
|
23065
|
+
ruleRefusal: { type: string, enum: [rule_lane_unavailable], description: 'As on `recorded`.' }
|
|
22936
23066
|
|
|
22937
23067
|
FleetMeta:
|
|
22938
23068
|
type: object
|
|
@@ -23929,11 +24059,12 @@ components:
|
|
|
23929
24059
|
additionalProperties: false
|
|
23930
24060
|
required: [reason]
|
|
23931
24061
|
description: >
|
|
23932
|
-
server >= 7.138.0 (core 7.59.0 `McpAuthorization`) — an MCP server the principal must authorize first. Rides WITH `errorCode: "unauthorized"` on three
|
|
24062
|
+
server >= 7.138.0 (core 7.59.0 `McpAuthorization`) — an MCP server the principal must authorize first. Rides WITH `errorCode: "unauthorized"` on six faces over three row schemas: the `WiringManifestMcpEntry` row (`wiring_manifest.mcp[]`, the `lastLegMcp.mcp[]` of the session MCP panel, and the `servers[]` of `GET /v1/capabilities/mcp` and
|
|
24063
|
+
`POST /v1/capabilities/mcp/probe` through `McpProbeFaceRow`), the reconnect receipt's `status`
|
|
23933
24064
|
and the `GET /v1/sessions/{sessionId}/mcp` panel's `servers[]` (the panel row carries no `errorCode`, so presence there reads "this server is unauthorized"). ONLY the closed word `reason` leaves the server: the engine record's two
|
|
23934
24065
|
addresses (`authorizeUrl` — only ever from the deployment's authorization seat, which this deployment does not have — and `resourceMetadataUrl`, which the remote self-reports in its challenge header and is untrusted) never go on the wire.
|
|
23935
24066
|
A record whose word is outside the set, or that is not an object, is absent as a whole (the weakest claim, no minted word). The user-facing "go authorize" is the session notice `mcp.authorization_required`.
|
|
23936
|
-
server >= 7.150.0: every projection face of the record reads this one disposition table — the
|
|
24067
|
+
server >= 7.150.0: every projection face of the record reads this one disposition table (the server's self-minted registry lists nine faces in all) — the six faces above, plus the session history (`GET /v1/sessions/{sessionId}` `messages[].details.authorization`, a tool-result card whose `details.code` is
|
|
23937
24068
|
`unauthorized`) and `tool_end.structured.authorization` (`GET /v1/runs/{runId}/events` and SSE `tool_end`, a self-registered card whose `structured.code` is `unauthorized`): both carry ONLY `{ reason }`. On <= 7.149.x the history also carried the remote's
|
|
23938
24069
|
self-reported `resourceMetadataUrl` and `tool_end.structured.authorization` carried any card member that passed the text redactor; neither member is declared by this contract (`details` / `structured` are open bags), so a reader of
|
|
23939
24070
|
`authorization.resourceMetadataUrl` there reads `undefined` on >= 7.150.0. No knob.
|
|
@@ -23962,7 +24093,7 @@ components:
|
|
|
23962
24093
|
description: >
|
|
23963
24094
|
core >= 7.6.0 — the `McpFailureKind` word (`connect_refused` / `connection_failed` /
|
|
23964
24095
|
`connection_closed` / `unauthorized` / `http_status` / `not_mcp_response` / `spawn_failed` / `timeout` /
|
|
23965
|
-
`protocol` / `invalid_config` / `credential_unavailable` / `host_refused` / `unknown`; server >= 7.139.0 (core 7.60.0): `host_refused` = the host seat of a host-supplied transport did not hand the request to the remote (nothing was
|
|
24096
|
+
`protocol` / `invalid_config` / `credential_unavailable` / `host_refused` / `revoked` / `unknown`; `revoked` (core 7.67.0, servers embedding it, >= 7.153.0) = the deployment's revocation ledger answered that the server or peer is withdrawn when the engine went to dial it, so the dial was refused and nothing was sent (`delivered: "no"`; a CALL the ledger refuses before its request leaves is `mcp.server_revoked` on `tool_end.errorCode`, not this word); server >= 7.139.0 (core 7.60.0): `host_refused` = the host seat of a host-supplied transport did not hand the request to the remote (nothing was
|
|
23966
24097
|
sent; no deployment of this server mounts one today, the word is the engine's); server >= 7.138.0: `unauthorized` = the principal must authorize this server
|
|
23967
24098
|
first — the endpoint answered 401 (after the deployment's peer seat was asked once more) or a 403 with an `insufficient_scope` challenge, or the peer
|
|
23968
24099
|
seat answered that the principal is not authorized here; earlier servers sent the first two as `http_status`; `credential_unavailable` = the
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sema-agent/sdk",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "45.0.0",
|
|
4
4
|
"description": "Typed, zero-runtime-dependency SDK for the Sema agent fleet usage plane. The shared substrate for all doors (CC/Codex MCP façade + web). Server-side only — tokens never enter the browser.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "BUSL-1.1",
|