@managoat/fountain-sdk 4.0.0 → 5.1.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/CHANGELOG.md CHANGED
@@ -11,6 +11,53 @@ server releases.
11
11
 
12
12
  ---
13
13
 
14
+ ## [5.1.0] — 2026-09-14
15
+
16
+ ### Added
17
+
18
+ - `components["schemas"]["PermissionPolicy"]`. The permission-policy object was
19
+ declared inline in five server schemas; it is now one named component that
20
+ all five reference, so the generated type has a name instead of being
21
+ repeated as an anonymous intersection. The named type includes `null`, which
22
+ is what a policy-less agent or conversation carries.
23
+
24
+ ### Changed
25
+
26
+ - `permission_policy` on `Agent`, `AgentRequest`, `AgentUpdate`, `Conversation`
27
+ and `ConversationCreateRequest` is typed as
28
+ `components["schemas"]["PermissionPolicy"] | null`. It resolves to exactly
29
+ the type 5.0.0 had, so this is a rename and not a new shape: TypeScript is
30
+ structurally typed and existing code keeps compiling. Code that wrote the old
31
+ anonymous type out by hand can use the named one instead.
32
+
33
+ ## [5.0.0] — 2026-09-14
34
+
35
+ ### Breaking changes
36
+
37
+ - The public `Block.body` type now includes an array of plan entries alongside
38
+ `string | null | undefined`. Existing code that calls string methods on
39
+ `body` must check its type first. Checking `block.kind` alone does not narrow
40
+ `body`, because the generated `Block` type is not a discriminated union.
41
+
42
+ Replace `block.body?.trim() ?? ""` with a body-type check:
43
+
44
+ ```ts
45
+ function text(block: Block): string {
46
+ if (block.kind !== "text") return "";
47
+ return typeof block.body === "string" ? block.body.trim() : "";
48
+ }
49
+ ```
50
+
51
+ Read checklist entries only when `block.kind === "plan"` and
52
+ `Array.isArray(block.body)`. Each array is the full ordered snapshot;
53
+ an empty array clears the checklist.
54
+
55
+ ### Added
56
+
57
+ - `plan` blocks with full checklist arrays in `body`. Streaming block events
58
+ preserve the checklist, and the turn follower keeps it out of the
59
+ assistant's text.
60
+
14
61
  ## [4.0.0] — 2026-09-14
15
62
 
16
63
  ### Breaking changes
package/README.md CHANGED
@@ -435,7 +435,7 @@ does not have, publishes it, and tags the merge commit `sdk-v<version>`.
435
435
  A PR that touches only tests, examples or the changelog needs no bump; the
436
436
  gate stays quiet, and the publish workflow finds nothing to do. To change the
437
437
  published surface deliberately without releasing, label the PR
438
- `sdk-no-release`.
438
+ `release:skip-sdk`.
439
439
 
440
440
  ## License
441
441
 
