@oronts/vendure-data-hub-plugin 0.1.2 → 0.1.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +33 -1
- package/README.md +36 -10
- package/dashboard/components/pipelines/PipelineEditor.tsx +159 -5
- package/dashboard/components/pipelines/ReactFlowPipelineEditor.tsx +3 -3
- package/dashboard/components/pipelines/shared/NodePropertiesPanel.tsx +42 -4
- package/dashboard/components/pipelines/shared/StepListItem.tsx +2 -2
- package/dashboard/components/shared/CodeEditor.tsx +289 -0
- package/dashboard/components/shared/schema-form/fields/TextareaField.tsx +19 -4
- package/dashboard/components/shared/step-config/AdapterSelector.tsx +2 -2
- package/dashboard/components/shared/step-config/OperatorFieldInput.tsx +19 -0
- package/dashboard/components/shared/step-config/RouteConfigComponent.tsx +218 -29
- package/dashboard/components/shared/step-config/StepConfigPanel.tsx +24 -10
- package/dashboard/constants/ui-dimensions.ts +2 -1
- package/dashboard/constants/ui-states.ts +1 -0
- package/dashboard/gql/gql.ts +6 -6
- package/dashboard/gql/graphql.ts +9 -4
- package/dashboard/hooks/api/use-pipeline-runs.ts +1 -0
- package/dashboard/hooks/api/use-queues.ts +1 -0
- package/dashboard/hooks/use-adapter-catalog.ts +4 -32
- package/dashboard/routes/connections/ConnectionDetail.tsx +7 -1
- package/dashboard/routes/pipelines/RunDetailsPanel.tsx +1 -1
- package/dashboard/routes/pipelines/components/PipelineActionButtons.tsx +3 -3
- package/dashboard/routes/pipelines/utils/pipeline-conversion.ts +3 -5
- package/dashboard/utils/formatters.ts +6 -4
- package/dist/dashboard/components/pipelines/PipelineEditor.tsx +159 -5
- package/dist/dashboard/components/pipelines/ReactFlowPipelineEditor.tsx +3 -3
- package/dist/dashboard/components/pipelines/shared/NodePropertiesPanel.tsx +42 -4
- package/dist/dashboard/components/pipelines/shared/StepListItem.tsx +2 -2
- package/dist/dashboard/components/shared/CodeEditor.tsx +289 -0
- package/dist/dashboard/components/shared/schema-form/fields/TextareaField.tsx +19 -4
- package/dist/dashboard/components/shared/step-config/AdapterSelector.tsx +2 -2
- package/dist/dashboard/components/shared/step-config/OperatorFieldInput.tsx +19 -0
- package/dist/dashboard/components/shared/step-config/RouteConfigComponent.tsx +218 -29
- package/dist/dashboard/components/shared/step-config/StepConfigPanel.tsx +24 -10
- package/dist/dashboard/constants/ui-dimensions.ts +2 -1
- package/dist/dashboard/constants/ui-states.ts +1 -0
- package/dist/dashboard/gql/gql.ts +6 -6
- package/dist/dashboard/gql/graphql.ts +9 -4
- package/dist/dashboard/hooks/api/use-pipeline-runs.ts +1 -0
- package/dist/dashboard/hooks/api/use-queues.ts +1 -0
- package/dist/dashboard/hooks/use-adapter-catalog.ts +4 -32
- package/dist/dashboard/routes/connections/ConnectionDetail.tsx +7 -1
- package/dist/dashboard/routes/pipelines/RunDetailsPanel.tsx +1 -1
- package/dist/dashboard/routes/pipelines/components/PipelineActionButtons.tsx +3 -3
- package/dist/dashboard/routes/pipelines/utils/pipeline-conversion.ts +3 -5
- package/dist/dashboard/utils/formatters.ts +6 -4
- package/dist/shared/types/adapter-config.types.d.ts +400 -13
- package/dist/shared/types/adapter-config.types.d.ts.map +1 -1
- package/dist/shared/types/index.d.ts +1 -1
- package/dist/shared/types/index.d.ts.map +1 -1
- package/dist/shared/types/index.js.map +1 -1
- package/dist/shared/types/loader.types.d.ts +4 -0
- package/dist/shared/types/loader.types.d.ts.map +1 -1
- package/dist/shared/types/step.types.d.ts +6 -0
- package/dist/shared/types/step.types.d.ts.map +1 -1
- package/dist/shared/utils/error.d.ts +5 -0
- package/dist/shared/utils/error.d.ts.map +1 -1
- package/dist/shared/utils/error.js +11 -0
- package/dist/shared/utils/error.js.map +1 -1
- package/dist/src/adapters/registry.d.ts.map +1 -1
- package/dist/src/adapters/registry.js +2 -1
- package/dist/src/adapters/registry.js.map +1 -1
- package/dist/src/api/controllers/webhook.controller.d.ts +10 -0
- package/dist/src/api/controllers/webhook.controller.d.ts.map +1 -1
- package/dist/src/api/controllers/webhook.controller.js +50 -10
- package/dist/src/api/controllers/webhook.controller.js.map +1 -1
- package/dist/src/api/resolvers/queue.resolver.d.ts +3 -1
- package/dist/src/api/resolvers/queue.resolver.d.ts.map +1 -1
- package/dist/src/api/resolvers/queue.resolver.js +6 -5
- package/dist/src/api/resolvers/queue.resolver.js.map +1 -1
- package/dist/src/api/schema/pipeline.schema.d.ts +1 -1
- package/dist/src/api/schema/pipeline.schema.d.ts.map +1 -1
- package/dist/src/api/schema/pipeline.schema.js +6 -0
- package/dist/src/api/schema/pipeline.schema.js.map +1 -1
- package/dist/src/api/schema/test.schema.d.ts +1 -1
- package/dist/src/api/schema/test.schema.d.ts.map +1 -1
- package/dist/src/api/schema/test.schema.js +5 -1
- package/dist/src/api/schema/test.schema.js.map +1 -1
- package/dist/src/bootstrap/initialization.d.ts.map +1 -1
- package/dist/src/bootstrap/initialization.js +6 -0
- package/dist/src/bootstrap/initialization.js.map +1 -1
- package/dist/src/constants/adapter-schema-options.d.ts +65 -0
- package/dist/src/constants/adapter-schema-options.d.ts.map +1 -1
- package/dist/src/constants/adapter-schema-options.js +79 -3
- package/dist/src/constants/adapter-schema-options.js.map +1 -1
- package/dist/src/constants/builtin-adapters.d.ts +1 -1
- package/dist/src/constants/builtin-adapters.d.ts.map +1 -1
- package/dist/src/constants/builtin-adapters.js +19 -1
- package/dist/src/constants/builtin-adapters.js.map +1 -1
- package/dist/src/constants/core.d.ts +10 -0
- package/dist/src/constants/core.d.ts.map +1 -1
- package/dist/src/constants/core.js +10 -0
- package/dist/src/constants/core.js.map +1 -1
- package/dist/src/constants/defaults/webhook-defaults.d.ts +2 -0
- package/dist/src/constants/defaults/webhook-defaults.d.ts.map +1 -1
- package/dist/src/constants/defaults/webhook-defaults.js +2 -0
- package/dist/src/constants/defaults/webhook-defaults.js.map +1 -1
- package/dist/src/constants/enum-metadata.d.ts.map +1 -1
- package/dist/src/constants/enum-metadata.js +3 -0
- package/dist/src/constants/enum-metadata.js.map +1 -1
- package/dist/src/constants/hook-stage-metadata.d.ts.map +1 -1
- package/dist/src/constants/hook-stage-metadata.js +42 -0
- package/dist/src/constants/hook-stage-metadata.js.map +1 -1
- package/dist/src/constants/services.d.ts.map +1 -1
- package/dist/src/constants/services.js +7 -0
- package/dist/src/constants/services.js.map +1 -1
- package/dist/src/constants/time.d.ts +2 -0
- package/dist/src/constants/time.d.ts.map +1 -1
- package/dist/src/constants/time.js +2 -0
- package/dist/src/constants/time.js.map +1 -1
- package/dist/src/entities/data/error-record.entity.d.ts +1 -0
- package/dist/src/entities/data/error-record.entity.d.ts.map +1 -1
- package/dist/src/entities/data/error-record.entity.js +4 -0
- package/dist/src/entities/data/error-record.entity.js.map +1 -1
- package/dist/src/entities/pipeline/pipeline-run.entity.d.ts +4 -0
- package/dist/src/entities/pipeline/pipeline-run.entity.d.ts.map +1 -1
- package/dist/src/entities/pipeline/pipeline-run.entity.js +8 -0
- package/dist/src/entities/pipeline/pipeline-run.entity.js.map +1 -1
- package/dist/src/extractors/cdc/cdc.extractor.d.ts.map +1 -1
- package/dist/src/extractors/cdc/cdc.extractor.js +7 -2
- package/dist/src/extractors/cdc/cdc.extractor.js.map +1 -1
- package/dist/src/extractors/cdc/types.d.ts +1 -1
- package/dist/src/extractors/cdc/types.d.ts.map +1 -1
- package/dist/src/extractors/extractor-handler-registry.d.ts.map +1 -1
- package/dist/src/extractors/extractor-handler-registry.js +3 -0
- package/dist/src/extractors/extractor-handler-registry.js.map +1 -1
- package/dist/src/extractors/vendure-query/helpers.d.ts +9 -4
- package/dist/src/extractors/vendure-query/helpers.d.ts.map +1 -1
- package/dist/src/extractors/vendure-query/helpers.js +98 -32
- package/dist/src/extractors/vendure-query/helpers.js.map +1 -1
- package/dist/src/extractors/vendure-query/schema.d.ts.map +1 -1
- package/dist/src/extractors/vendure-query/schema.js +13 -0
- package/dist/src/extractors/vendure-query/schema.js.map +1 -1
- package/dist/src/feeds/generators/csv-feed.generator.d.ts.map +1 -1
- package/dist/src/feeds/generators/csv-feed.generator.js +5 -4
- package/dist/src/feeds/generators/csv-feed.generator.js.map +1 -1
- package/dist/src/feeds/generators/facebook-catalog.generator.d.ts.map +1 -1
- package/dist/src/feeds/generators/facebook-catalog.generator.js +83 -114
- package/dist/src/feeds/generators/facebook-catalog.generator.js.map +1 -1
- package/dist/src/feeds/generators/feed-constants.d.ts +1 -0
- package/dist/src/feeds/generators/feed-constants.d.ts.map +1 -1
- package/dist/src/feeds/generators/feed-constants.js +1 -0
- package/dist/src/feeds/generators/feed-constants.js.map +1 -1
- package/dist/src/feeds/generators/feed-helpers.d.ts +10 -8
- package/dist/src/feeds/generators/feed-helpers.d.ts.map +1 -1
- package/dist/src/feeds/generators/feed-helpers.js +23 -3
- package/dist/src/feeds/generators/feed-helpers.js.map +1 -1
- package/dist/src/feeds/generators/feed-item-builder.d.ts +59 -0
- package/dist/src/feeds/generators/feed-item-builder.d.ts.map +1 -0
- package/dist/src/feeds/generators/feed-item-builder.js +93 -0
- package/dist/src/feeds/generators/feed-item-builder.js.map +1 -0
- package/dist/src/feeds/generators/google-shopping.generator.d.ts.map +1 -1
- package/dist/src/feeds/generators/google-shopping.generator.js +52 -64
- package/dist/src/feeds/generators/google-shopping.generator.js.map +1 -1
- package/dist/src/feeds/generators/json-feed.generator.d.ts.map +1 -1
- package/dist/src/feeds/generators/json-feed.generator.js +4 -3
- package/dist/src/feeds/generators/json-feed.generator.js.map +1 -1
- package/dist/src/feeds/generators/xml-feed.generator.d.ts.map +1 -1
- package/dist/src/feeds/generators/xml-feed.generator.js +6 -5
- package/dist/src/feeds/generators/xml-feed.generator.js.map +1 -1
- package/dist/src/gql/generated.d.ts +5 -0
- package/dist/src/gql/generated.d.ts.map +1 -1
- package/dist/src/gql/generated.js.map +1 -1
- package/dist/src/index.d.ts +3 -1
- package/dist/src/index.d.ts.map +1 -1
- package/dist/src/index.js +7 -4
- package/dist/src/index.js.map +1 -1
- package/dist/src/loaders/asset/asset.loader.d.ts.map +1 -1
- package/dist/src/loaders/asset/asset.loader.js +5 -1
- package/dist/src/loaders/asset/asset.loader.js.map +1 -1
- package/dist/src/loaders/base/validation-builder.d.ts +128 -3
- package/dist/src/loaders/base/validation-builder.d.ts.map +1 -1
- package/dist/src/loaders/base/validation-builder.js +177 -6
- package/dist/src/loaders/base/validation-builder.js.map +1 -1
- package/dist/src/loaders/collection/collection.loader.d.ts.map +1 -1
- package/dist/src/loaders/collection/collection.loader.js +22 -1
- package/dist/src/loaders/collection/collection.loader.js.map +1 -1
- package/dist/src/loaders/collection/helpers.d.ts +16 -1
- package/dist/src/loaders/collection/helpers.d.ts.map +1 -1
- package/dist/src/loaders/collection/helpers.js +37 -0
- package/dist/src/loaders/collection/helpers.js.map +1 -1
- package/dist/src/loaders/customer/customer.loader.d.ts.map +1 -1
- package/dist/src/loaders/customer/customer.loader.js +13 -1
- package/dist/src/loaders/customer/customer.loader.js.map +1 -1
- package/dist/src/loaders/customer/helpers.d.ts +15 -3
- package/dist/src/loaders/customer/helpers.d.ts.map +1 -1
- package/dist/src/loaders/customer/helpers.js +188 -7
- package/dist/src/loaders/customer/helpers.js.map +1 -1
- package/dist/src/loaders/facet-value/facet-value.loader.d.ts.map +1 -1
- package/dist/src/loaders/facet-value/facet-value.loader.js +18 -0
- package/dist/src/loaders/facet-value/facet-value.loader.js.map +1 -1
- package/dist/src/loaders/facet-value/types.d.ts +1 -1
- package/dist/src/loaders/facet-value/types.js +1 -1
- package/dist/src/loaders/facet-value/types.js.map +1 -1
- package/dist/src/loaders/inventory/inventory.loader.d.ts.map +1 -1
- package/dist/src/loaders/inventory/inventory.loader.js +1 -2
- package/dist/src/loaders/inventory/inventory.loader.js.map +1 -1
- package/dist/src/loaders/order/helpers.d.ts +16 -2
- package/dist/src/loaders/order/helpers.d.ts.map +1 -1
- package/dist/src/loaders/order/helpers.js +108 -0
- package/dist/src/loaders/order/helpers.js.map +1 -1
- package/dist/src/loaders/order/order.loader.d.ts +38 -0
- package/dist/src/loaders/order/order.loader.d.ts.map +1 -1
- package/dist/src/loaders/order/order.loader.js +238 -24
- package/dist/src/loaders/order/order.loader.js.map +1 -1
- package/dist/src/loaders/order/types.d.ts +10 -3
- package/dist/src/loaders/order/types.d.ts.map +1 -1
- package/dist/src/loaders/order/types.js +13 -2
- package/dist/src/loaders/order/types.js.map +1 -1
- package/dist/src/loaders/product/product.loader.d.ts.map +1 -1
- package/dist/src/loaders/product/product.loader.js +18 -2
- package/dist/src/loaders/product/product.loader.js.map +1 -1
- package/dist/src/loaders/product-variant/helpers.d.ts +20 -0
- package/dist/src/loaders/product-variant/helpers.d.ts.map +1 -0
- package/dist/src/loaders/product-variant/helpers.js +103 -0
- package/dist/src/loaders/product-variant/helpers.js.map +1 -0
- package/dist/src/loaders/product-variant/product-variant.loader.d.ts.map +1 -1
- package/dist/src/loaders/product-variant/product-variant.loader.js +76 -10
- package/dist/src/loaders/product-variant/product-variant.loader.js.map +1 -1
- package/dist/src/loaders/product-variant/types.d.ts +7 -0
- package/dist/src/loaders/product-variant/types.d.ts.map +1 -1
- package/dist/src/loaders/product-variant/types.js.map +1 -1
- package/dist/src/loaders/promotion/helpers.d.ts +29 -0
- package/dist/src/loaders/promotion/helpers.d.ts.map +1 -1
- package/dist/src/loaders/promotion/helpers.js +68 -0
- package/dist/src/loaders/promotion/helpers.js.map +1 -1
- package/dist/src/loaders/promotion/promotion.loader.d.ts.map +1 -1
- package/dist/src/loaders/promotion/promotion.loader.js +12 -2
- package/dist/src/loaders/promotion/promotion.loader.js.map +1 -1
- package/dist/src/loaders/shared-helpers.d.ts +42 -2
- package/dist/src/loaders/shared-helpers.d.ts.map +1 -1
- package/dist/src/loaders/shared-helpers.js +384 -5
- package/dist/src/loaders/shared-helpers.js.map +1 -1
- package/dist/src/operators/data/copy.operator.js +2 -2
- package/dist/src/operators/data/copy.operator.js.map +1 -1
- package/dist/src/operators/data/rename.operator.js +1 -1
- package/dist/src/operators/data/rename.operator.js.map +1 -1
- package/dist/src/operators/helpers.d.ts.map +1 -1
- package/dist/src/operators/helpers.js +11 -1
- package/dist/src/operators/helpers.js.map +1 -1
- package/dist/src/operators/operator-runtime-registry.d.ts +2 -2
- package/dist/src/operators/operator-runtime-registry.d.ts.map +1 -1
- package/dist/src/operators/operator-runtime-registry.js +1 -1
- package/dist/src/operators/operator-runtime-registry.js.map +1 -1
- package/dist/src/operators/script/script.operators.d.ts.map +1 -1
- package/dist/src/operators/script/script.operators.js +9 -3
- package/dist/src/operators/script/script.operators.js.map +1 -1
- package/dist/src/runtime/config-types.d.ts +6 -0
- package/dist/src/runtime/config-types.d.ts.map +1 -1
- package/dist/src/runtime/executor-helpers.d.ts +77 -0
- package/dist/src/runtime/executor-helpers.d.ts.map +1 -0
- package/dist/src/runtime/executor-helpers.js +143 -0
- package/dist/src/runtime/executor-helpers.js.map +1 -0
- package/dist/src/runtime/executor-types.d.ts +3 -2
- package/dist/src/runtime/executor-types.d.ts.map +1 -1
- package/dist/src/runtime/executors/export.executor.d.ts +3 -1
- package/dist/src/runtime/executors/export.executor.d.ts.map +1 -1
- package/dist/src/runtime/executors/export.executor.js +15 -3
- package/dist/src/runtime/executors/export.executor.js.map +1 -1
- package/dist/src/runtime/executors/exporters/export-handler-registry.d.ts.map +1 -1
- package/dist/src/runtime/executors/exporters/export-handler-registry.js +5 -0
- package/dist/src/runtime/executors/exporters/export-handler-registry.js.map +1 -1
- package/dist/src/runtime/executors/exporters/export-handler.types.d.ts +3 -0
- package/dist/src/runtime/executors/exporters/export-handler.types.d.ts.map +1 -1
- package/dist/src/runtime/executors/exporters/export-handler.types.js.map +1 -1
- package/dist/src/runtime/executors/exporters/export-helpers.d.ts +1 -0
- package/dist/src/runtime/executors/exporters/export-helpers.d.ts.map +1 -1
- package/dist/src/runtime/executors/exporters/export-helpers.js +33 -4
- package/dist/src/runtime/executors/exporters/export-helpers.js.map +1 -1
- package/dist/src/runtime/executors/exporters/http-export.handler.js +4 -4
- package/dist/src/runtime/executors/exporters/http-export.handler.js.map +1 -1
- package/dist/src/runtime/executors/extractors/file-extract.handler.d.ts.map +1 -1
- package/dist/src/runtime/executors/extractors/file-extract.handler.js +33 -13
- package/dist/src/runtime/executors/extractors/file-extract.handler.js.map +1 -1
- package/dist/src/runtime/executors/extractors/memory-extract.handler.d.ts.map +1 -1
- package/dist/src/runtime/executors/extractors/memory-extract.handler.js +17 -9
- package/dist/src/runtime/executors/extractors/memory-extract.handler.js.map +1 -1
- package/dist/src/runtime/executors/feed.executor.d.ts.map +1 -1
- package/dist/src/runtime/executors/feed.executor.js +11 -2
- package/dist/src/runtime/executors/feed.executor.js.map +1 -1
- package/dist/src/runtime/executors/feeds/feed-handler-registry.d.ts.map +1 -1
- package/dist/src/runtime/executors/feeds/feed-handler-registry.js +4 -0
- package/dist/src/runtime/executors/feeds/feed-handler-registry.js.map +1 -1
- package/dist/src/runtime/executors/gate.executor.d.ts +3 -1
- package/dist/src/runtime/executors/gate.executor.d.ts.map +1 -1
- package/dist/src/runtime/executors/gate.executor.js +47 -26
- package/dist/src/runtime/executors/gate.executor.js.map +1 -1
- package/dist/src/runtime/executors/loaders/asset-handler.js +1 -1
- package/dist/src/runtime/executors/loaders/asset-handler.js.map +1 -1
- package/dist/src/runtime/executors/loaders/asset-import-handler.js +1 -1
- package/dist/src/runtime/executors/loaders/asset-import-handler.js.map +1 -1
- package/dist/src/runtime/executors/loaders/channel-handler.d.ts +3 -1
- package/dist/src/runtime/executors/loaders/channel-handler.d.ts.map +1 -1
- package/dist/src/runtime/executors/loaders/channel-handler.js +28 -5
- package/dist/src/runtime/executors/loaders/channel-handler.js.map +1 -1
- package/dist/src/runtime/executors/loaders/collection-handler.d.ts +14 -2
- package/dist/src/runtime/executors/loaders/collection-handler.d.ts.map +1 -1
- package/dist/src/runtime/executors/loaders/collection-handler.js +113 -23
- package/dist/src/runtime/executors/loaders/collection-handler.js.map +1 -1
- package/dist/src/runtime/executors/loaders/customer-group-handler.d.ts.map +1 -1
- package/dist/src/runtime/executors/loaders/customer-group-handler.js +2 -20
- package/dist/src/runtime/executors/loaders/customer-group-handler.js.map +1 -1
- package/dist/src/runtime/executors/loaders/customer-handler.d.ts +6 -1
- package/dist/src/runtime/executors/loaders/customer-handler.d.ts.map +1 -1
- package/dist/src/runtime/executors/loaders/customer-handler.js +128 -15
- package/dist/src/runtime/executors/loaders/customer-handler.js.map +1 -1
- package/dist/src/runtime/executors/loaders/deletion-handler.d.ts +39 -0
- package/dist/src/runtime/executors/loaders/deletion-handler.d.ts.map +1 -0
- package/dist/src/runtime/executors/loaders/deletion-handler.js +414 -0
- package/dist/src/runtime/executors/loaders/deletion-handler.js.map +1 -0
- package/dist/src/runtime/executors/loaders/facet-handler.d.ts +18 -3
- package/dist/src/runtime/executors/loaders/facet-handler.d.ts.map +1 -1
- package/dist/src/runtime/executors/loaders/facet-handler.js +161 -28
- package/dist/src/runtime/executors/loaders/facet-handler.js.map +1 -1
- package/dist/src/runtime/executors/loaders/graphql-mutation-handler.js +1 -1
- package/dist/src/runtime/executors/loaders/graphql-mutation-handler.js.map +1 -1
- package/dist/src/runtime/executors/loaders/index.d.ts +2 -0
- package/dist/src/runtime/executors/loaders/index.d.ts.map +1 -1
- package/dist/src/runtime/executors/loaders/index.js +5 -1
- package/dist/src/runtime/executors/loaders/index.js.map +1 -1
- package/dist/src/runtime/executors/loaders/inventory-adjust-handler.d.ts.map +1 -1
- package/dist/src/runtime/executors/loaders/inventory-adjust-handler.js +2 -21
- package/dist/src/runtime/executors/loaders/inventory-adjust-handler.js.map +1 -1
- package/dist/src/runtime/executors/loaders/inventory-handler.d.ts +2 -1
- package/dist/src/runtime/executors/loaders/inventory-handler.d.ts.map +1 -1
- package/dist/src/runtime/executors/loaders/inventory-handler.js +11 -9
- package/dist/src/runtime/executors/loaders/inventory-handler.js.map +1 -1
- package/dist/src/runtime/executors/loaders/loader-handler-registry.d.ts.map +1 -1
- package/dist/src/runtime/executors/loaders/loader-handler-registry.js +150 -11
- package/dist/src/runtime/executors/loaders/loader-handler-registry.js.map +1 -1
- package/dist/src/runtime/executors/loaders/order-handler.d.ts +32 -4
- package/dist/src/runtime/executors/loaders/order-handler.d.ts.map +1 -1
- package/dist/src/runtime/executors/loaders/order-handler.js +201 -18
- package/dist/src/runtime/executors/loaders/order-handler.js.map +1 -1
- package/dist/src/runtime/executors/loaders/order-upsert-handler.d.ts +15 -0
- package/dist/src/runtime/executors/loaders/order-upsert-handler.d.ts.map +1 -0
- package/dist/src/runtime/executors/loaders/order-upsert-handler.js +89 -0
- package/dist/src/runtime/executors/loaders/order-upsert-handler.js.map +1 -0
- package/dist/src/runtime/executors/loaders/payment-method-handler.d.ts +11 -2
- package/dist/src/runtime/executors/loaders/payment-method-handler.d.ts.map +1 -1
- package/dist/src/runtime/executors/loaders/payment-method-handler.js +92 -34
- package/dist/src/runtime/executors/loaders/payment-method-handler.js.map +1 -1
- package/dist/src/runtime/executors/loaders/product-handler.d.ts +20 -0
- package/dist/src/runtime/executors/loaders/product-handler.d.ts.map +1 -1
- package/dist/src/runtime/executors/loaders/product-handler.js +121 -31
- package/dist/src/runtime/executors/loaders/product-handler.js.map +1 -1
- package/dist/src/runtime/executors/loaders/promotion-handler.d.ts +9 -2
- package/dist/src/runtime/executors/loaders/promotion-handler.d.ts.map +1 -1
- package/dist/src/runtime/executors/loaders/promotion-handler.js +134 -68
- package/dist/src/runtime/executors/loaders/promotion-handler.js.map +1 -1
- package/dist/src/runtime/executors/loaders/rest-handler.js +1 -1
- package/dist/src/runtime/executors/loaders/rest-handler.js.map +1 -1
- package/dist/src/runtime/executors/loaders/shared-lookups.d.ts +62 -1
- package/dist/src/runtime/executors/loaders/shared-lookups.d.ts.map +1 -1
- package/dist/src/runtime/executors/loaders/shared-lookups.js +238 -0
- package/dist/src/runtime/executors/loaders/shared-lookups.js.map +1 -1
- package/dist/src/runtime/executors/loaders/shipping-method-handler.d.ts +11 -6
- package/dist/src/runtime/executors/loaders/shipping-method-handler.d.ts.map +1 -1
- package/dist/src/runtime/executors/loaders/shipping-method-handler.js +168 -54
- package/dist/src/runtime/executors/loaders/shipping-method-handler.js.map +1 -1
- package/dist/src/runtime/executors/loaders/stock-location-handler.d.ts.map +1 -1
- package/dist/src/runtime/executors/loaders/stock-location-handler.js +2 -20
- package/dist/src/runtime/executors/loaders/stock-location-handler.js.map +1 -1
- package/dist/src/runtime/executors/loaders/tax-rate-handler.d.ts.map +1 -1
- package/dist/src/runtime/executors/loaders/tax-rate-handler.js +14 -1
- package/dist/src/runtime/executors/loaders/tax-rate-handler.js.map +1 -1
- package/dist/src/runtime/executors/loaders/types.d.ts +2 -0
- package/dist/src/runtime/executors/loaders/types.d.ts.map +1 -1
- package/dist/src/runtime/executors/loaders/variant-handler.d.ts +24 -2
- package/dist/src/runtime/executors/loaders/variant-handler.d.ts.map +1 -1
- package/dist/src/runtime/executors/loaders/variant-handler.js +266 -47
- package/dist/src/runtime/executors/loaders/variant-handler.js.map +1 -1
- package/dist/src/runtime/executors/sink-handler-registry.d.ts +7 -11
- package/dist/src/runtime/executors/sink-handler-registry.d.ts.map +1 -1
- package/dist/src/runtime/executors/sink-handler-registry.js +376 -10
- package/dist/src/runtime/executors/sink-handler-registry.js.map +1 -1
- package/dist/src/runtime/executors/sink.executor.d.ts +1 -0
- package/dist/src/runtime/executors/sink.executor.d.ts.map +1 -1
- package/dist/src/runtime/executors/sink.executor.js +82 -12
- package/dist/src/runtime/executors/sink.executor.js.map +1 -1
- package/dist/src/runtime/executors/transform.executor.d.ts.map +1 -1
- package/dist/src/runtime/executors/transform.executor.js +31 -2
- package/dist/src/runtime/executors/transform.executor.js.map +1 -1
- package/dist/src/runtime/orchestration/graph-executor.d.ts.map +1 -1
- package/dist/src/runtime/orchestration/graph-executor.js +3 -2
- package/dist/src/runtime/orchestration/graph-executor.js.map +1 -1
- package/dist/src/runtime/orchestration/helpers.d.ts +4 -1
- package/dist/src/runtime/orchestration/helpers.d.ts.map +1 -1
- package/dist/src/runtime/orchestration/helpers.js +7 -2
- package/dist/src/runtime/orchestration/helpers.js.map +1 -1
- package/dist/src/runtime/orchestration/linear-executor.d.ts.map +1 -1
- package/dist/src/runtime/orchestration/linear-executor.js +3 -2
- package/dist/src/runtime/orchestration/linear-executor.js.map +1 -1
- package/dist/src/runtime/orchestration/replay-executor.d.ts.map +1 -1
- package/dist/src/runtime/orchestration/replay-executor.js +3 -2
- package/dist/src/runtime/orchestration/replay-executor.js.map +1 -1
- package/dist/src/runtime/orchestration/step-strategies/export-step.strategy.d.ts.map +1 -1
- package/dist/src/runtime/orchestration/step-strategies/export-step.strategy.js +12 -12
- package/dist/src/runtime/orchestration/step-strategies/export-step.strategy.js.map +1 -1
- package/dist/src/runtime/orchestration/step-strategies/feed-step.strategy.d.ts.map +1 -1
- package/dist/src/runtime/orchestration/step-strategies/feed-step.strategy.js +12 -12
- package/dist/src/runtime/orchestration/step-strategies/feed-step.strategy.js.map +1 -1
- package/dist/src/runtime/orchestration/step-strategies/load-step.strategy.js +2 -2
- package/dist/src/runtime/orchestration/step-strategies/load-step.strategy.js.map +1 -1
- package/dist/src/runtime/orchestration/step-strategies/sink-step.strategy.d.ts.map +1 -1
- package/dist/src/runtime/orchestration/step-strategies/sink-step.strategy.js +12 -12
- package/dist/src/runtime/orchestration/step-strategies/sink-step.strategy.js.map +1 -1
- package/dist/src/runtime/orchestration/step-strategies/step-dispatcher.d.ts.map +1 -1
- package/dist/src/runtime/orchestration/step-strategies/step-dispatcher.js +4 -3
- package/dist/src/runtime/orchestration/step-strategies/step-dispatcher.js.map +1 -1
- package/dist/src/runtime/orchestration/step-strategies/transform-step.strategy.js +4 -4
- package/dist/src/runtime/orchestration/step-strategies/transform-step.strategy.js.map +1 -1
- package/dist/src/runtime/orchestration/types.d.ts +1 -0
- package/dist/src/runtime/orchestration/types.d.ts.map +1 -1
- package/dist/src/runtime/utils.d.ts.map +1 -1
- package/dist/src/runtime/utils.js +8 -1
- package/dist/src/runtime/utils.js.map +1 -1
- package/dist/src/sdk/adapters/queue/index.d.ts +1 -0
- package/dist/src/sdk/adapters/queue/index.d.ts.map +1 -1
- package/dist/src/sdk/adapters/queue/index.js +1 -0
- package/dist/src/sdk/adapters/queue/index.js.map +1 -1
- package/dist/src/sdk/adapters/queue/internal.adapter.d.ts +32 -0
- package/dist/src/sdk/adapters/queue/internal.adapter.d.ts.map +1 -0
- package/dist/src/sdk/adapters/queue/internal.adapter.js +68 -0
- package/dist/src/sdk/adapters/queue/internal.adapter.js.map +1 -0
- package/dist/src/sdk/adapters/queue/queue-adapter.registry.d.ts.map +1 -1
- package/dist/src/sdk/adapters/queue/queue-adapter.registry.js +3 -0
- package/dist/src/sdk/adapters/queue/queue-adapter.registry.js.map +1 -1
- package/dist/src/sdk/adapters/queue/rabbitmq.adapter.d.ts.map +1 -1
- package/dist/src/sdk/adapters/queue/rabbitmq.adapter.js +2 -1
- package/dist/src/sdk/adapters/queue/rabbitmq.adapter.js.map +1 -1
- package/dist/src/sdk/constants.d.ts +2 -2
- package/dist/src/sdk/constants.d.ts.map +1 -1
- package/dist/src/sdk/dsl/pipeline-builder.d.ts +8 -2
- package/dist/src/sdk/dsl/pipeline-builder.d.ts.map +1 -1
- package/dist/src/sdk/dsl/pipeline-builder.js +115 -19
- package/dist/src/sdk/dsl/pipeline-builder.js.map +1 -1
- package/dist/src/sdk/dsl/step-configs.d.ts +24 -0
- package/dist/src/sdk/dsl/step-configs.d.ts.map +1 -1
- package/dist/src/services/data/record-error.service.d.ts +1 -1
- package/dist/src/services/data/record-error.service.d.ts.map +1 -1
- package/dist/src/services/data/record-error.service.js +4 -1
- package/dist/src/services/data/record-error.service.js.map +1 -1
- package/dist/src/services/events/consumer-discovery.d.ts.map +1 -1
- package/dist/src/services/events/consumer-discovery.js +2 -1
- package/dist/src/services/events/consumer-discovery.js.map +1 -1
- package/dist/src/services/events/consumer-lifecycle.d.ts.map +1 -1
- package/dist/src/services/events/consumer-lifecycle.js +19 -15
- package/dist/src/services/events/consumer-lifecycle.js.map +1 -1
- package/dist/src/services/events/event-trigger.service.d.ts.map +1 -1
- package/dist/src/services/events/event-trigger.service.js +9 -3
- package/dist/src/services/events/event-trigger.service.js.map +1 -1
- package/dist/src/services/events/hook.service.d.ts.map +1 -1
- package/dist/src/services/events/hook.service.js +7 -3
- package/dist/src/services/events/hook.service.js.map +1 -1
- package/dist/src/services/events/message-processing.d.ts.map +1 -1
- package/dist/src/services/events/message-processing.js +13 -8
- package/dist/src/services/events/message-processing.js.map +1 -1
- package/dist/src/services/logger/datahub-logger.d.ts +7 -0
- package/dist/src/services/logger/datahub-logger.d.ts.map +1 -1
- package/dist/src/services/logger/datahub-logger.js +9 -0
- package/dist/src/services/logger/datahub-logger.js.map +1 -1
- package/dist/src/services/logger/execution-logger.d.ts +1 -1
- package/dist/src/services/logger/execution-logger.d.ts.map +1 -1
- package/dist/src/services/logger/execution-logger.js +8 -4
- package/dist/src/services/logger/execution-logger.js.map +1 -1
- package/dist/src/services/pipeline/pipeline-runner.service.d.ts +3 -1
- package/dist/src/services/pipeline/pipeline-runner.service.d.ts.map +1 -1
- package/dist/src/services/pipeline/pipeline-runner.service.js +17 -7
- package/dist/src/services/pipeline/pipeline-runner.service.js.map +1 -1
- package/dist/src/services/pipeline/pipeline.service.d.ts.map +1 -1
- package/dist/src/services/pipeline/pipeline.service.js +8 -2
- package/dist/src/services/pipeline/pipeline.service.js.map +1 -1
- package/dist/src/services/storage/retention.service.d.ts.map +1 -1
- package/dist/src/services/storage/retention.service.js +22 -0
- package/dist/src/services/storage/retention.service.js.map +1 -1
- package/dist/src/services/testing/step-test.service.d.ts.map +1 -1
- package/dist/src/services/testing/step-test.service.js +17 -1
- package/dist/src/services/testing/step-test.service.js.map +1 -1
- package/dist/src/services/validation/definition-validation.service.d.ts.map +1 -1
- package/dist/src/services/validation/definition-validation.service.js +4 -1
- package/dist/src/services/validation/definition-validation.service.js.map +1 -1
- package/dist/src/services/validation/trigger-validation.d.ts.map +1 -1
- package/dist/src/services/validation/trigger-validation.js +76 -2
- package/dist/src/services/validation/trigger-validation.js.map +1 -1
- package/dist/src/types/index.d.ts +1 -0
- package/dist/src/types/index.d.ts.map +1 -1
- package/dist/src/types/index.js.map +1 -1
- package/dist/src/types/loader-configs.d.ts +1071 -0
- package/dist/src/types/loader-configs.d.ts.map +1 -0
- package/dist/src/types/loader-configs.js +54 -0
- package/dist/src/types/loader-configs.js.map +1 -0
- package/dist/src/types/step-configs.d.ts +1 -0
- package/dist/src/types/step-configs.d.ts.map +1 -1
- package/dist/src/types/step-configs.js +3 -0
- package/dist/src/types/step-configs.js.map +1 -1
- package/dist/src/utils/code-security.utils.d.ts +18 -0
- package/dist/src/utils/code-security.utils.d.ts.map +1 -1
- package/dist/src/utils/code-security.utils.js +125 -9
- package/dist/src/utils/code-security.utils.js.map +1 -1
- package/dist/src/utils/error.utils.d.ts +1 -1
- package/dist/src/utils/error.utils.d.ts.map +1 -1
- package/dist/src/utils/error.utils.js +2 -1
- package/dist/src/utils/error.utils.js.map +1 -1
- package/dist/src/utils/url-security.utils.d.ts +5 -3
- package/dist/src/utils/url-security.utils.d.ts.map +1 -1
- package/dist/src/utils/url-security.utils.js +20 -4
- package/dist/src/utils/url-security.utils.js.map +1 -1
- package/dist/src/validation/pipeline-definition.validator.js +2 -1
- package/dist/src/validation/pipeline-definition.validator.js.map +1 -1
- package/docs/developer-guide/README.md +2 -0
- package/docs/developer-guide/dsl/pipeline-builder.md +12 -0
- package/docs/developer-guide/extending/README.md +230 -10
- package/docs/developer-guide/extending/custom-sinks.md +87 -0
- package/docs/developer-guide/extending/events.md +4 -1
- package/docs/examples/validation-error-messages.md +246 -0
- package/docs/guides/multi-channel.md +1190 -0
- package/docs/guides/multi-currency.md +881 -0
- package/docs/guides/multi-entity.md +597 -0
- package/docs/guides/multi-language.md +957 -0
- package/docs/reference/README.md +11 -4
- package/docs/reference/extractors.md +30 -0
- package/docs/reference/loaders.md +396 -21
- package/docs/reference/operators-complete.md +1251 -0
- package/docs/reference/operators.md +36 -2
- package/docs/reference/sinks.md +7 -6
- package/docs/reference/step-types.md +12 -5
- package/docs/user-guide/pipelines.md +82 -13
- package/package.json +1 -1
- package/shared/types/adapter-config.types.ts +439 -10
- package/shared/types/index.ts +25 -0
- package/shared/types/loader.types.ts +4 -0
- package/shared/types/step.types.ts +6 -0
- package/shared/utils/error.ts +11 -0
|
@@ -0,0 +1,1251 @@
|
|
|
1
|
+
# Complete Operator Reference
|
|
2
|
+
|
|
3
|
+
**Auto-generated from OPERATOR_REGISTRY**
|
|
4
|
+
|
|
5
|
+
Total operators: **61**
|
|
6
|
+
|
|
7
|
+
This is the definitive reference for all built-in transform operators in the Data Hub plugin.
|
|
8
|
+
|
|
9
|
+
## Table of Contents
|
|
10
|
+
|
|
11
|
+
### [Aggregation Operators](#aggregation)
|
|
12
|
+
- [aggregate](#aggregate) - Compute a simple aggregate over records and set a field on each record.
|
|
13
|
+
- [count](#count) - Count elements in an array or characters in a string.
|
|
14
|
+
- [unique](#unique) - Remove duplicate values from an array field.
|
|
15
|
+
- [flatten](#flatten) - Flatten a nested array into a single-level array.
|
|
16
|
+
- [first](#first) - Get the first element of an array.
|
|
17
|
+
- [last](#last) - Get the last element of an array.
|
|
18
|
+
- [expand](#expand) - Expand an array field into multiple records. Each array element becomes a separate record with optional parent field inheritance.
|
|
19
|
+
- [multiJoin](#multijoin) - Join two datasets by matching key fields. Supports INNER, LEFT, RIGHT, and FULL OUTER join types.
|
|
20
|
+
|
|
21
|
+
### [File Operators](#file)
|
|
22
|
+
- [imageResize](#imageresize) - Resize images referenced in record fields (base64-encoded)
|
|
23
|
+
- [imageConvert](#imageconvert) - Convert image format (JPEG, PNG, WebP, AVIF, GIF)
|
|
24
|
+
- [pdfGenerate](#pdfgenerate) - Generate PDF from HTML template with record data
|
|
25
|
+
|
|
26
|
+
### [Data Operators](#data)
|
|
27
|
+
- [map](#map) - Transform records via field mapping. Provide a JSON object of dst -> src dot-paths.
|
|
28
|
+
- [set](#set) - Set a static value at a specified path.
|
|
29
|
+
- [remove](#remove) - Remove a field at a specified path.
|
|
30
|
+
- [rename](#rename) - Rename a field from one path to another.
|
|
31
|
+
- [copy](#copy) - Copy a field value to another path.
|
|
32
|
+
- [template](#template) - Render a string template and set it at target path.
|
|
33
|
+
- [hash](#hash) - Generate a cryptographic hash (MD5, SHA1, SHA256, SHA512) of field value(s).
|
|
34
|
+
- [uuid](#uuid) - Generate a UUID for each record. Supports v4 (random) and v5 (namespace-based deterministic).
|
|
35
|
+
- [validateRequired](#validaterequired) - Mark records as invalid if required fields are missing.
|
|
36
|
+
- [validateFormat](#validateformat) - Validate field format using regex.
|
|
37
|
+
|
|
38
|
+
### [Date Operators](#date)
|
|
39
|
+
- [dateFormat](#dateformat) - Format a date field to a string.
|
|
40
|
+
- [dateParse](#dateparse) - Parse a string to a date.
|
|
41
|
+
- [dateAdd](#dateadd) - Add or subtract time from a date.
|
|
42
|
+
- [dateDiff](#datediff) - Calculate the difference between two dates in a specified unit.
|
|
43
|
+
- [now](#now) - Set the current timestamp on a field. Useful for adding created/updated timestamps.
|
|
44
|
+
|
|
45
|
+
### [Enrichment Operators](#enrichment)
|
|
46
|
+
- [lookup](#lookup) - Lookup value from a map and set to target field.
|
|
47
|
+
- [coalesce](#coalesce) - Return the first non-null value from a list of field paths.
|
|
48
|
+
- [enrich](#enrich) - Enrich or default fields on records.
|
|
49
|
+
- [default](#default) - Set a default value if field is null or undefined.
|
|
50
|
+
- [httpLookup](#httplookup) - Enrich records by fetching data from external HTTP endpoints with caching, authentication, and error handling.
|
|
51
|
+
|
|
52
|
+
### [JSON Operators](#json)
|
|
53
|
+
- [parseJson](#parsejson) - Parse a JSON string field into an object.
|
|
54
|
+
- [stringifyJson](#stringifyjson) - Stringify an object field to a JSON string.
|
|
55
|
+
- [pick](#pick) - Pick specific fields from a record, discarding others.
|
|
56
|
+
- [omit](#omit) - Omit specific fields from a record.
|
|
57
|
+
|
|
58
|
+
### [Logic Operators](#logic)
|
|
59
|
+
- [when](#when) - Filter records by conditions. Action: keep or drop.
|
|
60
|
+
- [ifThenElse](#ifthenelse) - Set a value based on a condition.
|
|
61
|
+
- [switch](#switch) - Set a value based on multiple conditions (like a switch statement).
|
|
62
|
+
- [deltaFilter](#deltafilter) - Filter out unchanged records using a stable hash stored in checkpoint. Keeps only changed/new based on idPath.
|
|
63
|
+
|
|
64
|
+
### [Numeric Operators](#numeric)
|
|
65
|
+
- [math](#math) - Perform math operations on numeric fields.
|
|
66
|
+
- [currency](#currency) - Convert floats to minor units or re-map currency fields.
|
|
67
|
+
- [unit](#unit) - Convert units (e.g. g<->kg, cm<->m)
|
|
68
|
+
- [toNumber](#tonumber) - Convert a string field to a number.
|
|
69
|
+
- [toString](#tostring) - Convert a value to a string.
|
|
70
|
+
- [parseNumber](#parsenumber) - Parse a string to a number with locale-aware decimal/thousand separator handling.
|
|
71
|
+
- [formatNumber](#formatnumber) - Format a number as a localized string with optional currency or percent formatting.
|
|
72
|
+
- [toCents](#tocents) - Convert a decimal amount to cents (minor currency units). Multiplies by 100 and rounds.
|
|
73
|
+
- [round](#round) - Round a number to a specified number of decimal places.
|
|
74
|
+
|
|
75
|
+
### [String Operators](#string)
|
|
76
|
+
- [split](#split) - Split a string field into an array by delimiter.
|
|
77
|
+
- [join](#join) - Join an array field into a string.
|
|
78
|
+
- [trim](#trim) - Trim whitespace from a string field.
|
|
79
|
+
- [lowercase](#lowercase) - Convert a string field to lowercase.
|
|
80
|
+
- [uppercase](#uppercase) - Convert a string field to uppercase.
|
|
81
|
+
- [slugify](#slugify) - Generate a URL-friendly slug from a string field.
|
|
82
|
+
- [concat](#concat) - Concatenate multiple string fields into one.
|
|
83
|
+
- [replace](#replace) - Replace text in a string field.
|
|
84
|
+
- [extractRegex](#extractregex) - Extract a value from a string field using a regular expression pattern with capture groups.
|
|
85
|
+
- [replaceRegex](#replaceregex) - Replace values in a string field using a regular expression pattern.
|
|
86
|
+
- [stripHtml](#striphtml) - Remove HTML tags from a string field, preserving text content.
|
|
87
|
+
- [truncate](#truncate) - Truncate a string to a maximum length, optionally adding a suffix.
|
|
88
|
+
|
|
89
|
+
### [Scripting Operators](#scripting)
|
|
90
|
+
- [script](#script) - Execute inline JavaScript code to transform records. Use for complex logic that cannot be expressed with standard operators.
|
|
91
|
+
|
|
92
|
+
---
|
|
93
|
+
|
|
94
|
+
## Aggregation Operators
|
|
95
|
+
|
|
96
|
+
### aggregate
|
|
97
|
+
|
|
98
|
+
Compute a simple aggregate over records and set a field on each record.
|
|
99
|
+
|
|
100
|
+
| Argument | Type | Required | Description |
|
|
101
|
+
|----------|------|----------|-------------|
|
|
102
|
+
| `op` | select | Yes | Operation |
|
|
103
|
+
|
|
104
|
+
**Example:**
|
|
105
|
+
|
|
106
|
+
```typescript
|
|
107
|
+
{ op: 'aggregate', args: {
|
|
108
|
+
"op": "value"
|
|
109
|
+
} }
|
|
110
|
+
```
|
|
111
|
+
|
|
112
|
+
### count
|
|
113
|
+
|
|
114
|
+
Count elements in an array or characters in a string.
|
|
115
|
+
|
|
116
|
+
| Argument | Type | Required | Description |
|
|
117
|
+
|----------|------|----------|-------------|
|
|
118
|
+
| `source` | string | Yes | Source field path |
|
|
119
|
+
| `target` | string | Yes | Target field path |
|
|
120
|
+
|
|
121
|
+
**Example:**
|
|
122
|
+
|
|
123
|
+
```typescript
|
|
124
|
+
{ op: 'count', args: {
|
|
125
|
+
"source": "sourceField",
|
|
126
|
+
"target": "targetField"
|
|
127
|
+
} }
|
|
128
|
+
```
|
|
129
|
+
|
|
130
|
+
### unique
|
|
131
|
+
|
|
132
|
+
Remove duplicate values from an array field.
|
|
133
|
+
|
|
134
|
+
| Argument | Type | Required | Description |
|
|
135
|
+
|----------|------|----------|-------------|
|
|
136
|
+
| `source` | string | Yes | Source field path |
|
|
137
|
+
| `target` | string | No | Target field path |
|
|
138
|
+
| `by` | string | No | Object key to use for uniqueness |
|
|
139
|
+
|
|
140
|
+
**Example:**
|
|
141
|
+
|
|
142
|
+
```typescript
|
|
143
|
+
{ op: 'unique', args: {
|
|
144
|
+
"source": "sourceField"
|
|
145
|
+
} }
|
|
146
|
+
```
|
|
147
|
+
|
|
148
|
+
### flatten
|
|
149
|
+
|
|
150
|
+
Flatten a nested array into a single-level array.
|
|
151
|
+
|
|
152
|
+
| Argument | Type | Required | Description |
|
|
153
|
+
|----------|------|----------|-------------|
|
|
154
|
+
| `source` | string | Yes | Source field path |
|
|
155
|
+
| `target` | string | No | Defaults to source path if not set |
|
|
156
|
+
| `depth` | number | No | How deep to flatten (default: 1) |
|
|
157
|
+
|
|
158
|
+
**Example:**
|
|
159
|
+
|
|
160
|
+
```typescript
|
|
161
|
+
{ op: 'flatten', args: {
|
|
162
|
+
"source": "sourceField"
|
|
163
|
+
} }
|
|
164
|
+
```
|
|
165
|
+
|
|
166
|
+
### first
|
|
167
|
+
|
|
168
|
+
Get the first element of an array.
|
|
169
|
+
|
|
170
|
+
| Argument | Type | Required | Description |
|
|
171
|
+
|----------|------|----------|-------------|
|
|
172
|
+
| `source` | string | Yes | Source array path |
|
|
173
|
+
| `target` | string | Yes | Target field path |
|
|
174
|
+
|
|
175
|
+
**Example:**
|
|
176
|
+
|
|
177
|
+
```typescript
|
|
178
|
+
{ op: 'first', args: {
|
|
179
|
+
"source": "sourceField",
|
|
180
|
+
"target": "targetField"
|
|
181
|
+
} }
|
|
182
|
+
```
|
|
183
|
+
|
|
184
|
+
### last
|
|
185
|
+
|
|
186
|
+
Get the last element of an array.
|
|
187
|
+
|
|
188
|
+
| Argument | Type | Required | Description |
|
|
189
|
+
|----------|------|----------|-------------|
|
|
190
|
+
| `source` | string | Yes | Source array path |
|
|
191
|
+
| `target` | string | Yes | Target field path |
|
|
192
|
+
|
|
193
|
+
**Example:**
|
|
194
|
+
|
|
195
|
+
```typescript
|
|
196
|
+
{ op: 'last', args: {
|
|
197
|
+
"source": "sourceField",
|
|
198
|
+
"target": "targetField"
|
|
199
|
+
} }
|
|
200
|
+
```
|
|
201
|
+
|
|
202
|
+
### expand
|
|
203
|
+
|
|
204
|
+
Expand an array field into multiple records. Each array element becomes a separate record with optional parent field inheritance.
|
|
205
|
+
|
|
206
|
+
| Argument | Type | Required | Description |
|
|
207
|
+
|----------|------|----------|-------------|
|
|
208
|
+
| `path` | string | Yes | Path to the array to expand (e.g., |
|
|
209
|
+
| `mergeParent` | boolean | No | Include all parent fields in expanded records |
|
|
210
|
+
| `parentFields` | json | No | Map of target field names to source paths (e.g., { |
|
|
211
|
+
|
|
212
|
+
**Example:**
|
|
213
|
+
|
|
214
|
+
```typescript
|
|
215
|
+
{ op: 'expand', args: {
|
|
216
|
+
"path": "sourceField"
|
|
217
|
+
} }
|
|
218
|
+
```
|
|
219
|
+
|
|
220
|
+
### multiJoin
|
|
221
|
+
|
|
222
|
+
Join two datasets by matching key fields. Supports INNER, LEFT, RIGHT, and FULL OUTER join types.
|
|
223
|
+
|
|
224
|
+
| Argument | Type | Required | Description |
|
|
225
|
+
|----------|------|----------|-------------|
|
|
226
|
+
| `leftKey` | string | Yes | Field path in left (primary) records to join on |
|
|
227
|
+
| `rightKey` | string | Yes | Field path in right records to join on |
|
|
228
|
+
| `type` | select | Yes | Join type |
|
|
229
|
+
|
|
230
|
+
**Example:**
|
|
231
|
+
|
|
232
|
+
```typescript
|
|
233
|
+
{ op: 'multiJoin', args: {
|
|
234
|
+
"leftKey": "value",
|
|
235
|
+
"rightKey": "value",
|
|
236
|
+
"type": "value"
|
|
237
|
+
} }
|
|
238
|
+
```
|
|
239
|
+
|
|
240
|
+
## File Operators
|
|
241
|
+
|
|
242
|
+
### imageResize
|
|
243
|
+
|
|
244
|
+
Resize images referenced in record fields (base64-encoded)
|
|
245
|
+
|
|
246
|
+
**Example:**
|
|
247
|
+
|
|
248
|
+
```typescript
|
|
249
|
+
{ op: 'imageResize', args: {} }
|
|
250
|
+
```
|
|
251
|
+
|
|
252
|
+
### imageConvert
|
|
253
|
+
|
|
254
|
+
Convert image format (JPEG, PNG, WebP, AVIF, GIF)
|
|
255
|
+
|
|
256
|
+
**Example:**
|
|
257
|
+
|
|
258
|
+
```typescript
|
|
259
|
+
{ op: 'imageConvert', args: {} }
|
|
260
|
+
```
|
|
261
|
+
|
|
262
|
+
### pdfGenerate
|
|
263
|
+
|
|
264
|
+
Generate PDF from HTML template with record data
|
|
265
|
+
|
|
266
|
+
**Example:**
|
|
267
|
+
|
|
268
|
+
```typescript
|
|
269
|
+
{ op: 'pdfGenerate', args: {} }
|
|
270
|
+
```
|
|
271
|
+
|
|
272
|
+
## Data Operators
|
|
273
|
+
|
|
274
|
+
### map
|
|
275
|
+
|
|
276
|
+
Transform records via field mapping. Provide a JSON object of dst -> src dot-paths.
|
|
277
|
+
|
|
278
|
+
| Argument | Type | Required | Description |
|
|
279
|
+
|----------|------|----------|-------------|
|
|
280
|
+
| `mapping` | json | Yes | JSON object defining field mapping (target: source) |
|
|
281
|
+
| `passthrough` | boolean | No | If true, include fields not in mapping |
|
|
282
|
+
|
|
283
|
+
**Example:**
|
|
284
|
+
|
|
285
|
+
```typescript
|
|
286
|
+
{ op: 'map', args: {
|
|
287
|
+
"mapping": "value"
|
|
288
|
+
} }
|
|
289
|
+
```
|
|
290
|
+
|
|
291
|
+
### set
|
|
292
|
+
|
|
293
|
+
Set a static value at a specified path.
|
|
294
|
+
|
|
295
|
+
| Argument | Type | Required | Description |
|
|
296
|
+
|----------|------|----------|-------------|
|
|
297
|
+
| `path` | string | Yes | Dot notation path where to set the value |
|
|
298
|
+
| `value` | json | Yes | The value to set (any valid JSON) |
|
|
299
|
+
|
|
300
|
+
**Example:**
|
|
301
|
+
|
|
302
|
+
```typescript
|
|
303
|
+
{ op: 'set', args: {
|
|
304
|
+
"path": "sourceField",
|
|
305
|
+
"value": "value"
|
|
306
|
+
} }
|
|
307
|
+
```
|
|
308
|
+
|
|
309
|
+
### remove
|
|
310
|
+
|
|
311
|
+
Remove a field at a specified path.
|
|
312
|
+
|
|
313
|
+
| Argument | Type | Required | Description |
|
|
314
|
+
|----------|------|----------|-------------|
|
|
315
|
+
| `path` | string | Yes | Dot notation path of the field to remove |
|
|
316
|
+
|
|
317
|
+
**Example:**
|
|
318
|
+
|
|
319
|
+
```typescript
|
|
320
|
+
{ op: 'remove', args: {
|
|
321
|
+
"path": "sourceField"
|
|
322
|
+
} }
|
|
323
|
+
```
|
|
324
|
+
|
|
325
|
+
### rename
|
|
326
|
+
|
|
327
|
+
Rename a field from one path to another.
|
|
328
|
+
|
|
329
|
+
| Argument | Type | Required | Description |
|
|
330
|
+
|----------|------|----------|-------------|
|
|
331
|
+
| `from` | string | Yes | Source field path |
|
|
332
|
+
| `to` | string | Yes | Target field path |
|
|
333
|
+
|
|
334
|
+
**Example:**
|
|
335
|
+
|
|
336
|
+
```typescript
|
|
337
|
+
{ op: 'rename', args: {
|
|
338
|
+
"from": "value",
|
|
339
|
+
"to": "value"
|
|
340
|
+
} }
|
|
341
|
+
```
|
|
342
|
+
|
|
343
|
+
### copy
|
|
344
|
+
|
|
345
|
+
Copy a field value to another path.
|
|
346
|
+
|
|
347
|
+
| Argument | Type | Required | Description |
|
|
348
|
+
|----------|------|----------|-------------|
|
|
349
|
+
| `source` | string | Yes | Source field path |
|
|
350
|
+
| `target` | string | Yes | Target field path |
|
|
351
|
+
|
|
352
|
+
**Example:**
|
|
353
|
+
|
|
354
|
+
```typescript
|
|
355
|
+
{ op: 'copy', args: {
|
|
356
|
+
"source": "sourceField",
|
|
357
|
+
"target": "targetField"
|
|
358
|
+
} }
|
|
359
|
+
```
|
|
360
|
+
|
|
361
|
+
### template
|
|
362
|
+
|
|
363
|
+
Render a string template and set it at target path.
|
|
364
|
+
|
|
365
|
+
| Argument | Type | Required | Description |
|
|
366
|
+
|----------|------|----------|-------------|
|
|
367
|
+
| `template` | string | Yes | Use ${path.to.field} to substitute values |
|
|
368
|
+
| `target` | string | Yes | Where to store the result |
|
|
369
|
+
| `missingAsEmpty` | boolean | No | Treat missing fields as empty strings |
|
|
370
|
+
|
|
371
|
+
**Example:**
|
|
372
|
+
|
|
373
|
+
```typescript
|
|
374
|
+
{ op: 'template', args: {
|
|
375
|
+
"template": "value",
|
|
376
|
+
"target": "targetField"
|
|
377
|
+
} }
|
|
378
|
+
```
|
|
379
|
+
|
|
380
|
+
### hash
|
|
381
|
+
|
|
382
|
+
Generate a cryptographic hash (MD5, SHA1, SHA256, SHA512) of field value(s).
|
|
383
|
+
|
|
384
|
+
| Argument | Type | Required | Description |
|
|
385
|
+
|----------|------|----------|-------------|
|
|
386
|
+
| `source` | json | Yes | Single path string or array of paths to hash together |
|
|
387
|
+
| `target` | string | Yes | Path where the hash will be stored |
|
|
388
|
+
| `algorithm` | select | No | Default: sha256 |
|
|
389
|
+
| `encoding` | select | No | Default: hex |
|
|
390
|
+
|
|
391
|
+
**Example:**
|
|
392
|
+
|
|
393
|
+
```typescript
|
|
394
|
+
{ op: 'hash', args: {
|
|
395
|
+
"source": "sourceField",
|
|
396
|
+
"target": "targetField"
|
|
397
|
+
} }
|
|
398
|
+
```
|
|
399
|
+
|
|
400
|
+
### uuid
|
|
401
|
+
|
|
402
|
+
Generate a UUID for each record. Supports v4 (random) and v5 (namespace-based deterministic).
|
|
403
|
+
|
|
404
|
+
| Argument | Type | Required | Description |
|
|
405
|
+
|----------|------|----------|-------------|
|
|
406
|
+
| `target` | string | Yes | Path where the UUID will be stored |
|
|
407
|
+
| `version` | select | No | UUID version |
|
|
408
|
+
|
|
409
|
+
**Example:**
|
|
410
|
+
|
|
411
|
+
```typescript
|
|
412
|
+
{ op: 'uuid', args: {
|
|
413
|
+
"target": "targetField"
|
|
414
|
+
} }
|
|
415
|
+
```
|
|
416
|
+
|
|
417
|
+
### validateRequired
|
|
418
|
+
|
|
419
|
+
Mark records as invalid if required fields are missing.
|
|
420
|
+
|
|
421
|
+
| Argument | Type | Required | Description |
|
|
422
|
+
|----------|------|----------|-------------|
|
|
423
|
+
| `fields` | json | Yes | Required fields (JSON array) |
|
|
424
|
+
| `errorField` | string | No | Field to store validation errors |
|
|
425
|
+
|
|
426
|
+
**Example:**
|
|
427
|
+
|
|
428
|
+
```typescript
|
|
429
|
+
{ op: 'validateRequired', args: {
|
|
430
|
+
"fields": "value"
|
|
431
|
+
} }
|
|
432
|
+
```
|
|
433
|
+
|
|
434
|
+
### validateFormat
|
|
435
|
+
|
|
436
|
+
Validate field format using regex.
|
|
437
|
+
|
|
438
|
+
| Argument | Type | Required | Description |
|
|
439
|
+
|----------|------|----------|-------------|
|
|
440
|
+
| `field` | string | Yes | Field path |
|
|
441
|
+
| `pattern` | string | Yes | Regex pattern |
|
|
442
|
+
| `errorField` | string | No | Error output field |
|
|
443
|
+
| `errorMessage` | string | No | Error message |
|
|
444
|
+
|
|
445
|
+
**Example:**
|
|
446
|
+
|
|
447
|
+
```typescript
|
|
448
|
+
{ op: 'validateFormat', args: {
|
|
449
|
+
"field": "value",
|
|
450
|
+
"pattern": "value"
|
|
451
|
+
} }
|
|
452
|
+
```
|
|
453
|
+
|
|
454
|
+
## Date Operators
|
|
455
|
+
|
|
456
|
+
### dateFormat
|
|
457
|
+
|
|
458
|
+
Format a date field to a string.
|
|
459
|
+
|
|
460
|
+
| Argument | Type | Required | Description |
|
|
461
|
+
|----------|------|----------|-------------|
|
|
462
|
+
| `source` | string | Yes | Source field path |
|
|
463
|
+
| `target` | string | Yes | Target field path |
|
|
464
|
+
| `format` | string | Yes | e.g. YYYY-MM-DD, DD/MM/YYYY HH:mm |
|
|
465
|
+
| `inputFormat` | string | No | If source is string, specify its format |
|
|
466
|
+
| `timezone` | string | No | e.g. UTC, Europe/London |
|
|
467
|
+
|
|
468
|
+
**Example:**
|
|
469
|
+
|
|
470
|
+
```typescript
|
|
471
|
+
{ op: 'dateFormat', args: {
|
|
472
|
+
"source": "sourceField",
|
|
473
|
+
"target": "targetField",
|
|
474
|
+
"format": "value"
|
|
475
|
+
} }
|
|
476
|
+
```
|
|
477
|
+
|
|
478
|
+
### dateParse
|
|
479
|
+
|
|
480
|
+
Parse a string to a date.
|
|
481
|
+
|
|
482
|
+
| Argument | Type | Required | Description |
|
|
483
|
+
|----------|------|----------|-------------|
|
|
484
|
+
| `source` | string | Yes | Source field path |
|
|
485
|
+
| `target` | string | Yes | Target field path |
|
|
486
|
+
| `format` | string | Yes | Format of the source string |
|
|
487
|
+
| `timezone` | string | No | Timezone |
|
|
488
|
+
|
|
489
|
+
**Example:**
|
|
490
|
+
|
|
491
|
+
```typescript
|
|
492
|
+
{ op: 'dateParse', args: {
|
|
493
|
+
"source": "sourceField",
|
|
494
|
+
"target": "targetField",
|
|
495
|
+
"format": "value"
|
|
496
|
+
} }
|
|
497
|
+
```
|
|
498
|
+
|
|
499
|
+
### dateAdd
|
|
500
|
+
|
|
501
|
+
Add or subtract time from a date.
|
|
502
|
+
|
|
503
|
+
| Argument | Type | Required | Description |
|
|
504
|
+
|----------|------|----------|-------------|
|
|
505
|
+
| `source` | string | Yes | Source field path |
|
|
506
|
+
| `target` | string | Yes | Target field path |
|
|
507
|
+
| `amount` | number | Yes | Positive to add, negative to subtract |
|
|
508
|
+
| `unit` | select | Yes | Unit: `seconds`, `minutes`, `hours`, `days`, `weeks`, `months`, `years` |
|
|
509
|
+
|
|
510
|
+
> **Important:** Unit strings must be plural: `"days"`, `"hours"`, `"minutes"`, `"seconds"`, `"weeks"`, `"months"`, `"years"`. Singular forms like `"day"` are not supported.
|
|
511
|
+
|
|
512
|
+
**Example:**
|
|
513
|
+
|
|
514
|
+
```typescript
|
|
515
|
+
{ op: 'dateAdd', args: {
|
|
516
|
+
"source": "sourceField",
|
|
517
|
+
"target": "targetField",
|
|
518
|
+
"amount": 10,
|
|
519
|
+
"unit": "days"
|
|
520
|
+
} }
|
|
521
|
+
```
|
|
522
|
+
|
|
523
|
+
### dateDiff
|
|
524
|
+
|
|
525
|
+
Calculate the difference between two dates in a specified unit.
|
|
526
|
+
|
|
527
|
+
| Argument | Type | Required | Description |
|
|
528
|
+
|----------|------|----------|-------------|
|
|
529
|
+
| `startDate` | string | Yes | Start date field path |
|
|
530
|
+
| `endDate` | string | Yes | End date field path |
|
|
531
|
+
| `target` | string | Yes | Target field path |
|
|
532
|
+
| `unit` | select | Yes | Result unit: `seconds`, `minutes`, `hours`, `days`, `weeks`, `months`, `years` |
|
|
533
|
+
|
|
534
|
+
> **Important:** Unit strings must be plural: `"days"`, `"hours"`, `"minutes"`, `"seconds"`, `"weeks"`, `"months"`, `"years"`. Singular forms like `"day"` are not supported.
|
|
535
|
+
|
|
536
|
+
**Example:**
|
|
537
|
+
|
|
538
|
+
```typescript
|
|
539
|
+
{ op: 'dateDiff', args: {
|
|
540
|
+
"startDate": "startDateField",
|
|
541
|
+
"endDate": "endDateField",
|
|
542
|
+
"target": "targetField",
|
|
543
|
+
"unit": "days"
|
|
544
|
+
} }
|
|
545
|
+
```
|
|
546
|
+
|
|
547
|
+
### now
|
|
548
|
+
|
|
549
|
+
Set the current timestamp on a field. Useful for adding created/updated timestamps.
|
|
550
|
+
|
|
551
|
+
| Argument | Type | Required | Description |
|
|
552
|
+
|----------|------|----------|-------------|
|
|
553
|
+
| `target` | string | Yes | Target field path |
|
|
554
|
+
| `format` | select | No | Output format |
|
|
555
|
+
|
|
556
|
+
**Example:**
|
|
557
|
+
|
|
558
|
+
```typescript
|
|
559
|
+
{ op: 'now', args: {
|
|
560
|
+
"target": "targetField"
|
|
561
|
+
} }
|
|
562
|
+
```
|
|
563
|
+
|
|
564
|
+
## Enrichment Operators
|
|
565
|
+
|
|
566
|
+
### lookup
|
|
567
|
+
|
|
568
|
+
Lookup value from a map and set to target field.
|
|
569
|
+
|
|
570
|
+
| Argument | Type | Required | Description |
|
|
571
|
+
|----------|------|----------|-------------|
|
|
572
|
+
| `source` | string | Yes | Source field path |
|
|
573
|
+
| `map` | json | Yes | Map (JSON object) |
|
|
574
|
+
| `target` | string | Yes | Target field path |
|
|
575
|
+
| `default` | string | No | Default value |
|
|
576
|
+
|
|
577
|
+
**Example:**
|
|
578
|
+
|
|
579
|
+
```typescript
|
|
580
|
+
{ op: 'lookup', args: {
|
|
581
|
+
"source": "sourceField",
|
|
582
|
+
"map": "value",
|
|
583
|
+
"target": "targetField"
|
|
584
|
+
} }
|
|
585
|
+
```
|
|
586
|
+
|
|
587
|
+
### coalesce
|
|
588
|
+
|
|
589
|
+
Return the first non-null value from a list of field paths.
|
|
590
|
+
|
|
591
|
+
| Argument | Type | Required | Description |
|
|
592
|
+
|----------|------|----------|-------------|
|
|
593
|
+
| `paths` | json | Yes | Array of paths to check in order |
|
|
594
|
+
| `target` | string | Yes | Target field path |
|
|
595
|
+
| `default` | json | No | Value if all paths are null |
|
|
596
|
+
|
|
597
|
+
**Example:**
|
|
598
|
+
|
|
599
|
+
```typescript
|
|
600
|
+
{ op: 'coalesce', args: {
|
|
601
|
+
"paths": "value",
|
|
602
|
+
"target": "targetField"
|
|
603
|
+
} }
|
|
604
|
+
```
|
|
605
|
+
|
|
606
|
+
### enrich
|
|
607
|
+
|
|
608
|
+
Enrich or default fields on records.
|
|
609
|
+
|
|
610
|
+
| Argument | Type | Required | Description |
|
|
611
|
+
|----------|------|----------|-------------|
|
|
612
|
+
| `set` | json | No | JSON object of fields to set (dot paths allowed) |
|
|
613
|
+
| `defaults` | json | No | JSON object of fields to set if currently missing (dot paths allowed) |
|
|
614
|
+
|
|
615
|
+
**Example:**
|
|
616
|
+
|
|
617
|
+
```typescript
|
|
618
|
+
{ op: 'enrich', args: {} }
|
|
619
|
+
```
|
|
620
|
+
|
|
621
|
+
### default
|
|
622
|
+
|
|
623
|
+
Set a default value if field is null or undefined.
|
|
624
|
+
|
|
625
|
+
| Argument | Type | Required | Description |
|
|
626
|
+
|----------|------|----------|-------------|
|
|
627
|
+
| `path` | string | Yes | Field path |
|
|
628
|
+
| `value` | json | Yes | Default value (JSON) |
|
|
629
|
+
|
|
630
|
+
**Example:**
|
|
631
|
+
|
|
632
|
+
```typescript
|
|
633
|
+
{ op: 'default', args: {
|
|
634
|
+
"path": "sourceField",
|
|
635
|
+
"value": "value"
|
|
636
|
+
} }
|
|
637
|
+
```
|
|
638
|
+
|
|
639
|
+
### httpLookup
|
|
640
|
+
|
|
641
|
+
Enrich records by fetching data from external HTTP endpoints with caching, authentication, and error handling.
|
|
642
|
+
|
|
643
|
+
| Argument | Type | Required | Description |
|
|
644
|
+
|----------|------|----------|-------------|
|
|
645
|
+
| `url` | string | Yes | HTTP endpoint URL. Use {{field}} for dynamic values. |
|
|
646
|
+
| `method` | select | No | HTTP Method |
|
|
647
|
+
| `target` | string | Yes | Field path to store the response data. |
|
|
648
|
+
| `responsePath` | string | No | JSON path to extract from response (optional). |
|
|
649
|
+
| `keyField` | string | No | Field to use as cache key. If not set, URL is used. |
|
|
650
|
+
| `default` | json | No | Value to use if lookup fails or returns 404. |
|
|
651
|
+
| `timeoutMs` | number | No | Request timeout in milliseconds. |
|
|
652
|
+
| `cacheTtlSec` | number | No | Cache time-to-live in seconds. Set to 0 to disable. |
|
|
653
|
+
| `headers` | json | No | Static HTTP headers as JSON object. |
|
|
654
|
+
| `bearerTokenSecretCode` | string | No | Secret code for Bearer token authentication. |
|
|
655
|
+
| `apiKeySecretCode` | string | No | Secret code for API key authentication. |
|
|
656
|
+
| `apiKeyHeader` | string | No | Header name for API key. |
|
|
657
|
+
| `basicAuthSecretCode` | string | No | Secret code for Basic auth (username:password). |
|
|
658
|
+
| `bodyField` | string | No | Field path for POST body (uses record value at this path). |
|
|
659
|
+
| `body` | json | No | Static POST body (JSON object). |
|
|
660
|
+
| `skipOn404` | boolean | No | Skip record if endpoint returns 404. |
|
|
661
|
+
| `failOnError` | boolean | No | Fail pipeline if HTTP request fails. |
|
|
662
|
+
| `maxRetries` | number | No | Maximum retry attempts on transient errors. |
|
|
663
|
+
| `batchSize` | number | No | Process this many records in parallel (default: 50). |
|
|
664
|
+
| `rateLimitPerSecond` | number | No | Max requests per second per domain (default: 100). |
|
|
665
|
+
|
|
666
|
+
**Example:**
|
|
667
|
+
|
|
668
|
+
```typescript
|
|
669
|
+
{ op: 'httpLookup', args: {
|
|
670
|
+
"url": "value",
|
|
671
|
+
"target": "targetField"
|
|
672
|
+
} }
|
|
673
|
+
```
|
|
674
|
+
|
|
675
|
+
## JSON Operators
|
|
676
|
+
|
|
677
|
+
### parseJson
|
|
678
|
+
|
|
679
|
+
Parse a JSON string field into an object.
|
|
680
|
+
|
|
681
|
+
| Argument | Type | Required | Description |
|
|
682
|
+
|----------|------|----------|-------------|
|
|
683
|
+
| `source` | string | Yes | Source field path |
|
|
684
|
+
| `target` | string | No | Defaults to source if not set |
|
|
685
|
+
|
|
686
|
+
**Example:**
|
|
687
|
+
|
|
688
|
+
```typescript
|
|
689
|
+
{ op: 'parseJson', args: {
|
|
690
|
+
"source": "sourceField"
|
|
691
|
+
} }
|
|
692
|
+
```
|
|
693
|
+
|
|
694
|
+
### stringifyJson
|
|
695
|
+
|
|
696
|
+
Stringify an object field to a JSON string.
|
|
697
|
+
|
|
698
|
+
| Argument | Type | Required | Description |
|
|
699
|
+
|----------|------|----------|-------------|
|
|
700
|
+
| `source` | string | Yes | Source field path |
|
|
701
|
+
| `target` | string | No | Defaults to source if not set |
|
|
702
|
+
| `pretty` | boolean | No | Pretty print |
|
|
703
|
+
|
|
704
|
+
**Example:**
|
|
705
|
+
|
|
706
|
+
```typescript
|
|
707
|
+
{ op: 'stringifyJson', args: {
|
|
708
|
+
"source": "sourceField"
|
|
709
|
+
} }
|
|
710
|
+
```
|
|
711
|
+
|
|
712
|
+
### pick
|
|
713
|
+
|
|
714
|
+
Pick specific fields from a record, discarding others.
|
|
715
|
+
|
|
716
|
+
| Argument | Type | Required | Description |
|
|
717
|
+
|----------|------|----------|-------------|
|
|
718
|
+
| `fields` | json | Yes | Array of field paths to keep |
|
|
719
|
+
|
|
720
|
+
**Example:**
|
|
721
|
+
|
|
722
|
+
```typescript
|
|
723
|
+
{ op: 'pick', args: {
|
|
724
|
+
"fields": "value"
|
|
725
|
+
} }
|
|
726
|
+
```
|
|
727
|
+
|
|
728
|
+
### omit
|
|
729
|
+
|
|
730
|
+
Omit specific fields from a record.
|
|
731
|
+
|
|
732
|
+
| Argument | Type | Required | Description |
|
|
733
|
+
|----------|------|----------|-------------|
|
|
734
|
+
| `fields` | json | Yes | Array of field paths to remove |
|
|
735
|
+
|
|
736
|
+
**Example:**
|
|
737
|
+
|
|
738
|
+
```typescript
|
|
739
|
+
{ op: 'omit', args: {
|
|
740
|
+
"fields": "value"
|
|
741
|
+
} }
|
|
742
|
+
```
|
|
743
|
+
|
|
744
|
+
## Logic Operators
|
|
745
|
+
|
|
746
|
+
### when
|
|
747
|
+
|
|
748
|
+
Filter records by conditions. Action: keep or drop.
|
|
749
|
+
|
|
750
|
+
| Argument | Type | Required | Description |
|
|
751
|
+
|----------|------|----------|-------------|
|
|
752
|
+
| `conditions` | json | Yes | e.g. [{ field: |
|
|
753
|
+
|
|
754
|
+
**Example:**
|
|
755
|
+
|
|
756
|
+
```typescript
|
|
757
|
+
{ op: 'when', args: {
|
|
758
|
+
"conditions": "value"
|
|
759
|
+
} }
|
|
760
|
+
```
|
|
761
|
+
|
|
762
|
+
### ifThenElse
|
|
763
|
+
|
|
764
|
+
Set a value based on a condition.
|
|
765
|
+
|
|
766
|
+
| Argument | Type | Required | Description |
|
|
767
|
+
|----------|------|----------|-------------|
|
|
768
|
+
| `condition` | json | Yes | e.g. { field: |
|
|
769
|
+
| `thenValue` | json | Yes | Then value (JSON) |
|
|
770
|
+
| `elseValue` | json | No | Else value (JSON) |
|
|
771
|
+
| `target` | string | Yes | Target field path |
|
|
772
|
+
|
|
773
|
+
**Example:**
|
|
774
|
+
|
|
775
|
+
```typescript
|
|
776
|
+
{ op: 'ifThenElse', args: {
|
|
777
|
+
"condition": "value",
|
|
778
|
+
"thenValue": "value",
|
|
779
|
+
"target": "targetField"
|
|
780
|
+
} }
|
|
781
|
+
```
|
|
782
|
+
|
|
783
|
+
### switch
|
|
784
|
+
|
|
785
|
+
Set a value based on multiple conditions (like a switch statement).
|
|
786
|
+
|
|
787
|
+
| Argument | Type | Required | Description |
|
|
788
|
+
|----------|------|----------|-------------|
|
|
789
|
+
| `source` | string | Yes | Source field path |
|
|
790
|
+
| `cases` | json | Yes | Array of { value, result } objects |
|
|
791
|
+
| `default` | json | No | Default value (JSON) |
|
|
792
|
+
| `target` | string | Yes | Target field path |
|
|
793
|
+
|
|
794
|
+
**Example:**
|
|
795
|
+
|
|
796
|
+
```typescript
|
|
797
|
+
{ op: 'switch', args: {
|
|
798
|
+
"source": "sourceField",
|
|
799
|
+
"cases": "value",
|
|
800
|
+
"target": "targetField"
|
|
801
|
+
} }
|
|
802
|
+
```
|
|
803
|
+
|
|
804
|
+
### deltaFilter
|
|
805
|
+
|
|
806
|
+
Filter out unchanged records using a stable hash stored in checkpoint. Keeps only changed/new based on idPath.
|
|
807
|
+
|
|
808
|
+
| Argument | Type | Required | Description |
|
|
809
|
+
|----------|------|----------|-------------|
|
|
810
|
+
| `idPath` | string | Yes | ID field path |
|
|
811
|
+
| `includePaths` | json | No | Subset of fields to hash; default is entire record |
|
|
812
|
+
| `excludePaths` | json | No | Fields to ignore when hashing |
|
|
813
|
+
|
|
814
|
+
**Example:**
|
|
815
|
+
|
|
816
|
+
```typescript
|
|
817
|
+
{ op: 'deltaFilter', args: {
|
|
818
|
+
"idPath": "value"
|
|
819
|
+
} }
|
|
820
|
+
```
|
|
821
|
+
|
|
822
|
+
## Numeric Operators
|
|
823
|
+
|
|
824
|
+
### math
|
|
825
|
+
|
|
826
|
+
Perform math operations on numeric fields.
|
|
827
|
+
|
|
828
|
+
| Argument | Type | Required | Description |
|
|
829
|
+
|----------|------|----------|-------------|
|
|
830
|
+
| `operation` | select | Yes | Operation |
|
|
831
|
+
|
|
832
|
+
**Example:**
|
|
833
|
+
|
|
834
|
+
```typescript
|
|
835
|
+
{ op: 'math', args: {
|
|
836
|
+
"operation": "value"
|
|
837
|
+
} }
|
|
838
|
+
```
|
|
839
|
+
|
|
840
|
+
### currency
|
|
841
|
+
|
|
842
|
+
Convert floats to minor units or re-map currency fields.
|
|
843
|
+
|
|
844
|
+
| Argument | Type | Required | Description |
|
|
845
|
+
|----------|------|----------|-------------|
|
|
846
|
+
| `source` | string | Yes | Source field path |
|
|
847
|
+
| `target` | string | Yes | Target field path |
|
|
848
|
+
| `decimals` | number | Yes | Decimals (e.g. 2) |
|
|
849
|
+
| `round` | select | No | Rounding |
|
|
850
|
+
|
|
851
|
+
**Example:**
|
|
852
|
+
|
|
853
|
+
```typescript
|
|
854
|
+
{ op: 'currency', args: {
|
|
855
|
+
"source": "sourceField",
|
|
856
|
+
"target": "targetField",
|
|
857
|
+
"decimals": 10
|
|
858
|
+
} }
|
|
859
|
+
```
|
|
860
|
+
|
|
861
|
+
### unit
|
|
862
|
+
|
|
863
|
+
Convert units (e.g. g<->kg, cm<->m)
|
|
864
|
+
|
|
865
|
+
| Argument | Type | Required | Description |
|
|
866
|
+
|----------|------|----------|-------------|
|
|
867
|
+
| `source` | string | Yes | Source field path |
|
|
868
|
+
| `target` | string | Yes | Target field path |
|
|
869
|
+
| `from` | select | Yes | From unit |
|
|
870
|
+
|
|
871
|
+
**Example:**
|
|
872
|
+
|
|
873
|
+
```typescript
|
|
874
|
+
{ op: 'unit', args: {
|
|
875
|
+
"source": "sourceField",
|
|
876
|
+
"target": "targetField",
|
|
877
|
+
"from": "value"
|
|
878
|
+
} }
|
|
879
|
+
```
|
|
880
|
+
|
|
881
|
+
### toNumber
|
|
882
|
+
|
|
883
|
+
Convert a string field to a number.
|
|
884
|
+
|
|
885
|
+
| Argument | Type | Required | Description |
|
|
886
|
+
|----------|------|----------|-------------|
|
|
887
|
+
| `source` | string | Yes | Source field path |
|
|
888
|
+
| `target` | string | No | Target field path |
|
|
889
|
+
| `default` | number | No | Value if conversion fails |
|
|
890
|
+
|
|
891
|
+
**Example:**
|
|
892
|
+
|
|
893
|
+
```typescript
|
|
894
|
+
{ op: 'toNumber', args: {
|
|
895
|
+
"source": "sourceField"
|
|
896
|
+
} }
|
|
897
|
+
```
|
|
898
|
+
|
|
899
|
+
### toString
|
|
900
|
+
|
|
901
|
+
Convert a value to a string.
|
|
902
|
+
|
|
903
|
+
| Argument | Type | Required | Description |
|
|
904
|
+
|----------|------|----------|-------------|
|
|
905
|
+
| `source` | string | Yes | Source field path |
|
|
906
|
+
| `target` | string | No | Target field path |
|
|
907
|
+
|
|
908
|
+
**Example:**
|
|
909
|
+
|
|
910
|
+
```typescript
|
|
911
|
+
{ op: 'toString', args: {
|
|
912
|
+
"source": "sourceField"
|
|
913
|
+
} }
|
|
914
|
+
```
|
|
915
|
+
|
|
916
|
+
### parseNumber
|
|
917
|
+
|
|
918
|
+
Parse a string to a number with locale-aware decimal/thousand separator handling.
|
|
919
|
+
|
|
920
|
+
| Argument | Type | Required | Description |
|
|
921
|
+
|----------|------|----------|-------------|
|
|
922
|
+
| `source` | string | Yes | Source field path |
|
|
923
|
+
| `target` | string | No | Defaults to source path |
|
|
924
|
+
| `locale` | string | No | e.g., |
|
|
925
|
+
| `default` | number | No | Value if parsing fails |
|
|
926
|
+
|
|
927
|
+
**Example:**
|
|
928
|
+
|
|
929
|
+
```typescript
|
|
930
|
+
{ op: 'parseNumber', args: {
|
|
931
|
+
"source": "sourceField"
|
|
932
|
+
} }
|
|
933
|
+
```
|
|
934
|
+
|
|
935
|
+
### formatNumber
|
|
936
|
+
|
|
937
|
+
Format a number as a localized string with optional currency or percent formatting.
|
|
938
|
+
|
|
939
|
+
| Argument | Type | Required | Description |
|
|
940
|
+
|----------|------|----------|-------------|
|
|
941
|
+
| `source` | string | Yes | Source field path |
|
|
942
|
+
| `target` | string | Yes | Target field path |
|
|
943
|
+
| `locale` | string | No | e.g., |
|
|
944
|
+
| `decimals` | number | No | Decimal places |
|
|
945
|
+
| `style` | select | No | Format style |
|
|
946
|
+
|
|
947
|
+
**Example:**
|
|
948
|
+
|
|
949
|
+
```typescript
|
|
950
|
+
{ op: 'formatNumber', args: {
|
|
951
|
+
"source": "sourceField",
|
|
952
|
+
"target": "targetField"
|
|
953
|
+
} }
|
|
954
|
+
```
|
|
955
|
+
|
|
956
|
+
### toCents
|
|
957
|
+
|
|
958
|
+
Convert a decimal amount to cents (minor currency units). Multiplies by 100 and rounds.
|
|
959
|
+
|
|
960
|
+
| Argument | Type | Required | Description |
|
|
961
|
+
|----------|------|----------|-------------|
|
|
962
|
+
| `source` | string | Yes | Field containing decimal amount (e.g., 19.99) |
|
|
963
|
+
| `target` | string | Yes | Field for cents amount (e.g., 1999) |
|
|
964
|
+
| `round` | select | No | Rounding |
|
|
965
|
+
|
|
966
|
+
**Example:**
|
|
967
|
+
|
|
968
|
+
```typescript
|
|
969
|
+
{ op: 'toCents', args: {
|
|
970
|
+
"source": "sourceField",
|
|
971
|
+
"target": "targetField"
|
|
972
|
+
} }
|
|
973
|
+
```
|
|
974
|
+
|
|
975
|
+
### round
|
|
976
|
+
|
|
977
|
+
Round a number to a specified number of decimal places.
|
|
978
|
+
|
|
979
|
+
| Argument | Type | Required | Description |
|
|
980
|
+
|----------|------|----------|-------------|
|
|
981
|
+
| `source` | string | Yes | Source field path |
|
|
982
|
+
| `target` | string | No | Defaults to source if not set |
|
|
983
|
+
| `decimals` | number | No | Default: 0 (round to integer) |
|
|
984
|
+
| `mode` | select | No | Rounding mode |
|
|
985
|
+
|
|
986
|
+
**Example:**
|
|
987
|
+
|
|
988
|
+
```typescript
|
|
989
|
+
{ op: 'round', args: {
|
|
990
|
+
"source": "sourceField"
|
|
991
|
+
} }
|
|
992
|
+
```
|
|
993
|
+
|
|
994
|
+
## String Operators
|
|
995
|
+
|
|
996
|
+
### split
|
|
997
|
+
|
|
998
|
+
Split a string field into an array by delimiter.
|
|
999
|
+
|
|
1000
|
+
| Argument | Type | Required | Description |
|
|
1001
|
+
|----------|------|----------|-------------|
|
|
1002
|
+
| `source` | string | Yes | Source field path |
|
|
1003
|
+
| `target` | string | Yes | Target field path |
|
|
1004
|
+
| `delimiter` | string | Yes | Character(s) to split by |
|
|
1005
|
+
| `trim` | boolean | No | Trim whitespace from each item |
|
|
1006
|
+
|
|
1007
|
+
**Example:**
|
|
1008
|
+
|
|
1009
|
+
```typescript
|
|
1010
|
+
{ op: 'split', args: {
|
|
1011
|
+
"source": "sourceField",
|
|
1012
|
+
"target": "targetField",
|
|
1013
|
+
"delimiter": "value"
|
|
1014
|
+
} }
|
|
1015
|
+
```
|
|
1016
|
+
|
|
1017
|
+
### join
|
|
1018
|
+
|
|
1019
|
+
Join an array field into a string.
|
|
1020
|
+
|
|
1021
|
+
| Argument | Type | Required | Description |
|
|
1022
|
+
|----------|------|----------|-------------|
|
|
1023
|
+
| `source` | string | Yes | Source field path |
|
|
1024
|
+
| `target` | string | Yes | Target field path |
|
|
1025
|
+
| `delimiter` | string | Yes | Character(s) to join with |
|
|
1026
|
+
|
|
1027
|
+
**Example:**
|
|
1028
|
+
|
|
1029
|
+
```typescript
|
|
1030
|
+
{ op: 'join', args: {
|
|
1031
|
+
"source": "sourceField",
|
|
1032
|
+
"target": "targetField",
|
|
1033
|
+
"delimiter": "value"
|
|
1034
|
+
} }
|
|
1035
|
+
```
|
|
1036
|
+
|
|
1037
|
+
### trim
|
|
1038
|
+
|
|
1039
|
+
Trim whitespace from a string field.
|
|
1040
|
+
|
|
1041
|
+
| Argument | Type | Required | Description |
|
|
1042
|
+
|----------|------|----------|-------------|
|
|
1043
|
+
| `path` | string | Yes | Field path |
|
|
1044
|
+
| `mode` | select | No | Mode |
|
|
1045
|
+
|
|
1046
|
+
**Example:**
|
|
1047
|
+
|
|
1048
|
+
```typescript
|
|
1049
|
+
{ op: 'trim', args: {
|
|
1050
|
+
"path": "sourceField"
|
|
1051
|
+
} }
|
|
1052
|
+
```
|
|
1053
|
+
|
|
1054
|
+
### lowercase
|
|
1055
|
+
|
|
1056
|
+
Convert a string field to lowercase.
|
|
1057
|
+
|
|
1058
|
+
| Argument | Type | Required | Description |
|
|
1059
|
+
|----------|------|----------|-------------|
|
|
1060
|
+
| `path` | string | Yes | Field path |
|
|
1061
|
+
|
|
1062
|
+
**Example:**
|
|
1063
|
+
|
|
1064
|
+
```typescript
|
|
1065
|
+
{ op: 'lowercase', args: {
|
|
1066
|
+
"path": "sourceField"
|
|
1067
|
+
} }
|
|
1068
|
+
```
|
|
1069
|
+
|
|
1070
|
+
### uppercase
|
|
1071
|
+
|
|
1072
|
+
Convert a string field to uppercase.
|
|
1073
|
+
|
|
1074
|
+
| Argument | Type | Required | Description |
|
|
1075
|
+
|----------|------|----------|-------------|
|
|
1076
|
+
| `path` | string | Yes | Field path |
|
|
1077
|
+
|
|
1078
|
+
**Example:**
|
|
1079
|
+
|
|
1080
|
+
```typescript
|
|
1081
|
+
{ op: 'uppercase', args: {
|
|
1082
|
+
"path": "sourceField"
|
|
1083
|
+
} }
|
|
1084
|
+
```
|
|
1085
|
+
|
|
1086
|
+
### slugify
|
|
1087
|
+
|
|
1088
|
+
Generate a URL-friendly slug from a string field.
|
|
1089
|
+
|
|
1090
|
+
| Argument | Type | Required | Description |
|
|
1091
|
+
|----------|------|----------|-------------|
|
|
1092
|
+
| `source` | string | Yes | Source field path |
|
|
1093
|
+
| `target` | string | Yes | Target field path |
|
|
1094
|
+
| `separator` | string | No | Default: hyphen (-) |
|
|
1095
|
+
|
|
1096
|
+
**Example:**
|
|
1097
|
+
|
|
1098
|
+
```typescript
|
|
1099
|
+
{ op: 'slugify', args: {
|
|
1100
|
+
"source": "sourceField",
|
|
1101
|
+
"target": "targetField"
|
|
1102
|
+
} }
|
|
1103
|
+
```
|
|
1104
|
+
|
|
1105
|
+
### concat
|
|
1106
|
+
|
|
1107
|
+
Concatenate multiple string fields into one.
|
|
1108
|
+
|
|
1109
|
+
| Argument | Type | Required | Description |
|
|
1110
|
+
|----------|------|----------|-------------|
|
|
1111
|
+
| `sources` | json | Yes | Array of field paths to concatenate |
|
|
1112
|
+
| `target` | string | Yes | Target field path |
|
|
1113
|
+
| `separator` | string | No | Optional separator between values |
|
|
1114
|
+
|
|
1115
|
+
**Example:**
|
|
1116
|
+
|
|
1117
|
+
```typescript
|
|
1118
|
+
{ op: 'concat', args: {
|
|
1119
|
+
"sources": "value",
|
|
1120
|
+
"target": "targetField"
|
|
1121
|
+
} }
|
|
1122
|
+
```
|
|
1123
|
+
|
|
1124
|
+
### replace
|
|
1125
|
+
|
|
1126
|
+
Replace text in a string field.
|
|
1127
|
+
|
|
1128
|
+
| Argument | Type | Required | Description |
|
|
1129
|
+
|----------|------|----------|-------------|
|
|
1130
|
+
| `path` | string | Yes | Field path |
|
|
1131
|
+
| `search` | string | Yes | Search text |
|
|
1132
|
+
| `replacement` | string | Yes | Replacement |
|
|
1133
|
+
| `all` | boolean | No | Replace all occurrences |
|
|
1134
|
+
|
|
1135
|
+
**Example:**
|
|
1136
|
+
|
|
1137
|
+
```typescript
|
|
1138
|
+
{ op: 'replace', args: {
|
|
1139
|
+
"path": "sourceField",
|
|
1140
|
+
"search": "value",
|
|
1141
|
+
"replacement": "value"
|
|
1142
|
+
} }
|
|
1143
|
+
```
|
|
1144
|
+
|
|
1145
|
+
### extractRegex
|
|
1146
|
+
|
|
1147
|
+
Extract a value from a string field using a regular expression pattern with capture groups.
|
|
1148
|
+
|
|
1149
|
+
| Argument | Type | Required | Description |
|
|
1150
|
+
|----------|------|----------|-------------|
|
|
1151
|
+
| `source` | string | Yes | Source field path |
|
|
1152
|
+
| `target` | string | Yes | Target field path |
|
|
1153
|
+
| `pattern` | string | Yes | Regular expression pattern (without delimiters) |
|
|
1154
|
+
| `group` | number | No | Group index to extract (0=full match, 1+=capture groups). Default: 1 |
|
|
1155
|
+
| `flags` | string | No | e.g., |
|
|
1156
|
+
|
|
1157
|
+
**Example:**
|
|
1158
|
+
|
|
1159
|
+
```typescript
|
|
1160
|
+
{ op: 'extractRegex', args: {
|
|
1161
|
+
"source": "sourceField",
|
|
1162
|
+
"target": "targetField",
|
|
1163
|
+
"pattern": "value"
|
|
1164
|
+
} }
|
|
1165
|
+
```
|
|
1166
|
+
|
|
1167
|
+
### replaceRegex
|
|
1168
|
+
|
|
1169
|
+
Replace values in a string field using a regular expression pattern.
|
|
1170
|
+
|
|
1171
|
+
| Argument | Type | Required | Description |
|
|
1172
|
+
|----------|------|----------|-------------|
|
|
1173
|
+
| `path` | string | Yes | Field path |
|
|
1174
|
+
| `pattern` | string | Yes | Regular expression pattern (without delimiters) |
|
|
1175
|
+
| `replacement` | string | Yes | Replacement string (use $1, $2 for capture groups) |
|
|
1176
|
+
| `flags` | string | No | e.g., |
|
|
1177
|
+
|
|
1178
|
+
**Example:**
|
|
1179
|
+
|
|
1180
|
+
```typescript
|
|
1181
|
+
{ op: 'replaceRegex', args: {
|
|
1182
|
+
"path": "sourceField",
|
|
1183
|
+
"pattern": "value",
|
|
1184
|
+
"replacement": "value"
|
|
1185
|
+
} }
|
|
1186
|
+
```
|
|
1187
|
+
|
|
1188
|
+
### stripHtml
|
|
1189
|
+
|
|
1190
|
+
Remove HTML tags from a string field, preserving text content.
|
|
1191
|
+
|
|
1192
|
+
| Argument | Type | Required | Description |
|
|
1193
|
+
|----------|------|----------|-------------|
|
|
1194
|
+
| `source` | string | Yes | Source field path |
|
|
1195
|
+
| `target` | string | No | Defaults to source if not set |
|
|
1196
|
+
|
|
1197
|
+
**Example:**
|
|
1198
|
+
|
|
1199
|
+
```typescript
|
|
1200
|
+
{ op: 'stripHtml', args: {
|
|
1201
|
+
"source": "sourceField"
|
|
1202
|
+
} }
|
|
1203
|
+
```
|
|
1204
|
+
|
|
1205
|
+
### truncate
|
|
1206
|
+
|
|
1207
|
+
Truncate a string to a maximum length, optionally adding a suffix.
|
|
1208
|
+
|
|
1209
|
+
| Argument | Type | Required | Description |
|
|
1210
|
+
|----------|------|----------|-------------|
|
|
1211
|
+
| `source` | string | Yes | Source field path |
|
|
1212
|
+
| `target` | string | No | Defaults to source if not set |
|
|
1213
|
+
| `length` | number | Yes | Maximum length |
|
|
1214
|
+
| `suffix` | string | No | e.g., |
|
|
1215
|
+
|
|
1216
|
+
**Example:**
|
|
1217
|
+
|
|
1218
|
+
```typescript
|
|
1219
|
+
{ op: 'truncate', args: {
|
|
1220
|
+
"source": "sourceField",
|
|
1221
|
+
"length": 10
|
|
1222
|
+
} }
|
|
1223
|
+
```
|
|
1224
|
+
|
|
1225
|
+
## Scripting Operators
|
|
1226
|
+
|
|
1227
|
+
### script
|
|
1228
|
+
|
|
1229
|
+
Execute inline JavaScript code to transform records. Use for complex logic that cannot be expressed with standard operators.
|
|
1230
|
+
|
|
1231
|
+
| Argument | Type | Required | Description |
|
|
1232
|
+
|----------|------|----------|-------------|
|
|
1233
|
+
| `code` | code | Yes | JavaScript code to execute. In single-record mode: receives `record`, `index`, `context`. In batch mode: receives `records`, `context`. Must return the transformed result. |
|
|
1234
|
+
| `batch` | boolean | No | If true, processes all records at once. If false (default), processes one record at a time. |
|
|
1235
|
+
| `timeout` | number | No | Maximum execution time in milliseconds (default: 5000) |
|
|
1236
|
+
| `failOnError` | boolean | No | If true, errors fail the entire step. If false, errors are logged and records skipped. |
|
|
1237
|
+
| `context` | json | No | Optional JSON data passed to the script as context.data |
|
|
1238
|
+
|
|
1239
|
+
**Example:**
|
|
1240
|
+
|
|
1241
|
+
```typescript
|
|
1242
|
+
{ op: 'script', args: {
|
|
1243
|
+
"code": "value"
|
|
1244
|
+
} }
|
|
1245
|
+
```
|
|
1246
|
+
|
|
1247
|
+
---
|
|
1248
|
+
|
|
1249
|
+
## Custom Operators
|
|
1250
|
+
|
|
1251
|
+
You can register custom operators using the SDK. See [Custom Operators Guide](../guides/custom-operators.md) for details.
|