@aventara/core 0.1.0-pilot.4 → 1.0.0-rc.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +1478 -0
- package/README.md +275 -11
- package/dist/adapters/adapter-discovery-diagnostic.d.ts +4 -4
- package/dist/adapters/adapter-field.d.ts +11 -11
- package/dist/adapters/adapter-identifier.d.ts +6 -6
- package/dist/adapters/adapter-model.d.ts +17 -9
- package/dist/adapters/adapter-operation-executor.interface.d.ts +4 -4
- package/dist/adapters/adapter-operation.d.ts +3 -3
- package/dist/adapters/adapter-resource.d.ts +18 -9
- package/dist/adapters/adapter-sql-statement.d.ts +19 -0
- package/dist/adapters/adapter-transaction-executor.interface.d.ts +19 -0
- package/dist/adapters/adapter.interface.d.ts +49 -25
- package/dist/avz/avz-check.factory.d.ts +83 -0
- package/dist/avz/avz-check.factory.js +116 -0
- package/dist/avz/avz-check.registry.d.ts +35 -0
- package/dist/avz/avz-check.registry.js +9 -0
- package/dist/avz/avz.d.ts +203 -0
- package/dist/avz/avz.js +354 -0
- package/dist/avz/index.d.ts +7 -0
- package/dist/avz/index.js +1 -0
- package/dist/avz/json-shape.registry.d.ts +22 -0
- package/dist/avz/json-shape.registry.js +16 -0
- package/dist/avz/zod-issue.translator.d.ts +57 -0
- package/dist/avz/zod-issue.translator.js +149 -0
- package/dist/compiler/contract-compiler-diagnostic.d.ts +37 -5
- package/dist/compiler/contract.compiler.d.ts +18 -18
- package/dist/compiler/contract.compiler.js +595 -421
- package/dist/compiler/create-requirements.projector.d.ts +49 -0
- package/dist/compiler/create-requirements.projector.js +423 -0
- package/dist/compiler/field-validator.compiler.d.ts +47 -0
- package/dist/compiler/field-validator.compiler.js +238 -0
- package/dist/config/any-framework-config.d.ts +19 -12
- package/dist/config/config-diagnostic.d.ts +11 -4
- package/dist/config/config-layer.d.ts +15 -6
- package/dist/config/config.resolver.d.ts +75 -29
- package/dist/config/config.resolver.js +109 -44
- package/dist/config/config.validator.d.ts +7 -7
- package/dist/config/config.validator.js +586 -71
- package/dist/config/define-resource.d.ts +57 -0
- package/dist/config/define-resource.js +14 -0
- package/dist/config/effective-fields.d.ts +19 -23
- package/dist/config/entrypoint.normalizer.d.ts +1 -1
- package/dist/config/exact-framework-config.d.ts +280 -0
- package/dist/config/field-compute.resolver.d.ts +19 -0
- package/dist/config/field-compute.resolver.js +115 -0
- package/dist/config/field-pipeline-config.d.ts +47 -0
- package/dist/config/forced-operation.validator.d.ts +10 -0
- package/dist/config/forced-operation.validator.js +66 -0
- package/dist/config/framework-config.d.ts +111 -37
- package/dist/config/framework-exemptions-config.d.ts +91 -0
- package/dist/config/framework-exemptions-config.js +1 -0
- package/dist/config/framework-field-definition.d.ts +78 -0
- package/dist/config/framework-field-definition.js +28 -0
- package/dist/config/framework-resources-config.d.ts +116 -0
- package/dist/config/framework-resources-config.js +1 -0
- package/dist/config/pipeline-config.d.ts +56 -20
- package/dist/config/pipeline-tree.resolver.d.ts +79 -0
- package/dist/config/pipeline-tree.resolver.js +220 -0
- package/dist/config/stage-type.eraser.d.ts +65 -0
- package/dist/config/stage-type.eraser.js +1 -0
- package/dist/contracts/capability.d.ts +11 -11
- package/dist/contracts/client-contract-structure.validator.d.ts +344 -29
- package/dist/contracts/client-contract-structure.validator.js +248 -7
- package/dist/contracts/contract-canonicalizer.d.ts +19 -3
- package/dist/contracts/contract-canonicalizer.js +172 -27
- package/dist/contracts/contract-hash.d.ts +12 -7
- package/dist/contracts/contract-hash.js +3 -2
- package/dist/contracts/contract-limits.d.ts +4 -1
- package/dist/contracts/contract-limits.js +1 -0
- package/dist/contracts/contract-lookup.d.ts +5 -5
- package/dist/contracts/contract-protocol.d.ts +4 -4
- package/dist/contracts/contract.d.ts +31 -16
- package/dist/contracts/create-requirements.d.ts +35 -0
- package/dist/contracts/create-requirements.js +1 -0
- package/dist/contracts/enum-definition.d.ts +1 -1
- package/dist/contracts/field-check.d.ts +101 -0
- package/dist/contracts/field-check.js +1 -0
- package/dist/contracts/field.d.ts +61 -41
- package/dist/contracts/identifier.d.ts +4 -4
- package/dist/contracts/json-shape.d.ts +76 -0
- package/dist/contracts/json-shape.js +1 -0
- package/dist/contracts/lifecycle-trait.d.ts +2 -2
- package/dist/contracts/reference-write-limit.d.ts +7 -0
- package/dist/contracts/reference-write-limit.js +1 -0
- package/dist/contracts/resource-operations.d.ts +28 -28
- package/dist/contracts/resource.d.ts +15 -9
- package/dist/contracts/scalar-value-type.d.ts +25 -14
- package/dist/contracts/scalar.d.ts +3 -3
- package/dist/contracts/transaction-capability.d.ts +1 -1
- package/dist/contracts/wire-scalar-format.d.ts +4 -4
- package/dist/framework/contract-view.d.ts +234 -63
- package/dist/framework/framework-construction.error.d.ts +10 -10
- package/dist/framework/framework-construction.error.js +2 -2
- package/dist/framework/framework.d.ts +50 -24
- package/dist/framework/framework.factory.d.ts +8 -6
- package/dist/framework/framework.factory.js +95 -32
- package/dist/framework/operation-facade.d.ts +123 -52
- package/dist/framework/operation-facade.js +9 -1
- package/dist/index.d.ts +55 -82
- package/dist/index.js +6 -26
- package/dist/internal.d.ts +40 -0
- package/dist/internal.js +18 -0
- package/dist/operations/operation-arguments.d.ts +316 -201
- package/dist/operations/operation-call.d.ts +27 -28
- package/dist/operations/operation-identity.d.ts +12 -10
- package/dist/operations/operation-identity.js +3 -0
- package/dist/operations/operation-result.d.ts +21 -21
- package/dist/operations/operation-validator-core.d.ts +6 -6
- package/dist/operations/operation-validator-core.js +41 -12
- package/dist/operations/operation-validator.d.ts +24 -9
- package/dist/operations/operation-validator.js +26 -10
- package/dist/operations/projection-scope.resolver.d.ts +7 -7
- package/dist/operations/structural-limits.walker.d.ts +19 -0
- package/dist/operations/structural-limits.walker.js +489 -0
- package/dist/operations/validation-code.d.ts +11 -6
- package/dist/operations/validation-code.js +4 -0
- package/dist/operations/write-scope.resolver.d.ts +6 -6
- package/dist/protocol/absent-route.responder.d.ts +13 -11
- package/dist/protocol/absent-route.responder.js +42 -16
- package/dist/protocol/contract-document.responder.d.ts +3 -3
- package/dist/protocol/contract-document.responder.js +2 -2
- package/dist/protocol/http-request.decoder.d.ts +23 -13
- package/dist/protocol/http-request.decoder.js +19 -11
- package/dist/protocol/http-request.reader.d.ts +3 -3
- package/dist/protocol/http-response.encoder.d.ts +4 -4
- package/dist/protocol/http-response.encoder.js +94 -55
- package/dist/protocol/http-status.table.d.ts +2 -2
- package/dist/protocol/operation-response.guard.d.ts +2 -2
- package/dist/protocol/protocol-surface.d.ts +4 -4
- package/dist/protocol/protocol.binder.d.ts +52 -27
- package/dist/protocol/protocol.binder.js +14 -9
- package/dist/protocol/protocol.handler.d.ts +28 -15
- package/dist/protocol/protocol.handler.js +55 -10
- package/dist/protocol/unmounted-route.error.d.ts +19 -0
- package/dist/protocol/unmounted-route.error.js +10 -0
- package/dist/runtime/caller-data.copier.d.ts +59 -0
- package/dist/runtime/caller-data.copier.js +470 -0
- package/dist/runtime/caller-data.door.d.ts +56 -0
- package/dist/runtime/caller-data.door.js +67 -0
- package/dist/runtime/computed-read-runtime.d.ts +7 -6
- package/dist/runtime/computed-read-runtime.js +61 -55
- package/dist/runtime/computed-value.error.d.ts +13 -0
- package/dist/runtime/computed-value.error.js +9 -0
- package/dist/runtime/context-executor.runtime.d.ts +59 -0
- package/dist/runtime/context-executor.runtime.js +275 -0
- package/dist/runtime/create-requirement.d.ts +22 -57
- package/dist/runtime/create-requirement.js +140 -37
- package/dist/runtime/decimal.d.ts +2 -2
- package/dist/runtime/decimal.js +1 -1
- package/dist/runtime/diagnostics-reporter.d.ts +64 -22
- package/dist/runtime/diagnostics-reporter.js +35 -4
- package/dist/runtime/error-boundary.d.ts +73 -8
- package/dist/runtime/error-boundary.js +104 -48
- package/dist/runtime/execution-options.d.ts +10 -2
- package/dist/runtime/field-check.evaluator.d.ts +29 -0
- package/dist/runtime/field-check.evaluator.js +521 -0
- package/dist/runtime/field-compute.d.ts +64 -0
- package/dist/runtime/field-compute.js +1 -0
- package/dist/runtime/field-stage.plan.d.ts +15 -0
- package/dist/runtime/field-stage.plan.js +27 -0
- package/dist/runtime/field-stage.runtime.d.ts +35 -0
- package/dist/runtime/field-stage.runtime.js +143 -0
- package/dist/runtime/field-validator.runtime.d.ts +11 -0
- package/dist/runtime/field-validator.runtime.js +87 -0
- package/dist/runtime/framework-error-class.table.d.ts +33 -0
- package/dist/runtime/framework-error-class.table.js +25 -0
- package/dist/runtime/framework-error.d.ts +79 -7
- package/dist/runtime/framework-error.factory.d.ts +4 -0
- package/dist/runtime/framework-error.factory.js +15 -0
- package/dist/runtime/framework-error.js +23 -2
- package/dist/runtime/interceptor-next.error.d.ts +5 -0
- package/dist/runtime/interceptor-next.error.js +6 -0
- package/dist/runtime/json-value.d.ts +3 -3
- package/dist/runtime/level-lifecycle.runtime.d.ts +25 -0
- package/dist/runtime/level-lifecycle.runtime.js +42 -0
- package/dist/runtime/misuse-reporter.d.ts +32 -0
- package/dist/runtime/misuse-reporter.js +19 -0
- package/dist/runtime/mutation-planner.d.ts +19 -10
- package/dist/runtime/mutation-planner.js +62 -36
- package/dist/runtime/nested-write.walker.d.ts +32 -0
- package/dist/runtime/nested-write.walker.js +73 -0
- package/dist/runtime/operation-request.d.ts +35 -15
- package/dist/runtime/operation-response.d.ts +17 -17
- package/dist/runtime/operation-runtime.d.ts +125 -30
- package/dist/runtime/operation-runtime.js +423 -83
- package/dist/runtime/outcome-mapper.d.ts +16 -5
- package/dist/runtime/outcome-mapper.js +35 -8
- package/dist/runtime/output-validator.d.ts +16 -6
- package/dist/runtime/output-validator.js +12 -1
- package/dist/runtime/owned-execution.registry.d.ts +13 -0
- package/dist/runtime/owned-execution.registry.js +7 -0
- package/dist/runtime/pipe-output.validator.d.ts +33 -18
- package/dist/runtime/pipe-output.validator.js +12 -12
- package/dist/runtime/pipeline.d.ts +202 -28
- package/dist/runtime/readonly-value.d.ts +32 -0
- package/dist/runtime/readonly-value.js +141 -0
- package/dist/runtime/referential-action.d.ts +7 -0
- package/dist/runtime/request-envelope.validator.d.ts +5 -0
- package/dist/runtime/request-envelope.validator.js +123 -0
- package/dist/runtime/request-id.d.ts +1 -1
- package/dist/runtime/request-state.d.ts +14 -0
- package/dist/runtime/request-state.js +1 -0
- package/dist/runtime/request-state.resolver.d.ts +12 -0
- package/dist/runtime/request-state.resolver.js +20 -0
- package/dist/runtime/scalar-runtime.d.ts +56 -13
- package/dist/runtime/scalar-runtime.js +167 -86
- package/dist/transactions/deferred-operation.d.ts +35 -20
- package/dist/transactions/operation-arguments-encoder.d.ts +3 -3
- package/dist/transactions/operation-arguments-encoder.js +2 -2
- package/dist/transactions/sql-statement.d.ts +77 -0
- package/dist/transactions/sql-statement.js +47 -0
- package/dist/transactions/sql-statement.validator.d.ts +44 -0
- package/dist/transactions/sql-statement.validator.js +134 -0
- package/dist/transactions/transaction-envelope.d.ts +4 -4
- package/dist/transactions/transaction-integrity-error.d.ts +6 -6
- package/dist/transactions/transaction-integrity-error.js +5 -2
- package/dist/transactions/transaction-plan-assembler.d.ts +23 -9
- package/dist/transactions/transaction-plan-assembler.js +195 -82
- package/dist/transactions/transaction-plan-validator.d.ts +53 -21
- package/dist/transactions/transaction-plan-validator.js +246 -163
- package/dist/transactions/transaction-reference-collector.d.ts +30 -0
- package/dist/transactions/transaction-reference-collector.js +204 -0
- package/dist/transactions/transaction-reference-resolver.d.ts +19 -2
- package/dist/transactions/transaction-reference-resolver.js +27 -10
- package/dist/transactions/transaction-reference-validator.d.ts +34 -4
- package/dist/transactions/transaction-reference-validator.js +82 -43
- package/dist/transactions/transaction-reference.d.ts +30 -58
- package/dist/transactions/transaction-request.d.ts +20 -7
- package/dist/transactions/transaction-response.d.ts +12 -7
- package/dist/transactions/transaction-response.js +24 -1
- package/dist/transactions/transaction-runtime.d.ts +11 -8
- package/dist/transactions/transaction-runtime.js +167 -50
- package/dist/transactions/transaction-settlement.runtime.d.ts +51 -0
- package/dist/transactions/transaction-settlement.runtime.js +120 -0
- package/dist/transactions/transaction-slot-path-error.d.ts +4 -4
- package/dist/transactions/transaction-slot-path-error.js +2 -2
- package/dist/transactions/transaction-slot-writer.js +2 -2
- package/dist/transactions/transaction-stage.runtime.d.ts +81 -0
- package/dist/transactions/transaction-stage.runtime.js +123 -0
- package/package.json +18 -3
- package/src/runtime/field-check.evaluator.ts +720 -0
- package/dist/config/define-fields.d.ts +0 -35
- package/dist/config/define-fields.js +0 -3
- package/dist/config/framework-behaviors-config.d.ts +0 -30
- package/dist/config/framework-fields-config.d.ts +0 -36
- package/dist/config/framework-restrictions-config.d.ts +0 -142
- package/dist/operations/operation-boolean-nodes.d.ts +0 -11
- package/dist/operations/operation-boolean-nodes.js +0 -283
- package/dist/operations/operation-nesting.d.ts +0 -8
- package/dist/operations/operation-nesting.js +0 -307
- package/dist/runtime/field-behavior.d.ts +0 -48
- /package/dist/{config/framework-behaviors-config.js → adapters/adapter-sql-statement.js} +0 -0
- /package/dist/{config/framework-fields-config.js → adapters/adapter-transaction-executor.interface.js} +0 -0
- /package/dist/config/{framework-restrictions-config.js → exact-framework-config.js} +0 -0
- /package/dist/{runtime/field-behavior.js → config/field-pipeline-config.js} +0 -0
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { AvContractClient } from "./contract.js";
|
|
2
|
+
import type { JsonSchema } from "./json-shape.js";
|
|
2
3
|
/**
|
|
3
|
-
* Whether an untrusted value is
|
|
4
|
+
* Whether an untrusted value is an `AvContractClient`: every member present, of its JSON
|
|
4
5
|
* kind, inside its closed vocabulary, and nothing else. An enum's values must be
|
|
5
6
|
* distinct. Reads every member it judges and never throws on any input; a value that
|
|
6
7
|
* is not JSON at all is reported.
|
|
@@ -26,7 +27,8 @@ export type StructureNode = {
|
|
|
26
27
|
} | {
|
|
27
28
|
readonly is: "list";
|
|
28
29
|
readonly item: StructureNode;
|
|
29
|
-
|
|
30
|
+
/** The fewest entries it holds: 0, 1, or 2 (a pair and more). */
|
|
31
|
+
readonly minimum: 0 | 1 | 2;
|
|
30
32
|
/** No entry repeats an earlier one. Not a type fact: `Structured` ignores it. */
|
|
31
33
|
readonly unique: boolean;
|
|
32
34
|
} | {
|
|
@@ -44,6 +46,12 @@ export type StructureNode = {
|
|
|
44
46
|
} | {
|
|
45
47
|
readonly is: "union";
|
|
46
48
|
readonly arms: readonly StructureNode[];
|
|
49
|
+
} | {
|
|
50
|
+
/**
|
|
51
|
+
* A Json Shape's schema: recursive, so judged by its own reader
|
|
52
|
+
* ({@link jsonSchemaDefect}) rather than spelled out in nodes.
|
|
53
|
+
*/
|
|
54
|
+
readonly is: "jsonSchema";
|
|
47
55
|
};
|
|
48
56
|
/**
|
|
49
57
|
* The TypeScript type a structure description admits, dispatched through a
|
|
@@ -64,8 +72,8 @@ type StructuredBy<N> = {
|
|
|
64
72
|
} ? `${P}${string}` : never;
|
|
65
73
|
readonly list: N extends {
|
|
66
74
|
readonly item: infer I;
|
|
67
|
-
readonly
|
|
68
|
-
} ? E extends
|
|
75
|
+
readonly minimum: infer E;
|
|
76
|
+
} ? E extends 2 ? readonly [Structured<I>, Structured<I>, ...Structured<I>[]] : E extends 1 ? readonly [Structured<I>, ...Structured<I>[]] : readonly Structured<I>[] : never;
|
|
69
77
|
readonly registry: N extends {
|
|
70
78
|
readonly entry: infer E;
|
|
71
79
|
} ? Readonly<Record<string, Structured<E>>> : never;
|
|
@@ -79,13 +87,14 @@ type StructuredBy<N> = {
|
|
|
79
87
|
readonly union: N extends {
|
|
80
88
|
readonly arms: readonly (infer A)[];
|
|
81
89
|
} ? Structured<A> : never;
|
|
90
|
+
readonly jsonSchema: JsonSchema;
|
|
82
91
|
};
|
|
83
92
|
type StructuredObject<R, O> = {
|
|
84
93
|
readonly [K in keyof R]: Structured<R[K]>;
|
|
85
94
|
} & {
|
|
86
95
|
readonly [K in keyof O]?: Structured<O[K]>;
|
|
87
96
|
};
|
|
88
|
-
/** The structure of a ClientContract. Decodes to exactly `
|
|
97
|
+
/** The structure of a ClientContract. Decodes to exactly `AvContractClient`. */
|
|
89
98
|
export declare const CLIENT_CONTRACT_STRUCTURE: {
|
|
90
99
|
readonly is: "object";
|
|
91
100
|
readonly required: {
|
|
@@ -112,7 +121,7 @@ export declare const CLIENT_CONTRACT_STRUCTURE: {
|
|
|
112
121
|
readonly item: {
|
|
113
122
|
readonly is: "string";
|
|
114
123
|
};
|
|
115
|
-
readonly
|
|
124
|
+
readonly minimum: 0;
|
|
116
125
|
readonly unique: true;
|
|
117
126
|
};
|
|
118
127
|
};
|
|
@@ -169,7 +178,7 @@ export declare const CLIENT_CONTRACT_STRUCTURE: {
|
|
|
169
178
|
readonly is: "literal";
|
|
170
179
|
readonly values: readonly ["DEFAULTED", "GENERATED_ON_CREATE", "GENERATED_ON_UPDATE", "COMPUTED_ON_CREATE", "COMPUTED_ON_UPDATE", "COMPUTED_ON_READ", "VIRTUAL"];
|
|
171
180
|
};
|
|
172
|
-
readonly
|
|
181
|
+
readonly minimum: 0;
|
|
173
182
|
readonly unique: false;
|
|
174
183
|
};
|
|
175
184
|
readonly capabilities: {
|
|
@@ -185,7 +194,7 @@ export declare const CLIENT_CONTRACT_STRUCTURE: {
|
|
|
185
194
|
readonly is: "literal";
|
|
186
195
|
readonly values: readonly ["equals", "not", "in", "notIn", "lt", "lte", "gt", "gte", "contains", "startsWith", "endsWith", "mode", "has", "hasEvery", "hasSome", "isEmpty", "path", "stringContains", "stringStartsWith", "stringEndsWith", "arrayContains", "arrayStartsWith", "arrayEndsWith"];
|
|
187
196
|
};
|
|
188
|
-
readonly
|
|
197
|
+
readonly minimum: 0;
|
|
189
198
|
readonly unique: false;
|
|
190
199
|
};
|
|
191
200
|
readonly order: {
|
|
@@ -200,7 +209,7 @@ export declare const CLIENT_CONTRACT_STRUCTURE: {
|
|
|
200
209
|
readonly is: "literal";
|
|
201
210
|
readonly values: readonly ["$increment", "$decrement", "$multiply", "$divide", "$push", "$unset"];
|
|
202
211
|
};
|
|
203
|
-
readonly
|
|
212
|
+
readonly minimum: 0;
|
|
204
213
|
readonly unique: false;
|
|
205
214
|
};
|
|
206
215
|
readonly update: {
|
|
@@ -209,7 +218,7 @@ export declare const CLIENT_CONTRACT_STRUCTURE: {
|
|
|
209
218
|
readonly is: "literal";
|
|
210
219
|
readonly values: readonly ["$increment", "$decrement", "$multiply", "$divide", "$push", "$unset"];
|
|
211
220
|
};
|
|
212
|
-
readonly
|
|
221
|
+
readonly minimum: 0;
|
|
213
222
|
readonly unique: false;
|
|
214
223
|
};
|
|
215
224
|
};
|
|
@@ -219,6 +228,258 @@ export declare const CLIENT_CONTRACT_STRUCTURE: {
|
|
|
219
228
|
readonly format: {
|
|
220
229
|
readonly is: "string";
|
|
221
230
|
};
|
|
231
|
+
readonly json: {
|
|
232
|
+
readonly is: "jsonSchema";
|
|
233
|
+
};
|
|
234
|
+
readonly validators: {
|
|
235
|
+
readonly is: "list";
|
|
236
|
+
readonly item: {
|
|
237
|
+
readonly is: "variants";
|
|
238
|
+
readonly key: "check";
|
|
239
|
+
readonly arms: {
|
|
240
|
+
readonly less_than: {
|
|
241
|
+
readonly is: "object";
|
|
242
|
+
readonly required: {
|
|
243
|
+
readonly check: {
|
|
244
|
+
readonly is: "literal";
|
|
245
|
+
readonly values: readonly ["less_than"];
|
|
246
|
+
};
|
|
247
|
+
readonly value: {
|
|
248
|
+
readonly is: "union";
|
|
249
|
+
readonly arms: readonly [{
|
|
250
|
+
readonly is: "number";
|
|
251
|
+
}, {
|
|
252
|
+
readonly is: "string";
|
|
253
|
+
}];
|
|
254
|
+
};
|
|
255
|
+
readonly inclusive: {
|
|
256
|
+
readonly is: "boolean";
|
|
257
|
+
};
|
|
258
|
+
};
|
|
259
|
+
readonly optional: Record<never, never>;
|
|
260
|
+
};
|
|
261
|
+
readonly greater_than: {
|
|
262
|
+
readonly is: "object";
|
|
263
|
+
readonly required: {
|
|
264
|
+
readonly check: {
|
|
265
|
+
readonly is: "literal";
|
|
266
|
+
readonly values: readonly ["greater_than"];
|
|
267
|
+
};
|
|
268
|
+
readonly value: {
|
|
269
|
+
readonly is: "union";
|
|
270
|
+
readonly arms: readonly [{
|
|
271
|
+
readonly is: "number";
|
|
272
|
+
}, {
|
|
273
|
+
readonly is: "string";
|
|
274
|
+
}];
|
|
275
|
+
};
|
|
276
|
+
readonly inclusive: {
|
|
277
|
+
readonly is: "boolean";
|
|
278
|
+
};
|
|
279
|
+
};
|
|
280
|
+
readonly optional: Record<never, never>;
|
|
281
|
+
};
|
|
282
|
+
readonly multiple_of: {
|
|
283
|
+
readonly is: "object";
|
|
284
|
+
readonly required: {
|
|
285
|
+
readonly check: {
|
|
286
|
+
readonly is: "literal";
|
|
287
|
+
readonly values: readonly ["multiple_of"];
|
|
288
|
+
};
|
|
289
|
+
readonly value: {
|
|
290
|
+
readonly is: "union";
|
|
291
|
+
readonly arms: readonly [{
|
|
292
|
+
readonly is: "number";
|
|
293
|
+
}, {
|
|
294
|
+
readonly is: "string";
|
|
295
|
+
}];
|
|
296
|
+
};
|
|
297
|
+
};
|
|
298
|
+
readonly optional: Record<never, never>;
|
|
299
|
+
};
|
|
300
|
+
readonly max_length: {
|
|
301
|
+
readonly is: "object";
|
|
302
|
+
readonly required: {
|
|
303
|
+
readonly check: {
|
|
304
|
+
readonly is: "literal";
|
|
305
|
+
readonly values: readonly ["max_length"];
|
|
306
|
+
};
|
|
307
|
+
readonly maximum: {
|
|
308
|
+
readonly is: "number";
|
|
309
|
+
};
|
|
310
|
+
};
|
|
311
|
+
readonly optional: {
|
|
312
|
+
readonly list: {
|
|
313
|
+
readonly is: "literal";
|
|
314
|
+
readonly values: readonly [true];
|
|
315
|
+
};
|
|
316
|
+
};
|
|
317
|
+
};
|
|
318
|
+
readonly min_length: {
|
|
319
|
+
readonly is: "object";
|
|
320
|
+
readonly required: {
|
|
321
|
+
readonly check: {
|
|
322
|
+
readonly is: "literal";
|
|
323
|
+
readonly values: readonly ["min_length"];
|
|
324
|
+
};
|
|
325
|
+
readonly minimum: {
|
|
326
|
+
readonly is: "number";
|
|
327
|
+
};
|
|
328
|
+
};
|
|
329
|
+
readonly optional: {
|
|
330
|
+
readonly list: {
|
|
331
|
+
readonly is: "literal";
|
|
332
|
+
readonly values: readonly [true];
|
|
333
|
+
};
|
|
334
|
+
};
|
|
335
|
+
};
|
|
336
|
+
readonly length_equals: {
|
|
337
|
+
readonly is: "object";
|
|
338
|
+
readonly required: {
|
|
339
|
+
readonly check: {
|
|
340
|
+
readonly is: "literal";
|
|
341
|
+
readonly values: readonly ["length_equals"];
|
|
342
|
+
};
|
|
343
|
+
readonly length: {
|
|
344
|
+
readonly is: "number";
|
|
345
|
+
};
|
|
346
|
+
};
|
|
347
|
+
readonly optional: Record<never, never>;
|
|
348
|
+
};
|
|
349
|
+
readonly string_format: {
|
|
350
|
+
readonly is: "union";
|
|
351
|
+
readonly arms: readonly [{
|
|
352
|
+
readonly is: "object";
|
|
353
|
+
readonly required: {
|
|
354
|
+
readonly check: {
|
|
355
|
+
readonly is: "literal";
|
|
356
|
+
readonly values: readonly ["string_format"];
|
|
357
|
+
};
|
|
358
|
+
readonly format: {
|
|
359
|
+
readonly is: "literal";
|
|
360
|
+
readonly values: readonly ["regex"];
|
|
361
|
+
};
|
|
362
|
+
readonly pattern: {
|
|
363
|
+
readonly is: "object";
|
|
364
|
+
readonly required: {
|
|
365
|
+
readonly source: {
|
|
366
|
+
readonly is: "string";
|
|
367
|
+
};
|
|
368
|
+
readonly flags: {
|
|
369
|
+
readonly is: "string";
|
|
370
|
+
};
|
|
371
|
+
};
|
|
372
|
+
readonly optional: Record<never, never>;
|
|
373
|
+
};
|
|
374
|
+
};
|
|
375
|
+
readonly optional: Record<never, never>;
|
|
376
|
+
}, {
|
|
377
|
+
readonly is: "object";
|
|
378
|
+
readonly required: {
|
|
379
|
+
readonly check: {
|
|
380
|
+
readonly is: "literal";
|
|
381
|
+
readonly values: readonly ["string_format"];
|
|
382
|
+
};
|
|
383
|
+
readonly format: {
|
|
384
|
+
readonly is: "literal";
|
|
385
|
+
readonly values: readonly ["includes"];
|
|
386
|
+
};
|
|
387
|
+
readonly includes: {
|
|
388
|
+
readonly is: "string";
|
|
389
|
+
};
|
|
390
|
+
};
|
|
391
|
+
readonly optional: Record<never, never>;
|
|
392
|
+
}, {
|
|
393
|
+
readonly is: "object";
|
|
394
|
+
readonly required: {
|
|
395
|
+
readonly check: {
|
|
396
|
+
readonly is: "literal";
|
|
397
|
+
readonly values: readonly ["string_format"];
|
|
398
|
+
};
|
|
399
|
+
readonly format: {
|
|
400
|
+
readonly is: "literal";
|
|
401
|
+
readonly values: readonly ["starts_with"];
|
|
402
|
+
};
|
|
403
|
+
readonly prefix: {
|
|
404
|
+
readonly is: "string";
|
|
405
|
+
};
|
|
406
|
+
};
|
|
407
|
+
readonly optional: Record<never, never>;
|
|
408
|
+
}, {
|
|
409
|
+
readonly is: "object";
|
|
410
|
+
readonly required: {
|
|
411
|
+
readonly check: {
|
|
412
|
+
readonly is: "literal";
|
|
413
|
+
readonly values: readonly ["string_format"];
|
|
414
|
+
};
|
|
415
|
+
readonly format: {
|
|
416
|
+
readonly is: "literal";
|
|
417
|
+
readonly values: readonly ["ends_with"];
|
|
418
|
+
};
|
|
419
|
+
readonly suffix: {
|
|
420
|
+
readonly is: "string";
|
|
421
|
+
};
|
|
422
|
+
};
|
|
423
|
+
readonly optional: Record<never, never>;
|
|
424
|
+
}, {
|
|
425
|
+
readonly is: "object";
|
|
426
|
+
readonly required: {
|
|
427
|
+
readonly check: {
|
|
428
|
+
readonly is: "literal";
|
|
429
|
+
readonly values: readonly ["string_format"];
|
|
430
|
+
};
|
|
431
|
+
readonly format: {
|
|
432
|
+
readonly is: "literal";
|
|
433
|
+
readonly values: readonly ["lowercase", "uppercase", "email", "url", "emoji", "uuid", "guid", "nanoid", "cuid", "cuid2", "ulid", "xid", "ksuid", "datetime", "date", "time", "duration", "ipv4", "ipv6", "cidrv4", "cidrv6", "base64", "base64url", "json_string", "e164", "credit_card", "iban", "jwt"];
|
|
434
|
+
};
|
|
435
|
+
};
|
|
436
|
+
readonly optional: Record<never, never>;
|
|
437
|
+
}];
|
|
438
|
+
};
|
|
439
|
+
readonly max_size: {
|
|
440
|
+
readonly is: "object";
|
|
441
|
+
readonly required: {
|
|
442
|
+
readonly check: {
|
|
443
|
+
readonly is: "literal";
|
|
444
|
+
readonly values: readonly ["max_size"];
|
|
445
|
+
};
|
|
446
|
+
readonly maximum: {
|
|
447
|
+
readonly is: "number";
|
|
448
|
+
};
|
|
449
|
+
};
|
|
450
|
+
readonly optional: Record<never, never>;
|
|
451
|
+
};
|
|
452
|
+
readonly min_size: {
|
|
453
|
+
readonly is: "object";
|
|
454
|
+
readonly required: {
|
|
455
|
+
readonly check: {
|
|
456
|
+
readonly is: "literal";
|
|
457
|
+
readonly values: readonly ["min_size"];
|
|
458
|
+
};
|
|
459
|
+
readonly minimum: {
|
|
460
|
+
readonly is: "number";
|
|
461
|
+
};
|
|
462
|
+
};
|
|
463
|
+
readonly optional: Record<never, never>;
|
|
464
|
+
};
|
|
465
|
+
readonly size_equals: {
|
|
466
|
+
readonly is: "object";
|
|
467
|
+
readonly required: {
|
|
468
|
+
readonly check: {
|
|
469
|
+
readonly is: "literal";
|
|
470
|
+
readonly values: readonly ["size_equals"];
|
|
471
|
+
};
|
|
472
|
+
readonly size: {
|
|
473
|
+
readonly is: "number";
|
|
474
|
+
};
|
|
475
|
+
};
|
|
476
|
+
readonly optional: Record<never, never>;
|
|
477
|
+
};
|
|
478
|
+
};
|
|
479
|
+
};
|
|
480
|
+
readonly minimum: 0;
|
|
481
|
+
readonly unique: false;
|
|
482
|
+
};
|
|
222
483
|
};
|
|
223
484
|
};
|
|
224
485
|
readonly relation: {
|
|
@@ -252,7 +513,7 @@ export declare const CLIENT_CONTRACT_STRUCTURE: {
|
|
|
252
513
|
readonly is: "literal";
|
|
253
514
|
readonly values: readonly ["record", "bulkWrite"];
|
|
254
515
|
};
|
|
255
|
-
readonly
|
|
516
|
+
readonly minimum: 1;
|
|
256
517
|
readonly unique: false;
|
|
257
518
|
}];
|
|
258
519
|
};
|
|
@@ -266,7 +527,7 @@ export declare const CLIENT_CONTRACT_STRUCTURE: {
|
|
|
266
527
|
readonly is: "literal";
|
|
267
528
|
readonly values: readonly ["record", "bulkWrite"];
|
|
268
529
|
};
|
|
269
|
-
readonly
|
|
530
|
+
readonly minimum: 1;
|
|
270
531
|
readonly unique: false;
|
|
271
532
|
}];
|
|
272
533
|
};
|
|
@@ -276,7 +537,7 @@ export declare const CLIENT_CONTRACT_STRUCTURE: {
|
|
|
276
537
|
readonly is: "literal";
|
|
277
538
|
readonly values: readonly ["nested", "match", "null", "some", "every", "none"];
|
|
278
539
|
};
|
|
279
|
-
readonly
|
|
540
|
+
readonly minimum: 0;
|
|
280
541
|
readonly unique: false;
|
|
281
542
|
};
|
|
282
543
|
readonly order: {
|
|
@@ -288,7 +549,7 @@ export declare const CLIENT_CONTRACT_STRUCTURE: {
|
|
|
288
549
|
readonly is: "literal";
|
|
289
550
|
readonly values: readonly ["limit", "offset", "cursor"];
|
|
290
551
|
};
|
|
291
|
-
readonly
|
|
552
|
+
readonly minimum: 0;
|
|
292
553
|
readonly unique: false;
|
|
293
554
|
};
|
|
294
555
|
readonly reducers: {
|
|
@@ -299,7 +560,7 @@ export declare const CLIENT_CONTRACT_STRUCTURE: {
|
|
|
299
560
|
readonly is: "literal";
|
|
300
561
|
readonly values: readonly ["$count"];
|
|
301
562
|
};
|
|
302
|
-
readonly
|
|
563
|
+
readonly minimum: 0;
|
|
303
564
|
readonly unique: false;
|
|
304
565
|
}, {
|
|
305
566
|
readonly is: "object";
|
|
@@ -310,7 +571,7 @@ export declare const CLIENT_CONTRACT_STRUCTURE: {
|
|
|
310
571
|
readonly is: "literal";
|
|
311
572
|
readonly values: readonly ["$count"];
|
|
312
573
|
};
|
|
313
|
-
readonly
|
|
574
|
+
readonly minimum: 0;
|
|
314
575
|
readonly unique: false;
|
|
315
576
|
};
|
|
316
577
|
readonly scopes: {
|
|
@@ -319,7 +580,7 @@ export declare const CLIENT_CONTRACT_STRUCTURE: {
|
|
|
319
580
|
readonly is: "literal";
|
|
320
581
|
readonly values: readonly ["record", "bulkWrite"];
|
|
321
582
|
};
|
|
322
|
-
readonly
|
|
583
|
+
readonly minimum: 1;
|
|
323
584
|
readonly unique: false;
|
|
324
585
|
};
|
|
325
586
|
};
|
|
@@ -334,7 +595,7 @@ export declare const CLIENT_CONTRACT_STRUCTURE: {
|
|
|
334
595
|
readonly is: "literal";
|
|
335
596
|
readonly values: readonly ["$create", "$connect", "$connectOrCreate", "$disconnect", "$set", "$update", "$delete", "$upsert"];
|
|
336
597
|
};
|
|
337
|
-
readonly
|
|
598
|
+
readonly minimum: 0;
|
|
338
599
|
readonly unique: false;
|
|
339
600
|
}, {
|
|
340
601
|
readonly is: "object";
|
|
@@ -345,7 +606,7 @@ export declare const CLIENT_CONTRACT_STRUCTURE: {
|
|
|
345
606
|
readonly is: "literal";
|
|
346
607
|
readonly values: readonly ["$create", "$connect", "$connectOrCreate", "$disconnect", "$set", "$update", "$delete", "$upsert"];
|
|
347
608
|
};
|
|
348
|
-
readonly
|
|
609
|
+
readonly minimum: 0;
|
|
349
610
|
readonly unique: false;
|
|
350
611
|
};
|
|
351
612
|
readonly scopes: {
|
|
@@ -354,7 +615,7 @@ export declare const CLIENT_CONTRACT_STRUCTURE: {
|
|
|
354
615
|
readonly is: "literal";
|
|
355
616
|
readonly values: readonly ["nested", "bulkWrite"];
|
|
356
617
|
};
|
|
357
|
-
readonly
|
|
618
|
+
readonly minimum: 1;
|
|
358
619
|
readonly unique: false;
|
|
359
620
|
};
|
|
360
621
|
};
|
|
@@ -369,7 +630,7 @@ export declare const CLIENT_CONTRACT_STRUCTURE: {
|
|
|
369
630
|
readonly is: "literal";
|
|
370
631
|
readonly values: readonly ["$create", "$connect", "$connectOrCreate", "$disconnect", "$set", "$update", "$delete", "$upsert"];
|
|
371
632
|
};
|
|
372
|
-
readonly
|
|
633
|
+
readonly minimum: 0;
|
|
373
634
|
readonly unique: false;
|
|
374
635
|
}, {
|
|
375
636
|
readonly is: "object";
|
|
@@ -380,7 +641,7 @@ export declare const CLIENT_CONTRACT_STRUCTURE: {
|
|
|
380
641
|
readonly is: "literal";
|
|
381
642
|
readonly values: readonly ["$create", "$connect", "$connectOrCreate", "$disconnect", "$set", "$update", "$delete", "$upsert"];
|
|
382
643
|
};
|
|
383
|
-
readonly
|
|
644
|
+
readonly minimum: 0;
|
|
384
645
|
readonly unique: false;
|
|
385
646
|
};
|
|
386
647
|
readonly scopes: {
|
|
@@ -389,13 +650,17 @@ export declare const CLIENT_CONTRACT_STRUCTURE: {
|
|
|
389
650
|
readonly is: "literal";
|
|
390
651
|
readonly values: readonly ["nested", "bulkWrite"];
|
|
391
652
|
};
|
|
392
|
-
readonly
|
|
653
|
+
readonly minimum: 1;
|
|
393
654
|
readonly unique: false;
|
|
394
655
|
};
|
|
395
656
|
};
|
|
396
657
|
readonly optional: Record<never, never>;
|
|
397
658
|
}];
|
|
398
659
|
};
|
|
660
|
+
readonly nestedWriteFilter: {
|
|
661
|
+
readonly is: "literal";
|
|
662
|
+
readonly values: readonly ["scalar"];
|
|
663
|
+
};
|
|
399
664
|
};
|
|
400
665
|
};
|
|
401
666
|
};
|
|
@@ -411,10 +676,10 @@ export declare const CLIENT_CONTRACT_STRUCTURE: {
|
|
|
411
676
|
readonly item: {
|
|
412
677
|
readonly is: "string";
|
|
413
678
|
};
|
|
414
|
-
readonly
|
|
679
|
+
readonly minimum: 1;
|
|
415
680
|
readonly unique: false;
|
|
416
681
|
};
|
|
417
|
-
readonly
|
|
682
|
+
readonly minimum: 0;
|
|
418
683
|
readonly unique: false;
|
|
419
684
|
};
|
|
420
685
|
readonly operations: {
|
|
@@ -1014,7 +1279,49 @@ export declare const CLIENT_CONTRACT_STRUCTURE: {
|
|
|
1014
1279
|
};
|
|
1015
1280
|
};
|
|
1016
1281
|
};
|
|
1017
|
-
readonly optional:
|
|
1282
|
+
readonly optional: {
|
|
1283
|
+
readonly createRequirements: {
|
|
1284
|
+
readonly is: "object";
|
|
1285
|
+
readonly required: {};
|
|
1286
|
+
readonly optional: {
|
|
1287
|
+
readonly required: {
|
|
1288
|
+
readonly is: "list";
|
|
1289
|
+
readonly item: {
|
|
1290
|
+
readonly is: "string";
|
|
1291
|
+
};
|
|
1292
|
+
readonly minimum: 1;
|
|
1293
|
+
readonly unique: false;
|
|
1294
|
+
};
|
|
1295
|
+
readonly oneOf: {
|
|
1296
|
+
readonly is: "list";
|
|
1297
|
+
readonly item: {
|
|
1298
|
+
readonly is: "list";
|
|
1299
|
+
readonly item: {
|
|
1300
|
+
readonly is: "string";
|
|
1301
|
+
};
|
|
1302
|
+
readonly minimum: 2;
|
|
1303
|
+
readonly unique: false;
|
|
1304
|
+
};
|
|
1305
|
+
readonly minimum: 1;
|
|
1306
|
+
readonly unique: false;
|
|
1307
|
+
};
|
|
1308
|
+
readonly parentSupplies: {
|
|
1309
|
+
readonly is: "registry";
|
|
1310
|
+
readonly entry: {
|
|
1311
|
+
readonly is: "registry";
|
|
1312
|
+
readonly entry: {
|
|
1313
|
+
readonly is: "list";
|
|
1314
|
+
readonly item: {
|
|
1315
|
+
readonly is: "string";
|
|
1316
|
+
};
|
|
1317
|
+
readonly minimum: 1;
|
|
1318
|
+
readonly unique: false;
|
|
1319
|
+
};
|
|
1320
|
+
};
|
|
1321
|
+
};
|
|
1322
|
+
};
|
|
1323
|
+
};
|
|
1324
|
+
};
|
|
1018
1325
|
};
|
|
1019
1326
|
};
|
|
1020
1327
|
readonly limits: {
|
|
@@ -1035,6 +1342,9 @@ export declare const CLIENT_CONTRACT_STRUCTURE: {
|
|
|
1035
1342
|
readonly maxBooleanNodes: {
|
|
1036
1343
|
readonly is: "number";
|
|
1037
1344
|
};
|
|
1345
|
+
readonly maxJsonDepth: {
|
|
1346
|
+
readonly is: "number";
|
|
1347
|
+
};
|
|
1038
1348
|
};
|
|
1039
1349
|
readonly optional: Record<never, never>;
|
|
1040
1350
|
};
|
|
@@ -1057,7 +1367,12 @@ export declare const CLIENT_CONTRACT_STRUCTURE: {
|
|
|
1057
1367
|
readonly optional: Record<never, never>;
|
|
1058
1368
|
};
|
|
1059
1369
|
};
|
|
1060
|
-
readonly optional:
|
|
1370
|
+
readonly optional: {
|
|
1371
|
+
readonly referenceWrites: {
|
|
1372
|
+
readonly is: "literal";
|
|
1373
|
+
readonly values: readonly ["uniform"];
|
|
1374
|
+
};
|
|
1375
|
+
};
|
|
1061
1376
|
};
|
|
1062
1377
|
/**
|
|
1063
1378
|
* The answer of {@link validateClientContractStructure}. A refusal names the
|
|
@@ -1066,7 +1381,7 @@ export declare const CLIENT_CONTRACT_STRUCTURE: {
|
|
|
1066
1381
|
*/
|
|
1067
1382
|
export type ClientContractStructureVerdict = {
|
|
1068
1383
|
readonly valid: true;
|
|
1069
|
-
readonly contract:
|
|
1384
|
+
readonly contract: AvContractClient;
|
|
1070
1385
|
} | {
|
|
1071
1386
|
readonly valid: false;
|
|
1072
1387
|
readonly path: string;
|