@@ -2781,12 +2781,7 @@ export interface components {
2781
2781
  model: string | null;
2782
2782
  name: string;
2783
2783
  /** @description Per-tool permission policy: a map of key to verdict, plus an optional "default" key. A key is matched against the tool card's title first and then ACP's kind (execute, edit, read, fetch, …); prefer a kind, because claude titles a tool call with the command it is about to run. Unset keys fall back to the default, and an unset default is auto_allow — today's behaviour. "ask" holds the tool until a human answers it on the conversation stream, and denies if nobody does before the timeout. A runtime that never asks (opencode) refuses anything stricter than auto_allow with 422 permission_policy_unenforceable. */
2784
- permission_policy?: ({
2785
- /** @description Seconds a permission request that outlived its turn waits before it is denied (#1635). Names no tool, so it is the one key whose value is a number rather than a verdict, which is why the value schema below is a union. Absent leaves the global ask timeout. A request may shorten it with `_meta.fountain.timeout` on its own session/request_permission, and may not lengthen it. A launch may only shorten what the agent set, or the global ask timeout where the agent set nothing. Capped at a year, which is where the deadline stops fitting in a timestamp rather than a limit on how long a wait is useful. */
2786
- ask_timeout?: number;
2787
- } & {
2788
- [key: string]: ("auto_allow" | "ask" | "auto_deny") | number;
2789
- }) | null;
2784
+ permission_policy?: components["schemas"]["PermissionPolicy"] | null;
2790
2785
  /** @enum {string} */
2791
2786
  runtime: "claude" | "codex" | "gemini" | "opencode" | "acp" | "fountain-fixture";
2792
2787
  /** @description The command the acp runtime launches inside the sandbox, as a shell line resolved there (for example `chant acp`). Required when runtime is acp, and rejected on every other runtime, which resolves its own executable. A free string by design: it runs under the same isolation as an environment's setup script. */
@@ -2846,12 +2841,7 @@ export interface components {
2846
2841
  model?: string | null;
2847
2842
  name: string;
2848
2843
  /** @description Per-tool permission policy: a map of key to verdict, plus an optional "default" key. A key is matched against the tool card's title first and then ACP's kind (execute, edit, read, fetch, …); prefer a kind, because claude titles a tool call with the command it is about to run. Unset keys fall back to the default, and an unset default is auto_allow. "ask" holds the tool until a human answers it on the conversation stream, and denies if nobody does before the timeout. A conversation may narrow this at launch, never widen it. A runtime that never asks (opencode) refuses anything stricter than auto_allow with 422 permission_policy_unenforceable. */
2849
- permission_policy?: ({
2850
- /** @description Seconds a permission request that outlived its turn waits before it is denied (#1635). Names no tool, so it is the one key whose value is a number rather than a verdict, which is why the value schema below is a union. Absent leaves the global ask timeout. A request may shorten it with `_meta.fountain.timeout` on its own session/request_permission, and may not lengthen it. A launch may only shorten what the agent set, or the global ask timeout where the agent set nothing. Capped at a year, which is where the deadline stops fitting in a timestamp rather than a limit on how long a wait is useful. */
2851
- ask_timeout?: number;
2852
- } & {
2853
- [key: string]: ("auto_allow" | "ask" | "auto_deny") | number;
2854
- }) | null;
2844
+ permission_policy?: components["schemas"]["PermissionPolicy"] | null;
2855
2845
  /** @enum {string} */
2856
2846
  runtime: "claude" | "codex" | "gemini" | "opencode" | "acp" | "fountain-fixture";
2857
2847
  /** @description The command the acp runtime launches inside the sandbox, as a shell line resolved there (for example `chant acp`). Required when runtime is acp, and rejected on every other runtime, which resolves its own executable. A free string by design: it runs under the same isolation as an environment's setup script. */
@@ -2908,12 +2898,7 @@ export interface components {
2908
2898
  model?: string | null;
2909
2899
  name?: string;
2910
2900
  /** @description Per-tool permission policy: a map of key to verdict, plus an optional "default" key. A key is matched against the tool card's title first and then ACP's kind (execute, edit, read, fetch, …); prefer a kind, because claude titles a tool call with the command it is about to run. Unset keys fall back to the default, and an unset default is auto_allow. "ask" holds the tool until a human answers it on the conversation stream, and denies if nobody does before the timeout. A conversation may narrow this at launch, never widen it. A runtime that never asks (opencode) refuses anything stricter than auto_allow with 422 permission_policy_unenforceable. */
2911
- permission_policy?: ({
2912
- /** @description Seconds a permission request that outlived its turn waits before it is denied (#1635). Names no tool, so it is the one key whose value is a number rather than a verdict, which is why the value schema below is a union. Absent leaves the global ask timeout. A request may shorten it with `_meta.fountain.timeout` on its own session/request_permission, and may not lengthen it. A launch may only shorten what the agent set, or the global ask timeout where the agent set nothing. Capped at a year, which is where the deadline stops fitting in a timestamp rather than a limit on how long a wait is useful. */
2913
- ask_timeout?: number;
2914
- } & {
2915
- [key: string]: ("auto_allow" | "ask" | "auto_deny") | number;
2916
- }) | null;
2901
+ permission_policy?: components["schemas"]["PermissionPolicy"] | null;
2917
2902
  /** @enum {string} */
2918
2903
  runtime?: "claude" | "codex" | "gemini" | "opencode" | "acp" | "fountain-fixture";
2919
2904
  /** @description The command the acp runtime launches inside the sandbox, as a shell line resolved there (for example `chant acp`). Required when runtime is acp, and rejected on every other runtime, which resolves its own executable. A free string by design: it runs under the same isolation as an environment's setup script. */
@@ -3191,14 +3176,23 @@ export interface components {
3191
3176
  };
3192
3177
  /**
3193
3178
  * Block
3194
- * @description One structured piece of a log event's output — the same parse the web UI renders (`Fountain.Conversations.Blocks`). `kind` decides the other fields: `text`/`thinking` carry `body`; `tool_use` carries `id`, `name`, `summary`, `body` (the input); `tool_result` carries `tool_id`, `body`, `error` and pairs with the `tool_use` of the same id; `init` carries `summary`, `body`; `result` carries `body`, `raw`; `error` carries `body`; `raw` carries `body`, `summary`; `permission_request` carries `request_id`, `name`, `summary` and `options` — the agent is blocked on it, and a client answers with POST /api/conversations/{id}/requests/{request_id}. Render only the options in `options`; never synthesise one the agent did not offer.
3179
+ * @description One structured piece of a log event's output — the same parse the web UI renders (`Fountain.Conversations.Blocks`). `kind` decides the other fields: `text`/`thinking` carry `body`; `plan` carries the full ordered checklist in `body` (entries with `content`, `status`, and optional `priority`, `id`, `activeForm`); `tool_use` carries `id`, `name`, `summary`, `body` (the input); `tool_result` carries `tool_id`, `body`, `error` and pairs with the `tool_use` of the same id; `init` carries `summary`, `body`; `result` carries `body`, `raw`; `error` carries `body`; `raw` carries `body`, `summary`; `permission_request` carries `request_id`, `name`, `summary` and `options` — the agent is blocked on it, and a client answers with POST /api/conversations/{id}/requests/{request_id}. Render only the options in `options`; never synthesise one the agent did not offer.
3195
3180
  */
3196
3181
  Block: {
3197
- body?: string | null;
3182
+ body?: (string | null) | ({
3183
+ activeForm?: string;
3184
+ content: string;
3185
+ id?: string;
3186
+ priority?: string;
3187
+ /** @enum {string} */
3188
+ status: "pending" | "in_progress" | "completed";
3189
+ } & {
3190
+ [key: string]: unknown;
3191
+ })[];
3198
3192
  error?: boolean | null;
3199
3193
  id?: string | null;
3200
3194
  /** @enum {string} */
3201
- kind: "text" | "thinking" | "tool_use" | "tool_result" | "init" | "result" | "error" | "raw" | "permission_request";
3195
+ kind: "text" | "thinking" | "tool_use" | "tool_result" | "init" | "result" | "error" | "raw" | "permission_request" | "plan";
3202
3196
  name?: string | null;
3203
3197
  /** @description permission_request only: the options the agent offered, in its order. Each carries at least `optionId` and `kind` (allow_once, allow_always, reject_once, reject_always, ...). */
3204
3198
  options?: {
@@ -3714,12 +3708,7 @@ export interface components {
3714
3708
  /** @description Permission requests that outlived a turn and are still waiting for an answer (#1635). Served on GET /api/conversations/{id} only; absent from the list and from the create response. */
3715
3709
  pending_requests?: components["schemas"]["PendingPermissionRequest"][];
3716
3710
  /** @description The per-launch permission override this conversation was started with, or null if it had none. The policy actually in force is this merged with the agent's, taking the stricter of the two per tool. */
3717
- permission_policy?: ({
3718
- /** @description Seconds a permission request that outlived its turn waits before it is denied (#1635). Names no tool, so it is the one key whose value is a number rather than a verdict, which is why the value schema below is a union. Absent leaves the global ask timeout. A request may shorten it with `_meta.fountain.timeout` on its own session/request_permission, and may not lengthen it. A launch may only shorten what the agent set, or the global ask timeout where the agent set nothing. Capped at a year, which is where the deadline stops fitting in a timestamp rather than a limit on how long a wait is useful. */
3719
- ask_timeout?: number;
3720
- } & {
3721
- [key: string]: ("auto_allow" | "ask" | "auto_deny") | number;
3722
- }) | null;
3711
+ permission_policy?: components["schemas"]["PermissionPolicy"] | null;
3723
3712
  /** @enum {string} */
3724
3713
  runtime: "claude" | "codex" | "gemini" | "opencode" | "acp" | "fountain-fixture";
3725
3714
  runtime_session_id?: string | null;
@@ -3735,7 +3724,7 @@ export interface components {
3735
3724
  source?: "ui" | "api" | "agent";
3736
3725
  /** @enum {string} */
3737
3726
  status: "pending" | "running" | "idle" | "failed" | "terminated";
3738
- /** @description Generated from the first turn; null until one exists. */
3727
+ /** @description Optional display title, set explicitly or supplied by the harness over ACP. Harness titles may be revised or cleared; null when no title is set. */
3739
3728
  title?: string | null;
3740
3729
  turn_count?: number;
3741
3730
  /** @description last_active_at is later than last_read_at (true if never read). */
@@ -3771,12 +3760,7 @@ export interface components {
3771
3760
  [key: string]: string;
3772
3761
  } | null;
3773
3762
  /** @description Per-launch permission override (#939). Keys are matched against the tool card's title first and then ACP's kind (execute, edit, read, fetch, …); "default" covers the rest. Prefer a kind: claude titles a tool call with the command it is about to run, so a title matches one invocation only. Merged with the agent's own policy, taking the stricter of the two. It may only narrow: a policy that would loosen any tool is refused with 422 permission_policy_widens rather than silently clamped, and one the runtime never consults is refused with 422 permission_policy_unenforceable. */
3774
- permission_policy?: ({
3775
- /** @description Seconds a permission request that outlived its turn waits before it is denied (#1635). Names no tool, so it is the one key whose value is a number rather than a verdict, which is why the value schema below is a union. Absent leaves the global ask timeout. A request may shorten it with `_meta.fountain.timeout` on its own session/request_permission, and may not lengthen it. A launch may only shorten what the agent set, or the global ask timeout where the agent set nothing. Capped at a year, which is where the deadline stops fitting in a timestamp rather than a limit on how long a wait is useful. */
3776
- ask_timeout?: number;
3777
- } & {
3778
- [key: string]: ("auto_allow" | "ask" | "auto_deny") | number;
3779
- }) | null;
3763
+ permission_policy?: components["schemas"]["PermissionPolicy"] | null;
3780
3764
  /** @description Optional first turn prompt. A launch may open with no prompt at all, but a prompt that is present must carry words: blank and whitespace-only text is refused with 422 invalid_prompt, before the launch reserves a sandbox. */
3781
3765
  prompt?: string;
3782
3766
  /** @description When a fresh start reaches the tenant or the fleet concurrency ceiling, wait in the bounded sandbox queue and return 202 with a SandboxRequest instead of 429 or 503 (ADR 0042). Starts carrying images or an explicit sandbox_id are never queued, and a full queue keeps the immediate error. */
@@ -4389,6 +4373,16 @@ export interface components {
4389
4373
  /** @example true */
4390
4374
  ok: boolean;
4391
4375
  };
4376
+ /**
4377
+ * PermissionPolicy
4378
+ * @description The wire shape of a permission policy: a map of key to verdict, plus the optional `ask_timeout` key, whose value is a number rather than a verdict. Every place a policy travels shares this shape and says there what a policy means at that door. Null everywhere a policy is absent.
4379
+ */
4380
+ PermissionPolicy: ({
4381
+ /** @description Seconds a permission request that outlived its turn waits before it is denied (#1635). Names no tool, so it is the one key whose value is a number rather than a verdict, which is why the value schema below is a union. Absent leaves the global ask timeout. A request may shorten it with `_meta.fountain.timeout` on its own session/request_permission, and may not lengthen it. A launch may only shorten what the agent set, or the global ask timeout where the agent set nothing. Capped at a year, which is where the deadline stops fitting in a timestamp rather than a limit on how long a wait is useful. */
4382
+ ask_timeout?: number;
4383
+ } & {
4384
+ [key: string]: ("auto_allow" | "ask" | "auto_deny") | number;
4385
+ }) | null;
4392
4386
  /** PromptRequest */
4393
4387
  PromptRequest: {
4394
4388
  /** @description Optional images to attach to this prompt. */
package/dist/http.d.ts CHANGED
@@ -15,7 +15,7 @@ export interface RequestOptions {
15
15
  * this string is already what Fountain's request logs are keyed on. The
16
16
  * version half is asserted against `package.json` by a test.
17
17
  */
18
- export declare const USER_AGENT = "fountain-sdk-js/4.0.0";
18
+ export declare const USER_AGENT = "fountain-sdk-js/5.1.0";
19
19
  export declare class HttpClient {
20
20
  readonly config: ResolvedConfig;
21
21
  private readonly fetchImpl;
package/dist/http.js CHANGED
@@ -5,7 +5,7 @@ import { AuthError, ConnectionError, FountainError, errorForStatus } from "./err
5
5
  * this string is already what Fountain's request logs are keyed on. The
6
6
  * version half is asserted against `package.json` by a test.
7
7
  */
8
- export const USER_AGENT = "fountain-sdk-js/4.0.0";
8
+ export const USER_AGENT = "fountain-sdk-js/5.1.0";
9
9
  /**
10
10
  * The thin layer everything else is built on: one bearer token, JSON in and
11
11
  * out, and errors that say which call failed. `Fountain#api` exposes it
package/dist/turn.js CHANGED
@@ -92,7 +92,7 @@ export class TurnFollower {
92
92
  return out;
93
93
  }
94
94
  applyBlock(block) {
95
- const body = block.body ?? "";
95
+ const body = typeof block.body === "string" ? block.body : "";
96
96
  if (block.kind === "text") {
97
97
  if (!body)
98
98
  return [];
package/dist/turn.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"turn.js","sourceRoot":"","sources":["../src/turn.ts"],"names":[],"mappings":"AAEA,MAAM,oBAAoB,GAAG,IAAI,GAAG,CAAC,CAAC,MAAM,EAAE,QAAQ,EAAE,aAAa,CAAC,CAAC,CAAC;AAExE;;;;;;;;;;;;;;;GAeG;AACH,MAAM,OAAO,YAAY;IACd,UAAU,CAAS;IAC5B,MAAM,GAAkB,IAAI,CAAC;IAC7B,OAAO,GAAG,KAAK,CAAC;IAChB,KAAK,GAAqB,IAAI,CAAC;IAC/B,QAAQ,GAAkB,IAAI,CAAC;IAC/B,MAAM,GAAkB,IAAI,CAAC;IAEZ,MAAM,GAAa,EAAE,CAAC;IACtB,KAAK,GAAa,EAAE,CAAC;IAC9B,eAAe,GAAG,KAAK,CAAC;IAEhC,YAAY,UAAkB,EAAE,SAAwB,IAAI;QAC1D,IAAI,CAAC,UAAU,GAAG,UAAU,CAAC;QAC7B,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;IACvB,CAAC;IAED,IAAI,IAAI;QACN,OAAO,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC,IAAI,EAAE,CAAC;IACrC,CAAC;IAED,IAAI,SAAS;QACX,OAAO,CAAC,GAAG,IAAI,CAAC,KAAK,CAAC,CAAC;IACzB,CAAC;IAED,IAAI,QAAQ;QACV,OAAO,IAAI,CAAC,KAAK,KAAK,IAAI,CAAC;IAC7B,CAAC;IAED,4EAA4E;IAC5E,KAAK,CAAC,KAAe;QACnB,I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AC7B,IAAI,GAAG,IAAI,OAAO,GAAG,KAAK,QAAQ;QAAE,OAAO,GAA8B,CAAC;IAC1E,IAAI,OAAO,GAAG,KAAK,QAAQ,IAAI,CAAC,GAAG,CAAC,IAAI,EAAE;QAAE,OAAO,IAAI,CAAC;IACxD,IAAI,CAAC;QACH,MAAM,MAAM,GAAG,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;QAC/B,OAAO,MAAM,IAAI,OAAO,MAAM,KAAK,QAAQ,CAAC,CAAC,CAAE,MAAkC,CAAC,CAAC,CAAC,IAAI,CAAC;IAC3F,CAAC;IAAC,MAAM,CAAC;QACP,OAAO,IAAI,CAAC;IACd,CAAC;AACH,CAAC;AAED,SAAS,QAAQ,CAAC,KAAc;IAC9B,OAAO,OAAO,KAAK,KAAK,QAAQ,IAAI,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,IAAI,CAAC;AAC3D,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@managoat/fountain-sdk",
3
- "version": "4.0.0",
3
+ "version": "5.1.0",
4
4
  "description": "Run a coding agent on a real computer, with your repos and your credentials, in one call.",
5
5
  "license": "Apache-2.0",
6
6
  "publishConfig": {
@@ -51,6 +51,7 @@
51
51
  "prepublishOnly": "node scripts/ci-publishes.mjs && npm run typecheck && npm test && npm run build"
52
52
  },
53
53
  "devDependencies": {
54
+ "@redocly/ajv": "8.11.2",
54
55
  "@types/node": "^26.4.0",
55
56
  "openapi-typescript": "^7.13.0",
56
57
  "typescript": "^5.7.0"