@takeshape/schema 11.52.0 → 11.56.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/dist/__tests__/_examples.test.js +77 -0
- package/dist/__tests__/agents.test.js +163 -0
- package/dist/__tests__/api-version.test.js +24 -0
- package/dist/__tests__/builtin-schema.test.js +18 -0
- package/dist/__tests__/content-schema-transform.test.d.ts +1 -0
- package/dist/__tests__/content-schema-transform.test.js +522 -0
- package/dist/__tests__/create-input-schema.test.d.ts +1 -0
- package/dist/__tests__/create-input-schema.test.js +184 -0
- package/dist/__tests__/enum.test.d.ts +1 -0
- package/dist/__tests__/enum.test.js +36 -0
- package/dist/__tests__/flatten-templates.test.d.ts +1 -0
- package/dist/__tests__/flatten-templates.test.js +40 -0
- package/dist/__tests__/get-is-leaf.test.d.ts +1 -0
- package/dist/__tests__/get-is-leaf.test.js +50 -0
- package/dist/__tests__/interfaces.test.d.ts +1 -0
- package/dist/__tests__/interfaces.test.js +219 -0
- package/dist/__tests__/migration.test.d.ts +1 -0
- package/dist/__tests__/migration.test.js +34 -0
- package/dist/__tests__/mocks.test.d.ts +1 -0
- package/dist/__tests__/mocks.test.js +24 -0
- package/dist/__tests__/refs.test.d.ts +1 -0
- package/dist/__tests__/refs.test.js +752 -0
- package/dist/__tests__/relationships.test.d.ts +1 -0
- package/dist/__tests__/relationships.test.js +638 -0
- package/dist/__tests__/schema-transform.test.d.ts +1 -0
- package/dist/__tests__/schema-transform.test.js +205 -0
- package/dist/__tests__/schema-util.test.d.ts +1 -0
- package/dist/__tests__/schema-util.test.js +1731 -0
- package/dist/__tests__/service-dependencies.test.d.ts +1 -0
- package/dist/__tests__/service-dependencies.test.js +360 -0
- package/dist/__tests__/unions.test.d.ts +1 -0
- package/dist/__tests__/unions.test.js +44 -0
- package/dist/__tests__/validate.test.d.ts +1 -0
- package/dist/__tests__/validate.test.js +1926 -0
- package/dist/__tests__/workflows.test.d.ts +3 -0
- package/dist/__tests__/workflows.test.js +149 -0
- package/dist/agents.d.ts +14 -0
- package/dist/auth-schemas.d.ts +125 -0
- package/dist/builtin-schema.d.ts +8 -0
- package/dist/content-schema-transform.d.ts +35 -0
- package/dist/content-schema-transform.js +162 -0
- package/dist/create-input-schema.d.ts +9 -0
- package/dist/enum.d.ts +2 -0
- package/dist/flatten-templates.d.ts +2 -0
- package/dist/flatten-templates.js +20 -0
- package/dist/get-is-leaf.d.ts +3 -0
- package/dist/get-is-leaf.js +56 -0
- package/dist/index.d.ts +48 -0
- package/dist/index.js +46 -0
- package/dist/interfaces.d.ts +12 -0
- package/dist/interfaces.js +85 -0
- package/dist/layers/__tests__/layers.test.d.ts +1 -0
- package/dist/layers/__tests__/layers.test.js +38 -0
- package/dist/layers/layers.d.ts +26 -0
- package/dist/layers/layers.js +301 -0
- package/dist/layers/refs.d.ts +102 -0
- package/dist/layers/refs.js +220 -0
- package/dist/layers/type-utils.d.ts +59 -0
- package/dist/layers/type-utils.js +118 -0
- package/dist/layers/visitor.d.ts +5 -0
- package/dist/layers/visitor.js +38 -0
- package/dist/migration/index.d.ts +64 -0
- package/dist/migration/index.js +122 -0
- package/dist/migration/to/__tests__/v3.10.0.test.d.ts +1 -0
- package/dist/migration/to/__tests__/v3.10.0.test.js +90 -0
- package/dist/migration/to/__tests__/v3.12.3.test.d.ts +1 -0
- package/dist/migration/to/__tests__/v3.12.3.test.js +103 -0
- package/dist/migration/to/__tests__/v3.17.test.d.ts +1 -0
- package/dist/migration/to/__tests__/v3.17.test.js +71 -0
- package/dist/migration/to/__tests__/v3.34.0.test.d.ts +1 -0
- package/dist/migration/to/__tests__/v3.34.0.test.js +240 -0
- package/dist/migration/to/__tests__/v3.39.0.test.d.ts +1 -0
- package/dist/migration/to/__tests__/v3.39.0.test.js +116 -0
- package/dist/migration/to/__tests__/v3.46.0.test.d.ts +1 -0
- package/dist/migration/to/__tests__/v3.46.0.test.js +59 -0
- package/dist/migration/to/v3.0.0.d.ts +4 -0
- package/dist/migration/to/v3.0.0.js +212 -0
- package/dist/migration/to/v3.1.0.d.ts +4 -0
- package/dist/migration/to/v3.1.0.js +194 -0
- package/dist/migration/to/v3.10.0.d.ts +4 -0
- package/dist/migration/to/v3.11.0.d.ts +4 -0
- package/dist/migration/to/v3.12.0.d.ts +4 -0
- package/dist/migration/to/v3.12.1.d.ts +4 -0
- package/dist/migration/to/v3.12.2.d.ts +4 -0
- package/dist/migration/to/v3.12.3.d.ts +4 -0
- package/dist/migration/to/v3.13.0.d.ts +4 -0
- package/dist/migration/to/v3.14.0.d.ts +4 -0
- package/dist/migration/to/v3.15.0.d.ts +4 -0
- package/dist/migration/to/v3.16.0.d.ts +4 -0
- package/dist/migration/to/v3.17.0.d.ts +4 -0
- package/dist/migration/to/v3.17.1.d.ts +4 -0
- package/dist/migration/to/v3.18.0.d.ts +4 -0
- package/dist/migration/to/v3.18.1.d.ts +4 -0
- package/dist/migration/to/v3.18.2.d.ts +4 -0
- package/dist/migration/to/v3.19.0.d.ts +4 -0
- package/dist/migration/to/v3.2.0.d.ts +4 -0
- package/dist/migration/to/v3.20.0.d.ts +4 -0
- package/dist/migration/to/v3.21.0.d.ts +4 -0
- package/dist/migration/to/v3.22.0.d.ts +4 -0
- package/dist/migration/to/v3.23.0.d.ts +4 -0
- package/dist/migration/to/v3.24.0.d.ts +4 -0
- package/dist/migration/to/v3.25.0.d.ts +4 -0
- package/dist/migration/to/v3.26.0.d.ts +4 -0
- package/dist/migration/to/v3.27.0.d.ts +4 -0
- package/dist/migration/to/v3.28.0.d.ts +4 -0
- package/dist/migration/to/v3.29.0.d.ts +4 -0
- package/dist/migration/to/v3.3.0.d.ts +4 -0
- package/dist/migration/to/v3.30.0.d.ts +4 -0
- package/dist/migration/to/v3.31.0.d.ts +4 -0
- package/dist/migration/to/v3.32.0.d.ts +4 -0
- package/dist/migration/to/v3.32.0.js +59 -0
- package/dist/migration/to/v3.33.0.d.ts +4 -0
- package/dist/migration/to/v3.34.0.d.ts +6 -0
- package/dist/migration/to/v3.34.0.js +116 -0
- package/dist/migration/to/v3.35.0.d.ts +4 -0
- package/dist/migration/to/v3.36.0.d.ts +4 -0
- package/dist/migration/to/v3.37.0.d.ts +4 -0
- package/dist/migration/to/v3.38.0.d.ts +4 -0
- package/dist/migration/to/v3.39.0.d.ts +4 -0
- package/dist/migration/to/v3.39.0.js +45 -0
- package/dist/migration/to/v3.4.0.d.ts +4 -0
- package/dist/migration/to/v3.40.0.d.ts +4 -0
- package/dist/migration/to/v3.41.0.d.ts +4 -0
- package/dist/migration/to/v3.42.0.d.ts +4 -0
- package/dist/migration/to/v3.43.0.d.ts +4 -0
- package/dist/migration/to/v3.44.0.d.ts +4 -0
- package/dist/migration/to/v3.45.0.d.ts +4 -0
- package/dist/migration/to/v3.46.0.d.ts +4 -0
- package/dist/migration/to/v3.47.0.d.ts +4 -0
- package/dist/migration/to/v3.48.0.d.ts +4 -0
- package/dist/migration/to/v3.49.0.d.ts +4 -0
- package/dist/migration/to/v3.5.0.d.ts +4 -0
- package/dist/migration/to/v3.5.1.d.ts +4 -0
- package/dist/migration/to/v3.50.0.d.ts +4 -0
- package/dist/migration/to/v3.51.0.d.ts +4 -0
- package/dist/migration/to/v3.6.0.d.ts +4 -0
- package/dist/migration/to/v3.7.0.d.ts +4 -0
- package/dist/migration/to/v3.8.0.d.ts +4 -0
- package/dist/migration/to/v3.9.0.d.ts +4 -0
- package/dist/migration/types.d.ts +19 -0
- package/dist/migration/types.js +1 -0
- package/dist/mocks.d.ts +13 -0
- package/dist/mocks.js +58 -0
- package/dist/models/__tests__/project-schema.test.d.ts +1 -0
- package/dist/models/__tests__/project-schema.test.js +67 -0
- package/dist/models/__tests__/query.test.d.ts +1 -0
- package/dist/models/__tests__/query.test.js +27 -0
- package/dist/models/__tests__/service.test.d.ts +1 -0
- package/dist/models/__tests__/service.test.js +17 -0
- package/dist/models/__tests__/shape.test.d.ts +1 -0
- package/dist/models/__tests__/shape.test.js +61 -0
- package/dist/models/project-schema.d.ts +35 -0
- package/dist/models/project-schema.js +92 -0
- package/dist/models/query.d.ts +17 -0
- package/dist/models/service.d.ts +12 -0
- package/dist/models/shape.d.ts +41 -0
- package/dist/models/shape.js +85 -0
- package/dist/patterns.js +1 -0
- package/dist/project-schema/index.d.ts +187 -0
- package/dist/project-schema/index.js +75 -0
- package/dist/project-schema/latest.d.ts +2222 -0
- package/dist/project-schema/migrate.d.ts +4 -0
- package/dist/project-schema/migrate.js +194 -0
- package/dist/project-schema/v3.48.0.d.ts +2161 -0
- package/dist/project-schema/v3.49.0.d.ts +2170 -0
- package/dist/project-schema/v3.50.0.d.ts +2222 -0
- package/dist/project-schema/v3.51.0.d.ts +2222 -0
- package/dist/refs.d.ts +226 -0
- package/dist/refs.js +608 -0
- package/dist/relationships.d.ts +40 -0
- package/dist/relationships.js +311 -0
- package/dist/runtime-schema.d.ts +5 -0
- package/dist/runtime-schema.js +80 -0
- package/dist/schema-transform.d.ts +19 -0
- package/dist/schema-transform.js +74 -0
- package/dist/schema-util.d.ts +210 -0
- package/dist/schema-util.js +1077 -0
- package/dist/schemas/auth-schemas.json +365 -0
- package/dist/schemas/index.js +154 -0
- package/dist/schemas/project-schema/experimental.json +1104 -0
- package/dist/service-dependencies.d.ts +13 -0
- package/dist/service-dependencies.js +165 -0
- package/dist/services/__tests__/services.test.d.ts +1 -0
- package/dist/services/__tests__/services.test.js +113 -0
- package/dist/services/services.d.ts +31 -0
- package/dist/services/services.js +145 -0
- package/dist/services/types.js +1 -0
- package/dist/services/util.d.ts +16 -0
- package/dist/taxonomies.d.ts +15 -0
- package/dist/taxonomies.js +24 -0
- package/dist/template-shapes/__tests__/index.test.d.ts +1 -0
- package/dist/template-shapes/__tests__/index.test.js +40 -0
- package/dist/template-shapes/__tests__/names.test.d.ts +1 -0
- package/dist/template-shapes/__tests__/names.test.js +19 -0
- package/dist/template-shapes/__tests__/templates.test.d.ts +1 -0
- package/dist/template-shapes/__tests__/templates.test.js +80 -0
- package/dist/template-shapes/__tests__/where.test.d.ts +1 -0
- package/dist/template-shapes/__tests__/where.test.js +218 -0
- package/dist/template-shapes/index.d.ts +7 -0
- package/dist/template-shapes/names.d.ts +10 -0
- package/dist/template-shapes/templates.d.ts +32 -0
- package/dist/template-shapes/templates.js +319 -0
- package/dist/template-shapes/types.d.ts +15 -0
- package/dist/template-shapes/where.d.ts +37 -0
- package/dist/template-shapes/where.js +402 -0
- package/dist/types/__tests__/utils.test.d.ts +1 -0
- package/dist/types/__tests__/utils.test.js +159 -0
- package/dist/types/index.d.ts +3 -0
- package/dist/types/index.js +2 -0
- package/dist/types/transforms.d.ts +13 -0
- package/dist/types/transforms.js +1 -0
- package/dist/types/types.d.ts +211 -0
- package/dist/types/utils.d.ts +117 -0
- package/dist/types/utils.js +279 -0
- package/dist/unions.d.ts +14 -0
- package/dist/unions.js +77 -0
- package/dist/util/__tests__/api-indexing.test.d.ts +1 -0
- package/dist/util/__tests__/api-indexing.test.js +129 -0
- package/dist/util/__tests__/detect-cycles.test.d.ts +1 -0
- package/dist/util/__tests__/detect-cycles.test.js +193 -0
- package/dist/util/__tests__/find-shape-at-path.test.d.ts +1 -0
- package/dist/util/__tests__/find-shape-at-path.test.js +41 -0
- package/dist/util/__tests__/form-config.test.d.ts +1 -0
- package/dist/util/__tests__/form-config.test.js +196 -0
- package/dist/util/__tests__/get-return-shape.test.d.ts +1 -0
- package/dist/util/__tests__/get-return-shape.test.js +27 -0
- package/dist/util/__tests__/has-args.test.d.ts +1 -0
- package/dist/util/__tests__/has-args.test.js +46 -0
- package/dist/util/__tests__/merge.test.d.ts +1 -0
- package/dist/util/__tests__/merge.test.js +1074 -0
- package/dist/util/__tests__/patch-schema.test.d.ts +1 -0
- package/dist/util/__tests__/patch-schema.test.js +82 -0
- package/dist/util/__tests__/shapes.test.d.ts +1 -0
- package/dist/util/__tests__/shapes.test.js +30 -0
- package/dist/util/ai-tools.d.ts +3 -0
- package/dist/util/api-indexing.d.ts +9 -0
- package/dist/util/api-indexing.js +57 -0
- package/dist/util/detect-cycles.d.ts +7 -0
- package/dist/util/detect-cycles.js +45 -0
- package/dist/util/find-shape-at-path.d.ts +21 -0
- package/dist/util/form-config.d.ts +11 -0
- package/dist/util/form-config.js +62 -0
- package/dist/util/get-conflicting-properties.d.ts +6 -0
- package/dist/util/get-conflicting-properties.js +55 -0
- package/dist/util/get-return-shape.d.ts +4 -0
- package/dist/util/get-return-shape.js +30 -0
- package/dist/util/has-arg.d.ts +4 -0
- package/dist/util/has-arg.js +13 -0
- package/dist/util/merge.d.ts +15 -0
- package/dist/util/merge.js +256 -0
- package/dist/util/patch-schema.d.ts +8 -0
- package/dist/util/shapes.d.ts +5 -0
- package/dist/validate/errors.d.ts +3 -0
- package/dist/validate/errors.js +20 -0
- package/dist/validate/validate.d.ts +73 -0
- package/dist/validate/validate.js +1107 -0
- package/dist/versions.d.ts +4 -0
- package/dist/versions.js +4 -0
- package/dist/workflows.d.ts +14 -0
- package/dist/workflows.js +66 -0
- package/examples/latest/agent-schema.json +12 -4
- package/examples/latest/all-fields-shapes-inline.json +52 -18
- package/examples/latest/all-fields-shapes.json +76 -26
- package/examples/latest/betzino.json +3139 -902
- package/examples/latest/blog-schema.json +28 -8
- package/examples/latest/brewery-schema.json +25 -7
- package/examples/latest/clear-cache-schema.json +7 -3
- package/examples/latest/complex-project-schema.json +359 -98
- package/examples/latest/complex-schema.json +1754 -487
- package/examples/latest/edit-schema.json +11 -4
- package/examples/latest/fabric-ecommerce.json +838 -187
- package/examples/latest/frank-and-fred-schema.json +1753 -486
- package/examples/latest/klirr-schema.json +2411 -682
- package/examples/latest/layers/rick-and-morty-layer.json +32 -11
- package/examples/latest/layers/shopify-layer-2023-01.json +8637 -2206
- package/examples/latest/layers/shopify-storefront-2023-04.json +1714 -404
- package/examples/latest/layers/wordpress-2024-01.json +2746 -691
- package/examples/latest/massive-schema.json +584 -131
- package/examples/latest/mill-components-schema.json +125 -29
- package/examples/latest/nested-shape-arrays.json +19 -7
- package/examples/latest/one-earth.json +1113 -236
- package/examples/latest/pet-oneof-array.json +22 -7
- package/examples/latest/post-schema.json +20 -6
- package/examples/latest/pruned-shopify-product-schema.json +830 -185
- package/examples/latest/rag-example.json +15 -5
- package/examples/latest/real-world-schema.json +56 -14
- package/examples/latest/recursive-repeater-schema.json +11 -4
- package/examples/latest/recursive-schema.json +11 -4
- package/examples/latest/rick-and-morty-ast.json +174 -45
- package/examples/latest/rick-and-morty-graphql.json +100 -25
- package/examples/latest/rick-and-morty-rest.json +7 -3
- package/examples/latest/rick-and-morty-with-indexing.json +13 -5
- package/examples/latest/schema-where-filter.json +40 -11
- package/examples/latest/schema-with-repeater-draftjs.json +8 -3
- package/examples/latest/schema-with-rick-and-morty.json +4 -2
- package/examples/latest/shape-books-v3_2_0.json +71 -17
- package/examples/latest/shape-books.json +71 -17
- package/examples/latest/shape-editor-schema-edited.json +69 -23
- package/examples/latest/shape-editor-schema-initial.json +28 -10
- package/examples/latest/shapedb-crud-every-prop-type.json +22 -8
- package/examples/latest/shopify-lookbook.json +19 -5
- package/examples/latest/shopify-product-2022-07.json +3217 -726
- package/examples/latest/shopify-product-2023-04.json +4496 -1012
- package/examples/latest/shopify-store-with-widget.json +942 -213
- package/examples/latest/stripe-product-runtime-schema.json +277 -81
- package/examples/latest/stripe-starter-resolved.json +1953 -476
- package/examples/latest/user-schema-no-required.json +13 -3
- package/examples/latest/user-schema-with-defaults.json +27 -5
- package/examples/latest/valvoline-ai-demo.json +69 -17
- package/examples/latest/vector-search-schema.json +24 -8
- package/package.json +24 -26
- package/dist/cjs/package.json +0 -1
- package/dist/cjs/src/agents.js +0 -147
- package/dist/cjs/src/api-version.js +0 -24
- package/dist/cjs/src/auth-schemas.js +0 -8
- package/dist/cjs/src/builtin-schema.js +0 -616
- package/dist/cjs/src/constants.js +0 -4
- package/dist/cjs/src/content-schema-transform.js +0 -175
- package/dist/cjs/src/create-input-schema.js +0 -66
- package/dist/cjs/src/enum.js +0 -12
- package/dist/cjs/src/flatten-templates.js +0 -26
- package/dist/cjs/src/get-is-leaf.js +0 -59
- package/dist/cjs/src/index.js +0 -62
- package/dist/cjs/src/interfaces.js +0 -98
- package/dist/cjs/src/layers/layers.js +0 -313
- package/dist/cjs/src/layers/refs.js +0 -243
- package/dist/cjs/src/layers/type-utils.js +0 -145
- package/dist/cjs/src/layers/visitor.js +0 -42
- package/dist/cjs/src/migration/index.js +0 -142
- package/dist/cjs/src/migration/to/v3.0.0.js +0 -217
- package/dist/cjs/src/migration/to/v3.1.0.js +0 -199
- package/dist/cjs/src/migration/to/v3.10.0.js +0 -72
- package/dist/cjs/src/migration/to/v3.11.0.js +0 -90
- package/dist/cjs/src/migration/to/v3.12.0.js +0 -12
- package/dist/cjs/src/migration/to/v3.12.1.js +0 -12
- package/dist/cjs/src/migration/to/v3.12.2.js +0 -12
- package/dist/cjs/src/migration/to/v3.12.3.js +0 -92
- package/dist/cjs/src/migration/to/v3.13.0.js +0 -22
- package/dist/cjs/src/migration/to/v3.14.0.js +0 -12
- package/dist/cjs/src/migration/to/v3.15.0.js +0 -12
- package/dist/cjs/src/migration/to/v3.16.0.js +0 -12
- package/dist/cjs/src/migration/to/v3.17.0.js +0 -27
- package/dist/cjs/src/migration/to/v3.17.1.js +0 -12
- package/dist/cjs/src/migration/to/v3.18.0.js +0 -69
- package/dist/cjs/src/migration/to/v3.18.1.js +0 -20
- package/dist/cjs/src/migration/to/v3.18.2.js +0 -24
- package/dist/cjs/src/migration/to/v3.19.0.js +0 -12
- package/dist/cjs/src/migration/to/v3.2.0.js +0 -12
- package/dist/cjs/src/migration/to/v3.20.0.js +0 -29
- package/dist/cjs/src/migration/to/v3.21.0.js +0 -12
- package/dist/cjs/src/migration/to/v3.22.0.js +0 -30
- package/dist/cjs/src/migration/to/v3.23.0.js +0 -12
- package/dist/cjs/src/migration/to/v3.24.0.js +0 -13
- package/dist/cjs/src/migration/to/v3.25.0.js +0 -13
- package/dist/cjs/src/migration/to/v3.26.0.js +0 -12
- package/dist/cjs/src/migration/to/v3.27.0.js +0 -12
- package/dist/cjs/src/migration/to/v3.28.0.js +0 -12
- package/dist/cjs/src/migration/to/v3.29.0.js +0 -12
- package/dist/cjs/src/migration/to/v3.3.0.js +0 -15
- package/dist/cjs/src/migration/to/v3.30.0.js +0 -12
- package/dist/cjs/src/migration/to/v3.31.0.js +0 -43
- package/dist/cjs/src/migration/to/v3.32.0.js +0 -61
- package/dist/cjs/src/migration/to/v3.33.0.js +0 -12
- package/dist/cjs/src/migration/to/v3.34.0.js +0 -123
- package/dist/cjs/src/migration/to/v3.35.0.js +0 -12
- package/dist/cjs/src/migration/to/v3.36.0.js +0 -27
- package/dist/cjs/src/migration/to/v3.37.0.js +0 -12
- package/dist/cjs/src/migration/to/v3.38.0.js +0 -12
- package/dist/cjs/src/migration/to/v3.39.0.js +0 -47
- package/dist/cjs/src/migration/to/v3.4.0.js +0 -12
- package/dist/cjs/src/migration/to/v3.40.0.js +0 -31
- package/dist/cjs/src/migration/to/v3.41.0.js +0 -12
- package/dist/cjs/src/migration/to/v3.42.0.js +0 -12
- package/dist/cjs/src/migration/to/v3.43.0.js +0 -12
- package/dist/cjs/src/migration/to/v3.44.0.js +0 -12
- package/dist/cjs/src/migration/to/v3.45.0.js +0 -12
- package/dist/cjs/src/migration/to/v3.46.0.js +0 -37
- package/dist/cjs/src/migration/to/v3.47.0.js +0 -12
- package/dist/cjs/src/migration/to/v3.48.0.js +0 -12
- package/dist/cjs/src/migration/to/v3.49.0.js +0 -12
- package/dist/cjs/src/migration/to/v3.5.0.js +0 -12
- package/dist/cjs/src/migration/to/v3.5.1.js +0 -12
- package/dist/cjs/src/migration/to/v3.50.0.js +0 -12
- package/dist/cjs/src/migration/to/v3.51.0.js +0 -12
- package/dist/cjs/src/migration/to/v3.6.0.js +0 -12
- package/dist/cjs/src/migration/to/v3.7.0.js +0 -12
- package/dist/cjs/src/migration/to/v3.8.0.js +0 -12
- package/dist/cjs/src/migration/to/v3.9.0.js +0 -84
- package/dist/cjs/src/migration/types.js +0 -2
- package/dist/cjs/src/migration/utils.js +0 -10
- package/dist/cjs/src/mocks.js +0 -65
- package/dist/cjs/src/models/project-schema.js +0 -99
- package/dist/cjs/src/models/query.js +0 -35
- package/dist/cjs/src/models/service.js +0 -24
- package/dist/cjs/src/models/shape.js +0 -89
- package/dist/cjs/src/patterns.js +0 -2
- package/dist/cjs/src/project-schema/index.js +0 -156
- package/dist/cjs/src/project-schema/latest.js +0 -8
- package/dist/cjs/src/project-schema/migrate.js +0 -198
- package/dist/cjs/src/project-schema/v1.0.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.0.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.1.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.10.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.11.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.12.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.12.1.js +0 -8
- package/dist/cjs/src/project-schema/v3.12.2.js +0 -8
- package/dist/cjs/src/project-schema/v3.12.3.js +0 -8
- package/dist/cjs/src/project-schema/v3.13.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.13.1.js +0 -8
- package/dist/cjs/src/project-schema/v3.14.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.15.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.16.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.17.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.17.1.js +0 -8
- package/dist/cjs/src/project-schema/v3.18.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.18.1.js +0 -8
- package/dist/cjs/src/project-schema/v3.18.2.js +0 -8
- package/dist/cjs/src/project-schema/v3.19.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.2.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.20.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.21.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.22.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.23.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.24.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.25.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.26.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.27.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.28.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.29.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.3.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.30.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.31.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.32.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.33.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.34.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.35.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.36.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.37.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.38.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.39.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.4.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.40.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.41.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.42.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.43.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.44.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.45.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.46.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.47.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.48.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.49.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.5.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.5.1.js +0 -8
- package/dist/cjs/src/project-schema/v3.50.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.51.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.6.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.7.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.8.0.js +0 -8
- package/dist/cjs/src/project-schema/v3.9.0.js +0 -8
- package/dist/cjs/src/project-schema/v4.0.0.js +0 -8
- package/dist/cjs/src/refs.js +0 -671
- package/dist/cjs/src/relationships.js +0 -326
- package/dist/cjs/src/runtime-schema.js +0 -88
- package/dist/cjs/src/scalars.js +0 -8
- package/dist/cjs/src/schema-transform.js +0 -83
- package/dist/cjs/src/schema-util.js +0 -1140
- package/dist/cjs/src/schemas/auth-schemas.json +0 -313
- package/dist/cjs/src/schemas/index.js +0 -162
- package/dist/cjs/src/schemas/project-schema/experimental.json +0 -1101
- package/dist/cjs/src/schemas/user-schema.json +0 -51
- package/dist/cjs/src/service-dependencies.js +0 -172
- package/dist/cjs/src/services/services.js +0 -156
- package/dist/cjs/src/services/types.js +0 -2
- package/dist/cjs/src/services/util.js +0 -45
- package/dist/cjs/src/taxonomies.js +0 -28
- package/dist/cjs/src/template-shapes/index.js +0 -37
- package/dist/cjs/src/template-shapes/names.js +0 -26
- package/dist/cjs/src/template-shapes/templates.js +0 -331
- package/dist/cjs/src/template-shapes/types.js +0 -10
- package/dist/cjs/src/template-shapes/where.js +0 -414
- package/dist/cjs/src/types/index.js +0 -19
- package/dist/cjs/src/types/transforms.js +0 -2
- package/dist/cjs/src/types/types.js +0 -21
- package/dist/cjs/src/types/utils.js +0 -344
- package/dist/cjs/src/unions.js +0 -88
- package/dist/cjs/src/user-schema.js +0 -8
- package/dist/cjs/src/util/ai-tools.js +0 -10
- package/dist/cjs/src/util/api-indexing.js +0 -62
- package/dist/cjs/src/util/detect-cycles.js +0 -48
- package/dist/cjs/src/util/find-shape-at-path.js +0 -57
- package/dist/cjs/src/util/form-config.js +0 -66
- package/dist/cjs/src/util/get-conflicting-properties.js +0 -58
- package/dist/cjs/src/util/get-return-shape.js +0 -34
- package/dist/cjs/src/util/has-arg.js +0 -17
- package/dist/cjs/src/util/merge.js +0 -269
- package/dist/cjs/src/util/patch-schema.js +0 -55
- package/dist/cjs/src/util/shapes.js +0 -31
- package/dist/cjs/src/validate.js +0 -1140
- package/dist/cjs/src/versions.js +0 -8
- package/dist/cjs/src/workflows.js +0 -76
- package/dist/cjs/tsconfig.cjs.tsbuildinfo +0 -1
- package/dist/esm/package.json +0 -1
- package/dist/esm/src/content-schema-transform.js +0 -162
- package/dist/esm/src/flatten-templates.js +0 -20
- package/dist/esm/src/get-is-leaf.js +0 -56
- package/dist/esm/src/index.js +0 -46
- package/dist/esm/src/interfaces.js +0 -85
- package/dist/esm/src/layers/layers.js +0 -301
- package/dist/esm/src/layers/refs.js +0 -220
- package/dist/esm/src/layers/type-utils.js +0 -118
- package/dist/esm/src/layers/visitor.js +0 -38
- package/dist/esm/src/migration/index.js +0 -122
- package/dist/esm/src/migration/to/v3.0.0.js +0 -212
- package/dist/esm/src/migration/to/v3.1.0.js +0 -194
- package/dist/esm/src/migration/to/v3.32.0.js +0 -59
- package/dist/esm/src/migration/to/v3.34.0.js +0 -116
- package/dist/esm/src/migration/to/v3.39.0.js +0 -45
- package/dist/esm/src/mocks.js +0 -58
- package/dist/esm/src/models/project-schema.js +0 -92
- package/dist/esm/src/models/shape.js +0 -85
- package/dist/esm/src/project-schema/index.js +0 -138
- package/dist/esm/src/project-schema/migrate.js +0 -194
- package/dist/esm/src/refs.js +0 -608
- package/dist/esm/src/relationships.js +0 -311
- package/dist/esm/src/runtime-schema.js +0 -80
- package/dist/esm/src/schema-transform.js +0 -74
- package/dist/esm/src/schema-util.js +0 -1077
- package/dist/esm/src/schemas/auth-schemas.json +0 -313
- package/dist/esm/src/schemas/index.js +0 -154
- package/dist/esm/src/schemas/project-schema/experimental.json +0 -1101
- package/dist/esm/src/schemas/project-schema/latest.json +0 -3320
- package/dist/esm/src/schemas/project-schema/meta-schema-v1.0.0.json +0 -193
- package/dist/esm/src/schemas/project-schema/meta-schema-v3.0.0.json +0 -608
- package/dist/esm/src/schemas/project-schema/meta-schema-v3.1.0.json +0 -608
- package/dist/esm/src/schemas/project-schema/meta-schema-v3.2.0.json +0 -612
- package/dist/esm/src/schemas/project-schema/meta-schema-v3.3.0.json +0 -612
- package/dist/esm/src/schemas/project-schema/meta-schema-v3.4.0.json +0 -637
- package/dist/esm/src/schemas/project-schema/meta-schema-v3.5.0.json +0 -626
- package/dist/esm/src/schemas/project-schema/meta-schema-v3.5.1.json +0 -626
- package/dist/esm/src/schemas/project-schema/meta-schema-v3.6.0.json +0 -629
- package/dist/esm/src/schemas/project-schema/meta-schema-v3.7.0.json +0 -1137
- package/dist/esm/src/schemas/project-schema/meta-schema-v3.8.0.json +0 -1137
- package/dist/esm/src/schemas/project-schema/meta-schema-v3.9.0.json +0 -1477
- package/dist/esm/src/schemas/project-schema/v1.0.0.json +0 -321
- package/dist/esm/src/schemas/project-schema/v3.0.0.json +0 -414
- package/dist/esm/src/schemas/project-schema/v3.1.0.json +0 -572
- package/dist/esm/src/schemas/project-schema/v3.10.0.json +0 -2097
- package/dist/esm/src/schemas/project-schema/v3.11.0.json +0 -2141
- package/dist/esm/src/schemas/project-schema/v3.12.0.json +0 -2144
- package/dist/esm/src/schemas/project-schema/v3.12.1.json +0 -2282
- package/dist/esm/src/schemas/project-schema/v3.12.2.json +0 -2304
- package/dist/esm/src/schemas/project-schema/v3.12.3.json +0 -2357
- package/dist/esm/src/schemas/project-schema/v3.13.0.json +0 -2377
- package/dist/esm/src/schemas/project-schema/v3.14.0.json +0 -2385
- package/dist/esm/src/schemas/project-schema/v3.15.0.json +0 -2365
- package/dist/esm/src/schemas/project-schema/v3.16.0.json +0 -2373
- package/dist/esm/src/schemas/project-schema/v3.17.0.json +0 -2378
- package/dist/esm/src/schemas/project-schema/v3.17.1.json +0 -2380
- package/dist/esm/src/schemas/project-schema/v3.18.0.json +0 -2356
- package/dist/esm/src/schemas/project-schema/v3.18.1.json +0 -2357
- package/dist/esm/src/schemas/project-schema/v3.18.2.json +0 -2357
- package/dist/esm/src/schemas/project-schema/v3.19.0.json +0 -2369
- package/dist/esm/src/schemas/project-schema/v3.2.0.json +0 -580
- package/dist/esm/src/schemas/project-schema/v3.20.0.json +0 -2369
- package/dist/esm/src/schemas/project-schema/v3.21.0.json +0 -2376
- package/dist/esm/src/schemas/project-schema/v3.22.0.json +0 -2381
- package/dist/esm/src/schemas/project-schema/v3.23.0.json +0 -2456
- package/dist/esm/src/schemas/project-schema/v3.24.0.json +0 -2556
- package/dist/esm/src/schemas/project-schema/v3.25.0.json +0 -2552
- package/dist/esm/src/schemas/project-schema/v3.26.0.json +0 -2599
- package/dist/esm/src/schemas/project-schema/v3.27.0.json +0 -2611
- package/dist/esm/src/schemas/project-schema/v3.28.0.json +0 -2656
- package/dist/esm/src/schemas/project-schema/v3.29.0.json +0 -2670
- package/dist/esm/src/schemas/project-schema/v3.3.0.json +0 -581
- package/dist/esm/src/schemas/project-schema/v3.30.0.json +0 -2656
- package/dist/esm/src/schemas/project-schema/v3.31.0.json +0 -2714
- package/dist/esm/src/schemas/project-schema/v3.32.0.json +0 -2708
- package/dist/esm/src/schemas/project-schema/v3.33.0.json +0 -2715
- package/dist/esm/src/schemas/project-schema/v3.34.0.json +0 -2715
- package/dist/esm/src/schemas/project-schema/v3.35.0.json +0 -2748
- package/dist/esm/src/schemas/project-schema/v3.36.0.json +0 -2756
- package/dist/esm/src/schemas/project-schema/v3.37.0.json +0 -2821
- package/dist/esm/src/schemas/project-schema/v3.38.0.json +0 -2819
- package/dist/esm/src/schemas/project-schema/v3.39.0.json +0 -2827
- package/dist/esm/src/schemas/project-schema/v3.4.0.json +0 -571
- package/dist/esm/src/schemas/project-schema/v3.40.0.json +0 -2830
- package/dist/esm/src/schemas/project-schema/v3.41.0.json +0 -2830
- package/dist/esm/src/schemas/project-schema/v3.42.0.json +0 -2835
- package/dist/esm/src/schemas/project-schema/v3.43.0.json +0 -2841
- package/dist/esm/src/schemas/project-schema/v3.44.0.json +0 -3013
- package/dist/esm/src/schemas/project-schema/v3.45.0.json +0 -3064
- package/dist/esm/src/schemas/project-schema/v3.46.0.json +0 -3136
- package/dist/esm/src/schemas/project-schema/v3.47.0.json +0 -3189
- package/dist/esm/src/schemas/project-schema/v3.48.0.json +0 -3196
- package/dist/esm/src/schemas/project-schema/v3.49.0.json +0 -3239
- package/dist/esm/src/schemas/project-schema/v3.5.0.json +0 -571
- package/dist/esm/src/schemas/project-schema/v3.5.1.json +0 -571
- package/dist/esm/src/schemas/project-schema/v3.50.0.json +0 -3320
- package/dist/esm/src/schemas/project-schema/v3.51.0.json +0 -3320
- package/dist/esm/src/schemas/project-schema/v3.6.0.json +0 -587
- package/dist/esm/src/schemas/project-schema/v3.7.0.json +0 -587
- package/dist/esm/src/schemas/project-schema/v3.8.0.json +0 -604
- package/dist/esm/src/schemas/project-schema/v3.9.0.json +0 -604
- package/dist/esm/src/schemas/project-schema/v4.0.0.json +0 -2316
- package/dist/esm/src/schemas/project-schema.json +0 -190
- package/dist/esm/src/schemas/user-schema.json +0 -51
- package/dist/esm/src/service-dependencies.js +0 -165
- package/dist/esm/src/services/services.js +0 -145
- package/dist/esm/src/taxonomies.js +0 -24
- package/dist/esm/src/template-shapes/templates.js +0 -319
- package/dist/esm/src/template-shapes/where.js +0 -402
- package/dist/esm/src/types/index.js +0 -3
- package/dist/esm/src/types/utils.js +0 -279
- package/dist/esm/src/unions.js +0 -77
- package/dist/esm/src/user-schema.js +0 -7
- package/dist/esm/src/util/api-indexing.js +0 -57
- package/dist/esm/src/util/detect-cycles.js +0 -45
- package/dist/esm/src/util/form-config.js +0 -62
- package/dist/esm/src/util/get-conflicting-properties.js +0 -55
- package/dist/esm/src/util/get-return-shape.js +0 -30
- package/dist/esm/src/util/has-arg.js +0 -13
- package/dist/esm/src/util/merge.js +0 -256
- package/dist/esm/src/validate.js +0 -1126
- package/dist/esm/src/versions.js +0 -4
- package/dist/esm/src/workflows.js +0 -66
- package/dist/esm/tsconfig.esm.tsbuildinfo +0 -1
- package/dist/types/src/agents.d.ts +0 -14
- package/dist/types/src/auth-schemas.d.ts +0 -104
- package/dist/types/src/builtin-schema.d.ts +0 -8
- package/dist/types/src/content-schema-transform.d.ts +0 -35
- package/dist/types/src/create-input-schema.d.ts +0 -9
- package/dist/types/src/enum.d.ts +0 -2
- package/dist/types/src/flatten-templates.d.ts +0 -2
- package/dist/types/src/get-is-leaf.d.ts +0 -3
- package/dist/types/src/index.d.ts +0 -48
- package/dist/types/src/interfaces.d.ts +0 -12
- package/dist/types/src/layers/layers.d.ts +0 -26
- package/dist/types/src/layers/refs.d.ts +0 -102
- package/dist/types/src/layers/type-utils.d.ts +0 -59
- package/dist/types/src/layers/visitor.d.ts +0 -5
- package/dist/types/src/migration/index.d.ts +0 -64
- package/dist/types/src/migration/to/v3.0.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.1.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.10.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.11.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.12.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.12.1.d.ts +0 -4
- package/dist/types/src/migration/to/v3.12.2.d.ts +0 -4
- package/dist/types/src/migration/to/v3.12.3.d.ts +0 -4
- package/dist/types/src/migration/to/v3.13.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.14.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.15.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.16.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.17.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.17.1.d.ts +0 -4
- package/dist/types/src/migration/to/v3.18.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.18.1.d.ts +0 -4
- package/dist/types/src/migration/to/v3.18.2.d.ts +0 -4
- package/dist/types/src/migration/to/v3.19.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.2.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.20.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.21.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.22.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.23.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.24.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.25.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.26.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.27.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.28.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.29.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.3.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.30.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.31.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.32.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.33.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.34.0.d.ts +0 -6
- package/dist/types/src/migration/to/v3.35.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.36.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.37.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.38.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.39.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.4.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.40.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.41.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.42.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.43.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.44.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.45.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.46.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.47.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.48.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.49.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.5.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.5.1.d.ts +0 -4
- package/dist/types/src/migration/to/v3.50.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.51.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.6.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.7.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.8.0.d.ts +0 -4
- package/dist/types/src/migration/to/v3.9.0.d.ts +0 -4
- package/dist/types/src/migration/types.d.ts +0 -19
- package/dist/types/src/mocks.d.ts +0 -13
- package/dist/types/src/models/project-schema.d.ts +0 -35
- package/dist/types/src/models/query.d.ts +0 -17
- package/dist/types/src/models/service.d.ts +0 -12
- package/dist/types/src/models/shape.d.ts +0 -41
- package/dist/types/src/project-schema/index.d.ts +0 -187
- package/dist/types/src/project-schema/latest.d.ts +0 -2221
- package/dist/types/src/project-schema/migrate.d.ts +0 -4
- package/dist/types/src/project-schema/v3.48.0.d.ts +0 -2160
- package/dist/types/src/project-schema/v3.49.0.d.ts +0 -2169
- package/dist/types/src/project-schema/v3.50.0.d.ts +0 -2221
- package/dist/types/src/project-schema/v3.51.0.d.ts +0 -2221
- package/dist/types/src/refs.d.ts +0 -226
- package/dist/types/src/relationships.d.ts +0 -40
- package/dist/types/src/runtime-schema.d.ts +0 -5
- package/dist/types/src/schema-transform.d.ts +0 -19
- package/dist/types/src/schema-util.d.ts +0 -210
- package/dist/types/src/service-dependencies.d.ts +0 -13
- package/dist/types/src/services/services.d.ts +0 -31
- package/dist/types/src/services/util.d.ts +0 -16
- package/dist/types/src/taxonomies.d.ts +0 -15
- package/dist/types/src/template-shapes/index.d.ts +0 -7
- package/dist/types/src/template-shapes/names.d.ts +0 -10
- package/dist/types/src/template-shapes/templates.d.ts +0 -32
- package/dist/types/src/template-shapes/types.d.ts +0 -15
- package/dist/types/src/template-shapes/where.d.ts +0 -37
- package/dist/types/src/types/index.d.ts +0 -3
- package/dist/types/src/types/transforms.d.ts +0 -13
- package/dist/types/src/types/types.d.ts +0 -211
- package/dist/types/src/types/utils.d.ts +0 -117
- package/dist/types/src/unions.d.ts +0 -14
- package/dist/types/src/user-schema.d.ts +0 -38
- package/dist/types/src/util/ai-tools.d.ts +0 -3
- package/dist/types/src/util/api-indexing.d.ts +0 -9
- package/dist/types/src/util/detect-cycles.d.ts +0 -7
- package/dist/types/src/util/find-shape-at-path.d.ts +0 -21
- package/dist/types/src/util/form-config.d.ts +0 -11
- package/dist/types/src/util/get-conflicting-properties.d.ts +0 -6
- package/dist/types/src/util/get-return-shape.d.ts +0 -4
- package/dist/types/src/util/has-arg.d.ts +0 -4
- package/dist/types/src/util/merge.d.ts +0 -15
- package/dist/types/src/util/patch-schema.d.ts +0 -8
- package/dist/types/src/util/shapes.d.ts +0 -5
- package/dist/types/src/validate.d.ts +0 -75
- package/dist/types/src/versions.d.ts +0 -4
- package/dist/types/src/workflows.d.ts +0 -14
- package/dist/types/tsconfig.types.tsbuildinfo +0 -1
- /package/dist/{esm/src/migration/types.js → __tests__/_examples.test.d.ts} +0 -0
- /package/dist/{esm/src/patterns.js → __tests__/agents.test.d.ts} +0 -0
- /package/dist/{esm/src/services/types.js → __tests__/api-version.test.d.ts} +0 -0
- /package/dist/{esm/src/types/transforms.js → __tests__/builtin-schema.test.d.ts} +0 -0
- /package/dist/{esm/src/agents.js → agents.js} +0 -0
- /package/dist/{types/src/api-version.d.ts → api-version.d.ts} +0 -0
- /package/dist/{esm/src/api-version.js → api-version.js} +0 -0
- /package/dist/{esm/src/auth-schemas.js → auth-schemas.js} +0 -0
- /package/dist/{esm/src/builtin-schema.js → builtin-schema.js} +0 -0
- /package/dist/{types/src/constants.d.ts → constants.d.ts} +0 -0
- /package/dist/{esm/src/constants.js → constants.js} +0 -0
- /package/dist/{esm/src/create-input-schema.js → create-input-schema.js} +0 -0
- /package/dist/{esm/src/enum.js → enum.js} +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.10.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.11.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.12.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.12.1.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.12.2.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.12.3.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.13.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.14.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.15.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.16.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.17.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.17.1.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.18.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.18.1.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.18.2.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.19.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.2.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.20.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.21.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.22.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.23.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.24.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.25.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.26.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.27.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.28.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.29.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.3.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.30.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.31.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.33.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.35.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.36.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.37.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.38.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.4.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.40.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.41.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.42.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.43.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.44.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.45.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.46.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.47.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.48.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.49.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.5.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.5.1.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.50.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.51.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.6.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.7.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.8.0.js +0 -0
- /package/dist/{esm/src/migration → migration}/to/v3.9.0.js +0 -0
- /package/dist/{types/src/migration → migration}/utils.d.ts +0 -0
- /package/dist/{esm/src/migration → migration}/utils.js +0 -0
- /package/dist/{esm/src/models → models}/query.js +0 -0
- /package/dist/{esm/src/models → models}/service.js +0 -0
- /package/dist/{types/src/patterns.d.ts → patterns.d.ts} +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/latest.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v1.0.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v1.0.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.0.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.0.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.1.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.1.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.10.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.10.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.11.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.11.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.12.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.12.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.12.1.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.12.1.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.12.2.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.12.2.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.12.3.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.12.3.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.13.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.13.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.13.1.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.13.1.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.14.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.14.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.15.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.15.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.16.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.16.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.17.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.17.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.17.1.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.17.1.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.18.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.18.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.18.1.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.18.1.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.18.2.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.18.2.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.19.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.19.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.2.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.2.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.20.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.20.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.21.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.21.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.22.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.22.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.23.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.23.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.24.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.24.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.25.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.25.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.26.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.26.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.27.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.27.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.28.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.28.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.29.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.29.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.3.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.3.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.30.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.30.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.31.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.31.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.32.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.32.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.33.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.33.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.34.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.34.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.35.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.35.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.36.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.36.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.37.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.37.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.38.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.38.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.39.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.39.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.4.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.4.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.40.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.40.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.41.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.41.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.42.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.42.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.43.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.43.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.44.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.44.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.45.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.45.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.46.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.46.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.47.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.47.0.js +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.48.0.js +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.49.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.5.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.5.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.5.1.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.5.1.js +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.50.0.js +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.51.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.6.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.6.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.7.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.7.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.8.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.8.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v3.9.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v3.9.0.js +0 -0
- /package/dist/{types/src/project-schema → project-schema}/v4.0.0.d.ts +0 -0
- /package/dist/{esm/src/project-schema → project-schema}/v4.0.0.js +0 -0
- /package/dist/{types/src/scalars.d.ts → scalars.d.ts} +0 -0
- /package/dist/{esm/src/scalars.js → scalars.js} +0 -0
- /package/dist/{types/src/schemas → schemas}/index.d.ts +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/latest.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/meta-schema-v1.0.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/meta-schema-v3.0.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/meta-schema-v3.1.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/meta-schema-v3.2.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/meta-schema-v3.3.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/meta-schema-v3.4.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/meta-schema-v3.5.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/meta-schema-v3.5.1.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/meta-schema-v3.6.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/meta-schema-v3.7.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/meta-schema-v3.8.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/meta-schema-v3.9.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v1.0.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.0.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.1.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.10.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.11.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.12.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.12.1.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.12.2.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.12.3.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.13.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.14.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.15.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.16.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.17.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.17.1.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.18.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.18.1.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.18.2.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.19.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.2.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.20.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.21.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.22.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.23.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.24.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.25.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.26.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.27.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.28.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.29.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.3.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.30.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.31.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.32.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.33.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.34.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.35.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.36.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.37.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.38.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.39.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.4.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.40.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.41.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.42.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.43.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.44.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.45.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.46.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.47.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.48.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.49.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.5.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.5.1.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.50.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.51.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.6.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.7.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.8.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v3.9.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema/v4.0.0.json +0 -0
- /package/dist/{cjs/src/schemas → schemas}/project-schema.json +0 -0
- /package/dist/{types/src/services → services}/types.d.ts +0 -0
- /package/dist/{esm/src/services → services}/util.js +0 -0
- /package/dist/{esm/src/template-shapes → template-shapes}/index.js +0 -0
- /package/dist/{esm/src/template-shapes → template-shapes}/names.js +0 -0
- /package/dist/{esm/src/template-shapes → template-shapes}/types.js +0 -0
- /package/dist/{esm/src/types → types}/types.js +0 -0
- /package/dist/{esm/src/util → util}/ai-tools.js +0 -0
- /package/dist/{esm/src/util → util}/find-shape-at-path.js +0 -0
- /package/dist/{esm/src/util → util}/patch-schema.js +0 -0
- /package/dist/{esm/src/util → util}/shapes.js +0 -0
|
@@ -1,344 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.getRefType = exports.getArgsType = exports.aiResolverNames = void 0;
|
|
7
|
-
exports.isBasicResolver = isBasicResolver;
|
|
8
|
-
exports.isServiceResolver = isServiceResolver;
|
|
9
|
-
exports.isComposeResolver = isComposeResolver;
|
|
10
|
-
exports.isTakeshapeResolver = isTakeshapeResolver;
|
|
11
|
-
exports.isShapedbResolver = isShapedbResolver;
|
|
12
|
-
exports.isGraphqlResolver = isGraphqlResolver;
|
|
13
|
-
exports.isRestResolver = isRestResolver;
|
|
14
|
-
exports.isAwsLambdaResolver = isAwsLambdaResolver;
|
|
15
|
-
exports.isUtilResolver = isUtilResolver;
|
|
16
|
-
exports.isAIResolverName = isAIResolverName;
|
|
17
|
-
exports.isAIResolver = isAIResolver;
|
|
18
|
-
exports.isAIAgentStateExecution = isAIAgentStateExecution;
|
|
19
|
-
exports.isProjectSchemaWithServices = isProjectSchemaWithServices;
|
|
20
|
-
exports.containsResolver = containsResolver;
|
|
21
|
-
exports.isDirectiveMappingMap = isDirectiveMappingMap;
|
|
22
|
-
exports.isDirectiveMappingArray = isDirectiveMappingArray;
|
|
23
|
-
exports.isDirectiveConfig = isDirectiveConfig;
|
|
24
|
-
exports.isParameterSerializeContentOptions = isParameterSerializeContentOptions;
|
|
25
|
-
exports.isParameterOp = isParameterOp;
|
|
26
|
-
exports.isParameterOpNested = isParameterOpNested;
|
|
27
|
-
exports.isParameterOpMapping = isParameterOpMapping;
|
|
28
|
-
exports.isParameterOpValue = isParameterOpValue;
|
|
29
|
-
exports.isParameterOpOp = isParameterOpOp;
|
|
30
|
-
exports.isParameterSerializeStyleForSearchParams = isParameterSerializeStyleForSearchParams;
|
|
31
|
-
exports.isParameterSerializeStyleForPathParams = isParameterSerializeStyleForPathParams;
|
|
32
|
-
exports.isParameterSerializeStyleOptions = isParameterSerializeStyleOptions;
|
|
33
|
-
exports.isRefSchema = isRefSchema;
|
|
34
|
-
exports.isRefSchemaLegacy = isRefSchemaLegacy;
|
|
35
|
-
exports.isAllOfSchema = isAllOfSchema;
|
|
36
|
-
exports.isExtendsSchema = isExtendsSchema;
|
|
37
|
-
exports.isOneOfSchema = isOneOfSchema;
|
|
38
|
-
exports.isEnumSchema = isEnumSchema;
|
|
39
|
-
exports.isArraySchema = isArraySchema;
|
|
40
|
-
exports.isReturnShapeArraySchema = isReturnShapeArraySchema;
|
|
41
|
-
exports.isObjectSchema = isObjectSchema;
|
|
42
|
-
exports.isAnyServiceConfig = isAnyServiceConfig;
|
|
43
|
-
exports.isGraphQLServiceConfig = isGraphQLServiceConfig;
|
|
44
|
-
exports.isRESTServiceConfig = isRESTServiceConfig;
|
|
45
|
-
exports.isOpenAPIServiceConfig = isOpenAPIServiceConfig;
|
|
46
|
-
exports.isShopifyServiceConfig = isShopifyServiceConfig;
|
|
47
|
-
exports.isEncryptedServiceConfig = isEncryptedServiceConfig;
|
|
48
|
-
exports.isServiceConfigWithOAuth2Authentication = isServiceConfigWithOAuth2Authentication;
|
|
49
|
-
exports.isServiceConfigWithCustomAuthentication = isServiceConfigWithCustomAuthentication;
|
|
50
|
-
exports.isServiceAuthentication = isServiceAuthentication;
|
|
51
|
-
exports.isBearerAuthentication = isBearerAuthentication;
|
|
52
|
-
exports.isBasicAuthentication = isBasicAuthentication;
|
|
53
|
-
exports.isSearchParamsAuthentication = isSearchParamsAuthentication;
|
|
54
|
-
exports.isOAuth2Authentication = isOAuth2Authentication;
|
|
55
|
-
exports.isOAuth2BearerAuthentication = isOAuth2BearerAuthentication;
|
|
56
|
-
exports.isGoogleAuthentication = isGoogleAuthentication;
|
|
57
|
-
exports.isCustomAuthentication = isCustomAuthentication;
|
|
58
|
-
exports.isPropertySchemaWithRelationship = isPropertySchemaWithRelationship;
|
|
59
|
-
exports.isModelShape = isModelShape;
|
|
60
|
-
exports.isCachedShape = isCachedShape;
|
|
61
|
-
exports.listCachedShapes = listCachedShapes;
|
|
62
|
-
exports.getCachedShapeMap = getCachedShapeMap;
|
|
63
|
-
exports.isMeshShape = isMeshShape;
|
|
64
|
-
const util_1 = require("@takeshape/util");
|
|
65
|
-
const has_js_1 = __importDefault(require("lodash/has.js"));
|
|
66
|
-
const isArray_js_1 = __importDefault(require("lodash/isArray.js"));
|
|
67
|
-
const isPlainObject_js_1 = __importDefault(require("lodash/isPlainObject.js"));
|
|
68
|
-
const isString_js_1 = __importDefault(require("lodash/isString.js"));
|
|
69
|
-
const isUndefined_js_1 = __importDefault(require("lodash/isUndefined.js"));
|
|
70
|
-
const schemas_1 = require("../schemas");
|
|
71
|
-
const types_1 = require("./types");
|
|
72
|
-
/** Resolver Type Utils **/
|
|
73
|
-
/**
|
|
74
|
-
* Only tests that the shape is right, not that the name is correct. That's a job for the validator.
|
|
75
|
-
*/
|
|
76
|
-
function isBasicResolver(resolver) {
|
|
77
|
-
return (0, util_1.isRecord)(resolver) && (0, isString_js_1.default)(resolver.name);
|
|
78
|
-
}
|
|
79
|
-
function isServiceResolver(resolver) {
|
|
80
|
-
return (0, util_1.isRecord)(resolver) && (0, isString_js_1.default)(resolver.name) && (0, isString_js_1.default)(resolver.service);
|
|
81
|
-
}
|
|
82
|
-
function isComposeResolver(resolver) {
|
|
83
|
-
return Boolean((0, isArray_js_1.default)(resolver?.compose) &&
|
|
84
|
-
resolver.compose.length &&
|
|
85
|
-
resolver.compose.every(isBasicResolver));
|
|
86
|
-
}
|
|
87
|
-
const { definitions: { takeshapeResolver, shapedbResolver, utilResolver, graphqlResolver, restResolver, awsLambdaResolver } } = schemas_1.latestSchemaJson;
|
|
88
|
-
function isTakeshapeResolver(resolver) {
|
|
89
|
-
return isBasicResolver(resolver) && takeshapeResolver.properties.name.enum.includes(resolver.name);
|
|
90
|
-
}
|
|
91
|
-
function isShapedbResolver(resolver) {
|
|
92
|
-
return isBasicResolver(resolver) && shapedbResolver.properties.name.enum.includes(resolver.name);
|
|
93
|
-
}
|
|
94
|
-
function isGraphqlResolver(resolver) {
|
|
95
|
-
return isBasicResolver(resolver) && graphqlResolver.properties.name.enum.includes(resolver.name);
|
|
96
|
-
}
|
|
97
|
-
function isRestResolver(resolver) {
|
|
98
|
-
return isBasicResolver(resolver) && restResolver.properties.name.enum.includes(resolver.name);
|
|
99
|
-
}
|
|
100
|
-
function isAwsLambdaResolver(resolver) {
|
|
101
|
-
return isBasicResolver(resolver) && awsLambdaResolver.properties.name.enum.includes(resolver.name);
|
|
102
|
-
}
|
|
103
|
-
function isUtilResolver(resolver) {
|
|
104
|
-
return isBasicResolver(resolver) && utilResolver.properties.name.enum.includes(resolver.name);
|
|
105
|
-
}
|
|
106
|
-
exports.aiResolverNames = ['ai:generateText', 'ai:chat'];
|
|
107
|
-
function isAIResolverName(name) {
|
|
108
|
-
return name ? exports.aiResolverNames.includes(name) : false;
|
|
109
|
-
}
|
|
110
|
-
function isAIResolver(resolver) {
|
|
111
|
-
return isBasicResolver(resolver) && isAIResolverName(resolver.name);
|
|
112
|
-
}
|
|
113
|
-
function isAIAgentStateExecution(agentExecution) {
|
|
114
|
-
return agentExecution.type === 'generate' || agentExecution.type === 'chat';
|
|
115
|
-
}
|
|
116
|
-
function isProjectSchemaWithServices(schema) {
|
|
117
|
-
return !(0, isUndefined_js_1.default)(schema.services);
|
|
118
|
-
}
|
|
119
|
-
function containsResolver(resolver, predicate) {
|
|
120
|
-
if (isBasicResolver(resolver)) {
|
|
121
|
-
return predicate(resolver);
|
|
122
|
-
}
|
|
123
|
-
return Boolean(resolver.compose.find((resolver) => containsResolver(resolver, predicate)));
|
|
124
|
-
}
|
|
125
|
-
/** Directive Mapping Utils **/
|
|
126
|
-
/**
|
|
127
|
-
* Determine whether the ambiguous Directive structure is a DirectiveMappingMap
|
|
128
|
-
*/
|
|
129
|
-
function isDirectiveMappingMap(maybeMap) {
|
|
130
|
-
return (0, isPlainObject_js_1.default)(maybeMap) && Object.keys(maybeMap).length > 0;
|
|
131
|
-
}
|
|
132
|
-
/**
|
|
133
|
-
* Determine whether the ambiguous Directive structure is a DirectiveMappingArray
|
|
134
|
-
*/
|
|
135
|
-
function isDirectiveMappingArray(maybeArray) {
|
|
136
|
-
return (0, isArray_js_1.default)(maybeArray) && (0, isArray_js_1.default)(maybeArray[0]) && (0, isString_js_1.default)(maybeArray[0][0]) && (0, isArray_js_1.default)(maybeArray[0][1]);
|
|
137
|
-
}
|
|
138
|
-
/**
|
|
139
|
-
* Determine whether the ambiguous Directive structure is a DirectiveConfig array
|
|
140
|
-
*/
|
|
141
|
-
function isDirectiveConfig(maybeConfig) {
|
|
142
|
-
return (0, isArray_js_1.default)(maybeConfig) && (0, isArray_js_1.default)(maybeConfig[0]) && (0, isString_js_1.default)(maybeConfig[0][0]) && (0, util_1.isRecord)(maybeConfig[0][1]);
|
|
143
|
-
}
|
|
144
|
-
/**
|
|
145
|
-
* Determine whether a ParameterSerializeOption is a content type serializer
|
|
146
|
-
*/
|
|
147
|
-
function isParameterSerializeContentOptions(maybeContent) {
|
|
148
|
-
return Boolean(maybeContent.contentType);
|
|
149
|
-
}
|
|
150
|
-
/**
|
|
151
|
-
* Determine whether an unknown variable is a `ParameterOp`
|
|
152
|
-
*/
|
|
153
|
-
function isParameterOp(maybeOp) {
|
|
154
|
-
const op = maybeOp;
|
|
155
|
-
if (!op.path) {
|
|
156
|
-
return false;
|
|
157
|
-
}
|
|
158
|
-
return isParameterOpNested(op) || isParameterOpMapping(op) || isParameterOpValue(op) || isParameterOpOp(op);
|
|
159
|
-
}
|
|
160
|
-
/**
|
|
161
|
-
* Determine whether a `ParameterOp` is a `ParameterOpNested`
|
|
162
|
-
*/
|
|
163
|
-
function isParameterOpNested(maybeOp) {
|
|
164
|
-
return Boolean(maybeOp.ops);
|
|
165
|
-
}
|
|
166
|
-
/**
|
|
167
|
-
* Determine whether a `ParameterOp` is a `ParameterOpMapping`
|
|
168
|
-
*/
|
|
169
|
-
function isParameterOpMapping(maybeOp) {
|
|
170
|
-
return Boolean(maybeOp.mapping);
|
|
171
|
-
}
|
|
172
|
-
/**
|
|
173
|
-
* Determine whether a `ParameterOp` is a `ParameterOpValue`
|
|
174
|
-
*/
|
|
175
|
-
function isParameterOpValue(maybeOp) {
|
|
176
|
-
return Boolean(maybeOp.value);
|
|
177
|
-
}
|
|
178
|
-
/**
|
|
179
|
-
* Determine whether a `ParameterOp` is a `ParameterOpOp`
|
|
180
|
-
*/
|
|
181
|
-
function isParameterOpOp(maybeOp) {
|
|
182
|
-
const op = maybeOp;
|
|
183
|
-
if (!op.op) {
|
|
184
|
-
return false;
|
|
185
|
-
}
|
|
186
|
-
return !(isParameterOpNested(op) || isParameterOpMapping(op) || isParameterOpValue(op));
|
|
187
|
-
}
|
|
188
|
-
const { definitions: { parameterSerializeStyleOptionsForSearchParams, parameterSerializeStyleOptionsForPathParams } } = schemas_1.latestSchemaJson;
|
|
189
|
-
function isParameterSerializeStyleForSearchParams(maybeParam) {
|
|
190
|
-
return Boolean(maybeParam && parameterSerializeStyleOptionsForSearchParams.properties.style.enum.includes(maybeParam));
|
|
191
|
-
}
|
|
192
|
-
function isParameterSerializeStyleForPathParams(maybeParam) {
|
|
193
|
-
return Boolean(maybeParam && parameterSerializeStyleOptionsForPathParams.properties.style.enum.includes(maybeParam));
|
|
194
|
-
}
|
|
195
|
-
/**
|
|
196
|
-
* Determine whether a ParameterSerializeOption is a style serializer
|
|
197
|
-
*/
|
|
198
|
-
function isParameterSerializeStyleOptions(maybeStyle) {
|
|
199
|
-
return Boolean(maybeStyle.style);
|
|
200
|
-
}
|
|
201
|
-
/** Typeguards for different types of shape schemas **/
|
|
202
|
-
function isRefSchema(propertySchema) {
|
|
203
|
-
return (0, isString_js_1.default)(propertySchema['@ref']) || (0, isString_js_1.default)(propertySchema.$ref);
|
|
204
|
-
}
|
|
205
|
-
function isRefSchemaLegacy(propertySchema) {
|
|
206
|
-
return (0, isString_js_1.default)(propertySchema.$ref);
|
|
207
|
-
}
|
|
208
|
-
function isAllOfSchema(propertySchema) {
|
|
209
|
-
return (0, isArray_js_1.default)(propertySchema.allOf);
|
|
210
|
-
}
|
|
211
|
-
function isExtendsSchema(propertySchema) {
|
|
212
|
-
return (0, util_1.isRecord)(propertySchema) && (0, isArray_js_1.default)(propertySchema.extends);
|
|
213
|
-
}
|
|
214
|
-
function isOneOfSchema(propertySchema) {
|
|
215
|
-
return (0, isArray_js_1.default)(propertySchema.oneOf);
|
|
216
|
-
}
|
|
217
|
-
function isEnumSchema(obj) {
|
|
218
|
-
return (0, isArray_js_1.default)(obj.enum);
|
|
219
|
-
}
|
|
220
|
-
function isArraySchema(propertySchema) {
|
|
221
|
-
return propertySchema.type === 'array' && (0, util_1.isRecord)(propertySchema.items);
|
|
222
|
-
}
|
|
223
|
-
function isReturnShapeArraySchema(returnShape) {
|
|
224
|
-
return typeof returnShape === 'object' && returnShape.type === 'array';
|
|
225
|
-
}
|
|
226
|
-
function isObjectSchema(propertySchema) {
|
|
227
|
-
return (0, util_1.isRecord)(propertySchema) && propertySchema.type === 'object' && (0, util_1.isRecord)(propertySchema.properties);
|
|
228
|
-
}
|
|
229
|
-
/** Service Config Utils **/
|
|
230
|
-
/**
|
|
231
|
-
* Test all required props, currently:
|
|
232
|
-
* "name", "slug", "provider", "serviceType", "authenticationType"
|
|
233
|
-
*/
|
|
234
|
-
function isAnyServiceConfig(maybeConfig) {
|
|
235
|
-
return (maybeConfig &&
|
|
236
|
-
(0, isString_js_1.default)(maybeConfig.title) &&
|
|
237
|
-
(0, isString_js_1.default)(maybeConfig.id) &&
|
|
238
|
-
(0, isString_js_1.default)(maybeConfig.provider) &&
|
|
239
|
-
(0, isString_js_1.default)(maybeConfig.serviceType) &&
|
|
240
|
-
(0, isString_js_1.default)(maybeConfig.authenticationType));
|
|
241
|
-
}
|
|
242
|
-
function isGraphQLServiceConfig(maybeConfig) {
|
|
243
|
-
return (isAnyServiceConfig(maybeConfig) && maybeConfig.serviceType === 'graphql' && (0, isString_js_1.default)(maybeConfig.options?.endpoint));
|
|
244
|
-
}
|
|
245
|
-
function isRESTServiceConfig(maybeConfig) {
|
|
246
|
-
return isAnyServiceConfig(maybeConfig) && maybeConfig.serviceType === 'rest';
|
|
247
|
-
}
|
|
248
|
-
function isOpenAPIServiceConfig(maybeConfig) {
|
|
249
|
-
return isAnyServiceConfig(maybeConfig) && maybeConfig.serviceType === 'openapi';
|
|
250
|
-
}
|
|
251
|
-
function isShopifyServiceConfig(maybeShopify) {
|
|
252
|
-
return maybeShopify.provider === 'shopify';
|
|
253
|
-
}
|
|
254
|
-
function isEncryptedServiceConfig(maybeConfig) {
|
|
255
|
-
return isAnyServiceConfig(maybeConfig) && (0, isString_js_1.default)(maybeConfig.authentication);
|
|
256
|
-
}
|
|
257
|
-
function isServiceConfigWithOAuth2Authentication(maybeServiceConfig) {
|
|
258
|
-
return (isAnyServiceConfig(maybeServiceConfig) &&
|
|
259
|
-
isServiceAuthentication(maybeServiceConfig.authentication) &&
|
|
260
|
-
isOAuth2Authentication(maybeServiceConfig.authentication));
|
|
261
|
-
}
|
|
262
|
-
function isServiceConfigWithCustomAuthentication(maybeServiceConfig) {
|
|
263
|
-
return (isAnyServiceConfig(maybeServiceConfig) &&
|
|
264
|
-
isServiceAuthentication(maybeServiceConfig.authentication) &&
|
|
265
|
-
isCustomAuthentication(maybeServiceConfig.authentication));
|
|
266
|
-
}
|
|
267
|
-
/** Authentication Utils **/
|
|
268
|
-
function isServiceAuthentication(maybeAuthentication) {
|
|
269
|
-
return maybeAuthentication?.type;
|
|
270
|
-
}
|
|
271
|
-
function isBearerAuthentication(authentication) {
|
|
272
|
-
return authentication?.type === 'bearer';
|
|
273
|
-
}
|
|
274
|
-
function isBasicAuthentication(authentication) {
|
|
275
|
-
return authentication?.type === 'basic';
|
|
276
|
-
}
|
|
277
|
-
function isSearchParamsAuthentication(authentication) {
|
|
278
|
-
return authentication?.type === 'searchParams';
|
|
279
|
-
}
|
|
280
|
-
function isOAuth2Authentication(authentication) {
|
|
281
|
-
return authentication?.type === 'oauth2';
|
|
282
|
-
}
|
|
283
|
-
function isOAuth2BearerAuthentication(authentication) {
|
|
284
|
-
return authentication?.type === 'oauth2Bearer';
|
|
285
|
-
}
|
|
286
|
-
function isGoogleAuthentication(authentication) {
|
|
287
|
-
return authentication?.type === 'google';
|
|
288
|
-
}
|
|
289
|
-
function isCustomAuthentication(authentication) {
|
|
290
|
-
return authentication?.type === 'custom';
|
|
291
|
-
}
|
|
292
|
-
/** Miscellaneous Utils **/
|
|
293
|
-
/**
|
|
294
|
-
* A utility to return the type of args present on a schema.
|
|
295
|
-
*
|
|
296
|
-
* @param argsSchema Any schema that may have an `args` property.
|
|
297
|
-
*/
|
|
298
|
-
const getArgsType = (argsSchema) => {
|
|
299
|
-
if ((0, has_js_1.default)(argsSchema, '@args')) {
|
|
300
|
-
return types_1.ArgsType['@args'];
|
|
301
|
-
}
|
|
302
|
-
if ((0, has_js_1.default)(argsSchema, 'args')) {
|
|
303
|
-
return types_1.ArgsType.args;
|
|
304
|
-
}
|
|
305
|
-
};
|
|
306
|
-
exports.getArgsType = getArgsType;
|
|
307
|
-
/**
|
|
308
|
-
* A utility to return the type of ref present on a schema.
|
|
309
|
-
*
|
|
310
|
-
* @param refSchema Any schema that may have a `ref` property.
|
|
311
|
-
*/
|
|
312
|
-
const getRefType = (refSchema) => {
|
|
313
|
-
if ((0, has_js_1.default)(refSchema, '@ref')) {
|
|
314
|
-
return types_1.RefType['@ref'];
|
|
315
|
-
}
|
|
316
|
-
if ((0, has_js_1.default)(refSchema, '$ref')) {
|
|
317
|
-
return types_1.RefType.$ref;
|
|
318
|
-
}
|
|
319
|
-
};
|
|
320
|
-
exports.getRefType = getRefType;
|
|
321
|
-
function isPropertySchemaWithRelationship(schema) {
|
|
322
|
-
return schema['@resolver']?.name === 'shapedb:getRelated';
|
|
323
|
-
}
|
|
324
|
-
function isModelShape(shape) {
|
|
325
|
-
return Boolean(shape.model);
|
|
326
|
-
}
|
|
327
|
-
function isCachedShape(shape) {
|
|
328
|
-
return shape.cache?.enabled === true && shape.loaders !== undefined;
|
|
329
|
-
}
|
|
330
|
-
function listCachedShapes(shapes) {
|
|
331
|
-
return Object.values(shapes).filter(isCachedShape);
|
|
332
|
-
}
|
|
333
|
-
function getCachedShapeMap(shapes) {
|
|
334
|
-
const results = {};
|
|
335
|
-
for (const shape of Object.values(shapes)) {
|
|
336
|
-
if (isCachedShape(shape)) {
|
|
337
|
-
results[shape.name] = shape;
|
|
338
|
-
}
|
|
339
|
-
}
|
|
340
|
-
return results;
|
|
341
|
-
}
|
|
342
|
-
function isMeshShape(shape) {
|
|
343
|
-
return Boolean(shape.joins);
|
|
344
|
-
}
|
package/dist/cjs/src/unions.js
DELETED
|
@@ -1,88 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.createWrapTransform = exports.createUnwrapTransform = void 0;
|
|
7
|
-
exports.enumerateOneOfKeys = enumerateOneOfKeys;
|
|
8
|
-
exports.isUnionSchema = isUnionSchema;
|
|
9
|
-
exports.oneOfToObject = oneOfToObject;
|
|
10
|
-
const errors_1 = require("@takeshape/errors");
|
|
11
|
-
const util_1 = require("@takeshape/util");
|
|
12
|
-
const omit_js_1 = __importDefault(require("lodash/omit.js"));
|
|
13
|
-
const refs_1 = require("./refs");
|
|
14
|
-
const names_1 = require("./template-shapes/names");
|
|
15
|
-
const utils_1 = require("./types/utils");
|
|
16
|
-
const shapes_1 = require("./util/shapes");
|
|
17
|
-
function enumerateOneOfKeys(projectSchema, oneOf) {
|
|
18
|
-
const result = [];
|
|
19
|
-
for (const child of oneOf) {
|
|
20
|
-
const refItem = (0, refs_1.getRef)(projectSchema, child);
|
|
21
|
-
if (refItem) {
|
|
22
|
-
const shapeName = (0, refs_1.refItemToNamespacedShapeName)(refItem);
|
|
23
|
-
if (projectSchema.shapes[shapeName]) {
|
|
24
|
-
const shapeId = projectSchema.shapes[shapeName].id;
|
|
25
|
-
result.push({
|
|
26
|
-
propName: (0, names_1.getOutputShapeName)((0, util_1.camelCase)(refItem.typeName)),
|
|
27
|
-
propSchema: child,
|
|
28
|
-
shapeName,
|
|
29
|
-
shapeId
|
|
30
|
-
});
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
return result;
|
|
35
|
-
}
|
|
36
|
-
function getOneOf(schema) {
|
|
37
|
-
if (!schema.oneOf) {
|
|
38
|
-
throw new Error(`Expected ${JSON.stringify(schema)} to be a oneOf schema`);
|
|
39
|
-
}
|
|
40
|
-
return schema.oneOf;
|
|
41
|
-
}
|
|
42
|
-
function isUnionSchema(schema) {
|
|
43
|
-
return Boolean(schema.oneOf?.every(utils_1.isRefSchema));
|
|
44
|
-
}
|
|
45
|
-
function oneOfToObject(projectSchema, schema) {
|
|
46
|
-
const properties = {};
|
|
47
|
-
for (const { propName, propSchema: child } of enumerateOneOfKeys(projectSchema, getOneOf(schema))) {
|
|
48
|
-
properties[propName] = child;
|
|
49
|
-
}
|
|
50
|
-
return { ...(0, omit_js_1.default)(schema, 'oneOf'), type: 'object', properties };
|
|
51
|
-
}
|
|
52
|
-
function formatKeys(keys) {
|
|
53
|
-
return keys.map((k) => `"${k}"`).join(', ');
|
|
54
|
-
}
|
|
55
|
-
const createUnwrapTransform = (projectSchema) => (obj, schema, name, shape, next) => {
|
|
56
|
-
if ((0, util_1.isRecord)(obj)) {
|
|
57
|
-
const oneOfKeys = enumerateOneOfKeys(projectSchema, getOneOf(schema));
|
|
58
|
-
const objectKeys = Object.keys(obj);
|
|
59
|
-
if (objectKeys.length !== 1) {
|
|
60
|
-
const propNames = oneOfKeys.map((k) => k.propName);
|
|
61
|
-
throw new errors_1.BadDataError(`Object should only specify one of the following keys: ${formatKeys(propNames)}, but found keys: ${formatKeys(objectKeys)}`);
|
|
62
|
-
}
|
|
63
|
-
for (const { propName, shapeId, propSchema } of oneOfKeys) {
|
|
64
|
-
const propValue = obj[propName];
|
|
65
|
-
if ((0, util_1.isRecord)(propValue)) {
|
|
66
|
-
const transformedPropValue = next(propValue, propSchema, name);
|
|
67
|
-
if ((0, util_1.isRecord)(transformedPropValue)) {
|
|
68
|
-
return {
|
|
69
|
-
...transformedPropValue,
|
|
70
|
-
_shapeId: shapeId
|
|
71
|
-
};
|
|
72
|
-
}
|
|
73
|
-
}
|
|
74
|
-
}
|
|
75
|
-
}
|
|
76
|
-
};
|
|
77
|
-
exports.createUnwrapTransform = createUnwrapTransform;
|
|
78
|
-
const createWrapTransform = (projectSchema) => (obj, schema, name, shape, next) => {
|
|
79
|
-
if ((0, util_1.isRecord)(obj) && typeof obj._shapeId === 'string') {
|
|
80
|
-
const shape = (0, shapes_1.getShapeById)(projectSchema, obj._shapeId);
|
|
81
|
-
if (shape) {
|
|
82
|
-
return {
|
|
83
|
-
[(0, util_1.camelCase)(shape.name)]: next((0, omit_js_1.default)(obj, '_shapeId'), shape.schema, name)
|
|
84
|
-
};
|
|
85
|
-
}
|
|
86
|
-
}
|
|
87
|
-
};
|
|
88
|
-
exports.createWrapTransform = createWrapTransform;
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/* tslint:disable */
|
|
3
|
-
/**
|
|
4
|
-
* This file was automatically generated by json-schema-to-typescript.
|
|
5
|
-
* DO NOT MODIFY IT BY HAND. Instead, modify the source JSONSchema file,
|
|
6
|
-
* and run json-schema-to-typescript to regenerate this file.
|
|
7
|
-
*/
|
|
8
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.getToolRef = getToolRef;
|
|
4
|
-
exports.normalizeToolConfig = normalizeToolConfig;
|
|
5
|
-
function getToolRef(tool) {
|
|
6
|
-
return typeof tool === 'string' ? tool : tool.ref;
|
|
7
|
-
}
|
|
8
|
-
function normalizeToolConfig(tool) {
|
|
9
|
-
return typeof tool === 'string' ? { ref: tool } : tool;
|
|
10
|
-
}
|
|
@@ -1,62 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.getGetQueryIndexConfig = exports.getListQueryIndexConfigs = void 0;
|
|
4
|
-
exports.serviceHasIndexedShapes = serviceHasIndexedShapes;
|
|
5
|
-
exports.getIndexedServices = getIndexedServices;
|
|
6
|
-
const util_1 = require("@takeshape/util");
|
|
7
|
-
const refs_1 = require("../refs");
|
|
8
|
-
const schema_util_1 = require("../schema-util");
|
|
9
|
-
const util_2 = require("../services/util");
|
|
10
|
-
const types_1 = require("../types");
|
|
11
|
-
function serviceHasIndexedShapes(schema, serviceId) {
|
|
12
|
-
for (const shape of Object.values(schema.shapes ?? {})) {
|
|
13
|
-
const indexingEnabled = (0, types_1.isCachedShape)(shape);
|
|
14
|
-
const listConfigs = shape.loaders?.list;
|
|
15
|
-
if (indexingEnabled && listConfigs) {
|
|
16
|
-
for (const { query: queryRef } of (0, util_1.ensureArray)(listConfigs)) {
|
|
17
|
-
const resolved = (0, refs_1.getQuery)(schema, queryRef);
|
|
18
|
-
if (resolved && (0, types_1.isServiceResolver)(resolved.query.resolver) && resolved.query.resolver.service === serviceId) {
|
|
19
|
-
return true;
|
|
20
|
-
}
|
|
21
|
-
}
|
|
22
|
-
}
|
|
23
|
-
}
|
|
24
|
-
return false;
|
|
25
|
-
}
|
|
26
|
-
function getIndexedServices(projectSchema, configs) {
|
|
27
|
-
return (0, util_1.ensureArray)(configs).reduce((services, queryConfig) => {
|
|
28
|
-
const resolved = queryConfig?.query ? (0, refs_1.getQuery)(projectSchema, queryConfig.query) : undefined;
|
|
29
|
-
return resolved?.query ? [...services, ...(0, util_2.getResolverServices)(resolved.query.resolver)] : services;
|
|
30
|
-
}, []);
|
|
31
|
-
}
|
|
32
|
-
function flattenListQueryConfigs(base, queryConfig, maybeConfigArray) {
|
|
33
|
-
return (maybeConfigArray &&
|
|
34
|
-
(0, util_1.ensureArray)(maybeConfigArray).flatMap((config) => (0, util_1.ensureArray)(config.args).map((args) => ({
|
|
35
|
-
...base,
|
|
36
|
-
...queryConfig,
|
|
37
|
-
...config,
|
|
38
|
-
args
|
|
39
|
-
}))));
|
|
40
|
-
}
|
|
41
|
-
function getQueryIndexConfigHelper(op) {
|
|
42
|
-
return ({ shapes }, shapeName) => {
|
|
43
|
-
const { cache, loaders } = shapes[shapeName] ?? {};
|
|
44
|
-
if (cache && loaders) {
|
|
45
|
-
const idField = (0, schema_util_1.getIdField)(cache);
|
|
46
|
-
if (op === 'list') {
|
|
47
|
-
return flattenListQueryConfigs({ shapeName, idField }, cache.fragment, loaders.list);
|
|
48
|
-
}
|
|
49
|
-
const queryConfig = loaders.get;
|
|
50
|
-
if (queryConfig) {
|
|
51
|
-
return {
|
|
52
|
-
idField,
|
|
53
|
-
shapeName,
|
|
54
|
-
...cache.fragment,
|
|
55
|
-
...queryConfig
|
|
56
|
-
};
|
|
57
|
-
}
|
|
58
|
-
}
|
|
59
|
-
};
|
|
60
|
-
}
|
|
61
|
-
exports.getListQueryIndexConfigs = getQueryIndexConfigHelper('list');
|
|
62
|
-
exports.getGetQueryIndexConfig = getQueryIndexConfigHelper('get');
|
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.hasCycle = hasCycle;
|
|
4
|
-
const util_1 = require("@takeshape/util");
|
|
5
|
-
const refs_1 = require("../refs");
|
|
6
|
-
function immutableSetAdd(set, str) {
|
|
7
|
-
const result = new Set(set);
|
|
8
|
-
result.add(str);
|
|
9
|
-
return result;
|
|
10
|
-
}
|
|
11
|
-
/**
|
|
12
|
-
* Use a basic depth-first search to determine whether a schema contains a cycle
|
|
13
|
-
*/
|
|
14
|
-
function hasCycle(projectSchema, schema, predicate = (0, util_1.value)(true)) {
|
|
15
|
-
const hasCycleHelper = (schema, shapesSeen = new Set(), shapeName, propName) => {
|
|
16
|
-
if (!predicate(projectSchema, schema, shapeName, propName)) {
|
|
17
|
-
return false;
|
|
18
|
-
}
|
|
19
|
-
const refItem = (0, refs_1.getRef)(projectSchema, schema);
|
|
20
|
-
if (refItem) {
|
|
21
|
-
const refShape = (0, refs_1.refItemToShape)(projectSchema, refItem);
|
|
22
|
-
// If we have a refItem, but no shape, this is a dangling ref and has no cycles
|
|
23
|
-
if (!refShape) {
|
|
24
|
-
return false;
|
|
25
|
-
}
|
|
26
|
-
if (shapesSeen.has(refShape.name)) {
|
|
27
|
-
return true;
|
|
28
|
-
}
|
|
29
|
-
return hasCycleHelper(refShape.schema, immutableSetAdd(shapesSeen, refShape.name), refShape.name);
|
|
30
|
-
}
|
|
31
|
-
const combo = schema.oneOf ?? schema.allOf ?? schema.extends;
|
|
32
|
-
if (combo) {
|
|
33
|
-
return combo.some((childSchema) => hasCycleHelper(childSchema, shapesSeen, shapeName, propName));
|
|
34
|
-
}
|
|
35
|
-
if (schema.items) {
|
|
36
|
-
return hasCycleHelper(schema.items, shapesSeen, shapeName, propName);
|
|
37
|
-
}
|
|
38
|
-
const { properties } = schema;
|
|
39
|
-
if (properties) {
|
|
40
|
-
return Object.keys(properties).some((name) => {
|
|
41
|
-
const propSchema = properties[name];
|
|
42
|
-
return hasCycleHelper(propSchema, shapesSeen, shapeName, name);
|
|
43
|
-
});
|
|
44
|
-
}
|
|
45
|
-
return false;
|
|
46
|
-
};
|
|
47
|
-
return hasCycleHelper(schema);
|
|
48
|
-
}
|
|
@@ -1,57 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.findSchemaAtPath = findSchemaAtPath;
|
|
4
|
-
exports.findShapeAtPath = findShapeAtPath;
|
|
5
|
-
const refs_1 = require("../refs");
|
|
6
|
-
const types_1 = require("../types");
|
|
7
|
-
/**
|
|
8
|
-
*
|
|
9
|
-
* @param projectSchema
|
|
10
|
-
* @param schema
|
|
11
|
-
* @param queryPath
|
|
12
|
-
*
|
|
13
|
-
* @example
|
|
14
|
-
* findShapeAtPath(projectSchema, projectSchema.shapes.Shopify_ProductConnection.shape, ['edges', 'node']) // finds {'@ref': Shopify_Product}
|
|
15
|
-
*/
|
|
16
|
-
function findSchemaAtPath(projectSchema, schema, queryPath) {
|
|
17
|
-
if (queryPath.length === 0) {
|
|
18
|
-
return schema;
|
|
19
|
-
}
|
|
20
|
-
const [prop, ...rest] = queryPath;
|
|
21
|
-
if ((0, types_1.isRefSchema)(schema)) {
|
|
22
|
-
const ref = (0, refs_1.getRef)(projectSchema, schema);
|
|
23
|
-
if (ref) {
|
|
24
|
-
const shapeSchema = (0, refs_1.refItemToShapeSchema)(projectSchema, ref);
|
|
25
|
-
if (shapeSchema) {
|
|
26
|
-
return findSchemaAtPath(projectSchema, shapeSchema, queryPath);
|
|
27
|
-
}
|
|
28
|
-
}
|
|
29
|
-
return undefined;
|
|
30
|
-
}
|
|
31
|
-
if ((0, types_1.isArraySchema)(schema)) {
|
|
32
|
-
return findSchemaAtPath(projectSchema, schema.items, queryPath);
|
|
33
|
-
}
|
|
34
|
-
if ((0, types_1.isObjectSchema)(schema)) {
|
|
35
|
-
const propSchema = schema.properties[prop];
|
|
36
|
-
if (propSchema) {
|
|
37
|
-
return findSchemaAtPath(projectSchema, propSchema, rest);
|
|
38
|
-
}
|
|
39
|
-
}
|
|
40
|
-
return undefined;
|
|
41
|
-
}
|
|
42
|
-
/**
|
|
43
|
-
*
|
|
44
|
-
* @param projectSchema
|
|
45
|
-
* @param propSchema
|
|
46
|
-
* @param queryPath
|
|
47
|
-
*
|
|
48
|
-
* @example
|
|
49
|
-
* findShapeAtPath(projectSchema, projectSchema.shapes.Shopify_ProductConnection.shape, ['edges', 'node']) // finds Shopify_Product
|
|
50
|
-
*/
|
|
51
|
-
function findShapeAtPath(projectSchema, propSchema, queryPath) {
|
|
52
|
-
const result = findSchemaAtPath(projectSchema, propSchema, queryPath);
|
|
53
|
-
if (result) {
|
|
54
|
-
const refItem = (0, refs_1.getRef)(projectSchema, result.items ?? result);
|
|
55
|
-
return refItem && (0, refs_1.refItemToShape)(projectSchema, refItem);
|
|
56
|
-
}
|
|
57
|
-
}
|
|
@@ -1,66 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.normalizeForms = normalizeForms;
|
|
4
|
-
exports.findShapeFormConfig = findShapeFormConfig;
|
|
5
|
-
const util_1 = require("@takeshape/util");
|
|
6
|
-
const refs_1 = require("../refs");
|
|
7
|
-
const schema_util_1 = require("../schema-util");
|
|
8
|
-
/**
|
|
9
|
-
* If there any non-normal (nested) forms in the schema, create forms for referenced shapes.
|
|
10
|
-
* The original forms are left intact.
|
|
11
|
-
*/
|
|
12
|
-
function normalizeForms(projectSchema) {
|
|
13
|
-
const normalizedForms = {};
|
|
14
|
-
const { forms = {} } = projectSchema;
|
|
15
|
-
const storeSourceForm = (shapeName, formConfig, propName) => {
|
|
16
|
-
// Leave original forms intact for backwards compatibility
|
|
17
|
-
if (!forms[shapeName]) {
|
|
18
|
-
normalizedForms[shapeName] ||= { default: (0, util_1.deepClone)(formConfig) };
|
|
19
|
-
// Remove prop now that it has been normalized
|
|
20
|
-
delete normalizedForms[shapeName].default.properties[propName];
|
|
21
|
-
}
|
|
22
|
-
};
|
|
23
|
-
const normalizeNested = (shapeName, formConfig) => {
|
|
24
|
-
const shape = projectSchema.shapes[shapeName];
|
|
25
|
-
if (!shape || !formConfig.properties) {
|
|
26
|
-
return;
|
|
27
|
-
}
|
|
28
|
-
const propertyAccessor = (0, schema_util_1.createSchemaPropertyAccessor)(projectSchema, shape);
|
|
29
|
-
for (const propName of Object.keys(formConfig.properties)) {
|
|
30
|
-
const propConfig = formConfig.properties[propName];
|
|
31
|
-
const propSchema = propertyAccessor.getValue(propName);
|
|
32
|
-
if (propSchema) {
|
|
33
|
-
const ref = (0, refs_1.getRefOrItemsRef)(projectSchema, propSchema);
|
|
34
|
-
if (ref && propConfig.properties) {
|
|
35
|
-
const nestedShapeName = (0, refs_1.refItemToNamespacedShapeName)(ref);
|
|
36
|
-
normalizedForms[nestedShapeName] = { default: (0, util_1.deepClone)(propConfig) };
|
|
37
|
-
storeSourceForm(shapeName, formConfig, propName);
|
|
38
|
-
normalizeNested(nestedShapeName, propConfig);
|
|
39
|
-
}
|
|
40
|
-
}
|
|
41
|
-
}
|
|
42
|
-
};
|
|
43
|
-
if (forms) {
|
|
44
|
-
for (const shapeName of Object.keys(forms)) {
|
|
45
|
-
normalizeNested(shapeName, forms[shapeName].default);
|
|
46
|
-
// copy forms with no changes
|
|
47
|
-
normalizedForms[shapeName] ||= forms[shapeName];
|
|
48
|
-
}
|
|
49
|
-
}
|
|
50
|
-
return normalizedForms;
|
|
51
|
-
}
|
|
52
|
-
const cache = new WeakMap();
|
|
53
|
-
/**
|
|
54
|
-
* Find the form config for a given shape name and the form key.
|
|
55
|
-
*/
|
|
56
|
-
function findShapeFormConfig(projectSchema, shapeName, formName) {
|
|
57
|
-
if (!projectSchema.forms) {
|
|
58
|
-
return;
|
|
59
|
-
}
|
|
60
|
-
let normalizedForms = cache.get(projectSchema);
|
|
61
|
-
if (!normalizedForms) {
|
|
62
|
-
normalizedForms = normalizeForms(projectSchema);
|
|
63
|
-
cache.set(projectSchema, normalizedForms);
|
|
64
|
-
}
|
|
65
|
-
return normalizedForms[shapeName]?.[formName];
|
|
66
|
-
}
|