@hachej/boring-agent 0.1.109 → 0.1.111

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 (30) hide show
  1. package/dist/{errors-CEU4iujR.d.ts → admin-DORVQfLn.d.ts} +80 -3
  2. package/dist/{chunk-GS4ADE34.js → chunk-42D6KAQV.js} +36 -12
  3. package/dist/{chunk-6OANSUEI.js → chunk-72KT6VWV.js} +59 -2
  4. package/dist/{chunk-3JFPS2O6.js → chunk-KJIEMSQP.js} +10 -1
  5. package/dist/{chunk-MVKXLMH3.js → chunk-KN72XWP7.js} +1 -1
  6. package/dist/{chunk-KDXIXVF6.js → chunk-V3H5A3BR.js} +12410 -5047
  7. package/dist/core/index.d.ts +5 -5
  8. package/dist/core/index.js +2 -1
  9. package/dist/{createHarness-AHWSC36D.js → createHarness-DOLOHA62.js} +2 -2
  10. package/dist/file-search-BUgMSKZE.d.ts +289 -0
  11. package/dist/front/index.d.ts +89 -4
  12. package/dist/front/index.js +508 -47
  13. package/dist/front/styles.css +55 -55
  14. package/dist/{harness-Ct0e4RWc.d.ts → harness-qHlMJhZo.d.ts} +1 -1
  15. package/dist/{piChatEvent-BUWIzw5l.d.ts → piChatEvent-DpE0lIb9.d.ts} +49 -17
  16. package/dist/{piChatSessionService-nvroRAVk.d.ts → piChatSessionService-CBct-hmz.d.ts} +4 -1
  17. package/dist/server/agent-host/testing/gatewayConformance.d.ts +7 -6
  18. package/dist/server/agent-host/testing/gatewayConformance.js +14 -7
  19. package/dist/server/index.d.ts +890 -56
  20. package/dist/server/index.js +73 -7
  21. package/dist/server/worker/index.js +5 -5
  22. package/dist/{lease-nASWv2tU.d.ts → share-entry-CxS6UJ_L.d.ts} +77 -179
  23. package/dist/shared/index.d.ts +118 -222
  24. package/dist/shared/index.js +17 -5
  25. package/dist/{types-B7-PN5jV.d.ts → types-DcWoQMn8.d.ts} +346 -10
  26. package/docs/AGENT_GATEWAY_V0.md +22 -2
  27. package/docs/AGENT_PACKAGES.md +15 -5
  28. package/docs/ERROR_CODES.md +14 -0
  29. package/package.json +10 -18
  30. package/dist/file-search-BGUHnW9o.d.ts +0 -87
