@jini-ai/daemon 0.5.2 → 0.5.4

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.
Files changed (78) hide show
  1. package/CHANGELOG.md +11 -0
  2. package/dist/agent-executor/contracts.d.ts +26 -20
  3. package/dist/agent-executor/contracts.js +0 -9
  4. package/dist/agent-executor/event-translation.d.ts +2 -2
  5. package/dist/agent-executor/event-translation.js +1 -2
  6. package/dist/agent-executor/events.d.ts +9 -4
  7. package/dist/agent-executor/events.js +29 -7
  8. package/dist/agent-executor/handoff.d.ts +1 -1
  9. package/dist/agent-executor/handoff.js +0 -1
  10. package/dist/agent-executor/launch.d.ts +1 -1
  11. package/dist/agent-executor/launch.js +24 -1
  12. package/dist/agent-executor/mcp-bridge.d.ts +2 -2
  13. package/dist/agent-executor/mcp-bridge.js +0 -2
  14. package/dist/agent-executor/model-receipts.d.ts +6 -0
  15. package/dist/agent-executor/model-receipts.js +26 -0
  16. package/dist/agent-executor.d.ts +8 -1663
  17. package/dist/agent-executor.js +8 -3005
  18. package/dist/attachment-content.d.ts +45 -0
  19. package/dist/attachment-content.js +40 -0
  20. package/dist/core/read-only-tools.d.ts +130 -0
  21. package/dist/core/read-only-tools.js +115 -0
  22. package/dist/core/tool-audit.d.ts +131 -0
  23. package/dist/core/tool-audit.js +113 -0
  24. package/dist/http/active-context.d.ts +2 -2
  25. package/dist/http/agents.d.ts +8 -2
  26. package/dist/http/agents.js +6 -2
  27. package/dist/http/attachments.d.ts +16 -7
  28. package/dist/http/attachments.js +3 -2
  29. package/dist/http/component-catalog.d.ts +2 -2
  30. package/dist/http/connectors.d.ts +17 -17
  31. package/dist/http/daemon-status.d.ts +2 -2
  32. package/dist/http/db-ops.d.ts +3 -3
  33. package/dist/http/delegated-tools.d.ts +1 -1
  34. package/dist/http/delegated-tools.js +1 -1
  35. package/dist/http/frontend-sessions.d.ts +1 -1
  36. package/dist/http/health.d.ts +6 -6
  37. package/dist/http/host-tools.d.ts +2 -2
  38. package/dist/http/media.d.ts +4 -4
  39. package/dist/http/memory.d.ts +15 -15
  40. package/dist/http/remote-run-events.d.ts +2 -2
  41. package/dist/http/research.d.ts +1 -1
  42. package/dist/http/routines.d.ts +7 -7
  43. package/dist/http/run-credentials.d.ts +2 -2
  44. package/dist/http/run-credentials.js +2 -2
  45. package/dist/http/runs.d.ts +4 -4
  46. package/dist/http/terminals.d.ts +6 -6
  47. package/dist/http/tool-catalog.d.ts +2 -2
  48. package/dist/http/xai.d.ts +6 -6
  49. package/dist/index.d.ts +76 -571
  50. package/dist/index.js +76 -571
  51. package/dist/read-only-tools.d.ts +1 -129
  52. package/dist/read-only-tools.js +2 -114
  53. package/dist/run-credentials.d.ts +47 -23
  54. package/dist/run-credentials.js +24 -8
  55. package/dist/run-lifecycle.d.ts +1 -1
  56. package/dist/run-lifecycle.js +6 -5
  57. package/dist/scheduler.d.ts +5 -0
  58. package/dist/scheduler.js +13 -1
  59. package/dist/session-coordination.d.ts +58 -24
  60. package/dist/session-coordination.js +40 -12
  61. package/dist/store/event-log/sqlite.js +3 -3
  62. package/dist/surface-exchanges.d.ts +207 -61
  63. package/dist/surface-exchanges.js +167 -20
  64. package/dist/tool-audit.d.ts +1 -113
  65. package/dist/tool-audit.js +2 -94
  66. package/dist/tool-recovery/diagnostics.d.ts +132 -0
  67. package/dist/tool-recovery/diagnostics.js +110 -0
  68. package/dist/tool-recovery/federated-refusal.d.ts +92 -0
  69. package/dist/tool-recovery/federated-refusal.js +152 -0
  70. package/dist/tool-recovery/index.d.ts +6 -0
  71. package/dist/tool-recovery/index.js +6 -0
  72. package/dist/tool-recovery/recovery.d.ts +49 -0
  73. package/dist/tool-recovery/recovery.js +419 -0
  74. package/dist/tool-recovery/redaction.d.ts +166 -0
  75. package/dist/tool-recovery/redaction.js +192 -0
  76. package/dist/tool-recovery/stack.d.ts +69 -0
  77. package/dist/tool-recovery/stack.js +62 -0
  78. package/package.json +35 -12
@@ -147,7 +147,8 @@ export interface AttachmentStore {
147
147
  readonly runId: string;
148
148
  }, _optional?: Record<string, never>) => Promise<StoredAttachment | undefined>;
149
149
  /**
150
- * Lists every still-unclaimed attachment registered with `ownerId` — the discovery counterpart to
150
+ * Lists unclaimed attachments registered with `ownerId`, plus attachments claimed by optional
151
+ * `runId` when supplied — the discovery counterpart to
151
152
  * `resolveForRun`'s single-lookup: a caller that does not yet hold a specific ref at all (an
152
153
  * attachment uploaded in an earlier turn, never named in this run's prompt) has no id to look up
153
154
  * with `resolveForRun` in the first place. This is what makes that attachment findable.
@@ -164,12 +165,18 @@ export interface AttachmentStore {
164
165
  * attachment from before this method existed) is excluded from every caller's results, never
165
166
  * just "unscoped" — this method is not callable with `ownerId: undefined`, so there is no input
166
167
  * that could accidentally match an ownerless record;
167
- * - a claimed attachment is excluded outright, whether or not this caller's own `runId` claimed
168
- * it, so this method can never be used to re-discover something already handed to a run — the
169
- * same "runs, not listings, are the reach here" boundary `resolveForRun` draws for a single ref.
168
+ * - a claimed attachment is excluded unless the host supplies that exact claiming `runId` in
169
+ * the optional argument. Hosts must derive ownerId/runId from authenticated execution context,
170
+ * never tool input. Run startup claims ALL message attachments before tools execute; including
171
+ * that run's claims keeps image, video and generic file discovery available after delivery.
172
+ * Owner matching remains mandatory even for the matching run. Without runId, the original
173
+ * unclaimed-only behavior is unchanged. Listing never claims, releases, or reads a file; callers
174
+ * still use `resolveForRun` for integrity-checked bytes/promotion.
170
175
  *
171
176
  * What this does NOT scope by: batch, conversation, or run — none of those are recorded on an
172
- * `AttachmentRecord` today. Two different conversations run by the SAME `ownerId` will each see
177
+ * `AttachmentRecord` today (except run ownership once claimed). Hosts restricting discovery to
178
+ * an accepted message must also intersect these summaries with that message's refs. Without that
179
+ * intersection, two different conversations run by the SAME `ownerId` will each see
173
180
  * the other's pending attachments through this method. A host for whom that is too wide needs a
174
181
  * finer-grained id than `ownerId` to pass into `register()` — this method does not itself assume
175
182
  * `ownerId` means "one admin account" rather than "one conversation, one composer, one browser
@@ -184,7 +191,9 @@ export interface AttachmentStore {
184
191
  */
