@apifuse/provider-sdk 2.2.0-beta.59 → 2.2.0-beta.61
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/AUTHORING.md +33 -16
- package/CHANGELOG.md +8 -0
- package/bin/apifuse-dev.ts +7 -8
- package/bin/apifuse-pack-types.ts +22 -0
- package/bin/apifuse-perf.ts +45 -10
- package/bin/apifuse-record.ts +6 -8
- package/bin/apifuse-submit-check.ts +2 -2
- package/dist/config/loader.js +13 -12
- package/dist/define.d.ts +3 -2
- package/dist/define.js +1 -1
- package/dist/dev.js +3 -1
- package/dist/engine.d.ts +7 -6
- package/dist/engine.js +6 -6
- package/dist/error-resolution.js +21 -4
- package/dist/errors.d.ts +3 -0
- package/dist/errors.js +9 -0
- package/dist/handle-meta.d.ts +39 -0
- package/dist/handle-meta.js +29 -0
- package/dist/handle.d.ts +187 -0
- package/dist/handle.js +254 -0
- package/dist/i18n/catalog.js +21 -1
- package/dist/index.d.ts +6 -4
- package/dist/index.js +4 -3
- package/dist/lint.d.ts +3 -0
- package/dist/lint.js +388 -62
- package/dist/provider.d.ts +4 -4
- package/dist/provider.js +3 -3
- package/dist/runtime/browser.js +2 -1
- package/dist/runtime/cache.js +3 -2
- package/dist/runtime/diagnostic-env-values.d.ts +5 -0
- package/dist/runtime/diagnostic-env-values.js +57 -0
- package/dist/runtime/diagnostic-env.d.ts +11 -0
- package/dist/runtime/diagnostic-env.js +35 -0
- package/dist/runtime/diagnostic-redactor.d.ts +49 -0
- package/dist/runtime/diagnostic-redactor.js +569 -0
- package/dist/runtime/egress-lease.d.ts +2 -0
- package/dist/runtime/egress-lease.js +4 -1
- package/dist/runtime/env.js +2 -1
- package/dist/runtime/handle-wordlist.d.ts +43 -0
- package/dist/runtime/{choice-wordlist.js → handle-wordlist.js} +127 -9
- package/dist/runtime/handle.d.ts +71 -0
- package/dist/runtime/handle.js +895 -0
- package/dist/runtime/instrumentation.js +3 -0
- package/dist/runtime/native-network.d.ts +10 -1
- package/dist/runtime/native-network.js +230 -29
- package/dist/runtime/native-telemetry.d.ts +142 -0
- package/dist/runtime/native-telemetry.js +231 -0
- package/dist/runtime/ocr.js +2 -1
- package/dist/runtime/otlp.js +5 -4
- package/dist/runtime/proxy-nodemaven.js +3 -2
- package/dist/runtime/request-options.d.ts +7 -0
- package/dist/runtime/request-options.js +62 -22
- package/dist/runtime/resolver-vendors/browser.js +0 -1
- package/dist/runtime/resolver.js +3 -2
- package/dist/runtime/state.d.ts +4 -1
- package/dist/runtime/state.js +32 -17
- package/dist/runtime/stt.js +3 -2
- package/dist/runtime/trace.d.ts +5 -0
- package/dist/runtime/trace.js +115 -20
- package/dist/schema.d.ts +11 -0
- package/dist/schema.js +56 -2
- package/dist/server/index.d.ts +1 -0
- package/dist/server/index.js +1 -0
- package/dist/server/self-test-redaction.js +8 -33
- package/dist/server/sensitive-values.d.ts +26 -0
- package/dist/server/sensitive-values.js +128 -0
- package/dist/server/serve-implementation.d.ts +4 -11
- package/dist/server/serve-implementation.js +305 -96
- package/dist/server/trace-output.d.ts +2 -1
- package/dist/server/trace-output.js +46 -14
- package/dist/testing/run.js +10 -7
- package/dist/trace-sanitization.d.ts +4 -3
- package/dist/trace-sanitization.js +45 -22
- package/dist/types.d.ts +4 -107
- package/package.json +2 -1
- package/src/config/loader.ts +13 -12
- package/src/define.ts +4 -3
- package/src/dev.ts +3 -1
- package/src/engine.ts +8 -8
- package/src/error-resolution.ts +21 -4
- package/src/errors.ts +13 -0
- package/src/handle-meta.ts +58 -0
- package/src/handle.ts +529 -0
- package/src/i18n/catalog.ts +23 -1
- package/src/index.ts +28 -13
- package/src/lint.ts +456 -71
- package/src/provider.ts +10 -20
- package/src/runtime/browser.ts +2 -1
- package/src/runtime/cache.ts +3 -2
- package/src/runtime/diagnostic-env-values.ts +56 -0
- package/src/runtime/diagnostic-env.ts +55 -0
- package/src/runtime/diagnostic-redactor.ts +662 -0
- package/src/runtime/egress-lease.ts +6 -1
- package/src/runtime/env.ts +2 -1
- package/src/runtime/{choice-wordlist.ts → handle-wordlist.ts} +130 -9
- package/src/runtime/handle.ts +1162 -0
- package/src/runtime/instrumentation.ts +3 -0
- package/src/runtime/native-network.ts +281 -33
- package/src/runtime/native-telemetry.ts +366 -0
- package/src/runtime/ocr.ts +2 -1
- package/src/runtime/otlp.ts +5 -4
- package/src/runtime/proxy-nodemaven.ts +3 -2
- package/src/runtime/request-options.ts +76 -28
- package/src/runtime/resolver-vendors/browser.ts +0 -1
- package/src/runtime/resolver.ts +3 -2
- package/src/runtime/state.ts +44 -16
- package/src/runtime/stt.ts +3 -2
- package/src/runtime/trace.ts +168 -26
- package/src/schema.ts +63 -2
- package/src/server/index.ts +17 -0
- package/src/server/self-test-redaction.ts +10 -40
- package/src/server/sensitive-values.ts +197 -0
- package/src/server/serve-implementation.ts +388 -128
- package/src/server/trace-output.ts +77 -17
- package/src/testing/run.ts +11 -7
- package/src/trace-sanitization.ts +70 -23
- package/src/types.ts +4 -137
- package/dist/choice-token.d.ts +0 -24
- package/dist/choice-token.js +0 -74
- package/dist/runtime/choice-wordlist.d.ts +0 -9
- package/dist/runtime/choice.d.ts +0 -27
- package/dist/runtime/choice.js +0 -801
- package/src/choice-token.ts +0 -165
- package/src/runtime/choice.ts +0 -1197
package/src/index.ts
CHANGED
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
|
|
3
3
|
export * from "./auth.js";
|
|
4
4
|
export * from "./ceremonies/index.js";
|
|
5
|
-
export * from "./choice-token.js";
|
|
6
5
|
export type {
|
|
7
6
|
ApiFuseConfig,
|
|
8
7
|
BrowserConfig,
|
|
@@ -139,12 +138,16 @@ export {
|
|
|
139
138
|
createProviderCache,
|
|
140
139
|
type ProviderCacheOptions,
|
|
141
140
|
} from "./runtime/cache.js";
|
|
141
|
+
export * from "./handle.js";
|
|
142
142
|
export {
|
|
143
|
-
type
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
143
|
+
type CreateHandleContextOptions,
|
|
144
|
+
type CreateTestHandleContextOptions,
|
|
145
|
+
createHandleContext,
|
|
146
|
+
createTestHandleContext,
|
|
147
|
+
type HandleNormalizationClass,
|
|
148
|
+
type NormalizedHandle,
|
|
149
|
+
normalizeHandle,
|
|
150
|
+
} from "./runtime/handle.js";
|
|
148
151
|
export {
|
|
149
152
|
type CreateCredentialContextOptions,
|
|
150
153
|
createCredentialContext,
|
|
@@ -275,6 +278,7 @@ export {
|
|
|
275
278
|
type Span,
|
|
276
279
|
type TraceContext,
|
|
277
280
|
} from "./runtime/trace.js";
|
|
281
|
+
export type { DiagnosticRedactor } from "./runtime/diagnostic-redactor.js";
|
|
278
282
|
export {
|
|
279
283
|
APIFUSE_CONTENT_PROVENANCE_META_KEY,
|
|
280
284
|
APIFUSE_CONTENT_TRUST_META_KEY,
|
|
@@ -287,6 +291,7 @@ export {
|
|
|
287
291
|
field,
|
|
288
292
|
fields,
|
|
289
293
|
isSensitiveSchema,
|
|
294
|
+
publicField,
|
|
290
295
|
redactPayload,
|
|
291
296
|
type SensitiveFieldKind,
|
|
292
297
|
type SensitiveFieldOptions,
|
|
@@ -422,13 +427,6 @@ export type {
|
|
|
422
427
|
ProviderCacheLookupMeta,
|
|
423
428
|
ProviderCacheResponseMeta,
|
|
424
429
|
ProviderCacheResult,
|
|
425
|
-
ProviderChoiceBindingOptions,
|
|
426
|
-
ProviderChoiceConsumeMode,
|
|
427
|
-
ProviderChoiceConsumeResult,
|
|
428
|
-
ProviderChoiceContext,
|
|
429
|
-
ProviderChoiceExplicitParseResult,
|
|
430
|
-
ProviderChoiceIssueOptions,
|
|
431
|
-
ProviderChoiceParseOptions,
|
|
432
430
|
ProviderChallenge,
|
|
433
431
|
ProviderChallengeKind,
|
|
434
432
|
ProviderContext,
|
|
@@ -538,3 +536,20 @@ export * from "./utils/date.js";
|
|
|
538
536
|
export * from "./utils/parse.js";
|
|
539
537
|
export * from "./utils/text.js";
|
|
540
538
|
export * from "./utils/transform.js";
|
|
539
|
+
|
|
540
|
+
export {
|
|
541
|
+
NativeTelemetryCollector,
|
|
542
|
+
type NativeAttemptSample,
|
|
543
|
+
type NativeConnectTelemetryEvent,
|
|
544
|
+
type NativeLifecycleTelemetryEvent,
|
|
545
|
+
type NativeTelemetryDiagnostics,
|
|
546
|
+
type NativeTelemetryErrorCode,
|
|
547
|
+
type NativeTelemetryHeaderPayload,
|
|
548
|
+
type NativeTelemetryKind,
|
|
549
|
+
type NativeTelemetryLifecycleKind,
|
|
550
|
+
type NativeTelemetryLogPayload,
|
|
551
|
+
type NativeTelemetryOutcome,
|
|
552
|
+
type NativeTelemetrySink,
|
|
553
|
+
type NativeTelemetryVendorSkipReason,
|
|
554
|
+
type NativeVendorSkipTelemetryEvent,
|
|
555
|
+
} from "./runtime/native-telemetry.js";
|