@@ -3,6 +3,19 @@ import {
3
3
  AgentFleetCompilationError,
4
4
  AgentFleetCompilationErrorCode,
5
5
  AuthoredAgentMaterializationError,
6
+ CHANNELS_ENV_FLAG,
7
+ CHANNEL_DURABLE_STREAM_REQUIRED,
8
+ CHANNEL_INBOUND_PARKED,
9
+ CHANNEL_OUTBOUND_PARKED,
10
+ CHANNEL_RUNTIME_FILE_NAME,
11
+ CHANNEL_TURN_STALLED,
12
+ CHANNEL_UNKNOWN_BINDING,
13
+ ChannelBindingStore,
14
+ ChannelInboundService,
15
+ ChannelIntentionService,
16
+ ChannelMessageRouter,
17
+ ChannelOutboundService,
18
+ ChannelSessionCreateTimeoutError,
6
19
  DEFAULT_AGENT_FLEET,
7
20
  DEFAULT_AGENT_TYPE_ID,
8
21
  DEFAULT_PI_RESOURCE_DIGEST_LIMITS,
@@ -12,8 +25,10 @@ import {
12
25
  InMemoryAgentRequestLedger,
13
26
  MANAGED_AGENT_MCP_DELIVERY_RULE,
14
27
  MANAGED_AGENT_MCP_ORIGIN_SURFACE,
28
+ MIN_REQUEST_RETENTION_MS,
15
29
  ManagedAgentMcpDelegateController,
16
30
  ManagedAgentMcpError,
31
+ PI_OAUTH_CREDENTIAL_FIELD_ID_V1,
17
32
  REMOTE_WORKER_EXCLUSIVE_BINARY_CREATE_CAPABILITY,
18
33
  REMOTE_WORKER_PROVIDER,
19
34
  REMOTE_WORKER_RUNTIME_CWD,
@@ -30,28 +45,40 @@ import {
30
45
  WORKER_REQUEST_ID_HEADER,
31
46
  WORKER_WORKSPACE_ID_HEADER,
32
47
  applyCspHeaders,
48
+ areChannelsEnabled,
49
+ assembleNextTurn,
50
+ assertChannelDurability,
33
51
  autoDetectMode,
34
52
  buildDeploymentSnapshotRecipe,
35
53
  compileAgentDirectory,
36
54
  compilePersonaPackageDirectory,
37
55
  constantTimeTokenEqual,
38
56
  createAgentHost,
57
+ createAgentHostChannelRuntime,
58
+ createAgentHostChannelStorage,
39
59
  createAuthMiddleware,
40
60
  createBlaxelSandboxModeAdapter,
41
61
  createBoundWorkspaceAgentDispatcher,
62
+ createChannelIntentionRuntime,
42
63
  createConfiguredAgentHostAgentSpec,
43
64
  createDirectModeAdapter,
44
65
  createEnvironmentProvisioningFingerprint,
45
- createFakeAuthorityVerifierV1,
46
66
  createHostSideCredentialResolverV1,
47
67
  createInMemoryCredentialBackendV1,
68
+ createInMemoryCredentialVaultPersistenceV1,
69
+ createInMemoryCredentialVersionAnchorV1,
70
+ createLocalCredentialVersionAnchorFromEnvV1,
71
+ createLocalFileCredentialVersionAnchorV1,
72
+ createLocalKekWorkspaceKekProviderFromEnvV1,
48
73
  createLocalModeAdapter,
49
74
  createManagedAgentMcpDelegateController,
50
75
  createManagedAgentMcpHttpHandler,
51
76
  createManagedAgentMcpServer,
77
+ createOpenAiCodexOAuthBrokerV1,
52
78
  createPiResourceDigestFence,
53
79
  createPiResourceDigestInput,
54
80
  createPluginDiagnosticsTool,
81
+ createPostgresCredentialVaultPersistenceV1,
55
82
  createProviderRuntimeModeAdapter,
56
83
  createRemoteWorkerModeAdapter,
57
84
  createRemoteWorkerSandbox,
@@ -62,12 +89,15 @@ import {
62
89
  createStandaloneAgentHostApp,
63
90
  createUserFilesystemBinding,
64
91
  createValidatingAgentFleetCompiler,
92
+ createVaultCredentialStoreBackendV1,
93
+ createVaultCredentialStoreV1,
65
94
  createVercelSandboxModeAdapter,
66
95
  decodeBytesFromWorker,
67
96
  deepLinkRoutes,
68
97
  digestPiResourceInputs,
69
98
  encodeBytesForWorker,
70
99
  hasBwrap,
100
+ initializeLocalFileCredentialVersionAnchorV1,
71
101
  loadConfiguredAgentFleet,
72
102
  materializeAgentDirectory,
73
103
  mergeRuntimeFilesystemBindings,
@@ -75,6 +105,7 @@ import {
75
105
  normalizeRuntimeReadonlyFilesystemPolicy,
76
106
  parseSkillMetadataFrontmatter,
77
107
  prepareDeploymentSnapshot,
108
+ projectAgentRequestRunId,
78
109
  projectAuthorizedSessionRunDetails,
79
110
  provisionRuntimeWorkspace,
80
111
  provisionWorkspaceRuntime,
@@ -88,29 +119,44 @@ import {
88
119
  resolveRequestLedgerPath,
89
120
  resolveRuntimeReadonlyFilesystemAccess,
90
121
  resolveWorkspaceRoot,
122
+ runCredentialVaultPostgresMigrationsV1,
91
123
  sandboxRuntimeHostOperations,
124
+ shapeChannelText,
92
125
  shareResourceUri,
93
126
  withResolvedCredential,
94
127
  withRuntimeEnvContributions
95
- } from "../chunk-KDXIXVF6.js";
128
+ } from "../chunk-V3H5A3BR.js";
96
129
  import {
97
130
  PI_PACKAGE_RESOURCE_FILTERS,
98
131
  compactPiPackages,
99
132
  createResourceSettingsManager,
100
133
  mergePiPackageSources,
101
134
  piPackageSourceKey
102
- } from "../chunk-GS4ADE34.js";
103
- import "../chunk-6OANSUEI.js";
135
+ } from "../chunk-42D6KAQV.js";
136
+ import "../chunk-72KT6VWV.js";
104
137
  import "../chunk-7XAOVFSN.js";
105
138
  import "../chunk-YTUZFKB3.js";
106
- import "../chunk-MVKXLMH3.js";
139
+ import "../chunk-KN72XWP7.js";
107
140
  import "../chunk-YGRQ4Q5P.js";
108
- import "../chunk-3JFPS2O6.js";
141
+ import "../chunk-KJIEMSQP.js";
109
142
  export {
110
143
  AgentDirectoryCompilerError,
111
144
  AgentFleetCompilationError,
112
145
  AgentFleetCompilationErrorCode,
113
146
  AuthoredAgentMaterializationError,
147
+ CHANNELS_ENV_FLAG,
148
+ CHANNEL_DURABLE_STREAM_REQUIRED,
149
+ CHANNEL_INBOUND_PARKED,
150
+ CHANNEL_OUTBOUND_PARKED,
151
+ CHANNEL_RUNTIME_FILE_NAME,
152
+ CHANNEL_TURN_STALLED,
153
+ CHANNEL_UNKNOWN_BINDING,
154
+ ChannelBindingStore,
155
+ ChannelInboundService,
156
+ ChannelIntentionService,
157
+ ChannelMessageRouter,
158
+ ChannelOutboundService,
159
+ ChannelSessionCreateTimeoutError,
114
160
  DEFAULT_AGENT_FLEET,
115
161
  DEFAULT_AGENT_TYPE_ID,
116
162
  DEFAULT_PI_RESOURCE_DIGEST_LIMITS,
@@ -120,8 +166,10 @@ export {
120
166
  InMemoryAgentRequestLedger,
121
167
  MANAGED_AGENT_MCP_DELIVERY_RULE,
122
168
  MANAGED_AGENT_MCP_ORIGIN_SURFACE,
169
+ MIN_REQUEST_RETENTION_MS,
123
170
  ManagedAgentMcpDelegateController,
124
171
  ManagedAgentMcpError,
172
+ PI_OAUTH_CREDENTIAL_FIELD_ID_V1,
125
173
  PI_PACKAGE_RESOURCE_FILTERS,
126
174
  REMOTE_WORKER_EXCLUSIVE_BINARY_CREATE_CAPABILITY,
127
175
  REMOTE_WORKER_PROVIDER,
@@ -139,6 +187,9 @@ export {
139
187
  WORKER_REQUEST_ID_HEADER,
140
188
  WORKER_WORKSPACE_ID_HEADER,
141
189
  applyCspHeaders,
190
+ areChannelsEnabled,
191
+ assembleNextTurn,
192
+ assertChannelDurability,
142
193
  autoDetectMode,
143
194
  buildDeploymentSnapshotRecipe,
144
195
  compactPiPackages,
@@ -147,21 +198,30 @@ export {
147
198
  constantTimeTokenEqual,
148
199
  createAuthMiddleware as createAgentAuthMiddleware,
149
200
  createAgentHost,
201
+ createAgentHostChannelRuntime,
202
+ createAgentHostChannelStorage,
150
203
  createBlaxelSandboxModeAdapter,
151
204
  createBoundWorkspaceAgentDispatcher,
205
+ createChannelIntentionRuntime,
152
206
  createConfiguredAgentHostAgentSpec,
153
207
  createDirectModeAdapter,
154
208
  createEnvironmentProvisioningFingerprint,
155
- createFakeAuthorityVerifierV1,
156
209
  createHostSideCredentialResolverV1,
157
210
  createInMemoryCredentialBackendV1,
211
+ createInMemoryCredentialVaultPersistenceV1,
212
+ createInMemoryCredentialVersionAnchorV1,
213
+ createLocalCredentialVersionAnchorFromEnvV1,
214
+ createLocalFileCredentialVersionAnchorV1,
215
+ createLocalKekWorkspaceKekProviderFromEnvV1,
158
216
  createLocalModeAdapter,
159
217
  createManagedAgentMcpDelegateController,
160
218
  createManagedAgentMcpHttpHandler,
161
219
  createManagedAgentMcpServer,
220
+ createOpenAiCodexOAuthBrokerV1,
162
221
  createPiResourceDigestFence,
163
222
  createPiResourceDigestInput,
164
223
  createPluginDiagnosticsTool,
224
+ createPostgresCredentialVaultPersistenceV1,
165
225
  createProviderRuntimeModeAdapter,
166
226
  createRemoteWorkerModeAdapter,
167
227
  createRemoteWorkerSandbox,
@@ -173,12 +233,15 @@ export {
173
233
  createStandaloneAgentHostApp,
174
234
  createUserFilesystemBinding,
175
235
  createValidatingAgentFleetCompiler,
236
+ createVaultCredentialStoreBackendV1,
237
+ createVaultCredentialStoreV1,
176
238
  createVercelSandboxModeAdapter,
177
239
  decodeBytesFromWorker,
178
240
  deepLinkRoutes,
179
241
  digestPiResourceInputs,
180
242
  encodeBytesForWorker,
181
243
  hasBwrap,
244
+ initializeLocalFileCredentialVersionAnchorV1,
182
245
  loadConfiguredAgentFleet,
183
246
  materializeAgentDirectory,
184
247
  mergePiPackageSources,
@@ -188,6 +251,7 @@ export {
188
251
  parseSkillMetadataFrontmatter,
189
252
  piPackageSourceKey,
190
253
  prepareDeploymentSnapshot,
254
+ projectAgentRequestRunId,
191
255
  projectAuthorizedSessionRunDetails,
192
256
  provisionRuntimeWorkspace,
193
257
  provisionWorkspaceRuntime,
@@ -201,7 +265,9 @@ export {
201
265
  resolveRequestLedgerPath,
202
266
  resolveRuntimeReadonlyFilesystemAccess,
203
267
  resolveWorkspaceRoot,
268
+ runCredentialVaultPostgresMigrationsV1,
204
269
  sandboxRuntimeHostOperations,
270
+ shapeChannelText,
205
271
  shareResourceUri,
206
272
  withResolvedCredential,
207
273
  withRuntimeEnvContributions
@@ -2,14 +2,14 @@ import {
2
2
  REMOTE_WORKER_EXCLUSIVE_BINARY_CREATE_CAPABILITY,
3
3
  WORKER_INTERNAL_TOKEN_HEADER,
4
4
  constantTimeTokenEqual
5
- } from "../../chunk-KDXIXVF6.js";
6
- import "../../chunk-GS4ADE34.js";
7
- import "../../chunk-6OANSUEI.js";
5
+ } from "../../chunk-V3H5A3BR.js";
6
+ import "../../chunk-42D6KAQV.js";
7
+ import "../../chunk-72KT6VWV.js";
8
8
  import "../../chunk-7XAOVFSN.js";
9
9
  import "../../chunk-YTUZFKB3.js";
10
- import "../../chunk-MVKXLMH3.js";
10
+ import "../../chunk-KN72XWP7.js";
11
11
  import "../../chunk-YGRQ4Q5P.js";
12
- import "../../chunk-3JFPS2O6.js";
12
+ import "../../chunk-KJIEMSQP.js";
13
13
 
14
14
  // src/server/worker/index.ts
15
15
  import Fastify from "fastify";
@@ -1,7 +1,80 @@
1
+ import { C as CredentialConsumerBindingId, P as ProviderId, a as CredentialFieldId, b as ProviderRegistryV1, c as ProviderDefinitionV1, d as CredentialFieldDefinitionV1, A as AuthorizedWorkspaceCredentialScopeV1 } from './file-search-BUgMSKZE.js';
1
2
  import { z } from 'zod';
2
- import { A as AgentDefinitionErrorCode, p as AgentDeploymentErrorCode } from './piChatEvent-BUWIzw5l.js';
3
+ import { A as AgentDefinitionErrorCode, p as AgentDeploymentErrorCode } from './piChatEvent-DpE0lIb9.js';
3
4
  import { b as Workspace } from './sandbox-BMhut3kh.js';
4
5
 
6
+ type CredentialConsumerKindV1 = "model-provider" | "first-party-tool" | "plugin-server" | "mcp-server" | "tenant-custom-tool";
7
+ type CredentialDeliveryV1 = "host-only" | "sandbox-pipe" | "sandbox-tmpfs";
8
+ /** Immutable authority registered by the host beside the tool/provider catalog. */
9
+ interface CredentialConsumerBindingV1 {
10
+ readonly contractVersion: "boring.credential-consumer-binding.v1";
11
+ readonly id: CredentialConsumerBindingId;
12
+ readonly providerId: ProviderId;
13
+ readonly consumer: Readonly<{
14
+ id: string;
15
+ kind: CredentialConsumerKindV1;
16
+ trust: "trusted" | "untrusted";
17
+ }>;
18
+ readonly purpose: string;
19
+ readonly allowedFieldIds: readonly CredentialFieldId[];
20
+ readonly delivery: CredentialDeliveryV1;
21
+ readonly sandbox?: Readonly<{
22
+ credentialChannel: "fd-3" | "tmpfs-v1";
23
+ egressOrigins: readonly `https://${string}`[];
24
+ }>;
25
+ }
26
+ interface CredentialConsumerBindingRegistryV1 {
27
+ readonly contractVersion: "boring.credential-consumer-bindings.v1";
28
+ require(bindingId: CredentialConsumerBindingId): CredentialConsumerBindingV1;
29
+ }
30
+ declare function providerCredentialFieldsV1(provider: ProviderDefinitionV1): readonly CredentialFieldDefinitionV1[];
31
+ declare function createCredentialConsumerBindingRegistryV1(bindings: readonly CredentialConsumerBindingV1[], providerRegistry: ProviderRegistryV1): CredentialConsumerBindingRegistryV1;
32
+
33
+ declare const PROVIDER_CREDENTIAL_REF_VERSION: "boring.provider-credential-ref.v1";
34
+ /** Constructed by a trusted factory from a registered binding. */
35
+ interface ProviderCredentialRefV1 {
36
+ readonly contractVersion: typeof PROVIDER_CREDENTIAL_REF_VERSION;
37
+ readonly providerId: ProviderId;
38
+ readonly executionId: string;
39
+ readonly bindingId: CredentialConsumerBindingId;
40
+ }
41
+ interface ProviderCredentialRefFactoryV1 {
42
+ readonly contractVersion: "boring.provider-credential-ref-factory.v1";
43
+ create(input: Readonly<{
44
+ providerId: ProviderId;
45
+ executionId: string;
46
+ bindingId: CredentialConsumerBindingId;
47
+ }>): ProviderCredentialRefV1;
48
+ }
49
+ declare function createProviderCredentialRefFactoryV1(bindingRegistry: CredentialConsumerBindingRegistryV1): ProviderCredentialRefFactoryV1;
50
+
51
+ type ResolvedCredentialMaterialV1 = Readonly<{
52
+ kind: "field-set";
53
+ fields: ReadonlyMap<CredentialFieldId, Uint8Array>;
54
+ }> | Readonly<{
55
+ kind: "external-managed-account";
56
+ custodianAdapterId: string;
57
+ opaqueAccountReference: Uint8Array;
58
+ }> | Readonly<{
59
+ kind: "none";
60
+ }>;
61
+ interface ResolvedCredentialLeaseV1 {
62
+ readonly contractVersion: "boring.resolved-credential.v1";
63
+ readonly workspaceId: string;
64
+ readonly providerId: ProviderId;
65
+ readonly credentialVersion: number;
66
+ readonly executionId: string;
67
+ /** Server implementation may use a Node byte array; shared stays Uint8Array. */
68
+ readonly material: ResolvedCredentialMaterialV1;
69
+ readonly expiresAt: string;
70
+ /** Idempotent best-effort overwrite and reference release. */
71
+ dispose(): void;
72
+ }
73
+ interface WorkspaceCredentialResolverV1 {
74
+ readonly contractVersion: "boring.workspace-credential-resolver.v1";
75
+ resolve(workspace: AuthorizedWorkspaceCredentialScopeV1, ref: ProviderCredentialRefV1): Promise<ResolvedCredentialLeaseV1>;
76
+ }
77
+
5
78
  interface SandboxHandleRecord {
6
79
  workspaceId: string;
7
80
  sandboxId: string;
@@ -137,8 +210,8 @@ declare const ShareEntryV1Schema: z.ZodObject<{
137
210
  producerPrincipalRef: string;
138
211
  }>;
139
212
  }, "strict", z.ZodTypeAny, {
140
- path: string;
141
213
  id: string;
214
+ path: string;
142
215
  workspaceId: string;
143
216
  schemaVersion: 1;
144
217
  provenance: {
@@ -146,8 +219,8 @@ declare const ShareEntryV1Schema: z.ZodObject<{
146
219
  producerPrincipalRef: string;
147
220
  };
148
221
  }, {
149
- path: string;
150
222
  id: string;
223
+ path: string;
151
224
  workspaceId: string;
152
225
  schemaVersion: 1;
153
226
  provenance: {
@@ -254,179 +327,4 @@ type ShareEntryResolution = {
254
327
  */
255
328
  declare function resolveShareEntry(store: ShareEntryStore, id: string, workspace: Workspace): Promise<ShareEntryResolution>;
256
329
 
257
- /**
258
- * Opaque, in-process Core capability. The brand symbol and constructor are not
259
- * exported; Core records issued object identity in a private WeakMap.
260
- */
261
- declare const authorizedWorkspaceCredentialScopeBrand: unique symbol;
262
- interface AuthorizedWorkspaceCredentialScopeV1 {
263
- readonly contractVersion: "boring.authorized-workspace-credential-scope.v1";
264
- readonly [authorizedWorkspaceCredentialScopeBrand]: true;
265
- }
266
- type VerifiedWorkspaceCredentialPrincipalV1 = Readonly<{
267
- kind: "user";
268
- userId: string;
269
- membershipRole: "owner" | "editor" | "viewer";
270
- }> | Readonly<{
271
- kind: "system";
272
- principalId: string;
273
- workspaceGrantId: string;
274
- }>;
275
- interface VerifiedWorkspaceCredentialAuthorityV1 {
276
- readonly workspaceId: string;
277
- readonly appId: string;
278
- readonly principal: VerifiedWorkspaceCredentialPrincipalV1;
279
- readonly authorizationReceiptId: string;
280
- readonly expiresAt: string;
281
- }
282
- /** Core-owned verifier; a TypeScript cast or copied object is never authority. */
283
- interface WorkspaceCredentialAuthorityVerifierV1 {
284
- readonly contractVersion: "boring.workspace-credential-authority-verifier.v1";
285
- verifyCurrent(scope: AuthorizedWorkspaceCredentialScopeV1): Promise<VerifiedWorkspaceCredentialAuthorityV1>;
286
- }
287
-
288
- type ProviderId = string & {
289
- readonly __providerId: unique symbol;
290
- };
291
- type CredentialFieldId = string & {
292
- readonly __credentialFieldId: unique symbol;
293
- };
294
- type CredentialConsumerBindingId = string & {
295
- readonly __credentialConsumerBindingId: unique symbol;
296
- };
297
- type ProviderCategoryV1 = "llm" | "search" | "transcription" | "mcp" | "other";
298
- interface CredentialFieldDefinitionV1 {
299
- readonly id: CredentialFieldId;
300
- readonly label: string;
301
- readonly required: boolean;
302
- readonly sensitivity: "secret" | "public";
303
- readonly minBytes?: number;
304
- readonly maxBytes: number;
305
- }
306
- interface ExternalManagedAccountReferenceDefinitionV1 {
307
- readonly label: string;
308
- readonly maxBytes: number;
309
- readonly persistence: "server-only-metadata";
310
- }
311
- type ProviderCredentialDefinitionV1 = Readonly<{
312
- type: "api-key";
313
- fields: readonly CredentialFieldDefinitionV1[];
314
- }> | Readonly<{
315
- type: "oauth2-authorization-code";
316
- tokenCustody: "local-vault";
317
- clientRegistrationRef: string;
318
- authorizationEndpoint: `https://${string}`;
319
- tokenEndpoint: `https://${string}`;
320
- revocationEndpoint?: `https://${string}`;
321
- scopes: readonly string[];
322
- usePkce: true;
323
- refreshTokenField: CredentialFieldDefinitionV1;
324
- resolvedAccessTokenField: CredentialFieldDefinitionV1;
325
- accessTokenPersistence: "memory-only";
326
- }> | Readonly<{
327
- type: "oauth2-authorization-code";
328
- tokenCustody: "external-managed";
329
- custodianAdapterId: string;
330
- connectUrlOrigins: readonly `https://${string}`[];
331
- scopes: readonly string[];
332
- accountReference: ExternalManagedAccountReferenceDefinitionV1;
333
- delivery: "host-session-adapter-only";
334
- }> | Readonly<{
335
- type: "none";
336
- }>;
337
- interface ProviderDefinitionV1 {
338
- readonly contractVersion: "boring.provider.v1";
339
- readonly id: ProviderId;
340
- readonly displayName: string;
341
- readonly category: ProviderCategoryV1;
342
- readonly credential: ProviderCredentialDefinitionV1;
343
- readonly consumerBindingIds: readonly CredentialConsumerBindingId[];
344
- readonly sandboxEgressOrigins: readonly `https://${string}`[];
345
- readonly mcp?: Readonly<{
346
- transport: "streamable-http";
347
- endpoint?: `https://${string}`;
348
- toolkitId?: string;
349
- allowedTools: readonly string[];
350
- deniedTools: readonly string[];
351
- }>;
352
- }
353
- interface ProviderRegistryV1 {
354
- readonly contractVersion: "boring.provider-registry.v1";
355
- list(): readonly ProviderDefinitionV1[];
356
- require(providerId: ProviderId): ProviderDefinitionV1;
357
- }
358
- declare function createProviderRegistryV1(defs: readonly ProviderDefinitionV1[]): ProviderRegistryV1;
359
-
360
- type CredentialConsumerKindV1 = "model-provider" | "first-party-tool" | "plugin-server" | "mcp-server" | "tenant-custom-tool";
361
- type CredentialDeliveryV1 = "host-only" | "sandbox-pipe" | "sandbox-tmpfs";
362
- /** Immutable authority registered by the host beside the tool/provider catalog. */
363
- interface CredentialConsumerBindingV1 {
364
- readonly contractVersion: "boring.credential-consumer-binding.v1";
365
- readonly id: CredentialConsumerBindingId;
366
- readonly providerId: ProviderId;
367
- readonly consumer: Readonly<{
368
- id: string;
369
- kind: CredentialConsumerKindV1;
370
- trust: "trusted" | "untrusted";
371
- }>;
372
- readonly purpose: string;
373
- readonly allowedFieldIds: readonly CredentialFieldId[];
374
- readonly delivery: CredentialDeliveryV1;
375
- readonly sandbox?: Readonly<{
376
- credentialChannel: "fd-3" | "tmpfs-v1";
377
- egressOrigins: readonly `https://${string}`[];
378
- }>;
379
- }
380
- interface CredentialConsumerBindingRegistryV1 {
381
- readonly contractVersion: "boring.credential-consumer-bindings.v1";
382
- require(bindingId: CredentialConsumerBindingId): CredentialConsumerBindingV1;
383
- }
384
- declare function providerCredentialFieldsV1(provider: ProviderDefinitionV1): readonly CredentialFieldDefinitionV1[];
385
- declare function createCredentialConsumerBindingRegistryV1(bindings: readonly CredentialConsumerBindingV1[], providerRegistry: ProviderRegistryV1): CredentialConsumerBindingRegistryV1;
386
-
387
- declare const PROVIDER_CREDENTIAL_REF_VERSION: "boring.provider-credential-ref.v1";
388
- /** Constructed by a trusted factory from a registered binding. */
389
- interface ProviderCredentialRefV1 {
390
- readonly contractVersion: typeof PROVIDER_CREDENTIAL_REF_VERSION;
391
- readonly providerId: ProviderId;
392
- readonly executionId: string;
393
- readonly bindingId: CredentialConsumerBindingId;
394
- }
395
- interface ProviderCredentialRefFactoryV1 {
396
- readonly contractVersion: "boring.provider-credential-ref-factory.v1";
397
- create(input: Readonly<{
398
- providerId: ProviderId;
399
- executionId: string;
400
- bindingId: CredentialConsumerBindingId;
401
- }>): ProviderCredentialRefV1;
402
- }
403
- declare function createProviderCredentialRefFactoryV1(bindingRegistry: CredentialConsumerBindingRegistryV1): ProviderCredentialRefFactoryV1;
404
-
405
- type ResolvedCredentialMaterialV1 = Readonly<{
406
- kind: "field-set";
407
- fields: ReadonlyMap<CredentialFieldId, Uint8Array>;
408
- }> | Readonly<{
409
- kind: "external-managed-account";
410
- custodianAdapterId: string;
411
- opaqueAccountReference: Uint8Array;
412
- }> | Readonly<{
413
- kind: "none";
414
- }>;
415
- interface ResolvedCredentialLeaseV1 {
416
- readonly contractVersion: "boring.resolved-credential.v1";
417
- readonly workspaceId: string;
418
- readonly providerId: ProviderId;
419
- readonly credentialVersion: number;
420
- readonly executionId: string;
421
- /** Server implementation may use a Node byte array; shared stays Uint8Array. */
422
- readonly material: ResolvedCredentialMaterialV1;
423
- readonly expiresAt: string;
424
- /** Idempotent best-effort overwrite and reference release. */
425
- dispose(): void;
426
- }
427
- interface WorkspaceCredentialResolverV1 {
428
- readonly contractVersion: "boring.workspace-credential-resolver.v1";
429
- resolve(workspace: AuthorizedWorkspaceCredentialScopeV1, ref: ProviderCredentialRefV1): Promise<ResolvedCredentialLeaseV1>;
430
- }
431
-
432
- export { createAgentDeploymentDigest as $, type AgentSchemaIssue as A, type ResolvedCredentialMaterialV1 as B, type CredentialConsumerBindingId as C, type SandboxHandleRecord as D, type ExternalManagedAccountReferenceDefinitionV1 as E, type SandboxHandleStore as F, Sha256DigestSchema as G, ShareEntryErrorCode as H, InMemoryShareEntryStore as I, type ShareEntryProvenance as J, ShareEntryProvenanceSchema as K, type ShareEntryResolution as L, type ShareEntryStore as M, type ShareEntryTombstone as N, OpaqueRefSchema as O, type ProviderCredentialRefV1 as P, type ShareEntryV1 as Q, type ResolvedCredentialLeaseV1 as R, SchemaValidationError as S, ShareEntryV1Schema as T, ShareEntryValidationError as U, type VerifiedWorkspaceCredentialAuthorityV1 as V, type VerifiedWorkspaceCredentialPrincipalV1 as W, type WorkspaceCredentialAuthorityVerifierV1 as X, type WorkspaceCredentialResolverV1 as Y, createAgentAssetDigest as Z, createAgentDefinitionDigest as _, type Sha256Digest as a, createCredentialConsumerBindingRegistryV1 as a0, createProviderCredentialRefFactoryV1 as a1, createProviderRegistryV1 as a2, providerCredentialFieldsV1 as a3, resolveShareEntry as a4, validateAgentDefinition as a5, validateAgentDeployment as a6, type AgentSchemaValidationResult as b, type CredentialFieldId as c, type AuthorizedWorkspaceCredentialScopeV1 as d, type AgentDefinition as e, type AgentDefinitionDigestAsset as f, type AgentDefinitionReference as g, AgentDefinitionValidationError as h, type AgentDeployment as i, AgentDeploymentValidationError as j, type CompiledAgentBundle as k, type CompiledAgentDefinition as l, type CreateShareEntryInput as m, type CredentialConsumerBindingRegistryV1 as n, type CredentialConsumerBindingV1 as o, type CredentialConsumerKindV1 as p, type CredentialDeliveryV1 as q, type CredentialFieldDefinitionV1 as r, OpaqueShareLocatorIdSchema as s, PROVIDER_CREDENTIAL_REF_VERSION as t, type ProviderCategoryV1 as u, type ProviderCredentialDefinitionV1 as v, type ProviderCredentialRefFactoryV1 as w, type ProviderDefinitionV1 as x, type ProviderId as y, type ProviderRegistryV1 as z };
330
+ export { type AgentSchemaIssue as A, type ShareEntryTombstone as B, type CompiledAgentBundle as C, type ShareEntryV1 as D, ShareEntryV1Schema as E, ShareEntryValidationError as F, createAgentAssetDigest as G, createAgentDefinitionDigest as H, InMemoryShareEntryStore as I, createAgentDeploymentDigest as J, createCredentialConsumerBindingRegistryV1 as K, createProviderCredentialRefFactoryV1 as L, providerCredentialFieldsV1 as M, resolveShareEntry as N, OpaqueRefSchema as O, type ProviderCredentialRefV1 as P, validateAgentDefinition as Q, type ResolvedCredentialLeaseV1 as R, SchemaValidationError as S, validateAgentDeployment as T, type WorkspaceCredentialResolverV1 as W, type Sha256Digest as a, type AgentSchemaValidationResult as b, type AgentDefinition as c, type AgentDefinitionDigestAsset as d, type AgentDefinitionReference as e, AgentDefinitionValidationError as f, type AgentDeployment as g, AgentDeploymentValidationError as h, type CompiledAgentDefinition as i, type CreateShareEntryInput as j, type CredentialConsumerBindingRegistryV1 as k, type CredentialConsumerBindingV1 as l, type CredentialConsumerKindV1 as m, type CredentialDeliveryV1 as n, OpaqueShareLocatorIdSchema as o, PROVIDER_CREDENTIAL_REF_VERSION as p, type ProviderCredentialRefFactoryV1 as q, type ResolvedCredentialMaterialV1 as r, type SandboxHandleRecord as s, type SandboxHandleStore as t, Sha256DigestSchema as u, ShareEntryErrorCode as v, type ShareEntryProvenance as w, ShareEntryProvenanceSchema as x, type ShareEntryResolution as y, type ShareEntryStore as z };