185
192
  listPendingForOwner: ({ ownerId }: {
186
193
  readonly ownerId: string;
187
- }, _optional?: Record<string, never>) => Promise<PendingAttachmentSummary[]>;
194
+ }, optional?: {
195
+ readonly runId?: string;
196
+ }) => Promise<PendingAttachmentSummary[]>;
188
197
  /** Deletes the named still-unclaimed uploads, then the batch directory if it is now empty. */
189
198
  deleteUnclaimed: ({ batchId, paths }: {
190
199
  readonly batchId: string;
@@ -265,7 +274,7 @@ export interface AttachmentRecord {
265
274
  ownerId?: string;
266
275
  }
267
276
  /**
268
- * What `listPendingForOwner` hands back for one still-unclaimed attachment: enough for a caller to
277
+ * What `listPendingForOwner` hands back for an unclaimed or same-run claimed attachment: enough for a caller to
269
278
  * show a person what is waiting, and to name it again (`ref`) to `claim()`/`resolveForRun`.
270
279
  */
271
280
  export interface PendingAttachmentSummary {
@@ -835,12 +835,13 @@ export async function createDiskAttachmentStore(requiredArgs, optionalArgs = {})
835
835
  }
836
836
  return { path: record.filePath, name: record.name, kind: record.kind, size: record.size };
837
837
  },
838
- async listPendingForOwner({ ownerId }, _optional = {}) {
838
+ async listPendingForOwner({ ownerId }, { runId } = {}) {
839
839
  return [...records.values()]
840
840
  // `record.ownerId !== undefined` first, short-circuiting before the comparison: this is
841
841
  // what makes an ownerless record excluded rather than accidentally matched by a falsy-ish
842
842
  // `ownerId` argument — see this method's own doc on why that must never be a wildcard.
843
- .filter((record) => record.claimedRunId === undefined && record.ownerId !== undefined && record.ownerId === ownerId)
843
+ .filter((record) => record.ownerId !== undefined && record.ownerId === ownerId
844
+ && (record.claimedRunId === undefined || (runId !== undefined && record.claimedRunId === runId)))
844
845
  .sort((a, b) => a.createdAt - b.createdAt)
845
846
  .map((record) => ({ ref: record.id, name: record.name, kind: record.kind, size: record.size, createdAt: record.createdAt }));
846
847
  },
@@ -62,7 +62,7 @@ export declare const componentCatalogSearchRoute: import("@jini-ai/http-kit").Js
62
62
  limit: number;
63
63
  }, {
64
64
  hits: readonly ComponentCatalogSearchHit[];
65
- }, ComponentCatalogHttpDeps>;
65
+ }, ComponentCatalogHttpDeps, undefined>;
66
66
  /**
67
67
  * `GET /api/components/:id` — full descriptor (propsSchema included). An unknown id is 404,
68
68
  * matching `tool-catalog.ts`'s describe route.
@@ -74,7 +74,7 @@ export declare const componentCatalogSearchRoute: import("@jini-ai/http-kit").Js
74
74
  */
75
75
  export declare const componentCatalogDescribeRoute: import("@jini-ai/http-kit").JsonRouteSpec<{
76
76
  id: string;
77
- }, ComponentCatalogEntry, ComponentCatalogHttpDeps>;
77
+ }, ComponentCatalogEntry, ComponentCatalogHttpDeps, undefined>;
78
78
  /** Mounts both component-catalog routes on `app`. A pack's `http(app, services)` calls this directly. */
