stitchkit 0.55.0 → 0.56.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/dist/browser/socket-io.d.ts +14 -6
- package/dist/browser/socket-io.d.ts.map +1 -1
- package/dist/cli.js +4 -4
- package/dist/contract/errors.d.ts +7 -0
- package/dist/contract/errors.d.ts.map +1 -1
- package/dist/contract/index.js +1 -1
- package/dist/files/boundary.d.ts +8 -5
- package/dist/files/boundary.d.ts.map +1 -1
- package/dist/files.js +1 -1
- package/dist/{index-rgd18hx3.js → index-28cqssm3.js} +7 -0
- package/dist/index-557by2db.js +34 -0
- package/dist/index-5r13htq1.js +283 -0
- package/dist/index-6y759j86.js +1031 -0
- package/dist/{index-1k16zv57.js → index-bfcpjw20.js} +125 -31
- package/dist/{index-0gv7k0ra.js → index-escqg10p.js} +73 -666
- package/dist/{index-v4bbq3p4.js → index-j3dem06f.js} +1 -1
- package/dist/{index-qx84bqzk.js → index-jcc611vh.js} +1 -1
- package/dist/{index-npye5kt7.js → index-n4nfa7gh.js} +3 -3
- package/dist/{index-pzc32v75.js → index-sm2tjx06.js} +41 -4
- package/dist/{index-js7yexng.js → index-xy8fmh6w.js} +83 -4
- package/dist/index.d.ts +2 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +27 -6
- package/dist/node.js +5 -4
- package/dist/observability/index.js +3 -3
- package/dist/remote.js +1 -1
- package/dist/server/context-contribution.d.ts +8 -0
- package/dist/server/context-contribution.d.ts.map +1 -1
- package/dist/server/index.d.ts +1 -1
- package/dist/server/index.d.ts.map +1 -1
- package/dist/server/index.js +8 -5
- package/dist/server/middleware/auth.d.ts +29 -2
- package/dist/server/middleware/auth.d.ts.map +1 -1
- package/dist/testing/surface-conformance.d.ts +143 -10
- package/dist/testing/surface-conformance.d.ts.map +1 -1
- package/dist/testing/surface-manifest.d.ts +132 -33
- package/dist/testing/surface-manifest.d.ts.map +1 -1
- package/dist/testing.d.ts +2 -2
- package/dist/testing.d.ts.map +1 -1
- package/dist/testing.js +470 -122
- package/dist/tools/async-operation.d.ts +210 -18
- package/dist/tools/async-operation.d.ts.map +1 -1
- package/dist/tools/define-download-tool.d.ts.map +1 -1
- package/dist/tools/define-upload-tool.d.ts.map +1 -1
- package/dist/tools/internal/surface-projector.d.ts +101 -0
- package/dist/tools/internal/surface-projector.d.ts.map +1 -0
- package/dist/tools/managed-file-error.d.ts +6 -0
- package/dist/tools/managed-file-error.d.ts.map +1 -0
- package/dist/tools/mcp-prepare.d.ts +3 -21
- package/dist/tools/mcp-prepare.d.ts.map +1 -1
- package/dist/tools/mcp-round-policy.d.ts +9 -0
- package/dist/tools/mcp-round-policy.d.ts.map +1 -0
- package/dist/tools/mcp-round.d.ts +0 -4
- package/dist/tools/mcp-round.d.ts.map +1 -1
- package/dist/tools/mount-download.d.ts.map +1 -1
- package/dist/tools/mount-upload.d.ts.map +1 -1
- package/dist/tools/mount.d.ts +5 -9
- package/dist/tools/mount.d.ts.map +1 -1
- package/dist/tools/runtime-tool.d.ts.map +1 -1
- package/dist/tools/surface.d.ts +7 -0
- package/dist/tools/surface.d.ts.map +1 -1
- package/dist/tools/view-file.d.ts.map +1 -1
- package/dist/tools.d.ts +1 -1
- package/dist/tools.d.ts.map +1 -1
- package/dist/tools.js +348 -383
- package/llms-full.txt +361 -58
- package/package.json +1 -1
- package/dist/index-h60df7rj.js +0 -110
- package/dist/index-k4dftwf7.js +0 -66
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
defaultSignalSource,
|
|
8
8
|
guardSignalCallback,
|
|
9
9
|
reportSignalError
|
|
10
|
-
} from "./index-
|
|
10
|
+
} from "./index-sm2tjx06.js";
|
|
11
11
|
import {
|
|
12
12
|
errorCode,
|
|
13
13
|
extractIp,
|
|
@@ -23,13 +23,13 @@ import {
|
|
|
23
23
|
setRequestError,
|
|
24
24
|
validateDeclaredOutput,
|
|
25
25
|
zodIssues
|
|
26
|
-
} from "./index-
|
|
26
|
+
} from "./index-j3dem06f.js";
|
|
27
27
|
import {
|
|
28
28
|
AppError,
|
|
29
29
|
badRequest,
|
|
30
30
|
isUnsafeKey,
|
|
31
31
|
safeJsonParse
|
|
32
|
-
} from "./index-
|
|
32
|
+
} from "./index-5r13htq1.js";
|
|
33
33
|
import {
|
|
34
34
|
isRecord,
|
|
35
35
|
parseTrailingWildcard,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
isUnsafeKey,
|
|
3
3
|
mergeMeta
|
|
4
|
-
} from "./index-
|
|
4
|
+
} from "./index-5r13htq1.js";
|
|
5
5
|
import {
|
|
6
6
|
callRuntimeHandler,
|
|
7
7
|
isRecord,
|
|
@@ -267,7 +267,41 @@ var RUNTIME_CONTEXT_RESERVED_KEYS = new Set([
|
|
|
267
267
|
function contributionError(scope, reason) {
|
|
268
268
|
return new TypeError(`[stitchkit] auth: invalid context contribution for scope ${JSON.stringify(scope)}: ${reason}`);
|
|
269
269
|
}
|
|
270
|
-
function
|
|
270
|
+
function descriptorsEqual(left, right) {
|
|
271
|
+
if (!left || !right)
|
|
272
|
+
return left === right;
|
|
273
|
+
if (left.enumerable !== right.enumerable || left.configurable !== right.configurable || left.writable !== right.writable) {
|
|
274
|
+
return false;
|
|
275
|
+
}
|
|
276
|
+
if ("value" in left || "value" in right) {
|
|
277
|
+
return "value" in left && "value" in right && Object.is(left.value, right.value);
|
|
278
|
+
}
|
|
279
|
+
return left.get === right.get && left.set === right.set;
|
|
280
|
+
}
|
|
281
|
+
function contextContributionDelta(original, shadow, scope) {
|
|
282
|
+
if (Object.getPrototypeOf(shadow) !== Object.getPrototypeOf(original)) {
|
|
283
|
+
throw contributionError(scope, "context prototype changes are not supported");
|
|
284
|
+
}
|
|
285
|
+
const originalKeys = Reflect.ownKeys(original);
|
|
286
|
+
const shadowKeys = Reflect.ownKeys(shadow);
|
|
287
|
+
const shadowKeySet = new Set(shadowKeys);
|
|
288
|
+
for (const key of originalKeys) {
|
|
289
|
+
if (!shadowKeySet.has(key)) {
|
|
290
|
+
const printable = typeof key === "string" ? JSON.stringify(key) : "a symbol key";
|
|
291
|
+
throw contributionError(scope, `context key ${printable} may not be deleted`);
|
|
292
|
+
}
|
|
293
|
+
}
|
|
294
|
+
const contribution = Object.create(null);
|
|
295
|
+
for (const key of shadowKeys) {
|
|
296
|
+
const originalDescriptor = Object.getOwnPropertyDescriptor(original, key);
|
|
297
|
+
const shadowDescriptor = Object.getOwnPropertyDescriptor(shadow, key);
|
|
298
|
+
if (!shadowDescriptor || descriptorsEqual(originalDescriptor, shadowDescriptor))
|
|
299
|
+
continue;
|
|
300
|
+
Object.defineProperty(contribution, key, shadowDescriptor);
|
|
301
|
+
}
|
|
302
|
+
return contribution;
|
|
303
|
+
}
|
|
304
|
+
function prepareContextContribution(value, scope) {
|
|
271
305
|
if (typeof value !== "object" || value === null || Array.isArray(value)) {
|
|
272
306
|
throw contributionError(scope, "expected a plain record");
|
|
273
307
|
}
|
|
@@ -301,7 +335,10 @@ function mergeContextContribution(ctx, value, scope) {
|
|
|
301
335
|
}
|
|
302
336
|
prepared[key] = descriptor.value;
|
|
303
337
|
}
|
|
304
|
-
|
|
338
|
+
return prepared;
|
|
339
|
+
}
|
|
340
|
+
function mergeContextContribution(ctx, value, scope) {
|
|
341
|
+
Object.assign(ctx, prepareContextContribution(value, scope));
|
|
305
342
|
}
|
|
306
343
|
|
|
307
344
|
// src/server/process-signal-common.ts
|
|
@@ -333,4 +370,4 @@ function guardSignalCallback(run, phase, onError) {
|
|
|
333
370
|
}
|
|
334
371
|
}
|
|
335
372
|
|
|
336
|
-
export { RUNTIME_CONTEXT_RESERVED_KEYS, mergeContextContribution, DEFAULT_CORS_ALLOW_HEADERS, DEFAULT_CORS_EXPOSE_HEADERS, assertCorsConfig, corsHeaders, corsPreflightResponse, defineMultipartStream, createMultipartStream, contractOnlyService, implement, createImplement, createScopedImplement, createScopedImplementRegistry, implementRegistry, createImplementRegistry, DEFAULT_PROCESS_SIGNALS, defaultSignalSource, reportSignalError, guardSignalCallback };
|
|
373
|
+
export { RUNTIME_CONTEXT_RESERVED_KEYS, contextContributionDelta, prepareContextContribution, mergeContextContribution, DEFAULT_CORS_ALLOW_HEADERS, DEFAULT_CORS_EXPOSE_HEADERS, assertCorsConfig, corsHeaders, corsPreflightResponse, defineMultipartStream, createMultipartStream, contractOnlyService, implement, createImplement, createScopedImplement, createScopedImplementRegistry, implementRegistry, createImplementRegistry, DEFAULT_PROCESS_SIGNALS, defaultSignalSource, reportSignalError, guardSignalCallback };
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import {
|
|
2
|
-
|
|
3
|
-
|
|
2
|
+
contextContributionDelta,
|
|
3
|
+
mergeContextContribution,
|
|
4
|
+
prepareContextContribution
|
|
5
|
+
} from "./index-sm2tjx06.js";
|
|
4
6
|
import {
|
|
5
7
|
base64UrlToBytes,
|
|
6
8
|
bytesToBase64Url,
|
|
@@ -8,7 +10,7 @@ import {
|
|
|
8
10
|
isUnsafeKey,
|
|
9
11
|
safeJsonParse,
|
|
10
12
|
unauthorized
|
|
11
|
-
} from "./index-
|
|
13
|
+
} from "./index-5r13htq1.js";
|
|
12
14
|
import {
|
|
13
15
|
isRecord
|
|
14
16
|
} from "./index-7eq9va6e.js";
|
|
@@ -160,6 +162,17 @@ function isThenable(value) {
|
|
|
160
162
|
return false;
|
|
161
163
|
}
|
|
162
164
|
}
|
|
165
|
+
var scopedAuthHookBrand = Symbol("stitchkit.scoped-auth-hook");
|
|
166
|
+
var authOwnershipPlans = new WeakMap;
|
|
167
|
+
function createShadowContext(ctx) {
|
|
168
|
+
const shadow = {
|
|
169
|
+
params: ctx.params,
|
|
170
|
+
input: ctx.input,
|
|
171
|
+
source: ctx.source
|
|
172
|
+
};
|
|
173
|
+
Object.defineProperties(shadow, Object.getOwnPropertyDescriptors(ctx));
|
|
174
|
+
return shadow;
|
|
175
|
+
}
|
|
163
176
|
function createAuthHook(config) {
|
|
164
177
|
const onAnonymous = config.onAnonymous ?? (() => unauthorized());
|
|
165
178
|
const onForbidden = config.onForbidden ?? (() => forbidden());
|
|
@@ -198,8 +211,74 @@ function createAuthHook(config) {
|
|
|
198
211
|
return;
|
|
199
212
|
mergeContextContribution(ctx, result, scope);
|
|
200
213
|
}
|
|
214
|
+
auth[scopedAuthHookBrand] = () => {
|
|
215
|
+
return;
|
|
216
|
+
};
|
|
217
|
+
authOwnershipPlans.set(auth, {
|
|
218
|
+
defaultScope: config.defaultScope,
|
|
219
|
+
hook: auth,
|
|
220
|
+
scopes: new Set(Object.keys(config.rules))
|
|
221
|
+
});
|
|
201
222
|
return auth;
|
|
202
223
|
}
|
|
224
|
+
function composeAuthHooks(config) {
|
|
225
|
+
const plans = [];
|
|
226
|
+
for (const hook of config.hooks) {
|
|
227
|
+
const plan = authOwnershipPlans.get(hook);
|
|
228
|
+
if (!plan) {
|
|
229
|
+
throw new TypeError("[stitchkit] auth: composeAuthHooks accepts only hooks created by createAuthHook or composeAuthHooks");
|
|
230
|
+
}
|
|
231
|
+
if (plan.defaultScope !== undefined && plan.defaultScope !== config.defaultScope) {
|
|
232
|
+
throw new TypeError(`[stitchkit] auth: child default scope ${JSON.stringify(plan.defaultScope)} must match the composite default scope`);
|
|
233
|
+
}
|
|
234
|
+
plans.push(plan);
|
|
235
|
+
}
|
|
236
|
+
const defaultScope = config.defaultScope;
|
|
237
|
+
if (defaultScope !== undefined && !plans.some((plan) => plan.scopes.has(defaultScope))) {
|
|
238
|
+
throw new TypeError(`[stitchkit] auth: composite default scope ${JSON.stringify(defaultScope)} has no owner`);
|
|
239
|
+
}
|
|
240
|
+
const ownedScopes = new Set;
|
|
241
|
+
for (const plan of plans) {
|
|
242
|
+
for (const scope of plan.scopes)
|
|
243
|
+
ownedScopes.add(scope);
|
|
244
|
+
}
|
|
245
|
+
async function composed(ctx, endpoint) {
|
|
246
|
+
const scope = endpoint.scope ?? config.defaultScope;
|
|
247
|
+
if (!scope)
|
|
248
|
+
return;
|
|
249
|
+
const owners = plans.filter((plan) => plan.scopes.has(scope));
|
|
250
|
+
if (owners.length === 0) {
|
|
251
|
+
throw new Error(`[stitchkit] auth: no rule for scope "${scope}"`);
|
|
252
|
+
}
|
|
253
|
+
const scopedEndpoint = { ...endpoint, scope };
|
|
254
|
+
const contribution = Object.create(null);
|
|
255
|
+
const contributionOwners = new Set;
|
|
256
|
+
for (const owner of owners) {
|
|
257
|
+
ctx.signal?.throwIfAborted();
|
|
258
|
+
const shadow = createShadowContext(ctx);
|
|
259
|
+
await owner.hook(shadow, scopedEndpoint);
|
|
260
|
+
const ownerContribution = prepareContextContribution(contextContributionDelta(ctx, shadow, scope), scope);
|
|
261
|
+
for (const key of Object.keys(ownerContribution)) {
|
|
262
|
+
if (contributionOwners.has(key)) {
|
|
263
|
+
throw new TypeError(`[stitchkit] auth: multiple owners contributed context key ${JSON.stringify(key)} for scope ${JSON.stringify(scope)}`);
|
|
264
|
+
}
|
|
265
|
+
contributionOwners.add(key);
|
|
266
|
+
}
|
|
267
|
+
Object.assign(contribution, ownerContribution);
|
|
268
|
+
}
|
|
269
|
+
ctx.signal?.throwIfAborted();
|
|
270
|
+
mergeContextContribution(ctx, contribution, scope);
|
|
271
|
+
}
|
|
272
|
+
composed[scopedAuthHookBrand] = () => {
|
|
273
|
+
return;
|
|
274
|
+
};
|
|
275
|
+
authOwnershipPlans.set(composed, {
|
|
276
|
+
defaultScope: config.defaultScope,
|
|
277
|
+
hook: composed,
|
|
278
|
+
scopes: ownedScopes
|
|
279
|
+
});
|
|
280
|
+
return composed;
|
|
281
|
+
}
|
|
203
282
|
function createBearerResolver(config) {
|
|
204
283
|
return async (req) => {
|
|
205
284
|
const token = extractToken(req);
|
|
@@ -221,4 +300,4 @@ async function verifyPkce(verifier, challenge) {
|
|
|
221
300
|
return derived === challenge;
|
|
222
301
|
}
|
|
223
302
|
|
|
224
|
-
export { parseCookies, serializeCookie, defineCookie, verifyJwt, signJwt, extractToken, createAuthHook, createBearerResolver, deriveCodeChallenge, verifyPkce };
|
|
303
|
+
export { parseCookies, serializeCookie, defineCookie, verifyJwt, signJwt, extractToken, createAuthHook, composeAuthHooks, createBearerResolver, deriveCodeChallenge, verifyPkce };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
export { type ClientConfig, type ClientContract, type ClientFetch, type ClientRegistryValue, type ContractClientConfig, contractEndpointMatchers, createClient, createClients, createScopedClients, createScopedUrlBuilders, createUrlBuilder, createUrlBuilders, type PathPrefixArgs, type RegistryScope, type ScopeClientConfigs, type ScopedClientRegistry, type ScopedUrlBuilderRegistry, type UrlBuilderConfig, } from './browser/client';
|
|
2
2
|
export { ApiError, type ApiEvent, type ApiEventListener, type ConfiguredHttpClient, createHttpClient, type HeaderProvider, type HttpClient, type HttpClientConfig, type RequestOptions, type UnauthorizedMatcher, } from './browser/http';
|
|
3
|
-
export type { RealtimeClient, RealtimeClientOptions, SocketEventMap, SocketIOClient, SocketIOClientConfig, } from './browser/socket-io';
|
|
4
|
-
export { createRealtimeClient, createSocketIOClient } from './browser/socket-io';
|
|
3
|
+
export type { BindRealtimeClientOptions, BoundRealtimeClient, RealtimeClient, RealtimeClientOptions, RealtimeClientTransport, SocketEventMap, SocketIOClient, SocketIOClientConfig, } from './browser/socket-io';
|
|
4
|
+
export { bindRealtimeClient, createRealtimeClient, createSocketIOClient, } from './browser/socket-io';
|
|
5
5
|
export { type ParseSSEOptions, parseSSE } from './browser/stream';
|
|
6
6
|
export * from './contract';
|
|
7
7
|
export type { StitchLogger } from './logger';
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,YAAY,EACjB,KAAK,cAAc,EACnB,KAAK,WAAW,EAChB,KAAK,mBAAmB,EACxB,KAAK,oBAAoB,EACzB,wBAAwB,EACxB,YAAY,EACZ,aAAa,EACb,mBAAmB,EACnB,uBAAuB,EACvB,gBAAgB,EAChB,iBAAiB,EACjB,KAAK,cAAc,EACnB,KAAK,aAAa,EAClB,KAAK,kBAAkB,EACvB,KAAK,oBAAoB,EACzB,KAAK,wBAAwB,EAC7B,KAAK,gBAAgB,GACtB,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EACL,QAAQ,EACR,KAAK,QAAQ,EACb,KAAK,gBAAgB,EACrB,KAAK,oBAAoB,EACzB,gBAAgB,EAChB,KAAK,cAAc,EACnB,KAAK,UAAU,EACf,KAAK,gBAAgB,EACrB,KAAK,cAAc,EACnB,KAAK,mBAAmB,GACzB,MAAM,gBAAgB,CAAC;AACxB,YAAY,EACV,cAAc,EACd,qBAAqB,EACrB,cAAc,EACd,cAAc,EACd,oBAAoB,GACrB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,YAAY,EACjB,KAAK,cAAc,EACnB,KAAK,WAAW,EAChB,KAAK,mBAAmB,EACxB,KAAK,oBAAoB,EACzB,wBAAwB,EACxB,YAAY,EACZ,aAAa,EACb,mBAAmB,EACnB,uBAAuB,EACvB,gBAAgB,EAChB,iBAAiB,EACjB,KAAK,cAAc,EACnB,KAAK,aAAa,EAClB,KAAK,kBAAkB,EACvB,KAAK,oBAAoB,EACzB,KAAK,wBAAwB,EAC7B,KAAK,gBAAgB,GACtB,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EACL,QAAQ,EACR,KAAK,QAAQ,EACb,KAAK,gBAAgB,EACrB,KAAK,oBAAoB,EACzB,gBAAgB,EAChB,KAAK,cAAc,EACnB,KAAK,UAAU,EACf,KAAK,gBAAgB,EACrB,KAAK,cAAc,EACnB,KAAK,mBAAmB,GACzB,MAAM,gBAAgB,CAAC;AACxB,YAAY,EACV,yBAAyB,EACzB,mBAAmB,EACnB,cAAc,EACd,qBAAqB,EACrB,uBAAuB,EACvB,cAAc,EACd,cAAc,EACd,oBAAoB,GACrB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EACL,kBAAkB,EAClB,oBAAoB,EACpB,oBAAoB,GACrB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EAAE,KAAK,eAAe,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAClE,cAAc,YAAY,CAAC;AAC3B,YAAY,EAAE,YAAY,EAAE,MAAM,UAAU,CAAC;AAG7C,OAAO,EACL,SAAS,EACT,kBAAkB,EAClB,iBAAiB,EACjB,gBAAgB,EAChB,KAAK,YAAY,GAClB,MAAM,uBAAuB,CAAC;AAC/B,cAAc,YAAY,CAAC;AAC3B,OAAO,EAAE,oBAAoB,EAAE,KAAK,cAAc,EAAE,MAAM,YAAY,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -19,7 +19,7 @@ import {
|
|
|
19
19
|
parseTrailingWildcard,
|
|
20
20
|
rateLimited,
|
|
21
21
|
unauthorized
|
|
22
|
-
} from "./index-
|
|
22
|
+
} from "./index-28cqssm3.js";
|
|
23
23
|
import {
|
|
24
24
|
isRecord,
|
|
25
25
|
mapObject,
|
|
@@ -1120,8 +1120,18 @@ function toIoAuth(auth) {
|
|
|
1120
1120
|
Promise.resolve().then(auth).then(cb, () => cb({}));
|
|
1121
1121
|
};
|
|
1122
1122
|
}
|
|
1123
|
-
function
|
|
1124
|
-
const
|
|
1123
|
+
function assertRealtimeClientTransport(transport) {
|
|
1124
|
+
for (const capability of ["on", "emit", "emitWithAck", "onConnectionChange"]) {
|
|
1125
|
+
if (typeof Reflect.get(transport, capability) !== "function") {
|
|
1126
|
+
throw new TypeError(`Realtime client transport does not implement ${capability}()`);
|
|
1127
|
+
}
|
|
1128
|
+
}
|
|
1129
|
+
if (typeof transport.connected !== "boolean") {
|
|
1130
|
+
throw new TypeError("Realtime client transport does not expose boolean connected");
|
|
1131
|
+
}
|
|
1132
|
+
}
|
|
1133
|
+
function bindRealtimeClient(contract, transport, { onRejected, logger } = {}) {
|
|
1134
|
+
assertRealtimeClientTransport(transport);
|
|
1125
1135
|
const events = createValidatedRealtimeSocket({
|
|
1126
1136
|
target: transport,
|
|
1127
1137
|
inbound: contract.serverToClient,
|
|
@@ -1165,13 +1175,23 @@ function createRealtimeClient(contract, { onRejected, logger, ...config }) {
|
|
|
1165
1175
|
}
|
|
1166
1176
|
return {
|
|
1167
1177
|
...events,
|
|
1168
|
-
connect: transport.connect,
|
|
1169
|
-
disconnect: transport.disconnect,
|
|
1170
1178
|
get connected() {
|
|
1171
1179
|
return transport.connected;
|
|
1172
1180
|
},
|
|
1173
1181
|
request,
|
|
1174
|
-
onConnectionChange: transport.onConnectionChange
|
|
1182
|
+
onConnectionChange: (listener) => transport.onConnectionChange(listener)
|
|
1183
|
+
};
|
|
1184
|
+
}
|
|
1185
|
+
function createRealtimeClient(contract, { onRejected, logger, ...config }) {
|
|
1186
|
+
const transport = createSocketIOClient(config);
|
|
1187
|
+
const bound = bindRealtimeClient(contract, transport, { onRejected, logger });
|
|
1188
|
+
return {
|
|
1189
|
+
...bound,
|
|
1190
|
+
get connected() {
|
|
1191
|
+
return bound.connected;
|
|
1192
|
+
},
|
|
1193
|
+
connect: transport.connect,
|
|
1194
|
+
disconnect: transport.disconnect
|
|
1175
1195
|
};
|
|
1176
1196
|
}
|
|
1177
1197
|
function createSocketIOClient(config) {
|
|
@@ -1382,6 +1402,7 @@ export {
|
|
|
1382
1402
|
STITCH_ERROR_STATUS,
|
|
1383
1403
|
appError,
|
|
1384
1404
|
badRequest,
|
|
1405
|
+
bindRealtimeClient,
|
|
1385
1406
|
childSpan,
|
|
1386
1407
|
conflict,
|
|
1387
1408
|
contractEndpointMatchers,
|
package/dist/node.js
CHANGED
|
@@ -8,7 +8,7 @@ import {
|
|
|
8
8
|
createHandler,
|
|
9
9
|
createServerLifecycle,
|
|
10
10
|
createSocketIOServer
|
|
11
|
-
} from "./index-
|
|
11
|
+
} from "./index-n4nfa7gh.js";
|
|
12
12
|
import {
|
|
13
13
|
createImplement,
|
|
14
14
|
createImplementRegistry,
|
|
@@ -17,8 +17,9 @@ import {
|
|
|
17
17
|
createScopedImplementRegistry,
|
|
18
18
|
implement,
|
|
19
19
|
implementRegistry
|
|
20
|
-
} from "./index-
|
|
21
|
-
import"./index-
|
|
20
|
+
} from "./index-sm2tjx06.js";
|
|
21
|
+
import"./index-557by2db.js";
|
|
22
|
+
import"./index-j3dem06f.js";
|
|
22
23
|
import {
|
|
23
24
|
AppError,
|
|
24
25
|
appError,
|
|
@@ -28,7 +29,7 @@ import {
|
|
|
28
29
|
notFound,
|
|
29
30
|
rateLimited,
|
|
30
31
|
unauthorized
|
|
31
|
-
} from "./index-
|
|
32
|
+
} from "./index-5r13htq1.js";
|
|
32
33
|
import"./index-6k1937bx.js";
|
|
33
34
|
import"./index-7eq9va6e.js";
|
|
34
35
|
import"./index-1bx83sw4.js";
|
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
redact,
|
|
4
4
|
sanitizePayload,
|
|
5
5
|
truncatePreview
|
|
6
|
-
} from "../index-
|
|
6
|
+
} from "../index-jcc611vh.js";
|
|
7
7
|
import {
|
|
8
8
|
getRequestContext,
|
|
9
9
|
getTraceId,
|
|
@@ -15,8 +15,8 @@ import {
|
|
|
15
15
|
setRequestError,
|
|
16
16
|
setRequestUser,
|
|
17
17
|
wrapInRequestContext
|
|
18
|
-
} from "../index-
|
|
19
|
-
import"../index-
|
|
18
|
+
} from "../index-j3dem06f.js";
|
|
19
|
+
import"../index-5r13htq1.js";
|
|
20
20
|
import"../index-6k1937bx.js";
|
|
21
21
|
import {
|
|
22
22
|
childSpan,
|
package/dist/remote.js
CHANGED
|
@@ -1,6 +1,14 @@
|
|
|
1
1
|
import type { RuntimeContext } from '../contract';
|
|
2
2
|
/** Keys whose value is owned by a transport/runtime boundary, never by application enrichment. */
|
|
3
3
|
export declare const RUNTIME_CONTEXT_RESERVED_KEYS: Set<string>;
|
|
4
|
+
/**
|
|
5
|
+
* Return the application-owned fields changed on an isolated context. The
|
|
6
|
+
* descriptors are preserved so the regular contribution validator can reject
|
|
7
|
+
* accessors and symbols without invoking consumer code.
|
|
8
|
+
*/
|
|
9
|
+
export declare function contextContributionDelta(original: RuntimeContext, shadow: RuntimeContext, scope: string): Record<string, unknown>;
|
|
10
|
+
/** Validate and copy a contribution without mutating a runtime context. */
|
|
11
|
+
export declare function prepareContextContribution(value: unknown, scope: string): Record<string, unknown>;
|
|
4
12
|
/**
|
|
5
13
|
* Validate the complete contribution before mutating the runtime context.
|
|
6
14
|
* Accessors, exotic prototypes and transport-owned keys fail closed so a
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"context-contribution.d.ts","sourceRoot":"","sources":["../../src/server/context-contribution.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAGlD,kGAAkG;AAClG,eAAO,MAAM,6BAA6B,aAexC,CAAC;
|
|
1
|
+
{"version":3,"file":"context-contribution.d.ts","sourceRoot":"","sources":["../../src/server/context-contribution.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAGlD,kGAAkG;AAClG,eAAO,MAAM,6BAA6B,aAexC,CAAC;AA0BH;;;;GAIG;AACH,wBAAgB,wBAAwB,CACtC,QAAQ,EAAE,cAAc,EACxB,MAAM,EAAE,cAAc,EACtB,KAAK,EAAE,MAAM,GACZ,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAuBzB;AAED,2EAA2E;AAC3E,wBAAgB,0BAA0B,CACxC,KAAK,EAAE,OAAO,EACd,KAAK,EAAE,MAAM,GACZ,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAuCzB;AAED;;;;GAIG;AACH,wBAAgB,wBAAwB,CACtC,GAAG,EAAE,cAAc,EACnB,KAAK,EAAE,OAAO,EACd,KAAK,EAAE,MAAM,GACZ,IAAI,CAEN"}
|
package/dist/server/index.d.ts
CHANGED
|
@@ -10,7 +10,7 @@ export { type ByteRange, parseByteRange, type ServeFileOptions, serveFile, stati
|
|
|
10
10
|
export { createImplement, createImplementRegistry, createMultipartStream, createScopedImplement, createScopedImplementRegistry, defineMultipartStream, type ExactRegistryHandlers, type ExactScopedRegistryHandlers, type ImplementationRegistry, implement, implementRegistry, type KeyedServices, type MultipartStreamConfig, type RegistryHandlers, type ScopedImplementationRegistry, type ScopedRegistryHandlers, type StreamScope, } from './implement';
|
|
11
11
|
export { composeLifecycleHooks } from './lifecycle';
|
|
12
12
|
export type { LogFormat } from './logger';
|
|
13
|
-
export { type AuthHook, type AuthHookConfig, type AuthRule, type AuthRuleContribution, type AuthRules, type AuthScopes, type BearerResolverConfig, createAuthHook, createBearerResolver, extractToken, type JwtPayload, type RuleScopes, type ScopedAuthHook, type ScopedAuthRule, type SignJwtOptions, signJwt, type VerifyJwtOptions, verifyJwt, } from './middleware/auth';
|
|
13
|
+
export { type AuthHook, type AuthHookConfig, type AuthRule, type AuthRuleContribution, type AuthRules, type AuthScopes, type BearerResolverConfig, type ComposeAuthHooksConfig, type ComposedAuthScopes, composeAuthHooks, createAuthHook, createBearerResolver, extractToken, type JwtPayload, type RuleScopes, type ScopedAuthHook, type ScopedAuthRule, type SignJwtOptions, signJwt, type VerifyJwtOptions, verifyJwt, } from './middleware/auth';
|
|
14
14
|
export { type CookieDef, type CookieOptions, defineCookie, parseCookies, serializeCookie, } from './middleware/cookies';
|
|
15
15
|
export { type CorsConfig, corsHeaders, corsPreflightResponse, DEFAULT_CORS_ALLOW_HEADERS, DEFAULT_CORS_EXPOSE_HEADERS, } from './middleware/cors';
|
|
16
16
|
export { deriveCodeChallenge, type PkceMethod, verifyPkce } from './middleware/pkce';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/server/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,EACR,QAAQ,EACR,UAAU,EAC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,KAAK,YAAY,EACjB,wBAAwB,EACxB,KAAK,sBAAsB,EAC3B,KAAK,aAAa,EAClB,aAAa,GACd,MAAM,aAAa,CAAC"}
|
package/dist/server/index.js
CHANGED
|
@@ -12,8 +12,9 @@ import {
|
|
|
12
12
|
parseMultipart,
|
|
13
13
|
socketIoLane,
|
|
14
14
|
webSocketLane
|
|
15
|
-
} from "../index-
|
|
15
|
+
} from "../index-n4nfa7gh.js";
|
|
16
16
|
import {
|
|
17
|
+
composeAuthHooks,
|
|
17
18
|
createAuthHook,
|
|
18
19
|
createBearerResolver,
|
|
19
20
|
defineCookie,
|
|
@@ -24,7 +25,7 @@ import {
|
|
|
24
25
|
signJwt,
|
|
25
26
|
verifyJwt,
|
|
26
27
|
verifyPkce
|
|
27
|
-
} from "../index-
|
|
28
|
+
} from "../index-xy8fmh6w.js";
|
|
28
29
|
import {
|
|
29
30
|
DEFAULT_CORS_ALLOW_HEADERS,
|
|
30
31
|
DEFAULT_CORS_EXPOSE_HEADERS,
|
|
@@ -38,11 +39,12 @@ import {
|
|
|
38
39
|
defineMultipartStream,
|
|
39
40
|
implement,
|
|
40
41
|
implementRegistry
|
|
41
|
-
} from "../index-
|
|
42
|
+
} from "../index-sm2tjx06.js";
|
|
42
43
|
import {
|
|
43
44
|
isWithinDir,
|
|
44
45
|
realPathWithinDir
|
|
45
46
|
} from "../index-sbdmyz75.js";
|
|
47
|
+
import"../index-557by2db.js";
|
|
46
48
|
import {
|
|
47
49
|
jsonSchemaFields,
|
|
48
50
|
toJsonSchema
|
|
@@ -61,7 +63,7 @@ import {
|
|
|
61
63
|
resolveSocketIp,
|
|
62
64
|
resolveTraceId,
|
|
63
65
|
zodIssues
|
|
64
|
-
} from "../index-
|
|
66
|
+
} from "../index-j3dem06f.js";
|
|
65
67
|
import {
|
|
66
68
|
AppError,
|
|
67
69
|
STITCH_ERROR_STATUS,
|
|
@@ -73,7 +75,7 @@ import {
|
|
|
73
75
|
notFound,
|
|
74
76
|
rateLimited,
|
|
75
77
|
unauthorized
|
|
76
|
-
} from "../index-
|
|
78
|
+
} from "../index-5r13htq1.js";
|
|
77
79
|
import"../index-6k1937bx.js";
|
|
78
80
|
import {
|
|
79
81
|
isRecord,
|
|
@@ -1027,6 +1029,7 @@ export {
|
|
|
1027
1029
|
bindProcessSignals,
|
|
1028
1030
|
bindRealtimeServer,
|
|
1029
1031
|
cacheHeaders,
|
|
1032
|
+
composeAuthHooks,
|
|
1030
1033
|
composeLifecycleHooks,
|
|
1031
1034
|
composeWebSocketHandlers,
|
|
1032
1035
|
conflict,
|
|
@@ -134,14 +134,15 @@ export interface AuthHook {
|
|
|
134
134
|
(ctx: AuthorizationContext, endpoint: OperationIdentity): Promise<void>;
|
|
135
135
|
(ctx: RuntimeContext, endpoint: OperationIdentity): Promise<void>;
|
|
136
136
|
}
|
|
137
|
+
declare const scopedAuthHookBrand: unique symbol;
|
|
137
138
|
/**
|
|
138
139
|
* An auth hook that carries its derived scope→context map at the type level.
|
|
139
140
|
* The marker property never exists at runtime; it only lets {@link AuthScopes}
|
|
140
141
|
* recover the map.
|
|
141
142
|
*/
|
|
142
143
|
export interface ScopedAuthHook<TScopes extends Record<string, object>> extends AuthHook {
|
|
143
|
-
/**
|
|
144
|
-
readonly
|
|
144
|
+
/** Module-private nominal carrier for {@link AuthScopes}. */
|
|
145
|
+
readonly [scopedAuthHookBrand]: () => TScopes | undefined;
|
|
145
146
|
}
|
|
146
147
|
/**
|
|
147
148
|
* The scope→context map a hook derived from its rules — feed it straight to
|
|
@@ -153,6 +154,25 @@ export interface ScopedAuthHook<TScopes extends Record<string, object>> extends
|
|
|
153
154
|
* ```
|
|
154
155
|
*/
|
|
155
156
|
export type AuthScopes<THook extends ScopedAuthHook<Record<string, object>>> = THook extends ScopedAuthHook<infer TScopes> ? TScopes : never;
|
|
157
|
+
type ScopedHook = ScopedAuthHook<Record<string, object>>;
|
|
158
|
+
type HookScopeMaps<THooks extends readonly ScopedHook[]> = THooks[number] extends infer THook ? THook extends ScopedHook ? AuthScopes<THook> : never : never;
|
|
159
|
+
type ContributionsForScope<THooks extends readonly ScopedHook[], TScope extends PropertyKey> = THooks[number] extends infer THook ? THook extends ScopedHook ? TScope extends keyof AuthScopes<THook> ? AuthScopes<THook>[TScope] : never : never : never;
|
|
160
|
+
type AnyRequiredKeys<T> = T extends object ? RequiredKeys<T> : never;
|
|
161
|
+
type ComposeContributions<T extends object> = [UnionKeys<T>] extends [never] ? object : {
|
|
162
|
+
[K in AnyRequiredKeys<T>]: UnionValue<T, K>;
|
|
163
|
+
} & {
|
|
164
|
+
[K in Exclude<UnionKeys<T>, AnyRequiredKeys<T>>]?: UnionValue<T, K>;
|
|
165
|
+
};
|
|
166
|
+
/** Scope→context map guaranteed by every owner selected for each scope. */
|
|
167
|
+
export type ComposedAuthScopes<THooks extends readonly ScopedHook[]> = {
|
|
168
|
+
[TScope in UnionKeys<HookScopeMaps<THooks>>]: ComposeContributions<ContributionsForScope<THooks, TScope>>;
|
|
169
|
+
};
|
|
170
|
+
export interface ComposeAuthHooksConfig<THooks extends readonly [ScopedHook, ...ScopedHook[]]> {
|
|
171
|
+
/** Canonical hooks to route by their declared rule ownership. */
|
|
172
|
+
hooks: THooks;
|
|
173
|
+
/** The only default used by the composite. Must name an owned scope. */
|
|
174
|
+
defaultScope?: UnionKeys<HookScopeMaps<THooks>>;
|
|
175
|
+
}
|
|
156
176
|
/**
|
|
157
177
|
* Build a scope authorization hook.
|
|
158
178
|
*
|
|
@@ -167,6 +187,13 @@ export type AuthScopes<THook extends ScopedAuthHook<Record<string, object>>> = T
|
|
|
167
187
|
* scoped tool call has no identity and **fails closed** (never silently passes).
|
|
168
188
|
*/
|
|
169
189
|
export declare function createAuthHook<TIdentity, const TRules extends AuthRules<TIdentity> = AuthRules<TIdentity>>(config: AuthHookConfig<TIdentity, TRules>): ScopedAuthHook<RuleScopes<TRules>>;
|
|
190
|
+
/**
|
|
191
|
+
* Compose independent auth domains without teaching either domain about the
|
|
192
|
+
* other's identities or scopes. Only owners of the selected scope run. Their
|
|
193
|
+
* context changes are staged independently and committed atomically after all
|
|
194
|
+
* owners pass.
|
|
195
|
+
*/
|
|
196
|
+
export declare function composeAuthHooks<const THooks extends readonly [ScopedHook, ...ScopedHook[]]>(config: ComposeAuthHooksConfig<THooks>): ScopedAuthHook<ComposedAuthScopes<THooks>>;
|
|
170
197
|
/**
|
|
171
198
|
* Bearer-token identity resolver — the MCP / API-key counterpart of the
|
|
172
199
|
* cookie session hook. Strips `Authorization: Bearer <token>` and hands the
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"auth.d.ts","sourceRoot":"","sources":["../../../src/server/middleware/auth.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;
|
|
1
|
+
{"version":3,"file":"auth.d.ts","sourceRoot":"","sources":["../../../src/server/middleware/auth.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAUrD,OAAO,KAAK,EAAE,oBAAoB,EAAE,iBAAiB,EAAE,MAAM,UAAU,CAAC;AAGxE,MAAM,WAAW,UAAU;IACzB,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC;CACxB;AAED,8BAA8B;AAC9B,MAAM,WAAW,gBAAgB;IAC/B,wEAAwE;IACxE,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,gEAAgE;IAChE,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,4EAA4E;IAC5E,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB;AAKD,wBAAsB,SAAS,CAC7B,KAAK,EAAE,MAAM,EACb,MAAM,EAAE,MAAM,EACd,OAAO,GAAE,gBAAqB,GAC7B,OAAO,CAAC,UAAU,CAAC,CAgErB;AAED,4BAA4B;AAC5B,MAAM,WAAW,cAAc;IAC7B,0EAA0E;IAC1E,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,mBAAmB;IACnB,M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