@beehexa/hexasync-ai-toolkit 2611.8.3 → 2612.3.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/.claude-plugin/marketplace.json +2 -2
- package/.claude-plugin/plugin.json +2 -2
- package/.codex-plugin/plugin.json +3 -4
- package/.cursor-plugin/plugin.json +3 -4
- package/README.md +5 -74
- package/dist/cli.js +15 -2070
- package/gemini-extension.json +2 -11
- package/openclaw.extension.mjs +2 -3
- package/openclaw.plugin.json +2 -2
- package/package.json +3 -4
- package/plugin.json +3 -4
- package/skills/hexasync-connections/SKILL.md +11 -16
- package/skills/hexasync-connections/references/INDEX.md +20 -2
- package/skills/hexasync-connections/references/INSTALL.md +5 -48
- package/skills/hexasync-connections/references/connections.CONNECTIONS.api-recovery.md +1 -1
- package/skills/hexasync-connections/references/connections.CONNECTIONS.captured-call-and-authenticated-composition.md +2 -2
- package/skills/hexasync-connections/references/connections.CONNECTIONS.framework-understood-connection-option-catalogue.md +2 -2
- package/skills/hexasync-connections/references/connections.CONNECTIONS.how-a-step-finds-its-connection.md +2 -2
- package/skills/hexasync-connections/references/connections.CONNECTIONS.md +1 -1
- package/skills/hexasync-connections/references/connections.CONNECTIONS.one-connection-one-credential-scope.md +2 -2
- package/skills/hexasync-connections/references/connections.CONNECTIONS.related.md +5 -5
- package/skills/hexasync-connections/references/connections.CONNECTIONS.the-self-connector.md +1 -1
- package/skills/hexasync-connections/references/frontend.FRONTEND-FLOWS.api_proxy.md +94 -0
- package/skills/hexasync-connections/references/frontend.FRONTEND-FLOWS.expressions-and-tooling.md +35 -0
- package/skills/hexasync-connections/references/frontend.FRONTEND-FLOWS.fail.md +48 -0
- package/skills/hexasync-connections/references/frontend.FRONTEND-FLOWS.frontend-step-fields.md +83 -0
- package/skills/hexasync-connections/references/frontend.FRONTEND-FLOWS.grouped-readiness-flows.md +54 -0
- package/skills/hexasync-connections/references/frontend.FRONTEND-FLOWS.md +16 -0
- package/skills/hexasync-connections/references/frontend.FRONTEND-FLOWS.preview-and-source-navigation.md +26 -0
- package/skills/hexasync-connections/references/frontend.FRONTEND-FLOWS.records_form.file-import-path.md +208 -0
- package/skills/hexasync-connections/references/frontend.FRONTEND-FLOWS.records_form.md +42 -0
- package/skills/hexasync-connections/references/frontend.FRONTEND-FLOWS.records_form.records_form-change-set-path.md +208 -0
- package/skills/hexasync-connections/references/frontend.FRONTEND-FLOWS.rejected-forms-non-copyable.md +23 -0
- package/skills/hexasync-connections/references/frontend.FRONTEND-FLOWS.return.md +84 -0
- package/skills/hexasync-connections/references/frontend.FRONTEND-FLOWS.task-and-reference-data-changes.md +92 -0
- package/skills/hexasync-error-handling/SKILL.md +9 -16
- package/skills/hexasync-error-handling/references/INDEX.md +1 -1
- package/skills/hexasync-error-handling/references/INSTALL.md +5 -48
- package/skills/hexasync-error-handling/references/routing.NEXT.md +10 -10
- package/skills/hexasync-error-handling/references/steps.EXCEPTION.md +5 -5
- package/skills/hexasync-error-handling/references/steps.Error.md +8 -8
- package/skills/hexasync-expressions/SKILL.md +10 -24
- package/skills/hexasync-expressions/references/INDEX.md +8 -3
- package/skills/hexasync-expressions/references/INSTALL.md +5 -48
- package/skills/hexasync-expressions/references/expressions.CONTEXT-AND-IO.arguments--computed-before-the-step-runs.md +1 -1
- package/skills/hexasync-expressions/references/expressions.CONTEXT-AND-IO.dialect-classification-and-silent-scriban-fallback.md +2 -2
- package/skills/hexasync-expressions/references/expressions.CONTEXT-AND-IO.exact-mutation-timeline.md +4 -4
- package/skills/hexasync-expressions/references/expressions.CONTEXT-AND-IO.executor-results-are-not-downstream-values.md +2 -2
- package/skills/hexasync-expressions/references/expressions.CONTEXT-AND-IO.graceful-failures-and-run-errors.md +1 -1
- package/skills/hexasync-expressions/references/expressions.CONTEXT-AND-IO.jsonata-call-site-scope-and-bindings.md +17 -17
- package/skills/hexasync-expressions/references/expressions.CONTEXT-AND-IO.jsonata-engine-pinned-version-and-restrictions.md +1 -1
- package/skills/hexasync-expressions/references/expressions.CONTEXT-AND-IO.jsonpath-expressions.md +2 -2
- package/skills/hexasync-expressions/references/expressions.CONTEXT-AND-IO.related.md +1 -1
- package/skills/hexasync-expressions/references/expressions.CONTEXT-AND-IO.runtime-scope.md +12 -12
- package/skills/hexasync-expressions/references/expressions.CONTEXT-AND-IO.scriban-default-and-host-custom-builtins.host-qualified-authoring-examples.md +2 -2
- package/skills/hexasync-expressions/references/frontend.FRONTEND-FLOWS.api_proxy.md +94 -0
- package/skills/hexasync-expressions/references/frontend.FRONTEND-FLOWS.expressions-and-tooling.md +11 -5
- package/skills/hexasync-expressions/references/frontend.FRONTEND-FLOWS.fail.md +48 -0
- package/skills/hexasync-expressions/references/frontend.FRONTEND-FLOWS.frontend-step-fields.md +4 -4
- package/skills/hexasync-expressions/references/frontend.FRONTEND-FLOWS.grouped-readiness-flows.md +3 -3
- package/skills/hexasync-expressions/references/frontend.FRONTEND-FLOWS.md +6 -4
- package/skills/hexasync-expressions/references/frontend.FRONTEND-FLOWS.preview-and-source-navigation.md +12 -2
- package/skills/hexasync-expressions/references/frontend.FRONTEND-FLOWS.records_form.file-import-path.md +208 -0
- package/skills/hexasync-expressions/references/frontend.FRONTEND-FLOWS.records_form.md +11 -200
- package/skills/hexasync-expressions/references/frontend.FRONTEND-FLOWS.records_form.records_form-change-set-path.md +208 -0
- package/skills/hexasync-expressions/references/frontend.FRONTEND-FLOWS.return.md +2 -2
- package/skills/hexasync-expressions/references/frontend.FRONTEND-FLOWS.task-and-reference-data-changes.md +92 -0
- package/skills/hexasync-expressions/references/steps.JSONata.md +8 -8
- package/skills/hexasync-expressions/references/steps.Liquid.md +2 -2
- package/skills/hexasync-expressions/references/steps.Scriban.md +9 -9
- package/skills/hexasync-field-mapping/SKILL.md +13 -19
- package/skills/hexasync-field-mapping/references/INDEX.md +2 -2
- package/skills/hexasync-field-mapping/references/INSTALL.md +5 -48
- package/skills/hexasync-field-mapping/references/steps.SAVE_TASK_DATA.md +19 -19
- package/skills/hexasync-field-mapping/references/tables.TABLES.best-practices.md +1 -1
- package/skills/hexasync-field-mapping/references/tables.TABLES.fields.md +1 -1
- package/skills/hexasync-field-mapping/references/tables.TABLES.md +1 -1
- package/skills/hexasync-field-mapping/references/tables.TABLES.minimal-declaration-and-composed-usage.md +1 -1
- package/skills/hexasync-field-mapping/references/tables.TABLES.related.md +5 -5
- package/skills/hexasync-field-mapping/references/tables.TABLES.the-system-columns-are-not-declared-here.md +1 -1
- package/skills/hexasync-field-mapping/references/transformations.TRANSFORMATIONS.puller-mapping-transformations.md +1 -1
- package/skills/hexasync-field-mapping/references/transformations.TRANSFORMATIONS.related.md +6 -6
- package/skills/hexasync-field-mapping/references/transformations.TRANSFORMATIONS.renamedependency--declared-but-unimplemented.md +1 -1
- package/skills/hexasync-field-mapping/references/transformations.TRANSFORMATIONS.transformation-types.jsonata--compute-a-field-from-a-jsonata-expression.md +1 -1
- package/skills/hexasync-field-mapping/references/transformations.TRANSFORMATIONS.transformation-types.query-argument-binding.md +2 -2
- package/skills/hexasync-field-mapping/references/transformations.TRANSFORMATIONS.transformation-types.query_single--the-dsl-replacement-for-sql.md +4 -4
- package/skills/hexasync-field-mapping/references/transformations.TRANSFORMATIONS.transformation-types.scriban--compute-a-field-from-a-scriban-expression.md +1 -1
- package/skills/hexasync-field-mapping/references/transformations.TRANSFORMATIONS.when-to-use.md +1 -1
- package/skills/hexasync-metrics-reports/SKILL.md +9 -16
- package/skills/hexasync-metrics-reports/references/INDEX.md +1 -1
- package/skills/hexasync-metrics-reports/references/INSTALL.md +5 -48
- package/skills/hexasync-metrics-reports/references/metrics.METRICS_REFERENCE.common-metadata-properties.md +1 -1
- package/skills/hexasync-metrics-reports/references/metrics.METRICS_REFERENCE.metric-configuration.md +1 -1
- package/skills/hexasync-metrics-reports/references/metrics.METRICS_REFERENCE.metric-kinds-reference.md +2 -2
- package/skills/hexasync-metrics-reports/references/metrics.METRICS_REFERENCE.related.md +4 -4
- package/skills/hexasync-metrics-reports/references/metrics.METRICS_REFERENCE.when-to-use.md +1 -1
- package/skills/hexasync-metrics-reports/references/reports.REPORTS.md +4 -4
- package/skills/hexasync-metrics-reports/references/steps.METRIC_QUERY.md +2 -2
- package/skills/hexasync-metrics-reports/references/steps.QUERY_METRICS.md +8 -8
- package/skills/hexasync-pullers/SKILL.md +11 -18
- package/skills/hexasync-pullers/references/INDEX.md +3 -3
- package/skills/hexasync-pullers/references/INSTALL.md +5 -48
- package/skills/hexasync-pullers/references/pullers.PULLERS.api-error-classification.md +3 -3
- package/skills/hexasync-pullers/references/pullers.PULLERS.entity-classification.md +1 -1
- package/skills/hexasync-pullers/references/pullers.PULLERS.entry-context-and-transitions.md +1 -1
- package/skills/hexasync-pullers/references/pullers.PULLERS.overview.md +2 -2
- package/skills/hexasync-pullers/references/pullers.PULLERS.page-termination-and-the-four-platform-guards.md +2 -2
- package/skills/hexasync-pullers/references/pullers.PULLERS.persistence-and-safe-full-pull-removal.md +2 -2
- package/skills/hexasync-pullers/references/pullers.PULLERS.placement-afterpullsteps.md +1 -1
- package/skills/hexasync-pullers/references/pullers.PULLERS.placement-beforepullsteps.md +1 -1
- package/skills/hexasync-pullers/references/pullers.PULLERS.placement-contracts.md +1 -1
- package/skills/hexasync-pullers/references/pullers.PULLERS.placement-onerrorsteps.md +2 -2
- package/skills/hexasync-pullers/references/pullers.PULLERS.placement-pullsteps.md +1 -1
- package/skills/hexasync-pullers/references/pullers.PULLERS.placement-steps.md +1 -1
- package/skills/hexasync-pullers/references/pullers.PULLERS.property-reference.md +6 -6
- package/skills/hexasync-pullers/references/pullers.PULLERS.puller-completeness-contract.md +6 -6
- package/skills/hexasync-pullers/references/pullers.PULLERS.related.md +7 -7
- package/skills/hexasync-pullers/references/pullers.PULLERS.the-resume-computation.md +2 -2
- package/skills/hexasync-pullers/references/pullers.PULLERS.the-webhook-vs-puller-division.md +1 -1
- package/skills/hexasync-pullers/references/pullers.PULLERS.two-puller-host-modes-not-two-workflow-constructs.md +2 -2
- package/skills/hexasync-pullers/references/pullers.PULLERS.watermark-trustworthiness.md +1 -1
- package/skills/hexasync-pullers/references/pullers.PULLERS.worked-example-new-kind-snapshot-pull.md +2 -2
- package/skills/hexasync-pullers/references/steps.PULLER.md +8 -8
- package/skills/hexasync-pushers/SKILL.md +20 -22
- package/skills/hexasync-pushers/references/INDEX.md +2 -2
- package/skills/hexasync-pushers/references/INSTALL.md +5 -48
- package/skills/hexasync-pushers/references/pushers.PUSHERS.association-transform-routing.md +1 -1
- package/skills/hexasync-pushers/references/pushers.PUSHERS.best-practices.md +3 -3
- package/skills/hexasync-pushers/references/pushers.PUSHERS.expression-roots-differ-from-a-puller.md +1 -1
- package/skills/hexasync-pushers/references/pushers.PUSHERS.fields.md +4 -4
- package/skills/hexasync-pushers/references/pushers.PUSHERS.four-step-phases.md +1 -1
- package/skills/hexasync-pushers/references/pushers.PUSHERS.indirect-pushers.md +2 -2
- package/skills/hexasync-pushers/references/pushers.PUSHERS.md +1 -1
- package/skills/hexasync-pushers/references/pushers.PUSHERS.minimal-configuration.md +2 -2
- package/skills/hexasync-pushers/references/pushers.PUSHERS.placement-beforepushsteps.md +2 -2
- package/skills/hexasync-pushers/references/pushers.PUSHERS.placement-contracts.md +3 -3
- package/skills/hexasync-pushers/references/pushers.PUSHERS.placement-finalsteps.md +2 -2
- package/skills/hexasync-pushers/references/pushers.PUSHERS.related.md +6 -6
- package/skills/hexasync-pushers/references/pushers.PUSHERS.resolution-ordering-locks-and-retries.md +4 -4
- package/skills/hexasync-pushers/references/pushers.PUSHERS.worked-example-direct-push-with-dependency.md +1 -1
- package/skills/hexasync-pushers/references/steps.PUSHER.md +8 -8
- package/skills/hexasync-pushers/references/steps.UPDATE_ITEM_STATUS.md +14 -14
- package/skills/hexasync-pushers/references/steps.UPDATE_ITEM_SYNC_PROCESS.md +48 -21
- package/skills/hexasync-query-dsl/SKILL.md +13 -17
- package/skills/hexasync-query-dsl/references/INDEX.md +2 -2
- package/skills/hexasync-query-dsl/references/INSTALL.md +5 -48
- package/skills/hexasync-query-dsl/references/query-dsl.QUERY-DSL.best-practice.md +1 -1
- package/skills/hexasync-query-dsl/references/query-dsl.QUERY-DSL.filter-dsl-language-contract.filter-composition.md +2 -2
- package/skills/hexasync-query-dsl/references/query-dsl.QUERY-DSL.filter-dsl-language-contract.filter-fields.md +1 -1
- package/skills/hexasync-query-dsl/references/query-dsl.QUERY-DSL.filter-dsl-language-contract.filter-predicates.md +1 -1
- package/skills/hexasync-query-dsl/references/query-dsl.QUERY-DSL.filter-dsl-language-contract.filter-request-envelope.md +17 -9
- package/skills/hexasync-query-dsl/references/query-dsl.QUERY-DSL.filter-dsl-language-contract.md +3 -3
- package/skills/hexasync-query-dsl/references/query-dsl.QUERY-DSL.operands.md +1 -1
- package/skills/hexasync-query-dsl/references/query-dsl.QUERY-DSL.operands.query-arguments.md +3 -3
- package/skills/hexasync-query-dsl/references/query-dsl.QUERY-DSL.operands.value-binding-and-casts.md +1 -1
- package/skills/hexasync-query-dsl/references/query-dsl.QUERY-DSL.operators.between-takes-a-range-not-an-operand.md +1 -1
- package/skills/hexasync-query-dsl/references/query-dsl.QUERY-DSL.operators.bitwise-predicates.md +4 -4
- package/skills/hexasync-query-dsl/references/query-dsl.QUERY-DSL.operators.last_int_unit-needs-format-on-the-left.md +3 -3
- package/skills/hexasync-query-dsl/references/query-dsl.QUERY-DSL.operators.membership-predicates.md +1 -1
- package/skills/hexasync-query-dsl/references/query-dsl.QUERY-DSL.operators.null-predicates-are-unary.md +5 -5
- package/skills/hexasync-query-dsl/references/query-dsl.QUERY-DSL.operators.regex-predicates-complete-scalar-postgresql-patterns.md +2 -2
- package/skills/hexasync-query-dsl/references/query-dsl.QUERY-DSL.operators.text-matching-six-predicates-scalar-patterns-and-value-lists.md +2 -2
- package/skills/hexasync-query-dsl/references/query-dsl.QUERY-DSL.operators.verbatim-scalar-comparisons.md +2 -2
- package/skills/hexasync-query-dsl/references/query-dsl.QUERY-DSL.runtime-rules-and-authoring-shape.md +4 -4
- package/skills/hexasync-query-dsl/references/query-dsl.QUERY-DSL.the-shape.builder-condition-tree.md +1 -1
- package/skills/hexasync-query-dsl/references/query-dsl.QUERY-DSL.the-shape.grouping-precedence-and-exact-parentheses.md +2 -2
- package/skills/hexasync-query-dsl/references/query-dsl.QUERY-DSL.the-shape.join-types.md +1 -1
- package/skills/hexasync-query-dsl/references/query-dsl.QUERY-DSL.the-shape.query-envelope.md +3 -3
- package/skills/hexasync-query-dsl/references/query-dsl.QUERY-DSL.troubleshooting-and-canonical-references.md +2 -2
- package/skills/hexasync-query-dsl/references/query-dsl.QUERY-DSL.when-to-use.md +1 -1
- package/skills/hexasync-query-dsl/references/query-dsl.QUERY-DSL.where-it-is-used.md +7 -7
- package/skills/hexasync-query-dsl/references/steps.QUERY_MANY.md +9 -9
- package/skills/hexasync-query-dsl/references/steps.QUERY_SINGLE.md +9 -9
- package/skills/hexasync-query-dsl/references/steps.SQL.md +12 -12
- package/skills/hexasync-query-dsl/references/steps.SQL_PROXY.md +9 -9
- package/skills/hexasync-startup-tasks-scheduling/SKILL.md +9 -16
- package/skills/hexasync-startup-tasks-scheduling/references/INDEX.md +3 -3
- package/skills/hexasync-startup-tasks-scheduling/references/INSTALL.md +5 -48
- package/skills/hexasync-startup-tasks-scheduling/references/startupTasks.STARTUP-TASKS.legacy-target-tasks.md +3 -3
- package/skills/hexasync-startup-tasks-scheduling/references/startupTasks.STARTUP-TASKS.metric-defaults.md +1 -1
- package/skills/hexasync-startup-tasks-scheduling/references/startupTasks.STARTUP-TASKS.related.md +5 -5
- package/skills/hexasync-startup-tasks-scheduling/references/startupTasks.STARTUP-TASKS.scheduler-metadata.md +6 -6
- package/skills/hexasync-startup-tasks-scheduling/references/startupTasks.STARTUP-TASKS.when-to-use.md +2 -2
- package/skills/hexasync-startup-tasks-scheduling/references/steps.ENQUEUER.md +9 -9
- package/skills/hexasync-steps-api-http/SKILL.md +19 -26
- package/skills/hexasync-steps-api-http/references/INDEX.md +9 -4
- package/skills/hexasync-steps-api-http/references/INSTALL.md +5 -48
- package/skills/hexasync-steps-api-http/references/frontend.FRONTEND-FLOWS.api_proxy.md +94 -0
- package/skills/hexasync-steps-api-http/references/frontend.FRONTEND-FLOWS.expressions-and-tooling.md +11 -5
- package/skills/hexasync-steps-api-http/references/frontend.FRONTEND-FLOWS.fail.md +48 -0
- package/skills/hexasync-steps-api-http/references/frontend.FRONTEND-FLOWS.frontend-step-fields.md +4 -4
- package/skills/hexasync-steps-api-http/references/frontend.FRONTEND-FLOWS.grouped-readiness-flows.md +3 -3
- package/skills/hexasync-steps-api-http/references/frontend.FRONTEND-FLOWS.md +6 -4
- package/skills/hexasync-steps-api-http/references/frontend.FRONTEND-FLOWS.preview-and-source-navigation.md +12 -2
- package/skills/hexasync-steps-api-http/references/frontend.FRONTEND-FLOWS.records_form.file-import-path.md +208 -0
- package/skills/hexasync-steps-api-http/references/frontend.FRONTEND-FLOWS.records_form.md +11 -200
- package/skills/hexasync-steps-api-http/references/frontend.FRONTEND-FLOWS.records_form.records_form-change-set-path.md +208 -0
- package/skills/hexasync-steps-api-http/references/frontend.FRONTEND-FLOWS.return.md +2 -2
- package/skills/hexasync-steps-api-http/references/frontend.FRONTEND-FLOWS.task-and-reference-data-changes.md +92 -0
- package/skills/hexasync-steps-api-http/references/responseFilters.RESPONSE-FILTERS.best-practices.md +1 -1
- package/skills/hexasync-steps-api-http/references/responseFilters.RESPONSE-FILTERS.execution-order-and-shared-values.md +1 -1
- package/skills/hexasync-steps-api-http/references/responseFilters.RESPONSE-FILTERS.md +1 -1
- package/skills/hexasync-steps-api-http/references/responseFilters.RESPONSE-FILTERS.parsejson-boundary.md +2 -2
- package/skills/hexasync-steps-api-http/references/responseFilters.RESPONSE-FILTERS.related.md +1 -1
- package/skills/hexasync-steps-api-http/references/responseFilters.RESPONSE-FILTERS.same-name-different-placement-grammars.md +4 -4
- package/skills/hexasync-steps-api-http/references/routing.NEXT.md +7 -7
- package/skills/hexasync-steps-api-http/references/steps.API.api-pagination.md +1 -1
- package/skills/hexasync-steps-api-http/references/steps.API.contract.md +2 -2
- package/skills/hexasync-steps-api-http/references/steps.API.failure-handling.md +2 -2
- package/skills/hexasync-steps-api-http/references/steps.API.fields.md +1 -1
- package/skills/hexasync-steps-api-http/references/steps.API.related.md +4 -4
- package/skills/hexasync-steps-api-http/references/steps.INDEX.md +90 -90
- package/skills/hexasync-steps-api-http/references/steps.STEP-ENVELOPE._history--the-per-step-occurrence-ring.md +1 -1
- package/skills/hexasync-steps-api-http/references/steps.STEP-ENVELOPE.arguments-and-routing.md +2 -2
- package/skills/hexasync-steps-api-http/references/steps.STEP-ENVELOPE.best-practices.md +1 -1
- package/skills/hexasync-steps-api-http/references/steps.STEP-ENVELOPE.executor-selection-is-exact.md +6 -0
- package/skills/hexasync-steps-api-http/references/steps.STEP-ENVELOPE.one-canonical-workflow-component.md +16 -16
- package/skills/hexasync-steps-api-http/references/steps.STEP-ENVELOPE.recovery-bypasses-and-connector-restart.md +1 -1
- package/skills/hexasync-steps-api-http/references/steps.STEP-ENVELOPE.related.md +1 -1
- package/skills/hexasync-steps-api-http/references/steps.STEP-ENVELOPE.shape.md +4 -4
- package/skills/hexasync-steps-control-data/SKILL.md +25 -31
- package/skills/hexasync-steps-control-data/references/INDEX.md +8 -3
- package/skills/hexasync-steps-control-data/references/INSTALL.md +5 -48
- package/skills/hexasync-steps-control-data/references/frontend.FRONTEND-FLOWS.api_proxy.md +94 -0
- package/skills/hexasync-steps-control-data/references/frontend.FRONTEND-FLOWS.expressions-and-tooling.md +11 -5
- package/skills/hexasync-steps-control-data/references/frontend.FRONTEND-FLOWS.fail.md +48 -0
- package/skills/hexasync-steps-control-data/references/frontend.FRONTEND-FLOWS.frontend-step-fields.md +4 -4
- package/skills/hexasync-steps-control-data/references/frontend.FRONTEND-FLOWS.grouped-readiness-flows.md +3 -3
- package/skills/hexasync-steps-control-data/references/frontend.FRONTEND-FLOWS.md +6 -4
- package/skills/hexasync-steps-control-data/references/frontend.FRONTEND-FLOWS.preview-and-source-navigation.md +12 -2
- package/skills/hexasync-steps-control-data/references/frontend.FRONTEND-FLOWS.records_form.file-import-path.md +208 -0
- package/skills/hexasync-steps-control-data/references/frontend.FRONTEND-FLOWS.records_form.md +11 -200
- package/skills/hexasync-steps-control-data/references/frontend.FRONTEND-FLOWS.records_form.records_form-change-set-path.md +208 -0
- package/skills/hexasync-steps-control-data/references/frontend.FRONTEND-FLOWS.return.md +2 -2
- package/skills/hexasync-steps-control-data/references/frontend.FRONTEND-FLOWS.task-and-reference-data-changes.md +92 -0
- package/skills/hexasync-steps-control-data/references/steps.BASE64_TO_MIME_TYPE.md +3 -3
- package/skills/hexasync-steps-control-data/references/steps.Begin.md +3 -3
- package/skills/hexasync-steps-control-data/references/steps.CACHE.md +4 -4
- package/skills/hexasync-steps-control-data/references/steps.Composite.md +4 -4
- package/skills/hexasync-steps-control-data/references/steps.DIRECT_INDEX.md +12 -12
- package/skills/hexasync-steps-control-data/references/steps.DOWNLOAD_CSV.md +23 -23
- package/skills/hexasync-steps-control-data/references/steps.EXCEL_READER.md +7 -7
- package/skills/hexasync-steps-control-data/references/steps.End.md +4 -4
- package/skills/hexasync-steps-control-data/references/steps.GET_KEY_VALUE.md +6 -6
- package/skills/hexasync-steps-control-data/references/steps.GraphQL.md +7 -7
- package/skills/hexasync-steps-control-data/references/steps.IF.md +12 -12
- package/skills/hexasync-steps-control-data/references/steps.IGNORE_ITEM.md +7 -7
- package/skills/hexasync-steps-control-data/references/steps.INDEX.md +48 -48
- package/skills/hexasync-steps-control-data/references/steps.INVALIDATE_CACHE.md +2 -2
- package/skills/hexasync-steps-control-data/references/steps.LOOKUP_STEP.md +8 -8
- package/skills/hexasync-steps-control-data/references/steps.OData.md +4 -4
- package/skills/hexasync-steps-control-data/references/steps.PUBLISH_EVENT.md +5 -5
- package/skills/hexasync-steps-control-data/references/steps.QueryDSL.md +3 -3
- package/skills/hexasync-steps-control-data/references/steps.REMOVE_DATA.md +7 -7
- package/skills/hexasync-steps-control-data/references/steps.RESET_ITEM.md +12 -12
- package/skills/hexasync-steps-control-data/references/steps.RESOLVE_RAW_DATA.md +11 -11
- package/skills/hexasync-steps-control-data/references/steps.Restful.md +6 -6
- package/skills/hexasync-steps-control-data/references/steps.SEED_DATA.md +10 -10
- package/skills/hexasync-steps-control-data/references/steps.SET_KEY_VALUE.md +7 -7
- package/skills/hexasync-steps-control-data/references/steps.SLEEP.md +8 -8
- package/skills/hexasync-steps-control-data/references/steps.SWITCH.md +12 -12
- package/skills/hexasync-steps-control-data/references/steps.TRACK_FOR_REMOVAL.md +12 -12
- package/skills/hexasync-steps-control-data/references/steps.UPDATE_TASK_DATA_STATUS.md +13 -13
- package/skills/hexasync-steps-control-data/references/steps.VALUES.md +12 -12
- package/skills/hexasync-steps-control-data/references/steps.VERIFY_CACHED.md +5 -5
- package/skills/hexasync-steps-control-data/references/steps.cURL.md +8 -8
- package/skills/hexasync-tables-tasks-objects/SKILL.md +11 -18
- package/skills/hexasync-tables-tasks-objects/references/INDEX.md +2 -2
- package/skills/hexasync-tables-tasks-objects/references/INSTALL.md +5 -48
- package/skills/hexasync-tables-tasks-objects/references/dependencies.DEPENDENCIES.fields.md +1 -1
- package/skills/hexasync-tables-tasks-objects/references/dependencies.DEPENDENCIES.related.md +1 -1
- package/skills/hexasync-tables-tasks-objects/references/dependencies.DEPENDENCIES.using-resolved-prerequisite-data.md +1 -1
- package/skills/hexasync-tables-tasks-objects/references/objectAssociations.OBJECT-ASSOCIATIONS.md +7 -7
- package/skills/hexasync-tables-tasks-objects/references/objects.object.best-practices-and-pitfalls.md +1 -1
- package/skills/hexasync-tables-tasks-objects/references/objects.object.fields.dataprocessing.md +1 -1
- package/skills/hexasync-tables-tasks-objects/references/objects.object.fields.dependencies.md +2 -2
- package/skills/hexasync-tables-tasks-objects/references/objects.object.fields.description.md +1 -1
- package/skills/hexasync-tables-tasks-objects/references/objects.object.fields.enqueue.md +1 -1
- package/skills/hexasync-tables-tasks-objects/references/objects.object.fields.fromconnectionid.md +1 -1
- package/skills/hexasync-tables-tasks-objects/references/objects.object.fields.id.md +1 -1
- package/skills/hexasync-tables-tasks-objects/references/objects.object.fields.ignorechange.md +1 -1
- package/skills/hexasync-tables-tasks-objects/references/objects.object.fields.ignoreremoval.md +2 -2
- package/skills/hexasync-tables-tasks-objects/references/objects.object.fields.integrationtype.md +1 -1
- package/skills/hexasync-tables-tasks-objects/references/objects.object.fields.isdirtyremovable.md +1 -1
- package/skills/hexasync-tables-tasks-objects/references/objects.object.fields.md +1 -1
- package/skills/hexasync-tables-tasks-objects/references/objects.object.fields.metricgroups.md +1 -1
- package/skills/hexasync-tables-tasks-objects/references/objects.object.fields.metrics.md +2 -2
- package/skills/hexasync-tables-tasks-objects/references/objects.object.fields.name.md +1 -1
- package/skills/hexasync-tables-tasks-objects/references/objects.object.fields.newtablename.md +1 -1
- package/skills/hexasync-tables-tasks-objects/references/objects.object.fields.oldtablename.md +1 -1
- package/skills/hexasync-tables-tasks-objects/references/objects.object.fields.priority.md +1 -1
- package/skills/hexasync-tables-tasks-objects/references/objects.object.fields.puller.md +4 -4
- package/skills/hexasync-tables-tasks-objects/references/objects.object.fields.pusher.md +1 -1
- package/skills/hexasync-tables-tasks-objects/references/objects.object.fields.queuer.md +1 -1
- package/skills/hexasync-tables-tasks-objects/references/objects.object.fields.toconnectionid.md +1 -1
- package/skills/hexasync-tables-tasks-objects/references/objects.object.fields.type.md +1 -1
- package/skills/hexasync-tables-tasks-objects/references/objects.object.fields.valuetablename.md +1 -1
- package/skills/hexasync-tables-tasks-objects/references/objects.object.fields.viewname.md +1 -1
- package/skills/hexasync-tables-tasks-objects/references/objects.object.fields.visible.md +1 -1
- package/skills/hexasync-tables-tasks-objects/references/objects.object.minimal-declaration.md +1 -1
- package/skills/hexasync-tables-tasks-objects/references/objects.object.related.md +2 -2
- package/skills/hexasync-tables-tasks-objects/references/steps.SAVE_TASK_DATA.md +16 -16
- package/skills/hexasync-tables-tasks-objects/references/tables.TABLES.best-practices.md +1 -1
- package/skills/hexasync-tables-tasks-objects/references/tables.TABLES.fields.md +1 -1
- package/skills/hexasync-tables-tasks-objects/references/tables.TABLES.related.md +3 -3
- package/skills/hexasync-tables-tasks-objects/references/tasks.TASKS-AND-TABLES.fields.md +5 -5
- package/skills/hexasync-tables-tasks-objects/references/tasks.TASKS-AND-TABLES.md +1 -1
- package/skills/hexasync-tables-tasks-objects/references/tasks.TASKS-AND-TABLES.related.md +6 -6
- package/skills/hexasync-tables-tasks-objects/references/tasks.TASKS-AND-TABLES.status-and-row-clocks.md +1 -1
- package/skills/hexasync-tables-tasks-objects/references/tasks.TASKS-AND-TABLES.system-column-contract.md +1 -1
- package/skills/hexasync-templates/SKILL.md +16 -30
- package/skills/hexasync-templates/references/AI-INDEX.md +36 -35
- package/skills/hexasync-templates/references/INDEX.md +9 -4
- package/skills/hexasync-templates/references/INSTALL.md +5 -48
- package/skills/hexasync-templates/references/KB-INDEX.md +98 -98
- package/skills/hexasync-templates/references/PROFILE-ROOT.composed-and-render-only-metadata.md +1 -1
- package/skills/hexasync-templates/references/PROFILE-ROOT.md +1 -2
- package/skills/hexasync-templates/references/PROFILE-ROOT.minimal-worker-facing-profile.md +2 -2
- package/skills/hexasync-templates/references/PROFILE-ROOT.profile-references.md +10 -10
- package/skills/hexasync-templates/references/PROFILE-ROOT.profile-root-fields-1.connectors.md +1 -1
- package/skills/hexasync-templates/references/PROFILE-ROOT.profile-root-fields-1.dependencies.md +1 -1
- package/skills/hexasync-templates/references/PROFILE-ROOT.profile-root-fields-1.frontend-steps-creationsteps-setupsteps-authorizationsteps.api--gateway_api.md +14 -3
- package/skills/hexasync-templates/references/PROFILE-ROOT.profile-root-fields-1.frontend-steps-creationsteps-setupsteps-authorizationsteps.api_proxy.md +69 -0
- package/skills/hexasync-templates/references/PROFILE-ROOT.profile-root-fields-1.frontend-steps-creationsteps-setupsteps-authorizationsteps.fail.md +76 -0
- package/skills/hexasync-templates/references/PROFILE-ROOT.profile-root-fields-1.frontend-steps-creationsteps-setupsteps-authorizationsteps.md +4 -2
- package/skills/hexasync-templates/references/PROFILE-ROOT.profile-root-fields-1.frontend-steps-creationsteps-setupsteps-authorizationsteps.records_form.md +7 -3
- package/skills/hexasync-templates/references/PROFILE-ROOT.profile-root-fields-1.frontend-steps-creationsteps-setupsteps-authorizationsteps.step-envelope-fields.md +4 -4
- package/skills/hexasync-templates/references/PROFILE-ROOT.profile-root-fields-1.getreadyflows.md +1 -1
- package/skills/hexasync-templates/references/PROFILE-ROOT.profile-root-fields-1.legacy-roots--do-not-author.md +1 -1
- package/skills/hexasync-templates/references/PROFILE-ROOT.profile-root-fields-1.metricgroups.md +1 -1
- package/skills/hexasync-templates/references/PROFILE-ROOT.profile-root-fields-1.objectassociations.md +1 -1
- package/skills/hexasync-templates/references/PROFILE-ROOT.profile-root-fields-1.objects.md +1 -1
- package/skills/hexasync-templates/references/PROFILE-ROOT.profile-root-fields-1.pullers.md +1 -1
- package/skills/hexasync-templates/references/PROFILE-ROOT.profile-root-fields-1.pushers.md +1 -1
- package/skills/hexasync-templates/references/PROFILE-ROOT.profile-root-fields-1.reports.md +1 -1
- package/skills/hexasync-templates/references/PROFILE-ROOT.profile-root-fields-1.startuptasks.md +1 -1
- package/skills/hexasync-templates/references/PROFILE-ROOT.profile-root-fields-1.tables.md +1 -1
- package/skills/hexasync-templates/references/PROFILE-ROOT.profile-root-fields-1.transformations.md +1 -1
- package/skills/hexasync-templates/references/PROFILE-ROOT.profile-root-fields-1.validations.md +1 -1
- package/skills/hexasync-templates/references/PROFILE-ROOT.profile-root-fields-1.webhooks.md +1 -1
- package/skills/hexasync-templates/references/PROFILE-ROOT.recommendation-selection.md +1 -1
- package/skills/hexasync-templates/references/PROFILE-ROOT.reference-composition-across-run-and-render-scope.md +1 -1
- package/skills/hexasync-templates/references/PROFILE-ROOT.rejected-reference-forms-and-safe-correction.md +1 -1
- package/skills/hexasync-templates/references/PROFILE-ROOT.related.md +1 -1
- package/skills/hexasync-templates/references/frontend.FRONTEND-FLOWS.api_proxy.md +94 -0
- package/skills/hexasync-templates/references/frontend.FRONTEND-FLOWS.expressions-and-tooling.md +11 -5
- package/skills/hexasync-templates/references/frontend.FRONTEND-FLOWS.fail.md +48 -0
- package/skills/hexasync-templates/references/frontend.FRONTEND-FLOWS.frontend-step-fields.md +4 -4
- package/skills/hexasync-templates/references/frontend.FRONTEND-FLOWS.grouped-readiness-flows.md +3 -3
- package/skills/hexasync-templates/references/frontend.FRONTEND-FLOWS.md +6 -4
- package/skills/hexasync-templates/references/frontend.FRONTEND-FLOWS.preview-and-source-navigation.md +12 -2
- package/skills/hexasync-templates/references/frontend.FRONTEND-FLOWS.records_form.file-import-path.md +208 -0
- package/skills/hexasync-templates/references/frontend.FRONTEND-FLOWS.records_form.md +11 -200
- package/skills/hexasync-templates/references/frontend.FRONTEND-FLOWS.records_form.records_form-change-set-path.md +208 -0
- package/skills/hexasync-templates/references/frontend.FRONTEND-FLOWS.return.md +2 -2
- package/skills/hexasync-templates/references/frontend.FRONTEND-FLOWS.task-and-reference-data-changes.md +92 -0
- package/skills/hexasync-transformations/SKILL.md +9 -16
- package/skills/hexasync-transformations/references/INDEX.md +2 -2
- package/skills/hexasync-transformations/references/INSTALL.md +5 -48
- package/skills/hexasync-transformations/references/transformations.TRANSFORMATIONS.explicit-mapping-for-push.md +1 -1
- package/skills/hexasync-transformations/references/transformations.TRANSFORMATIONS.puller-mapping-transformations.md +1 -1
- package/skills/hexasync-transformations/references/transformations.TRANSFORMATIONS.related.md +6 -6
- package/skills/hexasync-transformations/references/transformations.TRANSFORMATIONS.renamedependency--declared-but-unimplemented.md +1 -1
- package/skills/hexasync-transformations/references/transformations.TRANSFORMATIONS.transformation-types.jsonata--compute-a-field-from-a-jsonata-expression.md +1 -1
- package/skills/hexasync-transformations/references/transformations.TRANSFORMATIONS.transformation-types.query-argument-binding.md +2 -2
- package/skills/hexasync-transformations/references/transformations.TRANSFORMATIONS.transformation-types.query_single--the-dsl-replacement-for-sql.md +4 -4
- package/skills/hexasync-transformations/references/transformations.TRANSFORMATIONS.transformation-types.scriban--compute-a-field-from-a-scriban-expression.md +1 -1
- package/skills/hexasync-transformations/references/transformations.TRANSFORMATIONS.when-to-use.md +1 -1
- package/skills/hexasync-validations/SKILL.md +9 -16
- package/skills/hexasync-validations/references/INDEX.md +1 -1
- package/skills/hexasync-validations/references/INSTALL.md +5 -48
- package/skills/hexasync-validations/references/steps.CHECK_FORMAT.md +6 -6
- package/skills/hexasync-validations/references/validations.VALIDATIONS.fields.md +1 -1
- package/skills/hexasync-validations/references/validations.VALIDATIONS.how-validations-behave.md +2 -2
- package/skills/hexasync-validations/references/validations.VALIDATIONS.md +1 -1
- package/skills/hexasync-validations/references/validations.VALIDATIONS.not-the-query-dsl.md +1 -1
- package/skills/hexasync-webhooks/SKILL.md +12 -19
- package/skills/hexasync-webhooks/references/INDEX.md +2 -2
- package/skills/hexasync-webhooks/references/INSTALL.md +5 -48
- package/skills/hexasync-webhooks/references/steps.FORWARD.md +7 -7
- package/skills/hexasync-webhooks/references/steps.WEBHOOK_FORWARD.md +10 -10
- package/skills/hexasync-webhooks/references/webhooks.WEBHOOKS.best-practices.md +2 -2
- package/skills/hexasync-webhooks/references/webhooks.WEBHOOKS.gateway-mcp-webhook-workflow.md +1 -1
- package/skills/hexasync-webhooks/references/webhooks.WEBHOOKS.md +2 -2
- package/skills/hexasync-webhooks/references/webhooks.WEBHOOKS.placement-finalsteps.md +1 -1
- package/skills/hexasync-webhooks/references/webhooks.WEBHOOKS.placement-pullsteps.md +6 -6
- package/skills/hexasync-webhooks/references/webhooks.WEBHOOKS.related.md +6 -6
- package/skills/hexasync-webhooks/references/webhooks.WEBHOOKS.target-properties.autoenqueue.md +2 -2
- package/skills/hexasync-webhooks/references/webhooks.WEBHOOKS.target-properties.dataparser.md +3 -3
- package/skills/hexasync-webhooks/references/webhooks.WEBHOOKS.target-properties.options.md +1 -1
- package/skills/hexasync-webhooks/references/webhooks.WEBHOOKS.target-properties.pullsteps.md +1 -1
- package/.cursor-plugin/mcp.json +0 -12
- package/.mcp.json +0 -11
- package/skills/hexasync-expressions/references/frontend.FRONTEND-FLOWS.publish_event.md +0 -42
- package/skills/hexasync-steps-api-http/references/frontend.FRONTEND-FLOWS.publish_event.md +0 -42
- package/skills/hexasync-steps-control-data/references/frontend.FRONTEND-FLOWS.publish_event.md +0 -42
- package/skills/hexasync-templates/references/PROFILE-ROOT.getreadyflows-1.md +0 -33
- package/skills/hexasync-templates/references/frontend.FRONTEND-FLOWS.publish_event.md +0 -42
|
@@ -1,14 +1,16 @@
|
|
|
1
1
|
> Part of [Frontend workflows](frontend.FRONTEND-FLOWS.md).
|
|
2
2
|
|
|
3
|
-
## RECORDS_FORM
|
|
3
|
+
## `RECORDS_FORM`
|
|
4
4
|
|
|
5
|
-
RECORDS_FORM lets the user add, change and remove several records in one paged table, then hands the changes to the steps after it. It is a pause step like FORM. **It never writes anything**:
|
|
5
|
+
RECORDS_FORM lets the user add, change and remove several records in one paged table, then hands the changes to the steps after it. It is a pause step like FORM. **It never writes anything**: save with an explicit `API` step, then check the returned outcomes. Use the [changes route](frontend.FRONTEND-FLOWS.task-and-reference-data-changes.md#changes-apply-a-row-change-set) after its worker.proxy deployment; the file-import example below remains available.
|
|
6
6
|
|
|
7
7
|
```mermaid
|
|
8
8
|
flowchart LR
|
|
9
|
-
READ[API: read rows] --> EDIT[RECORDS_FORM: edit] -->
|
|
10
|
-
|
|
11
|
-
|
|
9
|
+
READ[API: read rows] --> EDIT[RECORDS_FORM: edit] --> HAS{IF: any changes?}
|
|
10
|
+
HAS -- no --> NONE[RETURN SUCCESS]
|
|
11
|
+
HAS -- yes --> NOTE[FORM: change note] --> SAVE[API: changes] --> SAVED{IF: check returned outcomes}
|
|
12
|
+
SAVED -- yes --> OK[SHOW_INFO + RETURN SUCCESS]
|
|
13
|
+
SAVED -- no --> KO[SHOW_INFO + RETURN FAILED]
|
|
12
14
|
```
|
|
13
15
|
|
|
14
16
|
| Syntax | Meaning | Default and choice |
|
|
@@ -32,200 +34,9 @@ flowchart LR
|
|
|
32
34
|
- `removes` — removed loaded rows, **full and unmodified**, identity unchanged.
|
|
33
35
|
- `unchanged` — the count of loaded rows neither changed nor removed. Editing a value back to its original leaves the row unchanged.
|
|
34
36
|
|
|
35
|
-
An identity never appears in both `upserts` and `removes`: re-adding a removed identity restores the loaded row. Cancel follows `onCancelled` and stores no output. Completion
|
|
37
|
+
An identity never appears in both `upserts` and `removes`: re-adding a removed identity restores the loaded row. Cancel follows `onCancelled` and stores no output. Completion exposes only these four members; RECORDS_FORM does not apply output post-processors, and row members are not inferred.
|
|
36
38
|
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
- **TASK target** — send upserts with `__status: 1` and removes with `__status: 2` in ONE `POST /proxy/workers/api/tasks/<taskId>/data/import/data?r=false` call. Set `__status` explicitly on every row: a REFERENCE task imports a missing or blank status as Removed. Rows must be full because the import requires every table column and rejects unknown ones; with `allow.add`, declare every table column (readonly where users must not edit it), because added rows carry only declared columns. The import also needs a change note (`notes`): the dashboard's own import asks for at least 32 characters and a super-admin account is refused below 256, so ask the user for a real reason rather than sending fixed text. Then read back with `__status not_hbw 6` (active rows only): every upserted identity must be present with the intended values and every removed identity absent, matched on every identity key; otherwise the outcome is unverified, never success, and is never resent automatically.
|
|
40
|
-
- **Never** use `r=true` (it disables every row missing from the payload), a physical delete or `…/data/statuses` (an empty item list applies to every row).
|
|
41
|
-
- **WORKER_SETTINGS target** — persist with the existing `PUT …/worker-settings/` call carrying `{values: {…}}`. Worker settings have no disable status, so keep `allow.remove` false unless your `PUT` step defines what removing a setting means.
|
|
42
|
-
|
|
43
|
-
**Quoting and limits.** Values the user types can contain an apostrophe, which would end a single-quoted `--data '…'` body and make the request unreadable. Render JSON inside such a body as `{{ value | json | replace: "'", "\\u0027" }}`: `json` makes a JSON value and the replace turns each apostrophe into the JSON escape `\u0027`. A search request returns at most its `limit` rows: size the initial read above the largest table you expect, because rows that are not loaded cannot be edited or removed, and adding an identity that exists beyond the limit overwrites that row. A read-back can only confirm as many rows as its `limit`, so a save touching more identities than that is unverified.
|
|
44
|
-
|
|
45
|
-
The following is a complete generic declaration: the tasks and tables the form edits and searches, then the flow.
|
|
46
|
-
|
|
47
|
-
```yaml
|
|
48
|
-
objects:
|
|
49
|
-
- id: "**Example_Records_Task_Id**"
|
|
50
|
-
name: Example records
|
|
51
|
-
type: REFERENCE
|
|
52
|
-
priority: 1000
|
|
53
|
-
description: "!md[./tasks/example-records.md]"
|
|
54
|
-
valueTableName: __hsm_example_records
|
|
55
|
-
ignoreRemoval: true
|
|
56
|
-
ignoreChange: false
|
|
57
|
-
- id: "**Example_Catalog_Task_Id**"
|
|
58
|
-
name: Example catalog
|
|
59
|
-
type: REFERENCE
|
|
60
|
-
priority: 1000
|
|
61
|
-
description: "!md[./tasks/example-catalog.md]"
|
|
62
|
-
valueTableName: __hsm_example_catalog
|
|
63
|
-
ignoreRemoval: true
|
|
64
|
-
ignoreChange: false
|
|
65
|
-
objectAssociations:
|
|
66
|
-
"**Example_Records_Task_Id**":
|
|
67
|
-
table: { id: "**Example_Records_Table_Id**" }
|
|
68
|
-
"**Example_Catalog_Task_Id**":
|
|
69
|
-
table: { id: "**Example_Catalog_Table_Id**" }
|
|
70
|
-
tables:
|
|
71
|
-
- id: "**Example_Records_Table_Id**"
|
|
72
|
-
columns:
|
|
73
|
-
code: { name: Code }
|
|
74
|
-
name: { name: Name }
|
|
75
|
-
quantity: { name: Quantity, dataType: Numeric }
|
|
76
|
-
note: { name: Note }
|
|
77
|
-
- id: "**Example_Catalog_Table_Id**"
|
|
78
|
-
columns:
|
|
79
|
-
code: { name: Code }
|
|
80
|
-
name: { name: Name }
|
|
81
|
-
getReadyFlows:
|
|
82
|
-
- key: EDIT_RECORDS
|
|
83
|
-
title: Edit records
|
|
84
|
-
action: { label: Edit records }
|
|
85
|
-
completionVersion: "1"
|
|
86
|
-
steps:
|
|
87
|
-
- key: READ_RECORDS
|
|
88
|
-
type: API
|
|
89
|
-
root: true
|
|
90
|
-
name: Read the current records
|
|
91
|
-
metadata: |-
|
|
92
|
-
curl --location '/proxy/workers/api/tasks/**Example_Records_Task_Id**/data/search' --request POST \
|
|
93
|
-
--header 'HSS-PROFILE-ID: {{ inputs.PROFILE_ID }}' \
|
|
94
|
-
--header 'Content-Type: application/json' \
|
|
95
|
-
--data '{"fields":[],"offset":0,"limit":500,"filters":{"condition":"AND","rightOp":[{"leftOp":"__status","condition":"not_hbw","rightOp":6}]}}'
|
|
96
|
-
next: EDIT
|
|
97
|
-
- key: EDIT
|
|
98
|
-
type: RECORDS_FORM
|
|
99
|
-
name: Edit records
|
|
100
|
-
description: Add, change or remove records. Nothing is saved until you confirm.
|
|
101
|
-
metadata:
|
|
102
|
-
target: { kind: TASK, taskId: "**Example_Records_Task_Id**" }
|
|
103
|
-
identity: [code]
|
|
104
|
-
initial: "jsonata:: outputs.READ_RECORDS.items"
|
|
105
|
-
columns:
|
|
106
|
-
- { key: code, name: Code, type: TEXT, required: true, readonly: true }
|
|
107
|
-
- { key: name, name: Name, type: TEXT, required: true }
|
|
108
|
-
- { key: quantity, name: Quantity, type: NUMBER, min: 0 }
|
|
109
|
-
- { key: note, name: Note, type: MULTILINE_TEXT }
|
|
110
|
-
allow: { add: true, edit: true, remove: true }
|
|
111
|
-
pageSize: 20
|
|
112
|
-
search:
|
|
113
|
-
request: |-
|
|
114
|
-
curl --location '/proxy/workers/api/tasks/**Example_Catalog_Task_Id**/data/search' --request POST \
|
|
115
|
-
--header 'HSS-PROFILE-ID: {{ inputs.PROFILE_ID }}' \
|
|
116
|
-
--header 'Content-Type: application/json' \
|
|
117
|
-
--data '{"fields":[],"offset":0,"limit":20,"filters":{"condition":"AND","rightOp":[{"leftOp":"__status","condition":"not_hbw","rightOp":6},{"leftOp":"code","condition":"ct","rightOp":{{ search.text | json | replace: "'", "\\u0027" }}}]}}'
|
|
118
|
-
items: "jsonata:: items"
|
|
119
|
-
label: "{{ item.code }} — {{ item.name }}"
|
|
120
|
-
fill: { code: "{{ item.code }}", name: "{{ item.name }}" }
|
|
121
|
-
next: BUILD_IMPORT
|
|
122
|
-
onCancelled: CANCELLED
|
|
123
|
-
- key: BUILD_IMPORT
|
|
124
|
-
type: JSONATA
|
|
125
|
-
metadata:
|
|
126
|
-
expression: |-
|
|
127
|
-
{
|
|
128
|
-
"hasChanges": $count(outputs.EDIT.upserts) + $count(outputs.EDIT.removes) > 0,
|
|
129
|
-
"identities": [outputs.EDIT.upserts.code, outputs.EDIT.removes.code],
|
|
130
|
-
"items": [
|
|
131
|
-
outputs.EDIT.upserts.$merge([$, {"__status": 1}]),
|
|
132
|
-
outputs.EDIT.removes.$merge([$, {"__status": 2}])
|
|
133
|
-
]
|
|
134
|
-
}
|
|
135
|
-
next: HAS_CHANGES
|
|
136
|
-
- key: HAS_CHANGES
|
|
137
|
-
type: IF
|
|
138
|
-
metadata:
|
|
139
|
-
condition: "{{ outputs.BUILD_IMPORT.hasChanges }}"
|
|
140
|
-
then: CHANGE_NOTE
|
|
141
|
-
else: NO_CHANGES
|
|
142
|
-
- key: CHANGE_NOTE
|
|
143
|
-
type: FORM
|
|
144
|
-
name: Why are you changing these records?
|
|
145
|
-
metadata:
|
|
146
|
-
fields:
|
|
147
|
-
- key: REASON
|
|
148
|
-
type: MULTILINE_TEXT
|
|
149
|
-
name: Reason for this change (kept in the import history)
|
|
150
|
-
required: true
|
|
151
|
-
next: SAVE
|
|
152
|
-
onCancelled: CANCELLED
|
|
153
|
-
- key: SAVE
|
|
154
|
-
type: API
|
|
155
|
-
name: Save the changes
|
|
156
|
-
metadata: |-
|
|
157
|
-
curl --location '/proxy/workers/api/tasks/**Example_Records_Task_Id**/data/import/data?r=false' --request POST \
|
|
158
|
-
--header 'HSS-PROFILE-ID: {{ inputs.PROFILE_ID }}' \
|
|
159
|
-
--header 'Content-Type: application/json' \
|
|
160
|
-
--data '{"notes":{{ outputs.CHANGE_NOTE.REASON | json | replace: "'", "\\u0027" }},"items":{{ outputs.BUILD_IMPORT.items | json | replace: "'", "\\u0027" }}}'
|
|
161
|
-
next: READ_BACK
|
|
162
|
-
- key: READ_BACK
|
|
163
|
-
type: API
|
|
164
|
-
name: Confirm what was saved
|
|
165
|
-
metadata: |-
|
|
166
|
-
curl --location '/proxy/workers/api/tasks/**Example_Records_Task_Id**/data/search' --request POST \
|
|
167
|
-
--header 'HSS-PROFILE-ID: {{ inputs.PROFILE_ID }}' \
|
|
168
|
-
--header 'Content-Type: application/json' \
|
|
169
|
-
--data '{"fields":[],"offset":0,"limit":500,"filters":{"condition":"AND","rightOp":[{"leftOp":"__status","condition":"not_hbw","rightOp":6},{"leftOp":"code","condition":"in","rightOp":{{ outputs.BUILD_IMPORT.identities | json | replace: "'", "\\u0027" }}}]}}'
|
|
170
|
-
next: VERIFY
|
|
171
|
-
- key: VERIFY
|
|
172
|
-
type: JSONATA
|
|
173
|
-
metadata:
|
|
174
|
-
expression: |-
|
|
175
|
-
(
|
|
176
|
-
$saved := [outputs.READ_BACK.items];
|
|
177
|
-
$removed := [outputs.EDIT.removes.code];
|
|
178
|
-
$columns := ["code", "name", "quantity", "note"];
|
|
179
|
-
$text := function($v) { $exists($v) and $v != null ? $string($v) : "" };
|
|
180
|
-
$isSaved := function($row) { (
|
|
181
|
-
$found := $saved[code = $row.code][0];
|
|
182
|
-
$exists($found) and $count($columns[$text($lookup($found, $)) != $text($lookup($row, $))]) = 0
|
|
183
|
-
) };
|
|
184
|
-
{
|
|
185
|
-
"verified": outputs.READ_BACK._response.statusCode = 200
|
|
186
|
-
and $count([outputs.BUILD_IMPORT.identities]) <= 500
|
|
187
|
-
and $count([outputs.EDIT.upserts][$not($isSaved($))]) = 0
|
|
188
|
-
and $count($saved[code in $removed]) = 0
|
|
189
|
-
}
|
|
190
|
-
)
|
|
191
|
-
next: CHECK_SAVED
|
|
192
|
-
- key: CHECK_SAVED
|
|
193
|
-
type: IF
|
|
194
|
-
metadata:
|
|
195
|
-
condition: "{{ outputs.VERIFY.verified }}"
|
|
196
|
-
then: SHOW_SAVED
|
|
197
|
-
else: SHOW_UNVERIFIED
|
|
198
|
-
- key: SHOW_SAVED
|
|
199
|
-
type: SHOW_INFO
|
|
200
|
-
msg: Your changes are saved.
|
|
201
|
-
metadata: { type: SUCCESS, button_title: Finish }
|
|
202
|
-
next: DONE
|
|
203
|
-
- key: SHOW_UNVERIFIED
|
|
204
|
-
type: SHOW_INFO
|
|
205
|
-
msg: The save could not be confirmed. Reopen the records and check them before trying again.
|
|
206
|
-
metadata: { type: WARNING, button_title: Close }
|
|
207
|
-
next: UNVERIFIED
|
|
208
|
-
- key: DONE
|
|
209
|
-
type: RETURN
|
|
210
|
-
metadata:
|
|
211
|
-
status: SUCCESS
|
|
212
|
-
outputs:
|
|
213
|
-
upserted: "jsonata:: $count(outputs.EDIT.upserts)"
|
|
214
|
-
removed: "jsonata:: $count(outputs.EDIT.removes)"
|
|
215
|
-
- key: NO_CHANGES
|
|
216
|
-
type: RETURN
|
|
217
|
-
metadata:
|
|
218
|
-
status: SUCCESS
|
|
219
|
-
outputs: { upserted: 0, removed: 0 }
|
|
220
|
-
- key: UNVERIFIED
|
|
221
|
-
type: RETURN
|
|
222
|
-
metadata:
|
|
223
|
-
status: FAILED
|
|
224
|
-
error: { code: SAVE_UNVERIFIED, message: The saved records could not be confirmed }
|
|
225
|
-
- key: CANCELLED
|
|
226
|
-
type: RETURN
|
|
227
|
-
metadata: { status: CANCELLED }
|
|
228
|
-
```
|
|
229
|
-
|
|
230
|
-
The JSONATA step after the form is where removes become disables: it is the only place `__status` is set, and the single import carries both lists. A failed import or read-back takes the handler failure path (it does not advance `next`); it never advances to success and is never resent automatically, because a lost response does not prove the rows were not saved.
|
|
39
|
+
This section is served as 2 separate resources. Read the one you need:
|
|
231
40
|
|
|
41
|
+
- [`RECORDS_FORM` change-set path](frontend.FRONTEND-FLOWS.records_form.records_form-change-set-path.md) — This complete generic declaration uses the deployed changes capability: RECORDS_FORM → one changes API step → one outcome check.
|
|
42
|
+
- [File-import path](frontend.FRONTEND-FLOWS.records_form.file-import-path.md) — The existing example below is the file-import path, retained for callers using the original full-row import contract.
|
|
@@ -0,0 +1,208 @@
|
|
|
1
|
+
> Part of [Frontend workflows](frontend.FRONTEND-FLOWS.md) › [RECORDS_FORM](frontend.FRONTEND-FLOWS.records_form.md).
|
|
2
|
+
|
|
3
|
+
### `RECORDS_FORM` change-set path
|
|
4
|
+
|
|
5
|
+
This complete generic declaration uses the deployed [changes capability](frontend.FRONTEND-FLOWS.task-and-reference-data-changes.md#availability-of-the-data-routes): `RECORDS_FORM` → one changes API step → one outcome check. It keeps the form's rows intact, sends no status numbers, and performs no verification read. Its TASK table declares `code` as the stored key, matching the form identity. The host supplies `inputs.PROFILE_ID`; the example identities stand for real published tasks/tables.
|
|
6
|
+
|
|
7
|
+
The check treats a disable `notFound` as already absent, which satisfies this example's remove action. A different business action may require reporting it instead. Initial and search reads still use the existing search route: load all rows the user needs (here at most 500) before editing, because unloaded rows cannot be removed in this form. The change set itself is limited to 5,000 rows.
|
|
8
|
+
|
|
9
|
+
```yaml
|
|
10
|
+
objects:
|
|
11
|
+
- id: "**Example_Records_Task_Id**"
|
|
12
|
+
name: Example records
|
|
13
|
+
type: REFERENCE
|
|
14
|
+
priority: 1000
|
|
15
|
+
description: "!md[./tasks/example-records.md]"
|
|
16
|
+
valueTableName: __hsm_example_records
|
|
17
|
+
ignoreRemoval: true
|
|
18
|
+
ignoreChange: false
|
|
19
|
+
- id: "**Example_Catalog_Task_Id**"
|
|
20
|
+
name: Example catalog
|
|
21
|
+
type: REFERENCE
|
|
22
|
+
priority: 1000
|
|
23
|
+
description: "!md[./tasks/example-catalog.md]"
|
|
24
|
+
valueTableName: __hsm_example_catalog
|
|
25
|
+
ignoreRemoval: true
|
|
26
|
+
ignoreChange: false
|
|
27
|
+
objectAssociations:
|
|
28
|
+
"**Example_Records_Task_Id**":
|
|
29
|
+
table: { id: "**Example_Records_Table_Id**" }
|
|
30
|
+
"**Example_Catalog_Task_Id**":
|
|
31
|
+
table: { id: "**Example_Catalog_Table_Id**" }
|
|
32
|
+
tables:
|
|
33
|
+
- id: "**Example_Records_Table_Id**"
|
|
34
|
+
columns:
|
|
35
|
+
code: { name: Code, indexGroups: [SOURCE_ID, KEYS] }
|
|
36
|
+
name: { name: Name }
|
|
37
|
+
quantity: { name: Quantity, dataType: Numeric }
|
|
38
|
+
note: { name: Note }
|
|
39
|
+
- id: "**Example_Catalog_Table_Id**"
|
|
40
|
+
columns:
|
|
41
|
+
code: { name: Code, indexGroups: [SOURCE_ID, KEYS] }
|
|
42
|
+
name: { name: Name }
|
|
43
|
+
getReadyFlows:
|
|
44
|
+
- key: EDIT_RECORDS_CHANGES
|
|
45
|
+
title: Edit records
|
|
46
|
+
action: { label: Edit records }
|
|
47
|
+
completionVersion: "1"
|
|
48
|
+
steps:
|
|
49
|
+
- key: READ_RECORDS
|
|
50
|
+
type: API
|
|
51
|
+
root: true
|
|
52
|
+
name: Read the current records
|
|
53
|
+
metadata: |-
|
|
54
|
+
curl --location '/proxy/workers/api/tasks/**Example_Records_Task_Id**/data/search' --request POST \
|
|
55
|
+
--header 'HSS-PROFILE-ID: {{ inputs.PROFILE_ID }}' \
|
|
56
|
+
--header 'Content-Type: application/json' \
|
|
57
|
+
--data '{"fields":[],"offset":0,"limit":500,"filters":{"condition":"AND","rightOp":[{"leftOp":"__status","condition":"not_hbw","rightOp":6}]}}'
|
|
58
|
+
next: EDIT
|
|
59
|
+
- key: EDIT
|
|
60
|
+
type: RECORDS_FORM
|
|
61
|
+
name: Edit records
|
|
62
|
+
description: Add, change or remove records. Nothing is saved until you confirm.
|
|
63
|
+
metadata:
|
|
64
|
+
target: { kind: TASK, taskId: "**Example_Records_Task_Id**" }
|
|
65
|
+
identity: [code]
|
|
66
|
+
initial: "jsonata:: outputs.READ_RECORDS.items"
|
|
67
|
+
columns:
|
|
68
|
+
- { key: code, name: Code, type: TEXT, required: true, readonly: true }
|
|
69
|
+
- { key: name, name: Name, type: TEXT, required: true }
|
|
70
|
+
- { key: quantity, name: Quantity, type: NUMBER, min: 0 }
|
|
71
|
+
- { key: note, name: Note, type: MULTILINE_TEXT }
|
|
72
|
+
allow: { add: true, edit: true, remove: true }
|
|
73
|
+
pageSize: 20
|
|
74
|
+
search:
|
|
75
|
+
request: |-
|
|
76
|
+
curl --location '/proxy/workers/api/tasks/**Example_Catalog_Task_Id**/data/search' --request POST \
|
|
77
|
+
--header 'HSS-PROFILE-ID: {{ inputs.PROFILE_ID }}' \
|
|
78
|
+
--header 'Content-Type: application/json' \
|
|
79
|
+
--data '{"fields":[],"offset":0,"limit":20,"filters":{"condition":"AND","rightOp":[{"leftOp":"__status","condition":"not_hbw","rightOp":6},{"leftOp":"code","condition":"ct","rightOp":{{ search.text | json | replace: "'", "\\u0027" }}}]}}'
|
|
80
|
+
items: "jsonata:: items"
|
|
81
|
+
label: "{{ item.code }} — {{ item.name }}"
|
|
82
|
+
fill: { code: "{{ item.code }}", name: "{{ item.name }}" }
|
|
83
|
+
next: HAS_CHANGES
|
|
84
|
+
onCancelled: CANCELLED
|
|
85
|
+
- key: HAS_CHANGES
|
|
86
|
+
type: IF
|
|
87
|
+
metadata:
|
|
88
|
+
condition: "${ $count(outputs.EDIT.upserts) + $count(outputs.EDIT.removes) > 0 }"
|
|
89
|
+
then: CHANGE_NOTE
|
|
90
|
+
else: NO_CHANGES
|
|
91
|
+
- key: CHANGE_NOTE
|
|
92
|
+
type: FORM
|
|
93
|
+
name: Why are you changing these records?
|
|
94
|
+
metadata:
|
|
95
|
+
fields:
|
|
96
|
+
- key: REASON
|
|
97
|
+
type: MULTILINE_TEXT
|
|
98
|
+
name: Reason (at least 32 characters, or 256 for a super admin)
|
|
99
|
+
required: true
|
|
100
|
+
next: SAVE
|
|
101
|
+
onCancelled: CANCELLED
|
|
102
|
+
- key: SAVE
|
|
103
|
+
type: API
|
|
104
|
+
name: Save the changes
|
|
105
|
+
metadata: |-
|
|
106
|
+
curl --location '/proxy/workers/api/v2/tasks/**Example_Records_Task_Id**/data/changes' --request POST \
|
|
107
|
+
--header 'HSS-PROFILE-ID: {{ inputs.PROFILE_ID }}' \
|
|
108
|
+
--header 'Content-Type: application/json' \
|
|
109
|
+
--data '{"notes":{{ outputs.CHANGE_NOTE.REASON | json | replace: "'", "\\u0027" }},"changes":{"upsert":{{ outputs.EDIT.upserts | json | replace: "'", "\\u0027" }},"disable":{{ outputs.EDIT.removes | json | replace: "'", "\\u0027" }}}}'
|
|
110
|
+
next: CHECK_SAVED
|
|
111
|
+
- key: CHECK_SAVED
|
|
112
|
+
type: IF
|
|
113
|
+
metadata:
|
|
114
|
+
condition: >-
|
|
115
|
+
${ (
|
|
116
|
+
$result := outputs.SAVE;
|
|
117
|
+
$rows := $result.rows;
|
|
118
|
+
$summary := $result.summary;
|
|
119
|
+
$upsertCount := $count(outputs.EDIT.upserts);
|
|
120
|
+
$disableCount := $count(outputs.EDIT.removes);
|
|
121
|
+
$upserts := $rows[op = "upsert"];
|
|
122
|
+
$disables := $rows[op = "disable"];
|
|
123
|
+
$whole := function($value) {
|
|
124
|
+
$type($value) = "number" ? $value >= 0 and $value = $floor($value) : false
|
|
125
|
+
};
|
|
126
|
+
$stored := function($value) {
|
|
127
|
+
$type($value) = "object" and $type($value.code) = "string"
|
|
128
|
+
};
|
|
129
|
+
$result._response.statusCode = 200 and $not($exists($result.error))
|
|
130
|
+
and $not($exists($result.errorCode)) and $type($result.changeId) = "string"
|
|
131
|
+
and $length($trim($result.changeId)) > 0
|
|
132
|
+
and $type($rows) = "array" and $count($rows[$type($) != "object"]) = 0
|
|
133
|
+
and $count($rows) = $upsertCount + $disableCount
|
|
134
|
+
and $count($upserts) = $upsertCount and $count($disables) = $disableCount
|
|
135
|
+
and $count($upserts[$whole(index) and index < $upsertCount
|
|
136
|
+
and outcome in ["inserted", "updated", "unchanged"] and $stored(row)]) = $upsertCount
|
|
137
|
+
and $count($disables[$whole(index) and index < $disableCount
|
|
138
|
+
and ((outcome in ["disabled", "unchanged"] and $stored(row))
|
|
139
|
+
or (outcome = "notFound" and ($not($exists(row)) or row = null)))]) = $disableCount
|
|
140
|
+
and $count($distinct($upserts.index)) = $upsertCount
|
|
141
|
+
and $count($distinct($disables.index)) = $disableCount
|
|
142
|
+
and $type($summary) = "object"
|
|
143
|
+
and $whole($summary.inserted) and $whole($summary.updated) and $whole($summary.unchanged)
|
|
144
|
+
and $whole($summary.disabled) and $whole($summary.enabled) and $whole($summary.notFound)
|
|
145
|
+
and $whole($summary.healed) and $summary.enabled = 0
|
|
146
|
+
and $summary.inserted = $count($rows[outcome = "inserted"])
|
|
147
|
+
and $summary.updated = $count($rows[outcome = "updated"])
|
|
148
|
+
and $summary.unchanged = $count($rows[outcome = "unchanged"])
|
|
149
|
+
and $summary.disabled = $count($rows[outcome = "disabled"])
|
|
150
|
+
and $summary.notFound = $count($rows[outcome = "notFound"])
|
|
151
|
+
) }
|
|
152
|
+
then: SHOW_SAVED
|
|
153
|
+
else: SHOW_FAILED
|
|
154
|
+
- key: SHOW_SAVED
|
|
155
|
+
type: SHOW_INFO
|
|
156
|
+
msg: Your changes are saved.
|
|
157
|
+
metadata: { type: SUCCESS, button_title: Finish }
|
|
158
|
+
next: DONE
|
|
159
|
+
- key: SHOW_FAILED
|
|
160
|
+
type: SHOW_INFO
|
|
161
|
+
msg: >-
|
|
162
|
+
{%- assign problem = outputs.SAVE.error.detail.rawData -%}
|
|
163
|
+
{%- assign expected_status = 0 -%}
|
|
164
|
+
{%- assign expected_retryable = false -%}
|
|
165
|
+
{%- case problem.code -%}
|
|
166
|
+
{%- when 'INVALID_REQUEST' -%}{%- assign expected_status = 400 -%}
|
|
167
|
+
{%- when 'FORBIDDEN' -%}{%- assign expected_status = 403 -%}
|
|
168
|
+
{%- when 'ENTITY_NOT_FOUND' -%}{%- assign expected_status = 404 -%}
|
|
169
|
+
{%- when 'TASK_BUSY' -%}{%- assign expected_status = 409 -%}{%- assign expected_retryable = true -%}
|
|
170
|
+
{%- when 'IDENTITY_CONFLICT', 'KEY_AMBIGUOUS', 'IDENTITY_UNREPAIRABLE', 'IDENTITY_REPAIR_REQUIRED' -%}{%- assign expected_status = 409 -%}
|
|
171
|
+
{%- when 'NOTES_TOO_SHORT', 'UNKNOWN_COLUMN', 'KEY_MISSING', 'DUPLICATE_ROWS', 'INVALID_VALUE', 'ENTITY_NOT_WRITABLE' -%}{%- assign expected_status = 422 -%}
|
|
172
|
+
{%- when 'AUDIT_UNAVAILABLE' -%}{%- assign expected_status = 502 -%}{%- assign expected_retryable = true -%}
|
|
173
|
+
{%- endcase -%}
|
|
174
|
+
{%- assign detail_json = problem.detail | json -%}
|
|
175
|
+
{%- assign detail_marker = detail_json | slice: 0, 1 -%}
|
|
176
|
+
{%- if outputs.SAVE._response == nil and expected_status != 0 and outputs.SAVE.error.detail.status == expected_status and problem.status == expected_status and problem.retryable == expected_retryable and detail_marker == '"' and problem.detail != empty -%}
|
|
177
|
+
{{ problem.code }} — {{ problem.detail }}
|
|
178
|
+
{%- else -%}
|
|
179
|
+
SAVE_UNVERIFIED — The service could not confirm the save. The changes may have been saved. Check the dataset before running this action again. Nothing was resent automatically.
|
|
180
|
+
{%- endif -%}
|
|
181
|
+
metadata: { type: ERROR, button_title: Close }
|
|
182
|
+
next: FAILED
|
|
183
|
+
- key: DONE
|
|
184
|
+
type: RETURN
|
|
185
|
+
metadata:
|
|
186
|
+
status: SUCCESS
|
|
187
|
+
outputs:
|
|
188
|
+
changeId: "{{ outputs.SAVE.changeId }}"
|
|
189
|
+
summary: "jsonata:: outputs.SAVE.summary"
|
|
190
|
+
upserted: "jsonata:: $count(outputs.EDIT.upserts)"
|
|
191
|
+
removed: "jsonata:: $count(outputs.EDIT.removes)"
|
|
192
|
+
- key: NO_CHANGES
|
|
193
|
+
type: RETURN
|
|
194
|
+
metadata:
|
|
195
|
+
status: SUCCESS
|
|
196
|
+
outputs: { upserted: 0, removed: 0 }
|
|
197
|
+
- key: FAILED
|
|
198
|
+
type: RETURN
|
|
199
|
+
metadata:
|
|
200
|
+
status: FAILED
|
|
201
|
+
error: { code: SAVE_FAILED, message: The row changes were refused or their outcome is unknown }
|
|
202
|
+
- key: CANCELLED
|
|
203
|
+
type: RETURN
|
|
204
|
+
metadata: { status: CANCELLED }
|
|
205
|
+
```
|
|
206
|
+
|
|
207
|
+
A controlled API refusal follows `next` to `CHECK_SAVED`. The failure display reads the nested error problem and checks the known code/status/retryable contract before showing its code/detail. HTTP500 `INTERNAL_ERROR`, malformed or contradictory answers and network loss instead show `SAVE_UNVERIFIED`, explain that the changes may have been saved and return FAILED. The display never claims rollback for an unknown outcome. The flow never retries automatically. SUCCESS confirms the change-set outcome, not downstream engine or provider execution. A no-change submission returns SUCCESS without calling changes, which refuses an empty set. IF metadata uses its native `${ … }` JSONata form; `jsonata::` is used in ordinary mapped fields and branch `next.if`, not this IF metadata slot.
|
|
208
|
+
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
> Part of [Frontend workflows](frontend.FRONTEND-FLOWS.md).
|
|
2
2
|
|
|
3
|
-
## RETURN
|
|
3
|
+
## `RETURN`
|
|
4
4
|
|
|
5
5
|
RETURN terminates one invocation before ordinary output postprocessing or successor advancement. It never creates `outputs.<RETURN_KEY>`. Grouped fall-through is `MISSING_RETURN`, not success. A dynamic route or loop remains statically uncertain even if the document contains a RETURN elsewhere.
|
|
6
6
|
|
|
7
7
|
`metadata.status` is required and exactly `SUCCESS`, `FAILED` or `CANCELLED`:
|
|
8
8
|
|
|
9
9
|
- SUCCESS requires `metadata.outputs`: a JSON object or `jsonata::` expression resolving to one. Nested values use pure existing Liquid/JSONata mapping and preserve JSON types. No `error` member.
|
|
10
|
-
- FAILED requires `metadata.error: {code,message}`. Both strings
|
|
10
|
+
- FAILED requires `metadata.error: {code,message}`. Both are nonempty strings describing the failure; no `outputs` member.
|
|
11
11
|
- CANCELLED has neither outputs nor error.
|
|
12
12
|
- No `next`, `onCancelled`, top-level `outputs[]`, flow `successOutputs` alias or storage processor is accepted.
|
|
13
13
|
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
> Part of [Frontend workflows](frontend.FRONTEND-FLOWS.md).
|
|
2
|
+
|
|
3
|
+
## Task and reference data changes
|
|
4
|
+
|
|
5
|
+
Save a form's row changes in one request and use the returned outcomes to tell the user what happened. These worker.proxy routes are for workflow-sized changes; the existing [file-import path](frontend.FRONTEND-FLOWS.records_form.file-import-path.md) remains available for files and full-row imports.
|
|
6
|
+
|
|
7
|
+
### Availability of the data routes
|
|
8
|
+
|
|
9
|
+
**Unreleased capability:** the changes, preview, health and repair routes, and the corrected v2 search cursors (search the standards MCP), are implemented on worker.proxy `feats/task-flow`, PR #78. No published worker.proxy version has been identified as containing this feature. Enable a flow using it only after a worker.proxy build containing the feature has been deployed; record the actual first published version when released. An older proxy can forward an unknown route to the worker and return 404. No core.api version or worker upgrade is a prerequisite. This note is not a release or deployment claim.
|
|
10
|
+
|
|
11
|
+
### Changes: apply a row change set
|
|
12
|
+
|
|
13
|
+
`POST /api/v2/{entityType}/{entityId}/data/changes` requires profile UPDATE. `entityType` is `tasks` or `references` (an in-schema reference). Frontend API requests use `/proxy/workers/api/v2/…` and `HSS-PROFILE-ID`, through the same authenticated forwarding as other worker.proxy data calls.
|
|
14
|
+
|
|
15
|
+
```json
|
|
16
|
+
{
|
|
17
|
+
"notes": "Corrected these records after checking the source list.",
|
|
18
|
+
"apply": true,
|
|
19
|
+
"changes": {
|
|
20
|
+
"upsert": [{ "code": "A", "quantity": 5 }],
|
|
21
|
+
"disable": [{ "code": "B" }],
|
|
22
|
+
"enable": [{ "code": "C" }]
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
| Member or rule | Syntax, default and choice |
|
|
28
|
+
| --- | --- |
|
|
29
|
+
| `notes` | Required real reason, at least 32 characters, or 256 for a super admin. Ask the user; do not substitute a fixed reason. |
|
|
30
|
+
| `apply` | Optional boolean, default `true`: let the engine act on the change. `false` saves the requested data/state without newly scheduling it for application; it is not a preview. |
|
|
31
|
+
| `changes` | Required object containing optional `upsert`, `disable`, `enable` arrays. Send 1–5,000 rows in total; an empty set or unknown operation is refused. Skip saving when the form has no changes. Larger file loads use import. |
|
|
32
|
+
| `upsert` | Each row includes every key column and the columns to write. Omitted columns keep their value on update and use their database default on insert. A declared column with `null` is an explicit value, not omission. |
|
|
33
|
+
| `disable`, `enable` | Each row includes every key column; other data is not updated. Disable never deletes a row. A missing row returns `notFound`, not a refusal. |
|
|
34
|
+
| Keys | The union of the table's `SOURCE_ID` and `KEYS` columns. Every row carries every part; null/blank parts are allowed where the dataset allows them. One key appears once across the entire request. A dataset without keys, or a report, is not writable. |
|
|
35
|
+
| System members | `__*` members in the form's full rows are ignored. Do not construct status numbers, enabled flags or hashes. The service changes row state while preserving unrelated flags. |
|
|
36
|
+
| Tasks and references | Both use these routes. Reference keys match column by column, including null parts; hyphens do not join key parts into one identity. Stored duplicate keys are refused. `RECORDS_FORM.target` still accepts only TASK or WORKER_SETTINGS; a new route does not add a new form target kind. |
|
|
37
|
+
|
|
38
|
+
For a form, send `outputs.EDIT.upserts` as `changes.upsert` and `outputs.EDIT.removes` as `changes.disable`. The whole change set commits or none of it does. A repeated identical request is safe and returns `unchanged` for rows already in the requested state; this does not authorize an automatic retry after an uncertain network result.
|
|
39
|
+
|
|
40
|
+
A `200` response has `changeId`, `summary` and `rows`. Summary members are `inserted`, `updated`, `unchanged`, `disabled`, `enabled`, `notFound` and `healed`; healing is counted beside outcomes, so a row can be both unchanged and healed. Each row result contains `op`, its zero-based `index` within that operation, `outcome` and `row` (the stored content, or null for `notFound`). Results are ordered upsert, disable, enable, preserving order within each list.
|
|
41
|
+
|
|
42
|
+
| `op` | Possible `outcome` | What the flow should check |
|
|
43
|
+
| --- | --- | --- |
|
|
44
|
+
| `upsert` | `inserted`, `updated`, `unchanged` | The requested row is stored. Read `row` for its final content. |
|
|
45
|
+
| `disable` | `disabled`, `unchanged`, `notFound` | `notFound` means the row was already absent. Decide explicitly whether that satisfies this action. |
|
|
46
|
+
| `enable` | `enabled`, `unchanged`, `notFound` | A missing row has not been created or enabled; ask the user to correct the selection if an existing row was required. |
|
|
47
|
+
|
|
48
|
+
The returned rows are read in the transaction that writes them, using the search route's safe projection. **No second read is needed to verify the save.** A successful save is not proof that a pusher or external system has acted. Check the API status and the operation outcomes before returning SUCCESS; keep coded refusals and unknown network outcomes on a failure path.
|
|
49
|
+
|
|
50
|
+
### Preview: inspect changes without saving
|
|
51
|
+
|
|
52
|
+
`POST /api/v2/{entityType}/{entityId}/data/changes/preview` requires profile UPDATE. Send the same change-set body; `notes` is optional here. A `200` returns `summary` and `rows` with `op`, `index`, `outcome` and `current`, the stored row before the proposed change. `current` is absent for a row that does not exist. There is no `changeId`, write, audit file/event or table lock. The same validation, identity and ambiguity refusals apply. Preview is an observation, not a reservation: another save may change the result before apply.
|
|
53
|
+
|
|
54
|
+
### Health: inspect a dataset
|
|
55
|
+
|
|
56
|
+
`GET /api/v2/{entityType}/{entityId}/data/health` requires profile READ. It reports `entityType`, `keyColumns`, `keysAllText`, `rows`, `withoutIdentity`, `repairable`, `duplicateIdentity`, `duplicateKey`, `nullKeyRows`, `withoutChangeHash` and `samples`. Duplicate counts are shared-key/identity **groups**, not the number of rows in those groups. `withoutChangeHash` is an additional task diagnostic; repair can heal only the rows whose stored key/value proof is safe. Samples contain at most 20 declared-key dictionaries per list, one representative per duplicate group, with text/null key values and no raw/hash payloads. The lists are `withoutIdentity`, `repairable`, `duplicateIdentity`, `duplicateKey`, `nullKeyRows`, `withoutChangeHash`. Task identity problems are distinct from duplicate keys; a clean report describes this observation, not protection against later concurrent writes.
|
|
57
|
+
|
|
58
|
+
For an in-schema reference, `withoutIdentity`, `repairable`, `duplicateIdentity`, `withoutChangeHash` and their sample lists are explicitly null; `nullKeyRows` counts rows with a null key part and supplies samples. For a task, `nullKeyRows` and its sample list are null. A null reference key part alone is not a duplicate or a reason to discard a row: reference matching is null-safe. Health reads one consistent primary-database snapshot; it creates no audit file/event, takes no row-write lock and does not save or repair anything.
|
|
59
|
+
|
|
60
|
+
### Repair: heal task rows without identity or change hash
|
|
61
|
+
|
|
62
|
+
`POST /api/v2/tasks/{taskId}/data/repair` requires profile UPDATE. Send `{ "notes": "A real reason meeting the write-note length rule.", "limit": 5000 }`. `limit` is optional, defaults to 5,000, and accepts 1–50,000. Repair is task-only: it fills a missing identity and/or change hash where the stored data proves the result, with text key columns and one bounded, audited transaction. Missing means null or zero-length. It does not rewrite an existing nonempty identity or change hash, or change business values/status. The limit bounds eligible rows after conflicts have been classified across the dataset; conflicts do not consume a batch slot.
|
|
63
|
+
|
|
64
|
+
A `200` returns `healed`, `conflicts`, `remaining` and `samples.conflicts` (at most 20 declared-key dictionaries). `healed` counts distinct rows repaired for either deficit, not individual hashes. `remaining` counts rows still missing an identity **or** a change hash, including conflicts and eligible rows beyond this batch. Counts describe the same locked transaction.
|
|
65
|
+
|
|
66
|
+
An identity already owned by another row or shared by identity-less rows is a conflict. A stored-key/value proof that would change meaning through normalization, truncation, date/character conversion or an unhashable value is also a conflict: those rows remain untouched. Inspect the samples and correct the data explicitly; repeat bounded repair deliberately for eligible rows still remaining. A non-text key is refused with `IDENTITY_UNREPAIRABLE`. `IDENTITY_REPAIR_REQUIRED` is a save refusal directing the caller here, not a repair-backlog limit: repair processes a large backlog in bounded requests. Repair is not a reference deduplication tool.
|
|
67
|
+
|
|
68
|
+
### Data-route refusals
|
|
69
|
+
|
|
70
|
+
The four new routes return `application/problem+json` with `type`, `title`, `status`, `code`, `retryable`, `detail` and, when rows are at fault, `rows`. A row fault names `code`, `key`, optional `column` and, for an input row, `op` plus zero-based `index`. Up to 50 row faults are listed under the first refusal code. Branch on the code and retryable flag, never on message wording. The authentication layer can reject an unauthenticated request before a route runs; restore sign-in before handling its application result.
|
|
71
|
+
|
|
72
|
+
| HTTP | Code | Retryable | Flow response |
|
|
73
|
+
| --- | --- | --- | --- |
|
|
74
|
+
| 400 | `INVALID_REQUEST` | false | Correct the body, operation names, ids, header or size; send a nonempty bounded set. |
|
|
75
|
+
| 403 | `FORBIDDEN` | false | Obtain profile UPDATE, or READ for health; do not resend unchanged credentials. |
|
|
76
|
+
| 404 | `ENTITY_NOT_FOUND` | false | Select a dataset from this profile's published definition. |
|
|
77
|
+
| 409 | `TASK_BUSY` | true | Wait and offer a bounded retry; the dataset lock was not granted within 5 seconds. |
|
|
78
|
+
| 409 | `IDENTITY_CONFLICT` | false | Ask an operator to resolve the conflicting keys/identities before saving. |
|
|
79
|
+
| 409 | `KEY_AMBIGUOUS` | false | Resolve stored duplicate keys; do not choose an arbitrary stored row. |
|
|
80
|
+
| 409 | `IDENTITY_UNREPAIRABLE` | false | Correct the identity-less rows explicitly; automatic reconstruction cannot prove a non-text key. |
|
|
81
|
+
| 409 | `IDENTITY_REPAIR_REQUIRED` | false | Inspect health and run bounded task repair before saving again. |
|
|
82
|
+
| 422 | `NOTES_TOO_SHORT` | false | Ask for a real reason of at least 32 characters, or 256 for a super admin. |
|
|
83
|
+
| 422 | `UNKNOWN_COLUMN` | false | Correct the row's undeclared column name. |
|
|
84
|
+
| 422 | `KEY_MISSING` | false | Include every declared key column on each row. |
|
|
85
|
+
| 422 | `DUPLICATE_ROWS` | false | Send each key once across all operations. |
|
|
86
|
+
| 422 | `INVALID_VALUE` | false | Correct the named row/column to a value its database column accepts. |
|
|
87
|
+
| 422 | `ENTITY_NOT_WRITABLE` | false | Fix the dataset definition or select a keyed task/reference; reports cannot be changed. |
|
|
88
|
+
| 502 | `AUDIT_UNAVAILABLE` | true | Explain that audit storage/event delivery failed and the transaction rolled back; offer a later retry. |
|
|
89
|
+
| 500 | `INTERNAL_ERROR` | false | The save outcome is unconfirmed. Check the dataset and contact support before an explicit retry; never assume rollback or resend automatically. |
|
|
90
|
+
|
|
91
|
+
In a frontend `API` step a controlled non-2xx answer still follows plain `next`, so its next step must classify the actual error envelope: the HTTP status is `outputs.SAVE.error.detail.status`, and the problem document is `outputs.SAVE.error.detail.rawData` (its `code`, `detail`, `status` and `retryable`). Successful body members instead appear beside `outputs.SAVE._response`. Do not read a controlled refusal from top-level `SAVE.code`/`SAVE.detail`. A known refusal needs the documented code, matching transport/body status and retryable flag. `INTERNAL_ERROR`, an unrecognized or malformed problem, and network uncertainty are **unknown save outcomes**: changes may already be committed. Check the dataset before an explicit retry; never promise rollback or resend automatically. Existing import and search routes retain their own error formats; these problem codes do not replace them.
|
|
92
|
+
|
|
@@ -40,16 +40,16 @@ One output per value needed downstream, each a short, non-blank program reading
|
|
|
40
40
|
|
|
41
41
|
Each field is evaluated independently: a result from one output name is not visible to sibling expressions in the same step. Embedded `{{ }}` Scriban templates inside a program are rendered before the JSONata is evaluated.
|
|
42
42
|
|
|
43
|
-
Two extra functions are available in this step (and in
|
|
43
|
+
Two extra functions are available in this step (and in responseFilters.jsonata (search the standards MCP)) but not at item-transformation, argument or frontend sites:
|
|
44
44
|
|
|
45
45
|
- `$parseJson(text)` parses a JSON string. Undefined input stays undefined; non-string input and malformed JSON fail.
|
|
46
|
-
- `$fingerprint(value)` returns a stable SHA-256 digest of a value's structure (object key order normalised, array order and value types preserved). Undefined or unsupported input fails; explicit `null` is a valid input. Use it to compare raw response payloads, e.g. to detect a repeated page; see the
|
|
46
|
+
- `$fingerprint(value)` returns a stable SHA-256 digest of a value's structure (object key order normalised, array order and value types preserved). Undefined or unsupported input fails; explicit `null` is a valid input. Use it to compare raw response payloads, e.g. to detect a repeated page; see the adjacent-page recipe (search the standards MCP).
|
|
47
47
|
|
|
48
48
|
## Fields
|
|
49
49
|
|
|
50
50
|
### `data`
|
|
51
51
|
|
|
52
|
-
`data: { <name>: {expression: <jsonata>} } | null` — the output map. Missing, `null` or `{}` produces an empty output object. Any other non-object value fails. If `data` is present (even as `null`) it wins over the compatibility `input` spelling; see
|
|
52
|
+
`data: { <name>: {expression: <jsonata>} } | null` — the output map. Missing, `null` or `{}` produces an empty output object. Any other non-object value fails. If `data` is present (even as `null`) it wins over the compatibility `input` spelling; see STEP-ENVELOPE (search the standards MCP).
|
|
53
53
|
|
|
54
54
|
```yaml
|
|
55
55
|
- key: SHAPE
|
|
@@ -147,14 +147,14 @@ Embedded Scriban variant — any `{{ … }}` template inside the program is rend
|
|
|
147
147
|
amount: {expression: '{{ _outputs.PARSE.amount }}'}
|
|
148
148
|
```
|
|
149
149
|
|
|
150
|
-
|
|
150
|
+
VALUES (search the standards MCP) publishes the row first. `_outputs.PARSE = {amount: 2}`: the string body is decoded and the undefined `missing` member is omitted. [Scriban](steps.Scriban.md#contract) then keeps `2` as a number.
|
|
151
151
|
|
|
152
152
|
## Boundaries and correction
|
|
153
153
|
|
|
154
154
|
- Rejected form: `data: {jsonata: {amount: {expression: ...}}}` — that is response-filter syntax. Put `amount` directly under `data`.
|
|
155
155
|
- A blank program silently omits its output, while a malformed non-blank one fails the step.
|
|
156
156
|
- `data: {blank: {expression: '""'}, nil: {expression: 'null'}, skipped: {expression: ' '}}` produces `{blank: ""}`: blankness is checked on the program text, omission on the evaluated value.
|
|
157
|
-
- `data: {bad: {expression: '$sum('}}` fails without a partial result. Fix the program; an `onError` route (
|
|
157
|
+
- `data: {bad: {expression: '$sum('}}` fails without a partial result. Fix the program; an `onError` route (STEP-ENVELOPE (search the standards MCP)) can handle the failure but does not turn it into a success.
|
|
158
158
|
- Explicit `data: null` wins over a usable `input`; the step produces `{}`.
|
|
159
159
|
- Do not depend on sibling outputs within the same step, or on `$parseJson`/`$fingerprint` at item-transformation or argument sites.
|
|
160
160
|
- `acceptedStatuses` (a response-filter member) has no effect here; a leaf with only `acceptedStatuses` is skipped. Author only `expression`.
|
|
@@ -193,8 +193,8 @@ No-op forms that are schema-valid but produce nothing:
|
|
|
193
193
|
|
|
194
194
|
## Related
|
|
195
195
|
|
|
196
|
-
-
|
|
196
|
+
- Workflow and step envelope (search the standards MCP)
|
|
197
197
|
- [Context and expression dialects](expressions.CONTEXT-AND-IO.md)
|
|
198
198
|
- [Scriban step](steps.Scriban.md#contract)
|
|
199
|
-
-
|
|
200
|
-
-
|
|
199
|
+
- Routing (search the standards MCP)
|
|
200
|
+
- All step types (search the standards MCP)
|
|
@@ -91,5 +91,5 @@ Composed replacement — render a value produced earlier:
|
|
|
91
91
|
## Related
|
|
92
92
|
|
|
93
93
|
- [Scriban](steps.Scriban.md#contract), [JSONata](steps.JSONata.md#contract)
|
|
94
|
-
-
|
|
95
|
-
-
|
|
94
|
+
- Workflow and step envelope (search the standards MCP)
|
|
95
|
+
- All step types (search the standards MCP)
|