79
79
  export declare function registerComponentCatalogRoutes({ app, deps, adapter }: {
80
80
  readonly app: Express;
@@ -140,10 +140,10 @@ export interface ConnectorsAuthVerifyResponse {
140
140
  export interface ConnectorsOkResponse {
141
141
  readonly ok: true;
142
142
  }
143
- export declare const connectorsAuthSignUpRoute: import("@jini-ai/http-kit").JsonRouteSpec<AuthCredentials, ConnectorsAuthUserResponse, ConnectorsHttpDeps>;
144
- export declare const connectorsAuthSignInRoute: import("@jini-ai/http-kit").JsonRouteSpec<AuthCredentials, ConnectorsAuthSessionResponse, ConnectorsHttpDeps>;
145
- export declare const connectorsAuthSignOutRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, ConnectorsOkResponse, ConnectorsHttpDeps>;
146
- export declare const connectorsAuthSessionRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, ConnectorsAuthVerifyResponse, ConnectorsHttpDeps>;
143
+ export declare const connectorsAuthSignUpRoute: import("@jini-ai/http-kit").JsonRouteSpec<AuthCredentials, ConnectorsAuthUserResponse, ConnectorsHttpDeps, undefined>;
144
+ export declare const connectorsAuthSignInRoute: import("@jini-ai/http-kit").JsonRouteSpec<AuthCredentials, ConnectorsAuthSessionResponse, ConnectorsHttpDeps, undefined>;
145
+ export declare const connectorsAuthSignOutRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, ConnectorsOkResponse, ConnectorsHttpDeps, undefined>;
146
+ export declare const connectorsAuthSessionRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, ConnectorsAuthVerifyResponse, ConnectorsHttpDeps, undefined>;
147
147
  interface StoragePutRequest {
148
148
  readonly key: string;
149
149
  readonly dataBase64: string;
@@ -158,16 +158,16 @@ export interface ConnectorsStorageGetResponse {
158
158
  export interface ConnectorsStorageListResponse {
159
159
  readonly objects: readonly StorageObjectMeta[];
160
160
  }
161
- export declare const connectorsStoragePutRoute: import("@jini-ai/http-kit").JsonRouteSpec<StoragePutRequest, ConnectorsStorageMetaResponse, ConnectorsHttpDeps>;
162
- export declare const connectorsStorageGetRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, ConnectorsStorageGetResponse, ConnectorsHttpDeps>;
163
- export declare const connectorsStorageDeleteRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, ConnectorsOkResponse, ConnectorsHttpDeps>;
164
- export declare const connectorsStorageListRoute: import("@jini-ai/http-kit").JsonRouteSpec<string | undefined, ConnectorsStorageListResponse, ConnectorsHttpDeps>;
161
+ export declare const connectorsStoragePutRoute: import("@jini-ai/http-kit").JsonRouteSpec<StoragePutRequest, ConnectorsStorageMetaResponse, ConnectorsHttpDeps, undefined>;
162
+ export declare const connectorsStorageGetRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, ConnectorsStorageGetResponse, ConnectorsHttpDeps, undefined>;
163
+ export declare const connectorsStorageDeleteRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, ConnectorsOkResponse, ConnectorsHttpDeps, undefined>;
164
+ export declare const connectorsStorageListRoute: import("@jini-ai/http-kit").JsonRouteSpec<string | undefined, ConnectorsStorageListResponse, ConnectorsHttpDeps, undefined>;
165
165
  export interface ConnectorsChargeResponse {
166
166
  readonly charge: Charge;
167
167
  }
168
- export declare const connectorsPaymentsChargeRoute: import("@jini-ai/http-kit").JsonRouteSpec<ChargeInput, ConnectorsChargeResponse, ConnectorsHttpDeps>;
169
- export declare const connectorsPaymentsGetRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, ConnectorsChargeResponse, ConnectorsHttpDeps>;
170
- export declare const connectorsPaymentsRefundRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, ConnectorsChargeResponse, ConnectorsHttpDeps>;
168
+ export declare const connectorsPaymentsChargeRoute: import("@jini-ai/http-kit").JsonRouteSpec<ChargeInput, ConnectorsChargeResponse, ConnectorsHttpDeps, undefined>;
169
+ export declare const connectorsPaymentsGetRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, ConnectorsChargeResponse, ConnectorsHttpDeps, undefined>;
170
+ export declare const connectorsPaymentsRefundRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, ConnectorsChargeResponse, ConnectorsHttpDeps, undefined>;
171
171
  interface DbInsertRequest {
172
172
  readonly collection: string;
173
173
  readonly record: DbRecord;
@@ -189,16 +189,16 @@ export interface ConnectorsDbRecordResponse {
189
189
  export interface ConnectorsDbQueryResponse {
190
190
  readonly records: readonly DbRecord[];
191
191
  }
192
- export declare const connectorsDbInsertRoute: import("@jini-ai/http-kit").JsonRouteSpec<DbInsertRequest, ConnectorsDbRecordResponse, ConnectorsHttpDeps>;
193
- export declare const connectorsDbGetRoute: import("@jini-ai/http-kit").JsonRouteSpec<DbCollectionIdParams, ConnectorsDbRecordResponse, ConnectorsHttpDeps>;
194
- export declare const connectorsDbUpdateRoute: import("@jini-ai/http-kit").JsonRouteSpec<DbUpdateRequest, ConnectorsDbRecordResponse, ConnectorsHttpDeps>;
195
- export declare const connectorsDbDeleteRoute: import("@jini-ai/http-kit").JsonRouteSpec<DbCollectionIdParams, ConnectorsOkResponse, ConnectorsHttpDeps>;
196
- export declare const connectorsDbQueryRoute: import("@jini-ai/http-kit").JsonRouteSpec<DbQueryRequest, ConnectorsDbQueryResponse, ConnectorsHttpDeps>;
192
+ export declare const connectorsDbInsertRoute: import("@jini-ai/http-kit").JsonRouteSpec<DbInsertRequest, ConnectorsDbRecordResponse, ConnectorsHttpDeps, undefined>;
193
+ export declare const connectorsDbGetRoute: import("@jini-ai/http-kit").JsonRouteSpec<DbCollectionIdParams, ConnectorsDbRecordResponse, ConnectorsHttpDeps, undefined>;
194
+ export declare const connectorsDbUpdateRoute: import("@jini-ai/http-kit").JsonRouteSpec<DbUpdateRequest, ConnectorsDbRecordResponse, ConnectorsHttpDeps, undefined>;
195
+ export declare const connectorsDbDeleteRoute: import("@jini-ai/http-kit").JsonRouteSpec<DbCollectionIdParams, ConnectorsOkResponse, ConnectorsHttpDeps, undefined>;
196
+ export declare const connectorsDbQueryRoute: import("@jini-ai/http-kit").JsonRouteSpec<DbQueryRequest, ConnectorsDbQueryResponse, ConnectorsHttpDeps, undefined>;
197
197
  interface RealtimePublishRequest {
198
198
  readonly channel: string;
199
199
  readonly event: unknown;
200
200
  }
201
- export declare const connectorsRealtimePublishRoute: import("@jini-ai/http-kit").JsonRouteSpec<RealtimePublishRequest, ConnectorsOkResponse, ConnectorsHttpDeps>;
201
+ export declare const connectorsRealtimePublishRoute: import("@jini-ai/http-kit").JsonRouteSpec<RealtimePublishRequest, ConnectorsOkResponse, ConnectorsHttpDeps, undefined>;
202
202
  /** Mounts every connectors route on `app`. A pack's `http(app, services)` calls this directly. */
203
203
  export declare function registerConnectorsRoutes({ app, deps, adapter }: {
204
204
  readonly app: Express;
@@ -58,7 +58,7 @@ export interface DaemonShutdownResponse {
58
58
  * injectable readiness check) and are guaranteed reachable without a bearer token or an `Origin`
59
59
  * header. This route is still useful for a human/CLI wanting the richer operator detail below.
60
60
  */
61
- export declare const daemonStatusRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, DaemonStatusResponse, DaemonStatusDeps>;
61
+ export declare const daemonStatusRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, DaemonStatusResponse, DaemonStatusDeps, undefined>;
62
62
  /**
63
63
  * `POST /api/daemon/shutdown` — schedules a graceful shutdown. Responds
64
64
  * immediately (matching the origin's behavior) and defers the actual
@@ -66,7 +66,7 @@ export declare const daemonStatusRoute: import("@jini-ai/http-kit").JsonRouteSpe
66
66
  * written before whatever the caller's shutdown callback does takes effect.
67
67
  * Gated same-origin: this is a control-plane action, not a public read.
68
68
  */
69
- export declare const daemonShutdownRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, DaemonShutdownResponse, DaemonStatusDeps>;
69
+ export declare const daemonShutdownRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, DaemonShutdownResponse, DaemonStatusDeps, undefined>;
70
70
  /** Mounts both daemon-status routes on `app`. A pack's `http(app, services)` calls this directly. */
71
71
  export declare function registerDaemonStatusRoutes({ app, deps, adapter }: {
72
72
  readonly app: Express;
@@ -107,13 +107,13 @@ export interface DaemonDbHttpDeps {
107
107
  readonly onInternalError?: (context: DaemonDbInternalErrorContext) => void;
108
108
  }
109
109
  /** `GET /api/daemon/db` — the database inventory (schema version, tables, row counts, size). */
110
- export declare const daemonDbInspectRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, DaemonDbStatusReport, DaemonDbHttpDeps>;
110
+ export declare const daemonDbInspectRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, DaemonDbStatusReport, DaemonDbHttpDeps, undefined>;
111
111
  /** `POST /api/daemon/db/verify?quick=` — `PRAGMA integrity_check`/`quick_check` plus `foreign_key_check`. */
112
112
  export declare const daemonDbVerifyRoute: import("@jini-ai/http-kit").JsonRouteSpec<{
113
113
  quick: boolean;
114
- }, DbIntegrityReport, DaemonDbHttpDeps>;
114
+ }, DbIntegrityReport, DaemonDbHttpDeps, undefined>;
115
115
  /** `POST /api/daemon/db/vacuum` — runs `VACUUM` and reports bytes reclaimed. */
116
- export declare const daemonDbVacuumRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, DaemonDbVacuumResult, DaemonDbHttpDeps>;
116
+ export declare const daemonDbVacuumRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, DaemonDbVacuumResult, DaemonDbHttpDeps, undefined>;
117
117
  /** Mounts all three DB-ops routes on `app`. A pack's `http({ app, services })` calls this directly. */
118
118
  export declare function registerDaemonDbRoutes({ app, deps, adapter }: {
119
119
  readonly app: Express;
@@ -103,7 +103,7 @@ export interface DelegatedToolsHttpDeps {
103
103
  * became terminal between this route's existence check and the bridge's first emitted event)
104
104
  * reaches the same SEC-005 redaction path.
105
105
  */
106
- export declare const delegatedToolExecuteRoute: import("@jini-ai/http-kit").JsonRouteSpec<DelegatedToolExecuteRequest, DelegatedToolExecuteResponse, DelegatedToolsHttpDeps>;
106
+ export declare const delegatedToolExecuteRoute: import("@jini-ai/http-kit").JsonRouteSpec<DelegatedToolExecuteRequest, DelegatedToolExecuteResponse, DelegatedToolsHttpDeps, undefined>;
107
107
  /** Mounts `POST /api/delegated-tool-calls` on `app`. A pack's `http(app, services)` calls this directly. */
108
108
  export declare function registerDelegatedToolRoutes({ app, deps, adapter }: {
109
109
  readonly app: Express;
@@ -31,7 +31,7 @@ import { createDelegatedToolBridge } from '../index.js';
31
31
  import { defineJsonRoute, mountJsonRoute } from '@jini-ai/http-kit';
32
32
  import { validationError } from '@jini-ai/http-kit';
33
33
  import { err, ok } from '@jini-ai/http-kit';
34
- import * as readOnlyTools from '../read-only-tools.js';
34
+ import * as readOnlyTools from '../core/read-only-tools.js';
35
35
  /** Route preflight shares the same registration decision as nested dispatch. */
36
36
  function checkReadOnlyConstraint(deps, input) {
37
37
  if (input.requireReadOnly !== true)
@@ -93,7 +93,7 @@ export declare function handleFrontendSessionStream({ req, res, deps }: {
93
93
  * handler awaiting it. Always `200`; `{settled:false}` reports a duplicate or unknown answer,
94
94
  * which is an expected outcome rather than a transport error.
95
95
  */
96
- export declare const frontendSessionResponseRoute: import("@jini-ai/http-kit").JsonRouteSpec<FrontendSessionResponseRequest, FrontendSessionResponseBody, FrontendSessionsHttpDeps>;
96
+ export declare const frontendSessionResponseRoute: import("@jini-ai/http-kit").JsonRouteSpec<FrontendSessionResponseRequest, FrontendSessionResponseBody, FrontendSessionsHttpDeps, undefined>;
97
97
  /**
98
98
  * Mounts both frontend-session routes on `app`.
99
99
  *
@@ -80,12 +80,12 @@ export interface ReadinessResponse {
80
80
  export interface VersionResponse {
81
81
  readonly version: string;
82
82
  }
83
- export declare const healthRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, LivenessResponse, HealthHttpDeps>;
84
- export declare const apiHealthRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, LivenessResponse, HealthHttpDeps>;
85
- export declare const readyRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, ReadinessResponse, HealthHttpDeps>;
86
- export declare const apiReadyRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, ReadinessResponse, HealthHttpDeps>;
87
- export declare const versionInfoRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, VersionResponse, HealthHttpDeps>;
88
- export declare const apiVersionInfoRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, VersionResponse, HealthHttpDeps>;
83
+ export declare const healthRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, LivenessResponse, HealthHttpDeps, undefined>;
84
+ export declare const apiHealthRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, LivenessResponse, HealthHttpDeps, undefined>;
85
+ export declare const readyRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, ReadinessResponse, HealthHttpDeps, undefined>;
86
+ export declare const apiReadyRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, ReadinessResponse, HealthHttpDeps, undefined>;
87
+ export declare const versionInfoRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, VersionResponse, HealthHttpDeps, undefined>;
88
+ export declare const apiVersionInfoRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, VersionResponse, HealthHttpDeps, undefined>;
89
89
  /** Mounts all six health/readiness/version routes on `app`. Call this before installing `express.json()`/the bearer-auth/origin-guard middleware — see module doc. */
90
90
  export declare function registerHealthRoutes({ app, deps, adapter }: {
91
91
  readonly app: Express;
@@ -164,7 +164,7 @@ export declare function listAvailableEditors(_required: Record<string, never>, {
164
164
  readonly probeEnv?: HostToolProbeEnv | undefined;
165
165
  }): Promise<HostEditorsResponse>;
166
166
  /** `GET /api/editors` — lists the host-tool catalogue applicable to this platform with live availability. */
167
- export declare const hostEditorsRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, HostEditorsResponse, Record<string, never>>;
167
+ export declare const hostEditorsRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, HostEditorsResponse, Record<string, never>, undefined>;
168
168
  export interface OpenResourceInEditorRequest {
169
169
  readonly resourceRef: string;
170
170
  readonly editorId: string;
@@ -204,7 +204,7 @@ export interface HostToolsOpenInDeps {
204
204
  * operationally useful to the caller and does not cross a trust boundary
205
205
  * the way an internal agent-run exception can.
206
206
  */
207
- export declare const openResourceInEditorRoute: import("@jini-ai/http-kit").JsonRouteSpec<OpenResourceInEditorRequest, OpenResourceInEditorResponse, HostToolsOpenInDeps>;
207
+ export declare const openResourceInEditorRoute: import("@jini-ai/http-kit").JsonRouteSpec<OpenResourceInEditorRequest, OpenResourceInEditorResponse, HostToolsOpenInDeps, undefined>;
208
208
  /** Mounts `GET /api/editors` and `POST /api/resources/:resourceRef/open-in` on `app`. A pack's `http(app, services)` calls this directly. */
209
209
  export declare function registerHostToolsRoutes({ app, adapter }: {
210
210
  readonly app: Express;
@@ -123,19 +123,19 @@ interface MediaTaskListQuery {
123
123
  export interface MediaGenerateResponse {
124
124
  readonly task: MediaTask;
125
125
  }
126
- export declare const mediaGenerateRoute: import("@jini-ai/http-kit").JsonRouteSpec<MediaGenerateRequest, MediaGenerateResponse, MediaHttpDeps>;
126
+ export declare const mediaGenerateRoute: import("@jini-ai/http-kit").JsonRouteSpec<MediaGenerateRequest, MediaGenerateResponse, MediaHttpDeps, undefined>;
127
127
  export interface MediaTaskResponse {
128
128
  readonly task: MediaTask;
129
129
  }
130
- export declare const mediaTaskGetRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, MediaTaskResponse, MediaHttpDeps>;
130
+ export declare const mediaTaskGetRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, MediaTaskResponse, MediaHttpDeps, undefined>;
131
131
  export interface MediaTaskDeleteResponse {
132
132
  readonly ok: true;
133
133
  }
134
- export declare const mediaTaskDeleteRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, MediaTaskDeleteResponse, MediaHttpDeps>;
134
+ export declare const mediaTaskDeleteRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, MediaTaskDeleteResponse, MediaHttpDeps, undefined>;
135
135
  export interface MediaTaskListResponse {
136
136
  readonly tasks: readonly MediaTask[];
137
137
  }
138
- export declare const mediaTaskListRoute: import("@jini-ai/http-kit").JsonRouteSpec<MediaTaskListQuery, MediaTaskListResponse, MediaHttpDeps>;
138
+ export declare const mediaTaskListRoute: import("@jini-ai/http-kit").JsonRouteSpec<MediaTaskListQuery, MediaTaskListResponse, MediaHttpDeps, undefined>;
139
139
  /** Mounts every media route on `app`. A pack's `http(app, services)` calls this directly. */
140
140
  export declare function registerMediaRoutes({ app, deps, adapter }: {
141
141
  readonly app: Express;
@@ -162,13 +162,13 @@ export interface MemoryOverviewResponse {
162
162
  readonly index: string;
163
163
  readonly entries: readonly MemoryNoteEntrySummary[];
164
164
  }
165
- export declare const memoryOverviewRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, MemoryOverviewResponse, MemoryHttpDeps>;
165
+ export declare const memoryOverviewRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, MemoryOverviewResponse, MemoryHttpDeps, undefined>;
166
166
  export interface MemoryTreeResponse {
167
167
  readonly enabled: boolean;
168
168
  readonly rootDir: string;
169
169
  readonly tree: readonly MemoryTreeNode[];
170
170
  }
171
- export declare const memoryTreeRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, MemoryTreeResponse, MemoryHttpDeps>;
171
+ export declare const memoryTreeRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, MemoryTreeResponse, MemoryHttpDeps, undefined>;
172
172
  export interface MemoryTreeNodePatch {
173
173
  readonly name?: string;
174
174
  readonly description?: string;
@@ -183,30 +183,30 @@ export interface MemoryUpdateTreeNodeResponse {
183
183
  readonly entry: MemoryNoteEntry;
184
184
  readonly tree: readonly MemoryTreeNode[];
185
185
  }
186
- export declare const memoryUpdateTreeNodeRoute: import("@jini-ai/http-kit").JsonRouteSpec<MemoryUpdateTreeNodeInput, MemoryUpdateTreeNodeResponse, MemoryHttpDeps>;
186
+ export declare const memoryUpdateTreeNodeRoute: import("@jini-ai/http-kit").JsonRouteSpec<MemoryUpdateTreeNodeInput, MemoryUpdateTreeNodeResponse, MemoryHttpDeps, undefined>;
187
187
  export interface MemoryIndexResponse {
188
188
  readonly index: string;
189
189
  }
190
- export declare const memoryWriteIndexRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, MemoryIndexResponse, MemoryHttpDeps>;
190
+ export declare const memoryWriteIndexRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, MemoryIndexResponse, MemoryHttpDeps, undefined>;
191
191
  export interface MemoryConfigResponse {
192
192
  readonly enabled: boolean;
193
193
  }
194
- export declare const memoryWriteConfigRoute: import("@jini-ai/http-kit").JsonRouteSpec<Partial<MemoryNoteStoreOptions>, MemoryConfigResponse, MemoryHttpDeps>;
194
+ export declare const memoryWriteConfigRoute: import("@jini-ai/http-kit").JsonRouteSpec<Partial<MemoryNoteStoreOptions>, MemoryConfigResponse, MemoryHttpDeps, undefined>;
195
195
  export interface MemoryExtractionsResponse {
196
196
  readonly extractions: readonly unknown[];
197
197
  }
198
- export declare const memoryListExtractionsRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, MemoryExtractionsResponse, MemoryHttpDeps>;
198
+ export declare const memoryListExtractionsRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, MemoryExtractionsResponse, MemoryHttpDeps, undefined>;
199
199
  export interface MemoryRemovedResponse {
200
200
  readonly removed: number;
201
201
  }
202
- export declare const memoryClearExtractionsRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, MemoryRemovedResponse, MemoryHttpDeps>;
203
- export declare const memoryRemoveExtractionRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, MemoryRemovedResponse, MemoryHttpDeps>;
202
+ export declare const memoryClearExtractionsRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, MemoryRemovedResponse, MemoryHttpDeps, undefined>;
203
+ export declare const memoryRemoveExtractionRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, MemoryRemovedResponse, MemoryHttpDeps, undefined>;
204
204
  export interface MemoryVerificationsResponse {
205
205
  readonly verifications: readonly unknown[];
206
206
  }
207
- export declare const memoryListVerificationsRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, MemoryVerificationsResponse, MemoryHttpDeps>;
208
- export declare const memoryClearVerificationsRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, MemoryRemovedResponse, MemoryHttpDeps>;
209
- export declare const memoryRemoveVerificationRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, MemoryRemovedResponse, MemoryHttpDeps>;
207
+ export declare const memoryListVerificationsRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, MemoryVerificationsResponse, MemoryHttpDeps, undefined>;
208
+ export declare const memoryClearVerificationsRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, MemoryRemovedResponse, MemoryHttpDeps, undefined>;
209
+ export declare const memoryRemoveVerificationRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, MemoryRemovedResponse, MemoryHttpDeps, undefined>;
210
210
  export interface MemoryEntryInput {
211
211
  readonly id?: string;
212
212
  readonly name: string;
@@ -217,17 +217,17 @@ export interface MemoryEntryInput {
217
217
  export interface MemoryEntryResponse {
218
218
  readonly entry: MemoryNoteEntry;
219
219
  }
220
- export declare const memoryCreateEntryRoute: import("@jini-ai/http-kit").JsonRouteSpec<MemoryEntryInput, MemoryEntryResponse, MemoryHttpDeps>;
221
- export declare const memoryReadEntryRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, MemoryEntryResponse, MemoryHttpDeps>;
220
+ export declare const memoryCreateEntryRoute: import("@jini-ai/http-kit").JsonRouteSpec<MemoryEntryInput, MemoryEntryResponse, MemoryHttpDeps, undefined>;
221
+ export declare const memoryReadEntryRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, MemoryEntryResponse, MemoryHttpDeps, undefined>;
222
222
  interface MemoryUpdateEntryInput {
223
223
  readonly id: string;
224
224
  readonly input: MemoryEntryInput;
225
225
  }
226
- export declare const memoryUpdateEntryRoute: import("@jini-ai/http-kit").JsonRouteSpec<MemoryUpdateEntryInput, MemoryEntryResponse, MemoryHttpDeps>;
226
+ export declare const memoryUpdateEntryRoute: import("@jini-ai/http-kit").JsonRouteSpec<MemoryUpdateEntryInput, MemoryEntryResponse, MemoryHttpDeps, undefined>;
227
227
  export interface MemoryDeleteEntryResponse {
228
228
  readonly ok: true;
229
229
  }
230
- export declare const memoryDeleteEntryRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, MemoryDeleteEntryResponse, MemoryHttpDeps>;
230
+ export declare const memoryDeleteEntryRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, MemoryDeleteEntryResponse, MemoryHttpDeps, undefined>;
231
231
  /**
232
232
  * `GET /api/memory/events` — one SSE connection multiplexing three channels
233
233
  * (matching OD's own reasoning: "so the browser opens one connection instead
@@ -54,8 +54,8 @@ export interface RemoteToolResultRequest {
54
54
  export interface RemoteRunEventResponse {
55
55
  readonly recorded: true;
56
56
  }
57
- export declare const remoteToolUseRoute: import("@jini-ai/http-kit").JsonRouteSpec<RemoteToolUseRequest, RemoteRunEventResponse, RemoteRunEventHttpDeps>;
58
- export declare const remoteToolResultRoute: import("@jini-ai/http-kit").JsonRouteSpec<RemoteToolResultRequest, RemoteRunEventResponse, RemoteRunEventHttpDeps>;
57
+ export declare const remoteToolUseRoute: import("@jini-ai/http-kit").JsonRouteSpec<RemoteToolUseRequest, RemoteRunEventResponse, RemoteRunEventHttpDeps, undefined>;
58
+ export declare const remoteToolResultRoute: import("@jini-ai/http-kit").JsonRouteSpec<RemoteToolResultRequest, RemoteRunEventResponse, RemoteRunEventHttpDeps, undefined>;
59
59
  /**
60
60
  * Mounts both remote-run-event routes on `app`, gated by {@link requireRemoteToolBridgeToken}.
61
61
  * Unlike `registerRunRoutes`/`registerDelegatedToolRoutes`, these routes do not use
@@ -37,7 +37,7 @@ interface ResearchSearchRequest {
37
37
  readonly query: string;
38
38
  readonly maxSources?: number;
39
39
  }
40
- export declare const researchSearchRoute: import("@jini-ai/http-kit").JsonRouteSpec<ResearchSearchRequest, ResearchSearchResponse, ResearchHttpDeps>;
40
+ export declare const researchSearchRoute: import("@jini-ai/http-kit").JsonRouteSpec<ResearchSearchRequest, ResearchSearchResponse, ResearchHttpDeps, undefined>;
41
41
  /** Mounts `POST /api/research/search` on `app`. A pack's `http(app, services)` calls this directly. */
42
42
  export declare function registerResearchRoutes({ app, deps, adapter }: {
43
43
  readonly app: Express;
@@ -87,17 +87,17 @@ interface RoutineRunsQuery {
87
87
  export interface RoutineListResponse {
88
88
  readonly routines: readonly Routine[];
89
89
  }
90
- export declare const routineListRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, RoutineListResponse, RoutineHttpDeps>;
90
+ export declare const routineListRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, RoutineListResponse, RoutineHttpDeps, undefined>;
91
91
  export interface RoutineResponse {
92
92
  readonly routine: Routine;
93
93
  }
94
- export declare const routineCreateRoute: import("@jini-ai/http-kit").JsonRouteSpec<RoutineCreateInput, RoutineResponse, RoutineHttpDeps>;
95
- export declare const routineGetRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, RoutineResponse, RoutineHttpDeps>;
96
- export declare const routineUpdateRoute: import("@jini-ai/http-kit").JsonRouteSpec<RoutineUpdateRequest, RoutineResponse, RoutineHttpDeps>;
94
+ export declare const routineCreateRoute: import("@jini-ai/http-kit").JsonRouteSpec<RoutineCreateInput, RoutineResponse, RoutineHttpDeps, undefined>;
95
+ export declare const routineGetRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, RoutineResponse, RoutineHttpDeps, undefined>;
96
+ export declare const routineUpdateRoute: import("@jini-ai/http-kit").JsonRouteSpec<RoutineUpdateRequest, RoutineResponse, RoutineHttpDeps, undefined>;
97
97
  export interface RoutineDeleteResponse {
98
98
  readonly ok: true;
99
99
  }
100
- export declare const routineDeleteRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, RoutineDeleteResponse, RoutineHttpDeps>;
100
+ export declare const routineDeleteRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, RoutineDeleteResponse, RoutineHttpDeps, undefined>;
101
101
  export interface RoutineRunNowResponse {
102
102
  readonly routine: Routine | null;
103
103
  readonly run: RoutineRun | null;
@@ -105,11 +105,11 @@ export interface RoutineRunNowResponse {
105
105
  readonly conversationId: string;
106
106
  readonly agentRunId: string;
107
107
  }
108
- export declare const routineRunNowRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, RoutineRunNowResponse, RoutineHttpDeps>;
108
+ export declare const routineRunNowRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, RoutineRunNowResponse, RoutineHttpDeps, undefined>;
109
109
  export interface RoutineRunsResponse {
110
110
  readonly runs: readonly RoutineRun[];
111
111
  }
112
- export declare const routineRunsListRoute: import("@jini-ai/http-kit").JsonRouteSpec<RoutineRunsQuery, RoutineRunsResponse, RoutineHttpDeps>;
112
+ export declare const routineRunsListRoute: import("@jini-ai/http-kit").JsonRouteSpec<RoutineRunsQuery, RoutineRunsResponse, RoutineHttpDeps, undefined>;
113
113
  /** Mounts every routine route on `app`. A pack's `http(app, services)` calls this directly. */
114
114
  export declare function registerRoutineRoutes({ app, deps, adapter }: {
115
115
  readonly app: Express;
@@ -48,7 +48,7 @@ export interface RunOwnershipRequired {
48
48
  /** Mount after authentication on routes with a runId parameter. Denial envelopes pass through intact.
49
49
  * @complexity O(1) adapter work plus the injected ownership lookup; no storage or identity defaults.
50
50
  */
51
- export declare function createRunOwnershipMiddleware({ authorize, principalHeaderName, isEventStream }: RunOwnershipRequired): RequestHandler;
51
+ export declare function createRunOwnershipMiddleware({ authorize, principalHeaderName, isEventStream }: RunOwnershipRequired, _optional?: Record<string, never>): RequestHandler;
52
52
  export interface OwnedRunListRequired<Run> {
53
53
  readonly principalHeaderName: string;
54
54
  readonly listRuns: (required: Record<string, never>, optional: {
@@ -69,5 +69,5 @@ export interface OwnedRunListRequired<Run> {
69
69
  * Missing principals receive the existing 401 envelope before the list port is called.
70
70
  * @complexity O(n) policy filtering for n listed runs; O(1) adapter space excluding results.
71
71
  */
72
- export declare function createOwnedRunListHandler<Run>({ listRuns, filterOwnedRuns, principalHeaderName }: OwnedRunListRequired<Run>): RequestHandler;
72
+ export declare function createOwnedRunListHandler<Run>({ listRuns, filterOwnedRuns, principalHeaderName }: OwnedRunListRequired<Run>, _optional?: Record<string, never>): RequestHandler;
73
73
  //# sourceMappingURL=run-credentials.d.ts.map
@@ -27,7 +27,7 @@ export function createDaemonAuthMiddleware({ authorize, authorizationHeaderName
27
27
  /** Mount after authentication on routes with a runId parameter. Denial envelopes pass through intact.
28
28
  * @complexity O(1) adapter work plus the injected ownership lookup; no storage or identity defaults.
29
29
  */
30
- export function createRunOwnershipMiddleware({ authorize, principalHeaderName, isEventStream }) {
30
+ export function createRunOwnershipMiddleware({ authorize, principalHeaderName, isEventStream }, _optional = {}) {
31
31
  return async (req, res, next) => {
32
32
  try {
33
33
  const decision = await authorize({ runId: req.params.runId || undefined, principalId: req.get(principalHeaderName) || undefined, eventStream: isEventStream({ path: req.path }) });
@@ -46,7 +46,7 @@ export function createRunOwnershipMiddleware({ authorize, principalHeaderName, i
46
46
  * Missing principals receive the existing 401 envelope before the list port is called.
47
47
  * @complexity O(n) policy filtering for n listed runs; O(1) adapter space excluding results.
48
48
  */
49
- export function createOwnedRunListHandler({ listRuns, filterOwnedRuns, principalHeaderName }) {
49
+ export function createOwnedRunListHandler({ listRuns, filterOwnedRuns, principalHeaderName }, _optional = {}) {
50
50
  return async (req, res, next) => {
51
51
  try {
52
52
  const principalId = req.get(principalHeaderName) || undefined;
@@ -48,16 +48,16 @@ export interface RunCancelResponse {
48
48
  export interface RunListResponse {
49
49
  readonly runs: readonly RunStatus[];
50
50
  }
51
- export declare const runStartRoute: import("@jini-ai/http-kit").JsonRouteSpec<RunCreateRequest, RunStartResponse, RunHttpDeps>;
51
+ export declare const runStartRoute: import("@jini-ai/http-kit").JsonRouteSpec<RunCreateRequest, RunStartResponse, RunHttpDeps, undefined>;
52
52
  /** `GET /api/runs` — lists runs, optionally scoped to a `contextRef` query parameter. */
53
53
  export declare const runListRoute: import("@jini-ai/http-kit").JsonRouteSpec<{
54
54
  contextRef?: string;
55
- }, RunListResponse, RunHttpDeps>;
56
- export declare const runStatusRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, RunStatusResponse, RunHttpDeps>;
55
+ }, RunListResponse, RunHttpDeps, undefined>;
56
+ export declare const runStatusRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, RunStatusResponse, RunHttpDeps, undefined>;
57
57
  export declare const runCancelRoute: import("@jini-ai/http-kit").JsonRouteSpec<{
58
58
  runId: string;
59
59
  reason?: string;
60
- }, RunCancelResponse, RunHttpDeps>;
60
+ }, RunCancelResponse, RunHttpDeps, undefined>;
61
61
  /**
62
62
  * The core of `GET /api/runs/:runId/events` — canonical events as SSE, with Last-Event-ID
63
63
  * reconnect support. Takes `runId`/`afterCursor` already resolved by the caller. `res` is typed
@@ -35,14 +35,14 @@ export interface TerminalCreateRequest {
35
35
  * open-in route does, then authorizes+spawns the session through
36
36
  * `ToolExecutor.execute(..., 'terminal.create', ...)`.
37
37
  */
38
- export declare const terminalCreateRoute: import("@jini-ai/http-kit").JsonRouteSpec<TerminalCreateRequest, TerminalSessionInfo, TerminalsHttpDeps>;
38
+ export declare const terminalCreateRoute: import("@jini-ai/http-kit").JsonRouteSpec<TerminalCreateRequest, TerminalSessionInfo, TerminalsHttpDeps, undefined>;
39
39
  export interface TerminalListResponse {
40
40
  readonly terminals: readonly TerminalSessionInfo[];
41
41
  }
42
42
  /** `GET /api/terminals` — sessions the calling principal owns, optionally narrowed by `resourceRef`. Never gated through `ToolExecutor` — a read scoped to the caller's own sessions, matching `runs.ts`'s `runListRoute` precedent. */
43
43
  export declare const terminalListRoute: import("@jini-ai/http-kit").JsonRouteSpec<{
44
44
  resourceRef?: string;
45
- }, TerminalListResponse, TerminalsHttpDeps>;
45
+ }, TerminalListResponse, TerminalsHttpDeps, undefined>;
46
46
  export interface TerminalActionResponse {
47
47
  readonly ok: boolean;
48
48
  readonly terminal?: TerminalSessionInfo;
@@ -64,17 +64,17 @@ export declare function actionResultToApiResult({ result, notFoundMessage }: {
64
64
  export declare const terminalStdinRoute: import("@jini-ai/http-kit").JsonRouteSpec<{
65
65
  id: string;
66
66
  data: string;
67
- }, TerminalActionResponse, TerminalsHttpDeps>;
67
+ }, TerminalActionResponse, TerminalsHttpDeps, undefined>;
68
68
  /** `POST /api/terminals/:id/resize` — resizes the session's pty. */
69
69
  export declare const terminalResizeRoute: import("@jini-ai/http-kit").JsonRouteSpec<{
70
70
  id: string;
71
71
  cols: number;
72
72
  rows: number;
73
- }, TerminalActionResponse, TerminalsHttpDeps>;
73
+ }, TerminalActionResponse, TerminalsHttpDeps, undefined>;
74
74
  /** `POST /api/terminals/:id/kill` — sends `SIGTERM` to the session's pty. */
75
- export declare const terminalKillRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, TerminalActionResponse, TerminalsHttpDeps>;
75
+ export declare const terminalKillRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, TerminalActionResponse, TerminalsHttpDeps, undefined>;
76
76
  /** `DELETE /api/terminals/:id` — alias for `kill`, matching OD's dual `POST .../kill` / `DELETE` routes. */
77
- export declare const terminalDeleteRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, TerminalActionResponse, TerminalsHttpDeps>;
77
+ export declare const terminalDeleteRoute: import("@jini-ai/http-kit").JsonRouteSpec<string, TerminalActionResponse, TerminalsHttpDeps, undefined>;
78
78
  /** The one method {@link createDeferredEndGate} needs from `sse.ts`'s channel — narrowed so the gate is unit-testable against a bare fake, not a real `SseChannel`. */
79
79
  interface DeferredEndChannel {
80
80
  end(): void;
@@ -52,7 +52,7 @@ export declare const toolCatalogSearchRoute: import("@jini-ai/http-kit").JsonRou
52
52
  limit: number;
53
53
  }, {
54
54
  hits: readonly ToolCatalogSearchHit[];
55
- }, ToolCatalogHttpDeps>;
55
+ }, ToolCatalogHttpDeps, undefined>;
56
56
  /**
57
57
  * `GET /api/tools/:id` — full descriptor (schema included), paid for only once a candidate survives
58
58
  * search.
@@ -68,7 +68,7 @@ export declare const toolCatalogSearchRoute: import("@jini-ai/http-kit").JsonRou
68
68
  */
69
69
  export declare const toolCatalogDescribeRoute: import("@jini-ai/http-kit").JsonRouteSpec<{
70
70
  id: string;
71
- }, ToolCatalogEntry, ToolCatalogHttpDeps>;
71
+ }, ToolCatalogEntry, ToolCatalogHttpDeps, undefined>;
72
72
  /** Mounts both tool-catalog routes on `app`. A pack's `http({ app, services })` calls this directly. */
73
73
  export declare function registerToolCatalogRoutes({ app, deps, adapter }: {
74
74
  readonly app: Express;
@@ -45,7 +45,7 @@ export interface XaiOauthStartResponse {
45
45
  readonly port: number;
46
46
  };
47
47
  }
48
- export declare const xaiOauthStartRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, XaiOauthStartResponse, XaiHttpDeps>;
48
+ export declare const xaiOauthStartRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, XaiOauthStartResponse, XaiHttpDeps, undefined>;
49
49
  export interface XaiOkResponse {
50
50
  readonly ok: true;
51
51
  }
@@ -53,8 +53,8 @@ interface XaiOauthCompleteRequest {
53
53
  readonly state: string;
54
54
  readonly code: string;
55
55
  }
56
- export declare const xaiOauthCompleteRoute: import("@jini-ai/http-kit").JsonRouteSpec<XaiOauthCompleteRequest, XaiOkResponse, XaiHttpDeps>;
57
- export declare const xaiOauthCancelRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, XaiOkResponse, XaiHttpDeps>;
56
+ export declare const xaiOauthCompleteRoute: import("@jini-ai/http-kit").JsonRouteSpec<XaiOauthCompleteRequest, XaiOkResponse, XaiHttpDeps, undefined>;
57
+ export declare const xaiOauthCancelRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, XaiOkResponse, XaiHttpDeps, undefined>;
58
58
  export interface XaiAuthStatusResponse {
59
59
  readonly connected: boolean;
60
60
  readonly expiresAt: number | null;
@@ -62,8 +62,8 @@ export interface XaiAuthStatusResponse {
62
62
  readonly savedAt: number | null;
63
63
  readonly listening: boolean;
64
64
  }
65
- export declare const xaiAuthStatusRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, XaiAuthStatusResponse, XaiHttpDeps>;
66
- export declare const xaiOauthDisconnectRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, XaiOkResponse, XaiHttpDeps>;
65
+ export declare const xaiAuthStatusRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, XaiAuthStatusResponse, XaiHttpDeps, undefined>;
66
+ export declare const xaiOauthDisconnectRoute: import("@jini-ai/http-kit").JsonRouteSpec<void, XaiOkResponse, XaiHttpDeps, undefined>;
67
67
  interface XaiSearchRequest {
68
68
  readonly query: string;
69
69
  readonly allowedXHandles?: readonly string[];
@@ -79,7 +79,7 @@ export interface XaiSearchResponse {
79
79
  readonly citations: readonly string[];
80
80
  readonly model: string;
81
81
  }
82
- export declare const xaiSearchRoute: import("@jini-ai/http-kit").JsonRouteSpec<XaiSearchRequest, XaiSearchResponse, XaiHttpDeps>;
82
+ export declare const xaiSearchRoute: import("@jini-ai/http-kit").JsonRouteSpec<XaiSearchRequest, XaiSearchResponse, XaiHttpDeps, undefined>;
83
83
  /** Mounts every xAI route on `app`. A pack's `http(app, services)` calls this directly. */
84
84
  export declare function registerXaiRoutes({ app, deps, adapter }: {
85
85
  readonly app: Express;