n8n 2.43.3 → 2.44.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/abstract-server.d.ts +2 -0
- package/dist/abstract-server.js +12 -1
- package/dist/abstract-server.js.map +1 -1
- package/dist/agent-library-bundle.js +8 -0
- package/dist/auth/auth.service.js +1 -1
- package/dist/auth/auth.service.js.map +1 -1
- package/dist/binary-data/binary-data-access.service.d.ts +4 -1
- package/dist/binary-data/binary-data-access.service.js +20 -6
- package/dist/binary-data/binary-data-access.service.js.map +1 -1
- package/dist/build.tsbuildinfo +1 -1
- package/dist/chat/chat-execution-manager.js +1 -0
- package/dist/chat/chat-execution-manager.js.map +1 -1
- package/dist/commands/base-command.d.ts +4 -0
- package/dist/commands/base-command.js +10 -3
- package/dist/commands/base-command.js.map +1 -1
- package/dist/commands/engine.d.ts +1 -0
- package/dist/commands/engine.js +16 -0
- package/dist/commands/engine.js.map +1 -1
- package/dist/commands/start.js +0 -4
- package/dist/commands/start.js.map +1 -1
- package/dist/commands/webhook.js +1 -0
- package/dist/commands/webhook.js.map +1 -1
- package/dist/controllers/e2e.controller.js +1 -0
- package/dist/controllers/e2e.controller.js.map +1 -1
- package/dist/crash-journal.js +1 -1
- package/dist/crash-journal.js.map +1 -1
- package/dist/credentials/credential-options.controller.d.ts +10 -0
- package/dist/credentials/credential-options.controller.js +64 -0
- package/dist/credentials/credential-options.controller.js.map +1 -0
- package/dist/credentials/credential-options.service.d.ts +21 -0
- package/dist/credentials/credential-options.service.js +105 -0
- package/dist/credentials/credential-options.service.js.map +1 -0
- package/dist/credentials/credentials.service.d.ts +12 -2
- package/dist/credentials/credentials.service.ee.d.ts +3 -1
- package/dist/credentials/credentials.service.ee.js +8 -2
- package/dist/credentials/credentials.service.ee.js.map +1 -1
- package/dist/credentials/credentials.service.js +44 -18
- package/dist/credentials/credentials.service.js.map +1 -1
- package/dist/credentials/pending-authorization-cleanup.task.js +5 -1
- package/dist/credentials/pending-authorization-cleanup.task.js.map +1 -1
- package/dist/errors/job-returned-to-queue.error.d.ts +5 -0
- package/dist/errors/job-returned-to-queue.error.js +12 -0
- package/dist/errors/job-returned-to-queue.error.js.map +1 -0
- package/dist/errors/response-errors/incompatible-nodes-api-version.error.d.ts +4 -4
- package/dist/events/maps/relay.event-map.d.ts +24 -2
- package/dist/events/maps/system-task-metrics.event-map.d.ts +1 -1
- package/dist/events/maps/system-task-metrics.event-map.js.map +1 -1
- package/dist/events/relays/telemetry.event-relay.d.ts +2 -0
- package/dist/events/relays/telemetry.event-relay.js +66 -2
- package/dist/events/relays/telemetry.event-relay.js.map +1 -1
- package/dist/execution-lifecycle/execution-lifecycle-hooks.js +3 -2
- package/dist/execution-lifecycle/execution-lifecycle-hooks.js.map +1 -1
- package/dist/executions/engine-v2-execution-reader.service.d.ts +4 -0
- package/dist/executions/engine-v2-execution-reader.service.js +11 -0
- package/dist/executions/engine-v2-execution-reader.service.js.map +1 -1
- package/dist/executions/enqueued-execution-recovery.service.js +5 -1
- package/dist/executions/enqueued-execution-recovery.service.js.map +1 -1
- package/dist/executions/execution-crash.service.d.ts +3 -1
- package/dist/executions/execution-crash.service.js +4 -4
- package/dist/executions/execution-crash.service.js.map +1 -1
- package/dist/executions/execution-id.d.ts +1 -0
- package/dist/executions/execution-id.js +4 -1
- package/dist/executions/execution-id.js.map +1 -1
- package/dist/executions/execution-persistence.js +1 -1
- package/dist/executions/execution-persistence.js.map +1 -1
- package/dist/executions/execution-recovery.service.d.ts +1 -0
- package/dist/executions/execution-recovery.service.js +17 -5
- package/dist/executions/execution-recovery.service.js.map +1 -1
- package/dist/executions/execution.service.js +1 -0
- package/dist/executions/execution.service.js.map +1 -1
- package/dist/executions/pre-execution-checks/credentials-permission-checker.d.ts +3 -1
- package/dist/executions/pre-execution-checks/credentials-permission-checker.js +32 -3
- package/dist/executions/pre-execution-checks/credentials-permission-checker.js.map +1 -1
- package/dist/interfaces.d.ts +4 -1
- package/dist/license/license-renewal.task.d.ts +3 -0
- package/dist/license/license-renewal.task.js +4 -1
- package/dist/license/license-renewal.task.js.map +1 -1
- package/dist/license.js +14 -3
- package/dist/license.js.map +1 -1
- package/dist/load-nodes-and-credentials.d.ts +6 -0
- package/dist/load-nodes-and-credentials.js +28 -12
- package/dist/load-nodes-and-credentials.js.map +1 -1
- package/dist/manual-execution.service.d.ts +5 -3
- package/dist/manual-execution.service.js +7 -6
- package/dist/manual-execution.service.js.map +1 -1
- package/dist/metrics/prometheus/active-workflow-metrics.service.d.ts +3 -5
- package/dist/metrics/prometheus/active-workflow-metrics.service.js +6 -13
- package/dist/metrics/prometheus/active-workflow-metrics.service.js.map +1 -1
- package/dist/metrics/prometheus/cached-metric-query.d.ts +14 -3
- package/dist/metrics/prometheus/cached-metric-query.js +59 -7
- package/dist/metrics/prometheus/cached-metric-query.js.map +1 -1
- package/dist/metrics/prometheus/constant.d.ts +1 -0
- package/dist/metrics/prometheus/constant.js +2 -1
- package/dist/metrics/prometheus/constant.js.map +1 -1
- package/dist/metrics/prometheus/database-metric-query.service.d.ts +39 -0
- package/dist/metrics/prometheus/database-metric-query.service.js +88 -0
- package/dist/metrics/prometheus/database-metric-query.service.js.map +1 -0
- package/dist/metrics/prometheus/db-pool-metrics.service.js +21 -0
- package/dist/metrics/prometheus/db-pool-metrics.service.js.map +1 -1
- package/dist/metrics/prometheus/prometheus.service.d.ts +3 -1
- package/dist/metrics/prometheus/prometheus.service.js +7 -3
- package/dist/metrics/prometheus/prometheus.service.js.map +1 -1
- package/dist/metrics/prometheus/scheduler-metrics.service.d.ts +7 -5
- package/dist/metrics/prometheus/scheduler-metrics.service.js +30 -23
- package/dist/metrics/prometheus/scheduler-metrics.service.js.map +1 -1
- package/dist/metrics/prometheus/system-task-metrics.service.d.ts +4 -6
- package/dist/metrics/prometheus/system-task-metrics.service.js +9 -22
- package/dist/metrics/prometheus/system-task-metrics.service.js.map +1 -1
- package/dist/metrics/prometheus/workflow-info-metrics.service.d.ts +3 -5
- package/dist/metrics/prometheus/workflow-info-metrics.service.js +14 -20
- package/dist/metrics/prometheus/workflow-info-metrics.service.js.map +1 -1
- package/dist/metrics/prometheus/workflow-publication-metrics.service.d.ts +4 -5
- package/dist/metrics/prometheus/workflow-publication-metrics.service.js +10 -22
- package/dist/metrics/prometheus/workflow-publication-metrics.service.js.map +1 -1
- package/dist/metrics/prometheus/workflow-statistics-metrics.service.d.ts +3 -5
- package/dist/metrics/prometheus/workflow-statistics-metrics.service.js +6 -13
- package/dist/metrics/prometheus/workflow-statistics-metrics.service.js.map +1 -1
- package/dist/middlewares/content-security-policy.js +45 -10
- package/dist/middlewares/content-security-policy.js.map +1 -1
- package/dist/middlewares/list-query/dtos/workflow.filter.dto.d.ts +2 -0
- package/dist/middlewares/list-query/dtos/workflow.filter.dto.js +9 -0
- package/dist/middlewares/list-query/dtos/workflow.filter.dto.js.map +1 -1
- package/dist/modules/agent-evals/agent-eval-case-generation.service.d.ts +8 -2
- package/dist/modules/agent-evals/agent-eval-case-generation.service.js +113 -14
- package/dist/modules/agent-evals/agent-eval-case-generation.service.js.map +1 -1
- package/dist/modules/agent-evals/agent-eval-fix-suggestion.d.ts +21 -0
- package/dist/modules/agent-evals/agent-eval-fix-suggestion.js +55 -0
- package/dist/modules/agent-evals/agent-eval-fix-suggestion.js.map +1 -0
- package/dist/modules/agent-evals/agent-eval-instructions-rewrite.d.ts +22 -0
- package/dist/modules/agent-evals/agent-eval-instructions-rewrite.js +108 -0
- package/dist/modules/agent-evals/agent-eval-instructions-rewrite.js.map +1 -0
- package/dist/modules/agent-evals/agent-eval-judge.d.ts +22 -0
- package/dist/modules/agent-evals/agent-eval-judge.js +36 -0
- package/dist/modules/agent-evals/agent-eval-judge.js.map +1 -0
- package/dist/modules/agent-evals/agent-eval-record-mappers.js +8 -0
- package/dist/modules/agent-evals/agent-eval-record-mappers.js.map +1 -1
- package/dist/modules/agent-evals/agent-eval-runner.service.d.ts +12 -2
- package/dist/modules/agent-evals/agent-eval-runner.service.js +102 -2
- package/dist/modules/agent-evals/agent-eval-runner.service.js.map +1 -1
- package/dist/modules/agent-evals/agent-eval.service.d.ts +17 -3
- package/dist/modules/agent-evals/agent-eval.service.js +185 -2
- package/dist/modules/agent-evals/agent-eval.service.js.map +1 -1
- package/dist/modules/agent-evals/agent-evals.controller.d.ts +16 -2
- package/dist/modules/agent-evals/agent-evals.controller.js +111 -2
- package/dist/modules/agent-evals/agent-evals.controller.js.map +1 -1
- package/dist/modules/agent-evals/case-generation/case-generation-prompt.d.ts +18 -1
- package/dist/modules/agent-evals/case-generation/case-generation-prompt.js +47 -9
- package/dist/modules/agent-evals/case-generation/case-generation-prompt.js.map +1 -1
- package/dist/modules/agents/agent-budget-alert.service.d.ts +21 -0
- package/dist/modules/agents/agent-budget-alert.service.js +82 -0
- package/dist/modules/agents/agent-budget-alert.service.js.map +1 -0
- package/dist/modules/agents/agent-chat-execution.service.d.ts +6 -2
- package/dist/modules/agents/agent-chat-execution.service.js +13 -15
- package/dist/modules/agents/agent-chat-execution.service.js.map +1 -1
- package/dist/modules/agents/agent-chat.controller.d.ts +36 -0
- package/dist/modules/agents/agent-chat.controller.js +149 -54
- package/dist/modules/agents/agent-chat.controller.js.map +1 -1
- package/dist/modules/agents/agent-checkpoint-pruning.task.d.ts +5 -2
- package/dist/modules/agents/agent-checkpoint-pruning.task.js +7 -4
- package/dist/modules/agents/agent-checkpoint-pruning.task.js.map +1 -1
- package/dist/modules/agents/agent-config-preparation.service.d.ts +325 -0
- package/dist/modules/agents/agent-config-preparation.service.js +100 -0
- package/dist/modules/agents/agent-config-preparation.service.js.map +1 -0
- package/dist/modules/agents/agent-config.service.d.ts +15 -18
- package/dist/modules/agents/agent-config.service.js +58 -129
- package/dist/modules/agents/agent-config.service.js.map +1 -1
- package/dist/modules/agents/agent-context-readers.js +1 -2
- package/dist/modules/agents/agent-context-readers.js.map +1 -1
- package/dist/modules/agents/agent-custom-tools.service.d.ts +8 -9
- package/dist/modules/agents/agent-custom-tools.service.js +14 -19
- package/dist/modules/agents/agent-custom-tools.service.js.map +1 -1
- package/dist/modules/agents/agent-definition.service.d.ts +19 -0
- package/dist/modules/agents/agent-definition.service.js +75 -0
- package/dist/modules/agents/agent-definition.service.js.map +1 -0
- package/dist/modules/agents/agent-execution-orchestrator.service.d.ts +10 -8
- package/dist/modules/agents/agent-execution-orchestrator.service.js +250 -146
- package/dist/modules/agents/agent-execution-orchestrator.service.js.map +1 -1
- package/dist/modules/agents/agent-execution-update-broadcaster.js +2 -1
- package/dist/modules/agents/agent-execution-update-broadcaster.js.map +1 -1
- package/dist/modules/agents/agent-execution.service.d.ts +9 -1
- package/dist/modules/agents/agent-execution.service.js +22 -1
- package/dist/modules/agents/agent-execution.service.js.map +1 -1
- package/dist/modules/agents/agent-integration-persistence.service.d.ts +3 -1
- package/dist/modules/agents/agent-integration-persistence.service.js +23 -15
- package/dist/modules/agents/agent-integration-persistence.service.js.map +1 -1
- package/dist/modules/agents/agent-integrations.controller.d.ts +12 -2
- package/dist/modules/agents/agent-integrations.controller.js +49 -4
- package/dist/modules/agents/agent-integrations.controller.js.map +1 -1
- package/dist/modules/agents/agent-interrupted-execution-sweep.task.d.ts +12 -0
- package/dist/modules/agents/agent-interrupted-execution-sweep.task.js +36 -0
- package/dist/modules/agents/agent-interrupted-execution-sweep.task.js.map +1 -0
- package/dist/modules/agents/agent-interrupted-execution-sweeper.d.ts +3 -2
- package/dist/modules/agents/agent-interrupted-execution-sweeper.js +20 -7
- package/dist/modules/agents/agent-interrupted-execution-sweeper.js.map +1 -1
- package/dist/modules/agents/agent-message-queue-consumer.service.js +2 -5
- package/dist/modules/agents/agent-message-queue-consumer.service.js.map +1 -1
- package/dist/modules/agents/agent-message-queue.service.d.ts +3 -1
- package/dist/modules/agents/agent-message-queue.service.js +7 -5
- package/dist/modules/agents/agent-message-queue.service.js.map +1 -1
- package/dist/modules/agents/agent-message-steering.service.d.ts +2 -1
- package/dist/modules/agents/agent-message-steering.service.js +17 -9
- package/dist/modules/agents/agent-message-steering.service.js.map +1 -1
- package/dist/modules/agents/agent-modification-telemetry.service.d.ts +33 -3
- package/dist/modules/agents/agent-modification-telemetry.service.js +11 -8
- package/dist/modules/agents/agent-modification-telemetry.service.js.map +1 -1
- package/dist/modules/agents/agent-n8n-chat-unavailable.error.d.ts +4 -0
- package/dist/modules/agents/agent-n8n-chat-unavailable.error.js +11 -0
- package/dist/modules/agents/agent-n8n-chat-unavailable.error.js.map +1 -0
- package/dist/modules/agents/agent-policy.service.d.ts +10 -0
- package/dist/modules/agents/agent-policy.service.js +44 -0
- package/dist/modules/agents/agent-policy.service.js.map +1 -0
- package/dist/modules/agents/agent-publish.service.d.ts +17 -8
- package/dist/modules/agents/agent-publish.service.js +95 -113
- package/dist/modules/agents/agent-publish.service.js.map +1 -1
- package/dist/modules/agents/agent-push-recipients.service.d.ts +1 -0
- package/dist/modules/agents/agent-push-recipients.service.js +5 -2
- package/dist/modules/agents/agent-push-recipients.service.js.map +1 -1
- package/dist/modules/agents/agent-runnable-state.service.d.ts +3 -1
- package/dist/modules/agents/agent-runnable-state.service.js +5 -3
- package/dist/modules/agents/agent-runnable-state.service.js.map +1 -1
- package/dist/modules/agents/agent-runtime-cache.service.d.ts +3 -1
- package/dist/modules/agents/agent-runtime-cache.service.js +7 -7
- package/dist/modules/agents/agent-runtime-cache.service.js.map +1 -1
- package/dist/modules/agents/agent-runtime-instrumentation.d.ts +6 -0
- package/dist/modules/agents/agent-runtime-reconstruction.service.d.ts +2 -2
- package/dist/modules/agents/agent-runtime-reconstruction.service.js +23 -16
- package/dist/modules/agents/agent-runtime-reconstruction.service.js.map +1 -1
- package/dist/modules/agents/agent-save-completion.service.d.ts +14 -0
- package/dist/modules/agents/agent-save-completion.service.js +51 -0
- package/dist/modules/agents/agent-save-completion.service.js.map +1 -0
- package/dist/modules/agents/agent-setup-completion.service.d.ts +2 -1
- package/dist/modules/agents/agent-setup-completion.service.js +5 -3
- package/dist/modules/agents/agent-setup-completion.service.js.map +1 -1
- package/dist/modules/agents/agent-skill-refs.service.d.ts +12 -0
- package/dist/modules/agents/agent-skill-refs.service.js +52 -0
- package/dist/modules/agents/agent-skill-refs.service.js.map +1 -0
- package/dist/modules/agents/agent-skills.service.d.ts +14 -8
- package/dist/modules/agents/agent-skills.service.js +64 -41
- package/dist/modules/agents/agent-skills.service.js.map +1 -1
- package/dist/modules/agents/agent-sse-stream.d.ts +1 -0
- package/dist/modules/agents/agent-sse-stream.js +15 -0
- package/dist/modules/agents/agent-sse-stream.js.map +1 -1
- package/dist/modules/agents/agent-task.service.d.ts +12 -7
- package/dist/modules/agents/agent-task.service.js +35 -31
- package/dist/modules/agents/agent-task.service.js.map +1 -1
- package/dist/modules/agents/agent-telemetry.d.ts +2 -2
- package/dist/modules/agents/agent-telemetry.js +3 -2
- package/dist/modules/agents/agent-telemetry.js.map +1 -1
- package/dist/modules/agents/agent-test-run.service.d.ts +4 -2
- package/dist/modules/agents/agent-test-run.service.js +2 -2
- package/dist/modules/agents/agent-test-run.service.js.map +1 -1
- package/dist/modules/agents/agent-threads.controller.js +2 -1
- package/dist/modules/agents/agent-threads.controller.js.map +1 -1
- package/dist/modules/agents/agent-tool-approval.service.d.ts +1 -1
- package/dist/modules/agents/agent-tool-approval.service.js +2 -1
- package/dist/modules/agents/agent-tool-approval.service.js.map +1 -1
- package/dist/modules/agents/agent-turn-execution.service.d.ts +4 -4
- package/dist/modules/agents/agent-turn-execution.service.js +27 -25
- package/dist/modules/agents/agent-turn-execution.service.js.map +1 -1
- package/dist/modules/agents/agent-validation.service.d.ts +11 -7
- package/dist/modules/agents/agent-validation.service.js +60 -30
- package/dist/modules/agents/agent-validation.service.js.map +1 -1
- package/dist/modules/agents/agent-workflow-execution.service.d.ts +13 -5
- package/dist/modules/agents/agent-workflow-execution.service.js +44 -20
- package/dist/modules/agents/agent-workflow-execution.service.js.map +1 -1
- package/dist/modules/agents/agent-workflow-tool-resume.service.js +2 -3
- package/dist/modules/agents/agent-workflow-tool-resume.service.js.map +1 -1
- package/dist/modules/agents/agents-config.controller.d.ts +16 -0
- package/dist/modules/agents/agents-list.controller.d.ts +4 -1
- package/dist/modules/agents/agents-list.controller.js +44 -0
- package/dist/modules/agents/agents-list.controller.js.map +1 -1
- package/dist/modules/agents/agents.controller.js +1 -0
- package/dist/modules/agents/agents.controller.js.map +1 -1
- package/dist/modules/agents/agents.module.d.ts +1 -3
- package/dist/modules/agents/agents.module.js +9 -25
- package/dist/modules/agents/agents.module.js.map +1 -1
- package/dist/modules/agents/agents.service.d.ts +21 -5
- package/dist/modules/agents/agents.service.js +63 -12
- package/dist/modules/agents/agents.service.js.map +1 -1
- package/dist/modules/agents/background/agent-background-job.service.d.ts +3 -3
- package/dist/modules/agents/background/agent-background-job.service.js +39 -10
- package/dist/modules/agents/background/agent-background-job.service.js.map +1 -1
- package/dist/modules/agents/background/agent-wake.service.js +13 -5
- package/dist/modules/agents/background/agent-wake.service.js.map +1 -1
- package/dist/modules/agents/background/background-job-tools.d.ts +2 -2
- package/dist/modules/agents/background/background-job-tools.js +9 -58
- package/dist/modules/agents/background/background-job-tools.js.map +1 -1
- package/dist/modules/agents/budget-guardrail.d.ts +1 -0
- package/dist/modules/agents/budget-guardrail.js +42 -1
- package/dist/modules/agents/budget-guardrail.js.map +1 -1
- package/dist/modules/agents/builder/agents-builder-prompts.d.ts +5 -5
- package/dist/modules/agents/builder/agents-builder-prompts.js +52 -31
- package/dist/modules/agents/builder/agents-builder-prompts.js.map +1 -1
- package/dist/modules/agents/builder/agents-builder-tools.service.d.ts +4 -1
- package/dist/modules/agents/builder/agents-builder-tools.service.js +189 -89
- package/dist/modules/agents/builder/agents-builder-tools.service.js.map +1 -1
- package/dist/modules/agents/builder/get-resource-locator-options.tool.d.ts +2 -2
- package/dist/modules/agents/builder/prompts/config-mutation.prompt.js +25 -12
- package/dist/modules/agents/builder/prompts/config-mutation.prompt.js.map +1 -1
- package/dist/modules/agents/builder/prompts/llm-selection.prompt.d.ts +1 -1
- package/dist/modules/agents/builder/prompts/llm-selection.prompt.js +1 -1
- package/dist/modules/agents/builder/skills/external-services.skill.js +4 -4
- package/dist/modules/agents/builder/skills/node-tools.skill.js +4 -4
- package/dist/modules/agents/builder/skills/node-tools.skill.js.map +1 -1
- package/dist/modules/agents/builder/skills/target-skills.skill.js +14 -8
- package/dist/modules/agents/builder/skills/target-skills.skill.js.map +1 -1
- package/dist/modules/agents/builder/verify-mcp-server.tool.d.ts +9 -3
- package/dist/modules/agents/builder/verify-mcp-server.tool.js +16 -3
- package/dist/modules/agents/builder/verify-mcp-server.tool.js.map +1 -1
- package/dist/modules/agents/entities/agent-history.entity.d.ts +2 -2
- package/dist/modules/agents/entities/agent-history.entity.js.map +1 -1
- package/dist/modules/agents/entities/agent.entity.d.ts +2 -2
- package/dist/modules/agents/entities/agent.entity.js.map +1 -1
- package/dist/modules/agents/instance-ai-agent-context.adapter.d.ts +3 -1
- package/dist/modules/agents/instance-ai-agent-context.adapter.js +5 -3
- package/dist/modules/agents/instance-ai-agent-context.adapter.js.map +1 -1
- package/dist/modules/agents/instance-ai-builder-delegate.adapter.js +4 -1
- package/dist/modules/agents/instance-ai-builder-delegate.adapter.js.map +1 -1
- package/dist/modules/agents/integrations/agent-chat-bridge.d.ts +1 -0
- package/dist/modules/agents/integrations/agent-chat-bridge.js +67 -20
- package/dist/modules/agents/integrations/agent-chat-bridge.js.map +1 -1
- package/dist/modules/agents/integrations/agent-chat-integration.d.ts +18 -3
- package/dist/modules/agents/integrations/agent-chat-integration.js +1 -0
- package/dist/modules/agents/integrations/agent-chat-integration.js.map +1 -1
- package/dist/modules/agents/integrations/agent-chat-stream-consumer.d.ts +4 -0
- package/dist/modules/agents/integrations/agent-chat-stream-consumer.js +81 -24
- package/dist/modules/agents/integrations/agent-chat-stream-consumer.js.map +1 -1
- package/dist/modules/agents/integrations/channel-rate-limit.d.ts +6 -0
- package/dist/modules/agents/integrations/channel-rate-limit.js +11 -1
- package/dist/modules/agents/integrations/channel-rate-limit.js.map +1 -1
- package/dist/modules/agents/integrations/component-mapper.d.ts +6 -0
- package/dist/modules/agents/integrations/component-mapper.js +16 -3
- package/dist/modules/agents/integrations/component-mapper.js.map +1 -1
- package/dist/modules/agents/integrations/esm-loader.d.ts +1 -0
- package/dist/modules/agents/integrations/esm-loader.js +4 -0
- package/dist/modules/agents/integrations/esm-loader.js.map +1 -1
- package/dist/modules/agents/integrations/integration-helpers.d.ts +1 -0
- package/dist/modules/agents/integrations/integration-helpers.js +7 -0
- package/dist/modules/agents/integrations/integration-helpers.js.map +1 -1
- package/dist/modules/agents/integrations/integration-tool-execution.d.ts +1 -0
- package/dist/modules/agents/integrations/integration-tool-execution.js +13 -0
- package/dist/modules/agents/integrations/integration-tool-execution.js.map +1 -1
- package/dist/modules/agents/integrations/integration-tool-factory.js +1 -0
- package/dist/modules/agents/integrations/integration-tool-factory.js.map +1 -1
- package/dist/modules/agents/integrations/n8n-memory.d.ts +7 -0
- package/dist/modules/agents/integrations/n8n-memory.js +24 -10
- package/dist/modules/agents/integrations/n8n-memory.js.map +1 -1
- package/dist/modules/agents/integrations/platforms/slack/slack-integration.d.ts +2 -2
- package/dist/modules/agents/integrations/platforms/slack/slack-integration.js +2 -1
- package/dist/modules/agents/integrations/platforms/slack/slack-integration.js.map +1 -1
- package/dist/modules/agents/integrations/platforms/teams/teams-integration.d.ts +15 -1
- package/dist/modules/agents/integrations/platforms/teams/teams-integration.js +63 -2
- package/dist/modules/agents/integrations/platforms/teams/teams-integration.js.map +1 -1
- package/dist/modules/agents/integrations/platforms/teams/teams-manifest.service.d.ts +11 -0
- package/dist/modules/agents/integrations/platforms/teams/teams-manifest.service.js +5 -3
- package/dist/modules/agents/integrations/platforms/teams/teams-manifest.service.js.map +1 -1
- package/dist/modules/agents/integrations/platforms/telegram-integration.js.map +1 -1
- package/dist/modules/agents/integrations/platforms/whatsapp-integration.d.ts +43 -0
- package/dist/modules/agents/integrations/platforms/whatsapp-integration.js +337 -0
- package/dist/modules/agents/integrations/platforms/whatsapp-integration.js.map +1 -0
- package/dist/modules/agents/json-config/agent-config-composition.d.ts +2 -1
- package/dist/modules/agents/json-config/agent-config-composition.js +3 -2
- package/dist/modules/agents/json-config/agent-config-composition.js.map +1 -1
- package/dist/modules/agents/json-config/agent-document.d.ts +7 -0
- package/dist/modules/agents/json-config/agent-document.js +13 -0
- package/dist/modules/agents/json-config/agent-document.js.map +1 -0
- package/dist/modules/agents/json-config/credential-field-mapping.d.ts +1 -1
- package/dist/modules/agents/json-config/credential-field-mapping.js +33 -8
- package/dist/modules/agents/json-config/credential-field-mapping.js.map +1 -1
- package/dist/modules/agents/json-config/mcp-client-factory.js +6 -0
- package/dist/modules/agents/json-config/mcp-client-factory.js.map +1 -1
- package/dist/modules/agents/json-config/model-config.js +13 -1
- package/dist/modules/agents/json-config/model-config.js.map +1 -1
- package/dist/modules/agents/json-config/prune-missing-config-references.d.ts +5 -0
- package/dist/modules/agents/json-config/prune-missing-config-references.js +20 -0
- package/dist/modules/agents/json-config/prune-missing-config-references.js.map +1 -0
- package/dist/modules/agents/json-config/sanitize-unknown-agent-credentials.js +8 -94
- package/dist/modules/agents/json-config/sanitize-unknown-agent-credentials.js.map +1 -1
- package/dist/modules/agents/plans/agent-plan-tools.js +3 -3
- package/dist/modules/agents/plans/agent-plan-tools.js.map +1 -1
- package/dist/modules/agents/register-favorite-resolver.js +2 -2
- package/dist/modules/agents/register-favorite-resolver.js.map +1 -1
- package/dist/modules/agents/repositories/agent-credential-dependency.repository.js +4 -1
- package/dist/modules/agents/repositories/agent-credential-dependency.repository.js.map +1 -1
- package/dist/modules/agents/repositories/agent-execution-thread.repository.d.ts +10 -0
- package/dist/modules/agents/repositories/agent-execution-thread.repository.js +67 -8
- package/dist/modules/agents/repositories/agent-execution-thread.repository.js.map +1 -1
- package/dist/modules/agents/repositories/agent-history.repository.d.ts +8 -9
- package/dist/modules/agents/repositories/agent-history.repository.js +9 -8
- package/dist/modules/agents/repositories/agent-history.repository.js.map +1 -1
- package/dist/modules/agents/repositories/agent-message-queue.repository.d.ts +15 -2
- package/dist/modules/agents/repositories/agent-message-queue.repository.js +9 -2
- package/dist/modules/agents/repositories/agent-message-queue.repository.js.map +1 -1
- package/dist/modules/agents/repositories/agent-task-snapshot.repository.d.ts +6 -5
- package/dist/modules/agents/repositories/agent-task-snapshot.repository.js +9 -8
- package/dist/modules/agents/repositories/agent-task-snapshot.repository.js.map +1 -1
- package/dist/modules/agents/repositories/agent-task.repository.d.ts +9 -4
- package/dist/modules/agents/repositories/agent-task.repository.js +40 -6
- package/dist/modules/agents/repositories/agent-task.repository.js.map +1 -1
- package/dist/modules/agents/repositories/agent-thread.repository.d.ts +6 -0
- package/dist/modules/agents/repositories/agent-thread.repository.js +20 -0
- package/dist/modules/agents/repositories/agent-thread.repository.js.map +1 -1
- package/dist/modules/agents/repositories/agent.repository.d.ts +23 -9
- package/dist/modules/agents/repositories/agent.repository.js +118 -15
- package/dist/modules/agents/repositories/agent.repository.js.map +1 -1
- package/dist/modules/agents/sub-agents/delegate-sub-agent-tool.d.ts +1 -0
- package/dist/modules/agents/sub-agents/delegate-sub-agent-tool.js +2 -1
- package/dist/modules/agents/sub-agents/delegate-sub-agent-tool.js.map +1 -1
- package/dist/modules/agents/sub-agents/sub-agent-source-resolver.d.ts +3 -1
- package/dist/modules/agents/sub-agents/sub-agent-source-resolver.js +8 -5
- package/dist/modules/agents/sub-agents/sub-agent-source-resolver.js.map +1 -1
- package/dist/modules/agents/tools/node-tool-factory.d.ts +1 -1
- package/dist/modules/agents/tools/node-tool-factory.js +3 -14
- package/dist/modules/agents/tools/node-tool-factory.js.map +1 -1
- package/dist/modules/agents/tools/workflow-tool-factory.d.ts +4 -2
- package/dist/modules/agents/tools/workflow-tool-factory.js +39 -13
- package/dist/modules/agents/tools/workflow-tool-factory.js.map +1 -1
- package/dist/modules/agents/tools/workflow-tool-workflow-loader.service.js +5 -1
- package/dist/modules/agents/tools/workflow-tool-workflow-loader.service.js.map +1 -1
- package/dist/modules/agents/types/agent-queued-message.d.ts +1 -0
- package/dist/modules/agents/types/agent-queued-message.js +3 -1
- package/dist/modules/agents/types/agent-queued-message.js.map +1 -1
- package/dist/modules/agents/utils/agent-config-hash.d.ts +1 -0
- package/dist/modules/agents/utils/agent-config-hash.js +4 -0
- package/dist/modules/agents/utils/agent-config-hash.js.map +1 -1
- package/dist/modules/agents/utils/agent-definition.d.ts +329 -0
- package/dist/modules/agents/utils/agent-definition.js +17 -0
- package/dist/modules/agents/utils/agent-definition.js.map +1 -0
- package/dist/modules/agents/utils/agent-draft.utils.d.ts +2 -3
- package/dist/modules/agents/utils/agent-draft.utils.js +2 -2
- package/dist/modules/agents/utils/agent-draft.utils.js.map +1 -1
- package/dist/modules/agents/utils/agent-execution-counter.d.ts +2 -1
- package/dist/modules/agents/utils/agent-execution-counter.js +4 -1
- package/dist/modules/agents/utils/agent-execution-counter.js.map +1 -1
- package/dist/modules/agents/utils/agent-missing-skill-ids.d.ts +3 -2
- package/dist/modules/agents/utils/agent-missing-skill-ids.js +2 -2
- package/dist/modules/agents/utils/agent-missing-skill-ids.js.map +1 -1
- package/dist/modules/agents/utils/agent-published-snapshot.d.ts +8 -1
- package/dist/modules/agents/utils/agent-published-snapshot.js +21 -7
- package/dist/modules/agents/utils/agent-published-snapshot.js.map +1 -1
- package/dist/modules/agents/utils/agent-ref.d.ts +8 -0
- package/dist/modules/agents/utils/agent-ref.js +12 -0
- package/dist/modules/agents/utils/agent-ref.js.map +1 -0
- package/dist/modules/agents/utils/agent-thread-access.d.ts +3 -1
- package/dist/modules/agents/utils/agent-thread-access.js +7 -0
- package/dist/modules/agents/utils/agent-thread-access.js.map +1 -1
- package/dist/modules/agents/utils/extract-agent-credential-ids.d.ts +1 -2
- package/dist/modules/agents/utils/extract-agent-credential-ids.js +6 -33
- package/dist/modules/agents/utils/extract-agent-credential-ids.js.map +1 -1
- package/dist/modules/agents/utils/extract-agent-workflow-refs.d.ts +1 -1
- package/dist/modules/agents/utils/extract-agent-workflow-refs.js.map +1 -1
- package/dist/modules/agents/utils/parse-thread-list-limit.d.ts +1 -0
- package/dist/modules/agents/utils/parse-thread-list-limit.js +7 -0
- package/dist/modules/agents/utils/parse-thread-list-limit.js.map +1 -0
- package/dist/modules/agents/utils/skill-instruction-edits.d.ts +5 -0
- package/dist/modules/agents/utils/skill-instruction-edits.js +15 -0
- package/dist/modules/agents/utils/skill-instruction-edits.js.map +1 -0
- package/dist/modules/agents/utils/visit-agent-credential-references.d.ts +8 -0
- package/dist/modules/agents/utils/visit-agent-credential-references.js +67 -0
- package/dist/modules/agents/utils/visit-agent-credential-references.js.map +1 -0
- package/dist/modules/breaking-changes/breaking-changes.controller.d.ts +17 -5
- package/dist/modules/breaking-changes/breaking-changes.controller.js +94 -8
- package/dist/modules/breaking-changes/breaking-changes.controller.js.map +1 -1
- package/dist/modules/breaking-changes/breaking-changes.module.d.ts +1 -1
- package/dist/modules/breaking-changes/breaking-changes.module.js +2 -1
- package/dist/modules/breaking-changes/breaking-changes.module.js.map +1 -1
- package/dist/modules/breaking-changes/database/entities/migration-workflow-owner.entity.d.ts +14 -0
- package/dist/modules/breaking-changes/database/entities/migration-workflow-owner.entity.js +57 -0
- package/dist/modules/breaking-changes/database/entities/migration-workflow-owner.entity.js.map +1 -0
- package/dist/modules/breaking-changes/database/repositories/migration-finding.repository.d.ts +12 -6
- package/dist/modules/breaking-changes/database/repositories/migration-finding.repository.js +104 -30
- package/dist/modules/breaking-changes/database/repositories/migration-finding.repository.js.map +1 -1
- package/dist/modules/breaking-changes/database/repositories/migration-workflow-owner.repository.d.ts +14 -0
- package/dist/modules/breaking-changes/database/repositories/migration-workflow-owner.repository.js +79 -0
- package/dist/modules/breaking-changes/database/repositories/migration-workflow-owner.repository.js.map +1 -0
- package/dist/modules/breaking-changes/migrations/index.js +1 -2
- package/dist/modules/breaking-changes/migrations/index.js.map +1 -1
- package/dist/modules/breaking-changes/owners/migration-owner-assignment.service.d.ts +17 -0
- package/dist/modules/breaking-changes/owners/migration-owner-assignment.service.js +64 -0
- package/dist/modules/breaking-changes/owners/migration-owner-assignment.service.js.map +1 -0
- package/dist/modules/breaking-changes/owners/migration-owner-suggestion.service.d.ts +16 -0
- package/dist/modules/breaking-changes/owners/migration-owner-suggestion.service.js +113 -0
- package/dist/modules/breaking-changes/owners/migration-owner-suggestion.service.js.map +1 -0
- package/dist/modules/breaking-changes/owners/workflow-owner.d.ts +3 -0
- package/dist/modules/breaking-changes/owners/workflow-owner.js +13 -0
- package/dist/modules/breaking-changes/owners/workflow-owner.js.map +1 -0
- package/dist/modules/breaking-changes/query/migration-finding-query.service.d.ts +16 -5
- package/dist/modules/breaking-changes/query/migration-finding-query.service.js +51 -16
- package/dist/modules/breaking-changes/query/migration-finding-query.service.js.map +1 -1
- package/dist/modules/breaking-changes/rules/index.d.ts +0 -1
- package/dist/modules/breaking-changes/rules/index.js +0 -1
- package/dist/modules/breaking-changes/rules/index.js.map +1 -1
- package/dist/modules/breaking-changes/sync/migration-finding-diff.js +2 -1
- package/dist/modules/breaking-changes/sync/migration-finding-diff.js.map +1 -1
- package/dist/modules/breaking-changes/sync/migration-finding-sync.service.d.ts +7 -3
- package/dist/modules/breaking-changes/sync/migration-finding-sync.service.js +22 -15
- package/dist/modules/breaking-changes/sync/migration-finding-sync.service.js.map +1 -1
- package/dist/modules/breaking-changes/triage/migration-finding-triage.service.d.ts +11 -0
- package/dist/modules/breaking-changes/triage/migration-finding-triage.service.js +47 -0
- package/dist/modules/breaking-changes/triage/migration-finding-triage.service.js.map +1 -0
- package/dist/modules/chat-hub/chat-hub-execution-watcher.service.js +2 -0
- package/dist/modules/chat-hub/chat-hub-execution-watcher.service.js.map +1 -1
- package/dist/modules/chat-hub/chat-hub-execution.service.js +1 -0
- package/dist/modules/chat-hub/chat-hub-execution.service.js.map +1 -1
- package/dist/modules/community-packages/community-node-types-utils.d.ts +2 -2
- package/dist/modules/community-packages/community-node.command.d.ts +1 -1
- package/dist/modules/community-packages/community-packages.config.d.ts +1 -1
- package/dist/modules/community-packages/community-packages.service.js +6 -6
- package/dist/modules/community-packages/community-packages.service.js.map +1 -1
- package/dist/modules/data-table/data-table-column.repository.d.ts +12 -4
- package/dist/modules/data-table/data-table-column.repository.js +51 -6
- package/dist/modules/data-table/data-table-column.repository.js.map +1 -1
- package/dist/modules/data-table/data-table-file-cleanup.service.d.ts +5 -7
- package/dist/modules/data-table/data-table-file-cleanup.service.js +35 -37
- package/dist/modules/data-table/data-table-file-cleanup.service.js.map +1 -1
- package/dist/modules/data-table/data-table-file-cleanup.task.d.ts +14 -0
- package/dist/modules/data-table/data-table-file-cleanup.task.js +37 -0
- package/dist/modules/data-table/data-table-file-cleanup.task.js.map +1 -0
- package/dist/modules/data-table/data-table.module.d.ts +2 -1
- package/dist/modules/data-table/data-table.module.js +4 -4
- package/dist/modules/data-table/data-table.module.js.map +1 -1
- package/dist/modules/data-table/data-table.repository.d.ts +1 -1
- package/dist/modules/data-table/data-table.repository.js +2 -1
- package/dist/modules/data-table/data-table.repository.js.map +1 -1
- package/dist/modules/data-table/data-table.service.d.ts +8 -1
- package/dist/modules/data-table/data-table.service.js +11 -2
- package/dist/modules/data-table/data-table.service.js.map +1 -1
- package/dist/modules/data-table/register-favorite-resolver.js +2 -2
- package/dist/modules/data-table/register-favorite-resolver.js.map +1 -1
- package/dist/modules/data-table/utils/pair-columns.d.ts +27 -0
- package/dist/modules/data-table/utils/pair-columns.js +48 -0
- package/dist/modules/data-table/utils/pair-columns.js.map +1 -0
- package/dist/modules/dynamic-credentials.ee/credential-resolvers/identifiers/n8n-identifier.d.ts +40 -52
- package/dist/modules/dynamic-credentials.ee/credential-resolvers/identifiers/n8n-identifier.js +55 -40
- package/dist/modules/dynamic-credentials.ee/credential-resolvers/identifiers/n8n-identifier.js.map +1 -1
- package/dist/modules/external-secrets.ee/external-secrets-manager.ee.d.ts +1 -4
- package/dist/modules/external-secrets.ee/external-secrets-manager.ee.js +2 -15
- package/dist/modules/external-secrets.ee/external-secrets-manager.ee.js.map +1 -1
- package/dist/modules/external-secrets.ee/external-secrets-refresh.task.d.ts +13 -0
- package/dist/modules/external-secrets.ee/external-secrets-refresh.task.js +36 -0
- package/dist/modules/external-secrets.ee/external-secrets-refresh.task.js.map +1 -0
- package/dist/modules/external-secrets.ee/external-secrets.config.js +1 -1
- package/dist/modules/external-secrets.ee/external-secrets.config.js.map +1 -1
- package/dist/modules/external-secrets.ee/external-secrets.module.d.ts +1 -0
- package/dist/modules/external-secrets.ee/external-secrets.module.js +4 -0
- package/dist/modules/external-secrets.ee/external-secrets.module.js.map +1 -1
- package/dist/modules/external-secrets.ee/providers/one-password.js +1 -1
- package/dist/modules/external-secrets.ee/providers/one-password.js.map +1 -1
- package/dist/modules/external-secrets.ee/secrets-cache.service.d.ts +4 -2
- package/dist/modules/external-secrets.ee/secrets-cache.service.js +25 -8
- package/dist/modules/external-secrets.ee/secrets-cache.service.js.map +1 -1
- package/dist/modules/favorites/favorites.service.d.ts +1 -1
- package/dist/modules/favorites/favorites.service.js +2 -2
- package/dist/modules/favorites/favorites.service.js.map +1 -1
- package/dist/modules/inbound-auth-core/authentication-pipeline.d.ts +11 -0
- package/dist/modules/inbound-auth-core/authentication-pipeline.js +50 -0
- package/dist/modules/inbound-auth-core/authentication-pipeline.js.map +1 -0
- package/dist/modules/inbound-auth-core/authentication.service.d.ts +12 -0
- package/dist/modules/inbound-auth-core/authentication.service.js +86 -0
- package/dist/modules/inbound-auth-core/authentication.service.js.map +1 -0
- package/dist/modules/inbound-auth-core/database/entities/trusted-source.entity.d.ts +3 -0
- package/dist/modules/inbound-auth-core/database/entities/trusted-source.entity.js +12 -0
- package/dist/modules/inbound-auth-core/database/entities/trusted-source.entity.js.map +1 -1
- package/dist/modules/inbound-auth-core/database/repositories/trusted-source-identity.repository.d.ts +20 -3
- package/dist/modules/inbound-auth-core/database/repositories/trusted-source-identity.repository.js +70 -2
- package/dist/modules/inbound-auth-core/database/repositories/trusted-source-identity.repository.js.map +1 -1
- package/dist/modules/inbound-auth-core/database/repositories/trusted-source.repository.d.ts +15 -3
- package/dist/modules/inbound-auth-core/database/repositories/trusted-source.repository.js +58 -2
- package/dist/modules/inbound-auth-core/database/repositories/trusted-source.repository.js.map +1 -1
- package/dist/modules/inbound-auth-core/grant-authorization.d.ts +4 -0
- package/dist/modules/inbound-auth-core/grant-authorization.js +10 -0
- package/dist/modules/inbound-auth-core/grant-authorization.js.map +1 -0
- package/dist/modules/inbound-auth-core/identity/external-identity.d.ts +3 -0
- package/dist/modules/inbound-auth-core/identity/external-identity.js +86 -0
- package/dist/modules/inbound-auth-core/identity/external-identity.js.map +1 -0
- package/dist/modules/inbound-auth-core/identity/trusted-source-identity.service.d.ts +27 -0
- package/dist/modules/inbound-auth-core/identity/trusted-source-identity.service.js +287 -0
- package/dist/modules/inbound-auth-core/identity/trusted-source-identity.service.js.map +1 -0
- package/dist/modules/inbound-auth-core/inbound-auth-core.module.d.ts +1 -0
- package/dist/modules/inbound-auth-core/inbound-auth-core.module.js +30 -20
- package/dist/modules/inbound-auth-core/inbound-auth-core.module.js.map +1 -1
- package/dist/modules/inbound-auth-core/key.utils.d.ts +2 -0
- package/dist/modules/inbound-auth-core/key.utils.js +18 -0
- package/dist/modules/inbound-auth-core/key.utils.js.map +1 -0
- package/dist/modules/inbound-auth-core/oauth2-bearer.driver.d.ts +16 -0
- package/dist/modules/inbound-auth-core/oauth2-bearer.driver.js +171 -0
- package/dist/modules/inbound-auth-core/oauth2-bearer.driver.js.map +1 -0
- package/dist/modules/inbound-auth-core/system-trusted-source.seeder.d.ts +52 -0
- package/dist/modules/inbound-auth-core/system-trusted-source.seeder.js +74 -0
- package/dist/modules/inbound-auth-core/system-trusted-source.seeder.js.map +1 -0
- package/dist/modules/inbound-auth-core/trusted-source-discovery.service.d.ts +19 -0
- package/dist/modules/inbound-auth-core/trusted-source-discovery.service.js +141 -0
- package/dist/modules/inbound-auth-core/trusted-source-discovery.service.js.map +1 -0
- package/dist/modules/inbound-auth-core/trusted-source-discovery.task.d.ts +12 -0
- package/dist/modules/{insights/insights-compaction.task.js → inbound-auth-core/trusted-source-discovery.task.js} +14 -16
- package/dist/modules/inbound-auth-core/trusted-source-discovery.task.js.map +1 -0
- package/dist/modules/inbound-auth-core/trusted-source.gate.d.ts +13 -0
- package/dist/modules/inbound-auth-core/trusted-source.gate.js +53 -0
- package/dist/modules/inbound-auth-core/trusted-source.gate.js.map +1 -0
- package/dist/modules/inbound-auth-core/trusted-source.store.d.ts +18 -16
- package/dist/modules/inbound-auth-core/trusted-source.store.js +107 -7
- package/dist/modules/inbound-auth-core/trusted-source.store.js.map +1 -1
- package/dist/modules/instance-ai/eval/agent-execution.service.d.ts +2 -1
- package/dist/modules/instance-ai/eval/agent-execution.service.js +42 -37
- package/dist/modules/instance-ai/eval/agent-execution.service.js.map +1 -1
- package/dist/modules/instance-ai/eval/execution.service.d.ts +7 -2
- package/dist/modules/instance-ai/eval/execution.service.js +150 -22
- package/dist/modules/instance-ai/eval/execution.service.js.map +1 -1
- package/dist/modules/instance-ai/eval/mock-handler.js +6 -3
- package/dist/modules/instance-ai/eval/mock-handler.js.map +1 -1
- package/dist/modules/instance-ai/eval/pin-data-generator.js +2 -1
- package/dist/modules/instance-ai/eval/pin-data-generator.js.map +1 -1
- package/dist/modules/instance-ai/eval/thread-restore.service.d.ts +1 -1
- package/dist/modules/instance-ai/eval/thread-restore.service.js +2 -1
- package/dist/modules/instance-ai/eval/thread-restore.service.js.map +1 -1
- package/dist/modules/instance-ai/eval/workflow-analysis.d.ts +1 -0
- package/dist/modules/instance-ai/eval/workflow-analysis.js +25 -9
- package/dist/modules/instance-ai/eval/workflow-analysis.js.map +1 -1
- package/dist/modules/instance-ai/instance-ai-checkpoint-pruning.task.d.ts +4 -2
- package/dist/modules/instance-ai/instance-ai-checkpoint-pruning.task.js +5 -2
- package/dist/modules/instance-ai/instance-ai-checkpoint-pruning.task.js.map +1 -1
- package/dist/modules/instance-ai/instance-ai-credit.service.d.ts +3 -0
- package/dist/modules/instance-ai/instance-ai-credit.service.js +18 -0
- package/dist/modules/instance-ai/instance-ai-credit.service.js.map +1 -1
- package/dist/modules/instance-ai/instance-ai-pending-agent.service.js +1 -0
- package/dist/modules/instance-ai/instance-ai-pending-agent.service.js.map +1 -1
- package/dist/modules/instance-ai/instance-ai-thread-tabs.service.d.ts +10 -1
- package/dist/modules/instance-ai/instance-ai-thread-tabs.service.js +74 -5
- package/dist/modules/instance-ai/instance-ai-thread-tabs.service.js.map +1 -1
- package/dist/modules/instance-ai/instance-ai.adapter.service.js +30 -7
- package/dist/modules/instance-ai/instance-ai.adapter.service.js.map +1 -1
- package/dist/modules/instance-ai/instance-ai.controller.d.ts +28 -2
- package/dist/modules/instance-ai/instance-ai.controller.js +5 -3
- package/dist/modules/instance-ai/instance-ai.controller.js.map +1 -1
- package/dist/modules/instance-ai/instance-ai.module.d.ts +1 -1
- package/dist/modules/instance-ai/instance-ai.module.js +8 -0
- package/dist/modules/instance-ai/instance-ai.module.js.map +1 -1
- package/dist/modules/instance-ai/instance-ai.service.d.ts +10 -1
- package/dist/modules/instance-ai/instance-ai.service.js +164 -24
- package/dist/modules/instance-ai/instance-ai.service.js.map +1 -1
- package/dist/modules/instance-ai/instance-context.service.js +4 -5
- package/dist/modules/instance-ai/instance-context.service.js.map +1 -1
- package/dist/modules/instance-ai/repositories/instance-ai-thread-tabs.repository.d.ts +5 -3
- package/dist/modules/instance-ai/repositories/instance-ai-thread-tabs.repository.js +24 -4
- package/dist/modules/instance-ai/repositories/instance-ai-thread-tabs.repository.js.map +1 -1
- package/dist/modules/instance-ai/self-healing/database/self-healing-result.entity.d.ts +23 -0
- package/dist/modules/instance-ai/self-healing/database/self-healing-result.entity.js +100 -0
- package/dist/modules/instance-ai/self-healing/database/self-healing-result.entity.js.map +1 -0
- package/dist/modules/instance-ai/self-healing/database/self-healing-result.repository.d.ts +10 -0
- package/dist/modules/instance-ai/self-healing/database/self-healing-result.repository.js +50 -0
- package/dist/modules/instance-ai/self-healing/database/self-healing-result.repository.js.map +1 -0
- package/dist/modules/instance-ai/self-healing/self-healing-execution-reference.service.d.ts +16 -0
- package/dist/modules/instance-ai/self-healing/self-healing-execution-reference.service.js +77 -0
- package/dist/modules/instance-ai/self-healing/self-healing-execution-reference.service.js.map +1 -0
- package/dist/modules/instance-ai/self-healing/self-healing-result.service.d.ts +33 -0
- package/dist/modules/instance-ai/self-healing/self-healing-result.service.js +178 -0
- package/dist/modules/instance-ai/self-healing/self-healing-result.service.js.map +1 -0
- package/dist/modules/instance-ai/self-healing/self-healing-results.controller.d.ts +16 -0
- package/dist/modules/instance-ai/self-healing/self-healing-results.controller.js +69 -0
- package/dist/modules/instance-ai/self-healing/self-healing-results.controller.js.map +1 -0
- package/dist/modules/instance-ai/workflow-suggestions/database/workflow-suggestion-activity.entity.d.ts +3 -1
- package/dist/modules/instance-ai/workflow-suggestions/database/workflow-suggestion-activity.entity.js +10 -0
- package/dist/modules/instance-ai/workflow-suggestions/database/workflow-suggestion-activity.entity.js.map +1 -1
- package/dist/modules/instance-ai/workflow-suggestions/database/workflow-suggestion.entity.d.ts +6 -1
- package/dist/modules/instance-ai/workflow-suggestions/database/workflow-suggestion.entity.js +20 -0
- package/dist/modules/instance-ai/workflow-suggestions/database/workflow-suggestion.entity.js.map +1 -1
- package/dist/modules/instance-ai/workflow-suggestions/database/workflow-suggestion.repository.d.ts +5 -2
- package/dist/modules/instance-ai/workflow-suggestions/database/workflow-suggestion.repository.js +45 -1
- package/dist/modules/instance-ai/workflow-suggestions/database/workflow-suggestion.repository.js.map +1 -1
- package/dist/modules/instance-ai/workflow-suggestions/workflow-suggestion-actions.service.d.ts +26 -0
- package/dist/modules/instance-ai/workflow-suggestions/workflow-suggestion-actions.service.js +173 -0
- package/dist/modules/instance-ai/workflow-suggestions/workflow-suggestion-actions.service.js.map +1 -0
- package/dist/modules/instance-ai/workflow-suggestions/workflow-suggestion-event-relay.service.d.ts +6 -0
- package/dist/modules/instance-ai/workflow-suggestions/workflow-suggestion-event-relay.service.js +57 -0
- package/dist/modules/instance-ai/workflow-suggestions/workflow-suggestion-event-relay.service.js.map +1 -0
- package/dist/modules/instance-ai/workflow-suggestions/workflow-suggestion.service.d.ts +29 -5
- package/dist/modules/instance-ai/workflow-suggestions/workflow-suggestion.service.js +86 -25
- package/dist/modules/instance-ai/workflow-suggestions/workflow-suggestion.service.js.map +1 -1
- package/dist/modules/instance-reporting.ee/instance-reporting-settings.service.d.ts +1 -1
- package/dist/modules/instance-reporting.ee/instance-reporting-settings.service.js +2 -2
- package/dist/modules/instance-reporting.ee/instance-reporting-settings.service.js.map +1 -1
- package/dist/modules/instance-reporting.ee/instance-reporting.service.d.ts +3 -2
- package/dist/modules/instance-reporting.ee/instance-reporting.service.js +23 -9
- package/dist/modules/instance-reporting.ee/instance-reporting.service.js.map +1 -1
- package/dist/modules/mcp/tools/agents/agent-reference.js +4 -3
- package/dist/modules/mcp/tools/agents/agent-reference.js.map +1 -1
- package/dist/modules/mcp/tools/agents/agent-slack-setup.d.ts +1 -1
- package/dist/modules/mcp/tools/agents/agent-tools.service.d.ts +3 -1
- package/dist/modules/mcp/tools/agents/agent-tools.service.js +72 -43
- package/dist/modules/mcp/tools/agents/agent-tools.service.js.map +1 -1
- package/dist/modules/mcp/tools/execute-workflow.tool.js +1 -1
- package/dist/modules/mcp/tools/execute-workflow.tool.js.map +1 -1
- package/dist/modules/mcp/tools/get-workflow-details.tool.js +6 -1
- package/dist/modules/mcp/tools/get-workflow-details.tool.js.map +1 -1
- package/dist/modules/mcp/tools/publish-workflow.tool.js +1 -0
- package/dist/modules/mcp/tools/publish-workflow.tool.js.map +1 -1
- package/dist/modules/mcp/tools/workflow-builder/update-workflow.tool.js +2 -9
- package/dist/modules/mcp/tools/workflow-builder/update-workflow.tool.js.map +1 -1
- package/dist/modules/mcp/tools/workflow-history.utils.js +1 -1
- package/dist/modules/mcp/tools/workflow-history.utils.js.map +1 -1
- package/dist/modules/mcp/tools/workflow-validation.utils.d.ts +2 -1
- package/dist/modules/mcp/tools/workflow-validation.utils.js.map +1 -1
- package/dist/modules/modules.manifest.js +3 -1
- package/dist/modules/modules.manifest.js.map +1 -1
- package/dist/modules/n8n-packages/engine/credential-save-policy.d.ts +11 -0
- package/dist/modules/n8n-packages/engine/credential-save-policy.js +56 -0
- package/dist/modules/n8n-packages/engine/credential-save-policy.js.map +1 -0
- package/dist/modules/n8n-packages/engine/import-gates.d.ts +2 -0
- package/dist/modules/n8n-packages/engine/import-gates.js +9 -0
- package/dist/modules/n8n-packages/engine/import-gates.js.map +1 -1
- package/dist/modules/n8n-packages/engine/import-orchestrator.d.ts +4 -1
- package/dist/modules/n8n-packages/engine/import-orchestrator.js +106 -32
- package/dist/modules/n8n-packages/engine/import-orchestrator.js.map +1 -1
- package/dist/modules/n8n-packages/engine/import-result.d.ts +2 -2
- package/dist/modules/n8n-packages/engine/import-result.js +2 -2
- package/dist/modules/n8n-packages/engine/import-result.js.map +1 -1
- package/dist/modules/n8n-packages/engine/import-telemetry.js +2 -0
- package/dist/modules/n8n-packages/engine/import-telemetry.js.map +1 -1
- package/dist/modules/n8n-packages/engine/n8n-package-parser.d.ts +6 -0
- package/dist/modules/n8n-packages/engine/n8n-package-parser.js +72 -1
- package/dist/modules/n8n-packages/engine/n8n-package-parser.js.map +1 -1
- package/dist/modules/n8n-packages/engine/project-package-importer.js +7 -1
- package/dist/modules/n8n-packages/engine/project-package-importer.js.map +1 -1
- package/dist/modules/n8n-packages/engine/workflow-package-importer.js +1 -0
- package/dist/modules/n8n-packages/engine/workflow-package-importer.js.map +1 -1
- package/dist/modules/n8n-packages/entities/agent/agent-export.types.d.ts +39 -0
- package/dist/modules/n8n-packages/entities/agent/agent-export.types.js +3 -0
- package/dist/modules/n8n-packages/entities/agent/agent-export.types.js.map +1 -0
- package/dist/modules/n8n-packages/entities/agent/agent-import.types.d.ts +5 -0
- package/dist/modules/n8n-packages/entities/agent/agent-import.types.js +3 -0
- package/dist/modules/n8n-packages/entities/agent/agent-import.types.js.map +1 -0
- package/dist/modules/n8n-packages/entities/agent/agent-requirements.extractor.d.ts +12 -0
- package/dist/modules/n8n-packages/entities/agent/agent-requirements.extractor.js +75 -0
- package/dist/modules/n8n-packages/entities/agent/agent-requirements.extractor.js.map +1 -0
- package/dist/modules/n8n-packages/entities/agent/agent-selection.exporter.d.ts +20 -0
- package/dist/modules/n8n-packages/entities/agent/agent-selection.exporter.js +173 -0
- package/dist/modules/n8n-packages/entities/agent/agent-selection.exporter.js.map +1 -0
- package/dist/modules/n8n-packages/entities/agent/agent.exporter.d.ts +14 -0
- package/dist/modules/n8n-packages/entities/agent/agent.exporter.js +76 -0
- package/dist/modules/n8n-packages/entities/agent/agent.exporter.js.map +1 -0
- package/dist/modules/n8n-packages/entities/agent/agent.serializer.d.ts +8 -0
- package/dist/modules/n8n-packages/entities/agent/agent.serializer.js +50 -0
- package/dist/modules/n8n-packages/entities/agent/agent.serializer.js.map +1 -0
- package/dist/modules/n8n-packages/entities/credential/credential-importer.js +1 -12
- package/dist/modules/n8n-packages/entities/credential/credential-importer.js.map +1 -1
- package/dist/modules/n8n-packages/entities/credential/credential-matcher.js +1 -2
- package/dist/modules/n8n-packages/entities/credential/credential-matcher.js.map +1 -1
- package/dist/modules/n8n-packages/entities/credential/credential-missing-mode.d.ts +1 -0
- package/dist/modules/n8n-packages/entities/credential/credential-missing-mode.js +12 -1
- package/dist/modules/n8n-packages/entities/credential/credential-missing-mode.js.map +1 -1
- package/dist/modules/n8n-packages/entities/credential/credential-requirements.extractor.d.ts +5 -4
- package/dist/modules/n8n-packages/entities/credential/credential-requirements.extractor.js +18 -1
- package/dist/modules/n8n-packages/entities/credential/credential-requirements.extractor.js.map +1 -1
- package/dist/modules/n8n-packages/entities/credential/credential.exporter.d.ts +2 -2
- package/dist/modules/n8n-packages/entities/credential/credential.exporter.js +19 -14
- package/dist/modules/n8n-packages/entities/credential/credential.exporter.js.map +1 -1
- package/dist/modules/n8n-packages/entities/credential/credential.types.d.ts +8 -5
- package/dist/modules/n8n-packages/entities/credential/credential.types.js +0 -1
- package/dist/modules/n8n-packages/entities/credential/credential.types.js.map +1 -1
- package/dist/modules/n8n-packages/entities/data-table/data-table-compat.d.ts +14 -2
- package/dist/modules/n8n-packages/entities/data-table/data-table-compat.js +52 -0
- package/dist/modules/n8n-packages/entities/data-table/data-table-compat.js.map +1 -1
- package/dist/modules/n8n-packages/entities/data-table/data-table-importer.d.ts +10 -2
- package/dist/modules/n8n-packages/entities/data-table/data-table-importer.js +136 -30
- package/dist/modules/n8n-packages/entities/data-table/data-table-importer.js.map +1 -1
- package/dist/modules/n8n-packages/entities/data-table/data-table-matching-mode.d.ts +1 -1
- package/dist/modules/n8n-packages/entities/data-table/data-table-matching-mode.js.map +1 -1
- package/dist/modules/n8n-packages/entities/data-table/data-table-requirements.extractor.d.ts +9 -2
- package/dist/modules/n8n-packages/entities/data-table/data-table-requirements.extractor.js +11 -8
- package/dist/modules/n8n-packages/entities/data-table/data-table-requirements.extractor.js.map +1 -1
- package/dist/modules/n8n-packages/entities/data-table/data-table-schema-conflict-policy.d.ts +2 -7
- package/dist/modules/n8n-packages/entities/data-table/data-table-schema-conflict-policy.js +16 -1
- package/dist/modules/n8n-packages/entities/data-table/data-table-schema-conflict-policy.js.map +1 -1
- package/dist/modules/n8n-packages/entities/data-table/data-table.exporter.d.ts +2 -3
- package/dist/modules/n8n-packages/entities/data-table/data-table.exporter.js +5 -19
- package/dist/modules/n8n-packages/entities/data-table/data-table.exporter.js.map +1 -1
- package/dist/modules/n8n-packages/entities/data-table/data-table.serializer.js +1 -0
- package/dist/modules/n8n-packages/entities/data-table/data-table.serializer.js.map +1 -1
- package/dist/modules/n8n-packages/entities/data-table/data-table.types.d.ts +46 -2
- package/dist/modules/n8n-packages/entities/data-table/data-table.types.js +0 -1
- package/dist/modules/n8n-packages/entities/data-table/data-table.types.js.map +1 -1
- package/dist/modules/n8n-packages/entities/folder/folder.exporter.d.ts +4 -4
- package/dist/modules/n8n-packages/entities/folder/folder.exporter.js +1 -1
- package/dist/modules/n8n-packages/entities/folder/folder.exporter.js.map +1 -1
- package/dist/modules/n8n-packages/entities/project/project-export-access.d.ts +3 -0
- package/dist/modules/n8n-packages/entities/project/project-export-access.js +14 -0
- package/dist/modules/n8n-packages/entities/project/project-export-access.js.map +1 -0
- package/dist/modules/n8n-packages/entities/project/project-shell.exporter.d.ts +14 -0
- package/dist/modules/n8n-packages/entities/project/project-shell.exporter.js +35 -0
- package/dist/modules/n8n-packages/entities/project/project-shell.exporter.js.map +1 -0
- package/dist/modules/n8n-packages/entities/project/project.exporter.d.ts +7 -7
- package/dist/modules/n8n-packages/entities/project/project.exporter.js +20 -17
- package/dist/modules/n8n-packages/entities/project/project.exporter.js.map +1 -1
- package/dist/modules/n8n-packages/entities/requirement-source.d.ts +13 -0
- package/dist/modules/n8n-packages/entities/requirement-source.js +23 -0
- package/dist/modules/n8n-packages/entities/requirement-source.js.map +1 -0
- package/dist/modules/n8n-packages/entities/requirements.types.d.ts +10 -10
- package/dist/modules/n8n-packages/entities/requirements.types.js.map +1 -1
- package/dist/modules/n8n-packages/entities/tag/tag-import-decision.d.ts +1 -1
- package/dist/modules/n8n-packages/entities/tag/tag-import-decision.js.map +1 -1
- package/dist/modules/n8n-packages/entities/tag/tag-importer.js +5 -19
- package/dist/modules/n8n-packages/entities/tag/tag-importer.js.map +1 -1
- package/dist/modules/n8n-packages/entities/tag/tag.exporter.js +3 -3
- package/dist/modules/n8n-packages/entities/tag/tag.exporter.js.map +1 -1
- package/dist/modules/n8n-packages/entities/tag/tag.types.d.ts +1 -6
- package/dist/modules/n8n-packages/entities/tag/tag.types.js +3 -11
- package/dist/modules/n8n-packages/entities/tag/tag.types.js.map +1 -1
- package/dist/modules/n8n-packages/entities/variable/variable-importer.js +7 -6
- package/dist/modules/n8n-packages/entities/variable/variable-importer.js.map +1 -1
- package/dist/modules/n8n-packages/entities/variable/variable-requirements.extractor.d.ts +1 -0
- package/dist/modules/n8n-packages/entities/variable/variable-requirements.extractor.js +9 -3
- package/dist/modules/n8n-packages/entities/variable/variable-requirements.extractor.js.map +1 -1
- package/dist/modules/n8n-packages/entities/variable/variable.exporter.d.ts +0 -1
- package/dist/modules/n8n-packages/entities/variable/variable.exporter.js +25 -28
- package/dist/modules/n8n-packages/entities/variable/variable.exporter.js.map +1 -1
- package/dist/modules/n8n-packages/entities/variable/variable.types.d.ts +6 -9
- package/dist/modules/n8n-packages/entities/variable/variable.types.js +1 -27
- package/dist/modules/n8n-packages/entities/variable/variable.types.js.map +1 -1
- package/dist/modules/n8n-packages/entities/workflow/auto-included-workflow-resolver.d.ts +9 -7
- package/dist/modules/n8n-packages/entities/workflow/auto-included-workflow-resolver.js +17 -31
- package/dist/modules/n8n-packages/entities/workflow/auto-included-workflow-resolver.js.map +1 -1
- package/dist/modules/n8n-packages/entities/workflow/auto-included-workflow.exporter.d.ts +5 -6
- package/dist/modules/n8n-packages/entities/workflow/auto-included-workflow.exporter.js +6 -17
- package/dist/modules/n8n-packages/entities/workflow/auto-included-workflow.exporter.js.map +1 -1
- package/dist/modules/n8n-packages/entities/workflow/missing-node-type-mode.js +2 -1
- package/dist/modules/n8n-packages/entities/workflow/missing-node-type-mode.js.map +1 -1
- package/dist/modules/n8n-packages/entities/workflow/node-type-usage.d.ts +7 -10
- package/dist/modules/n8n-packages/entities/workflow/node-type-usage.js +17 -13
- package/dist/modules/n8n-packages/entities/workflow/node-type-usage.js.map +1 -1
- package/dist/modules/n8n-packages/entities/workflow/references/sub-workflow-node.reference.d.ts +4 -1
- package/dist/modules/n8n-packages/entities/workflow/references/sub-workflow-node.reference.js.map +1 -1
- package/dist/modules/n8n-packages/entities/workflow/static-sub-workflow-requirements.d.ts +2 -2
- package/dist/modules/n8n-packages/entities/workflow/static-sub-workflow-requirements.js.map +1 -1
- package/dist/modules/n8n-packages/entities/workflow/sub-workflow-ordering.js +2 -1
- package/dist/modules/n8n-packages/entities/workflow/sub-workflow-ordering.js.map +1 -1
- package/dist/modules/n8n-packages/entities/workflow/workflow-dependency-resolver.d.ts +2 -2
- package/dist/modules/n8n-packages/entities/workflow/workflow-dependency-resolver.js +1 -1
- package/dist/modules/n8n-packages/entities/workflow/workflow-dependency-resolver.js.map +1 -1
- package/dist/modules/n8n-packages/entities/workflow/workflow-requirement.exporter.d.ts +2 -2
- package/dist/modules/n8n-packages/entities/workflow/workflow-requirement.exporter.js +5 -11
- package/dist/modules/n8n-packages/entities/workflow/workflow-requirement.exporter.js.map +1 -1
- package/dist/modules/n8n-packages/entities/workflow/workflow-version-policy.d.ts +3 -3
- package/dist/modules/n8n-packages/entities/workflow/workflow-version-policy.js +5 -5
- package/dist/modules/n8n-packages/entities/workflow/workflow-version-policy.js.map +1 -1
- package/dist/modules/n8n-packages/entities/workflow/workflow.exporter.d.ts +4 -4
- package/dist/modules/n8n-packages/entities/workflow/workflow.exporter.js +3 -3
- package/dist/modules/n8n-packages/entities/workflow/workflow.exporter.js.map +1 -1
- package/dist/modules/n8n-packages/entities/workflow/workflow.types.d.ts +6 -0
- package/dist/modules/n8n-packages/io/directory/package-directory-inventory-reader.d.ts +8 -0
- package/dist/modules/n8n-packages/io/directory/package-directory-inventory-reader.js +23 -0
- package/dist/modules/n8n-packages/io/directory/package-directory-inventory-reader.js.map +1 -1
- package/dist/modules/n8n-packages/io/manifest-entry.d.ts +5 -0
- package/dist/modules/n8n-packages/io/manifest-entry.js +6 -0
- package/dist/modules/n8n-packages/io/manifest-entry.js.map +1 -1
- package/dist/modules/n8n-packages/n8n-packages.service.d.ts +5 -1
- package/dist/modules/n8n-packages/n8n-packages.service.js +124 -59
- package/dist/modules/n8n-packages/n8n-packages.service.js.map +1 -1
- package/dist/modules/n8n-packages/n8n-packages.types.d.ts +29 -8
- package/dist/modules/n8n-packages/n8n-packages.types.js +5 -3
- package/dist/modules/n8n-packages/n8n-packages.types.js.map +1 -1
- package/dist/modules/n8n-packages/spec/manifest.schema.d.ts +471 -97
- package/dist/modules/n8n-packages/spec/manifest.schema.js +12 -1
- package/dist/modules/n8n-packages/spec/manifest.schema.js.map +1 -1
- package/dist/modules/n8n-packages/spec/requirement-consumers.d.ts +5 -0
- package/dist/modules/n8n-packages/spec/requirement-consumers.js +16 -0
- package/dist/modules/n8n-packages/spec/requirement-consumers.js.map +1 -0
- package/dist/modules/n8n-packages/spec/requirements.schema.d.ts +457 -82
- package/dist/modules/n8n-packages/spec/requirements.schema.js +37 -10
- package/dist/modules/n8n-packages/spec/requirements.schema.js.map +1 -1
- package/dist/modules/n8n-packages/spec/serialized/agent.schema.d.ts +3860 -0
- package/dist/modules/n8n-packages/spec/serialized/agent.schema.js +55 -0
- package/dist/modules/n8n-packages/spec/serialized/agent.schema.js.map +1 -0
- package/dist/modules/n8n-packages/spec/serialized/data-table.schema.d.ts +10 -0
- package/dist/modules/n8n-packages/spec/serialized/data-table.schema.js +1 -0
- package/dist/modules/n8n-packages/spec/serialized/data-table.schema.js.map +1 -1
- package/dist/modules/n8n-packages/utils/import-package-upload.d.ts +3 -15
- package/dist/modules/n8n-packages/utils/import-package-upload.js +4 -60
- package/dist/modules/n8n-packages/utils/import-package-upload.js.map +1 -1
- package/dist/modules/oauth-server/oauth-local-authorization-server.d.ts +14 -0
- package/dist/modules/oauth-server/oauth-local-authorization-server.js +55 -0
- package/dist/modules/oauth-server/oauth-local-authorization-server.js.map +1 -0
- package/dist/modules/oauth-server/oauth-server.module.js +3 -0
- package/dist/modules/oauth-server/oauth-server.module.js.map +1 -1
- package/dist/modules/oauth-server/oauth-signing-key.constants.d.ts +3 -1
- package/dist/modules/oauth-server/oauth-signing-key.constants.js +4 -2
- package/dist/modules/oauth-server/oauth-signing-key.constants.js.map +1 -1
- package/dist/modules/oauth-server/oauth-signing-key.service.d.ts +16 -4
- package/dist/modules/oauth-server/oauth-signing-key.service.js +95 -19
- package/dist/modules/oauth-server/oauth-signing-key.service.js.map +1 -1
- package/dist/modules/oauth-server/oauth-token.service.d.ts +5 -3
- package/dist/modules/oauth-server/oauth-token.service.js +30 -21
- package/dist/modules/oauth-server/oauth-token.service.js.map +1 -1
- package/dist/modules/oauth-server/oauth.controller.d.ts +4 -2
- package/dist/modules/oauth-server/oauth.controller.js +17 -26
- package/dist/modules/oauth-server/oauth.controller.js.map +1 -1
- package/dist/modules/oauth-server/resource-gate.d.ts +0 -2
- package/dist/modules/oauth-server/resource-gate.js +2 -8
- package/dist/modules/oauth-server/resource-gate.js.map +1 -1
- package/dist/modules/otel/execution-identity.d.ts +27 -0
- package/dist/modules/otel/execution-identity.js +43 -0
- package/dist/modules/otel/execution-identity.js.map +1 -0
- package/dist/modules/otel/execution-level-tracer.d.ts +1 -0
- package/dist/modules/otel/execution-level-tracer.js +75 -37
- package/dist/modules/otel/execution-level-tracer.js.map +1 -1
- package/dist/modules/otel/execution-level-tracer.types.d.ts +5 -0
- package/dist/modules/otel/execution-level-tracer.types.js.map +1 -1
- package/dist/modules/otel/otel-lifecycle-handler.d.ts +5 -1
- package/dist/modules/otel/otel-lifecycle-handler.js +44 -16
- package/dist/modules/otel/otel-lifecycle-handler.js.map +1 -1
- package/dist/modules/otel/otel-settings.service.js +2 -0
- package/dist/modules/otel/otel-settings.service.js.map +1 -1
- package/dist/modules/otel/otel.config.d.ts +2 -0
- package/dist/modules/otel/otel.config.js +10 -0
- package/dist/modules/otel/otel.config.js.map +1 -1
- package/dist/modules/otel/otel.constants.d.ts +3 -0
- package/dist/modules/otel/otel.constants.js +3 -0
- package/dist/modules/otel/otel.constants.js.map +1 -1
- package/dist/modules/otel/otel.service.js +2 -1
- package/dist/modules/otel/otel.service.js.map +1 -1
- package/dist/modules/otel/tracing-context.d.ts +1 -0
- package/dist/modules/otel/tracing-context.js.map +1 -1
- package/dist/modules/policy-infrastructure/policy-decision-audit.d.ts +2 -0
- package/dist/modules/policy-infrastructure/policy-decision-audit.js +15 -11
- package/dist/modules/policy-infrastructure/policy-decision-audit.js.map +1 -1
- package/dist/modules/policy-infrastructure/policy-decision.service.js +1 -0
- package/dist/modules/policy-infrastructure/policy-decision.service.js.map +1 -1
- package/dist/modules/promotions.ee/base-branch-files.d.ts +3 -3
- package/dist/modules/promotions.ee/base-branch-files.js.map +1 -1
- package/dist/modules/promotions.ee/branch-placement.d.ts +6 -7
- package/dist/modules/promotions.ee/branch-placement.js +19 -18
- package/dist/modules/promotions.ee/branch-placement.js.map +1 -1
- package/dist/modules/promotions.ee/database/repositories/promotion-provider.repository.d.ts +1 -0
- package/dist/modules/promotions.ee/database/repositories/promotion-provider.repository.js +13 -0
- package/dist/modules/promotions.ee/database/repositories/promotion-provider.repository.js.map +1 -1
- package/dist/modules/promotions.ee/git-hosts/git-host-clients.d.ts +8 -0
- package/dist/modules/promotions.ee/git-hosts/git-host-clients.js +28 -0
- package/dist/modules/promotions.ee/git-hosts/git-host-clients.js.map +1 -0
- package/dist/modules/promotions.ee/git-hosts/git-host.types.d.ts +7 -0
- package/dist/modules/promotions.ee/git-hosts/git-host.types.js +3 -0
- package/dist/modules/promotions.ee/git-hosts/git-host.types.js.map +1 -0
- package/dist/modules/promotions.ee/git-hosts/gitlab-host.client.d.ts +10 -0
- package/dist/modules/promotions.ee/git-hosts/gitlab-host.client.js +151 -0
- package/dist/modules/promotions.ee/git-hosts/gitlab-host.client.js.map +1 -0
- package/dist/modules/promotions.ee/import-manifest-bridge.d.ts +2 -0
- package/dist/modules/promotions.ee/import-manifest-bridge.js +20 -14
- package/dist/modules/promotions.ee/import-manifest-bridge.js.map +1 -1
- package/dist/modules/promotions.ee/promotion-binding-preflight.service.d.ts +6 -1
- package/dist/modules/promotions.ee/promotion-binding-preflight.service.js +35 -3
- package/dist/modules/promotions.ee/promotion-binding-preflight.service.js.map +1 -1
- package/dist/modules/promotions.ee/promotion-change.service.js +12 -6
- package/dist/modules/promotions.ee/promotion-change.service.js.map +1 -1
- package/dist/modules/promotions.ee/promotion-connections.service.d.ts +1 -1
- package/dist/modules/promotions.ee/promotion-providers.service.d.ts +10 -4
- package/dist/modules/promotions.ee/promotion-providers.service.js +100 -29
- package/dist/modules/promotions.ee/promotion-providers.service.js.map +1 -1
- package/dist/modules/promotions.ee/promotions.service.js +41 -14
- package/dist/modules/promotions.ee/promotions.service.js.map +1 -1
- package/dist/modules/promotions.ee/promotions.types.d.ts +2 -0
- package/dist/modules/promotions.ee/working-copy-updater.d.ts +3 -1
- package/dist/modules/promotions.ee/working-copy-updater.js +51 -29
- package/dist/modules/promotions.ee/working-copy-updater.js.map +1 -1
- package/dist/modules/provisioning.ee/provisioning.module.js +9 -3
- package/dist/modules/provisioning.ee/provisioning.module.js.map +1 -1
- package/dist/modules/provisioning.ee/provisioning.service.ee.d.ts +5 -2
- package/dist/modules/provisioning.ee/provisioning.service.ee.js +2 -2
- package/dist/modules/provisioning.ee/provisioning.service.ee.js.map +1 -1
- package/dist/modules/provisioning.ee/role-mapping-provider.ee.d.ts +14 -0
- package/dist/modules/provisioning.ee/role-mapping-provider.ee.js +33 -0
- package/dist/modules/provisioning.ee/role-mapping-provider.ee.js.map +1 -0
- package/dist/modules/provisioning.ee/role-resolver-types.d.ts +2 -41
- package/dist/modules/provisioning.ee/role-resolver.service.ee.d.ts +2 -2
- package/dist/modules/provisioning.ee/role-resolver.service.ee.js +5 -9
- package/dist/modules/provisioning.ee/role-resolver.service.ee.js.map +1 -1
- package/dist/modules/scim/database/scim-api-key.repository.d.ts +11 -0
- package/dist/modules/scim/database/scim-api-key.repository.js +51 -0
- package/dist/modules/scim/database/scim-api-key.repository.js.map +1 -0
- package/dist/modules/scim/scim-auth.middleware.d.ts +14 -0
- package/dist/modules/scim/scim-auth.middleware.js +80 -0
- package/dist/modules/scim/scim-auth.middleware.js.map +1 -0
- package/dist/modules/scim/scim-discovery.controller.d.ts +7 -0
- package/dist/modules/scim/scim-discovery.controller.js +90 -0
- package/dist/modules/scim/scim-discovery.controller.js.map +1 -0
- package/dist/modules/scim/scim-route.d.ts +9 -0
- package/dist/modules/scim/scim-route.js +17 -0
- package/dist/modules/scim/scim-route.js.map +1 -0
- package/dist/modules/scim/scim-settings.service.d.ts +9 -0
- package/dist/modules/scim/scim-settings.service.js +41 -0
- package/dist/modules/scim/scim-settings.service.js.map +1 -0
- package/dist/modules/scim/scim-token.controller.d.ts +17 -0
- package/dist/modules/scim/scim-token.controller.js +115 -0
- package/dist/modules/scim/scim-token.controller.js.map +1 -0
- package/dist/modules/scim/scim-token.service.d.ts +23 -0
- package/dist/modules/scim/scim-token.service.js +83 -0
- package/dist/modules/scim/scim-token.service.js.map +1 -0
- package/dist/modules/scim/scim.config.d.ts +3 -0
- package/dist/modules/scim/scim.config.js +28 -0
- package/dist/modules/scim/scim.config.js.map +1 -0
- package/dist/modules/scim/scim.module.d.ts +8 -0
- package/dist/modules/scim/scim.module.js +36 -0
- package/dist/modules/scim/scim.module.js.map +1 -0
- package/dist/modules/source-control.ee/source-control-import.service.ee.d.ts +1 -1
- package/dist/modules/source-control.ee/source-control-import.service.ee.js +13 -2
- package/dist/modules/source-control.ee/source-control-import.service.ee.js.map +1 -1
- package/dist/modules/source-control.ee/source-control.service.ee.js +1 -1
- package/dist/modules/source-control.ee/source-control.service.ee.js.map +1 -1
- package/dist/modules/sso-oidc/oidc.service.ee.js +12 -7
- package/dist/modules/sso-oidc/oidc.service.ee.js.map +1 -1
- package/dist/modules/token-exchange/services/jwks-resolver.js +1 -3
- package/dist/modules/token-exchange/services/jwks-resolver.js.map +1 -1
- package/dist/modules/token-exchange/services/token-exchange.service.js.map +1 -1
- package/dist/modules/token-exchange/services/trusted-key.service.js +0 -2
- package/dist/modules/token-exchange/services/trusted-key.service.js.map +1 -1
- package/dist/modules/token-exchange/token-exchange.schemas.d.ts +6 -6
- package/dist/modules/type-availability-policies/credential-type-policy-instance.controller.d.ts +4 -4
- package/dist/modules/type-availability-policies/credential-type-policy-instance.controller.js +3 -3
- package/dist/modules/type-availability-policies/credential-type-policy-instance.controller.js.map +1 -1
- package/dist/modules/type-availability-policies/credential-type-policy-project.controller.d.ts +2 -2
- package/dist/modules/type-availability-policies/credential-type-policy-project.controller.js +1 -1
- package/dist/modules/type-availability-policies/credential-type-policy-project.controller.js.map +1 -1
- package/dist/modules/type-availability-policies/credential-type-policy.check.d.ts +2 -1
- package/dist/modules/type-availability-policies/credential-type-policy.check.js +5 -0
- package/dist/modules/type-availability-policies/credential-type-policy.check.js.map +1 -1
- package/dist/modules/type-availability-policies/database/repositories/restricted-node-type-match.d.ts +25 -0
- package/dist/modules/type-availability-policies/database/repositories/restricted-node-type-match.js +43 -0
- package/dist/modules/type-availability-policies/database/repositories/restricted-node-type-match.js.map +1 -0
- package/dist/modules/type-availability-policies/database/repositories/restricted-workflow.repository.d.ts +8 -0
- package/dist/modules/type-availability-policies/database/repositories/restricted-workflow.repository.js +49 -0
- package/dist/modules/type-availability-policies/database/repositories/restricted-workflow.repository.js.map +1 -0
- package/dist/modules/type-availability-policies/database/repositories/type-availability-policy-attachment.repository.d.ts +1 -0
- package/dist/modules/type-availability-policies/database/repositories/type-availability-policy-attachment.repository.js +23 -19
- package/dist/modules/type-availability-policies/database/repositories/type-availability-policy-attachment.repository.js.map +1 -1
- package/dist/modules/type-availability-policies/database/repositories/type-availability-policy-scope.repository.d.ts +4 -0
- package/dist/modules/type-availability-policies/database/repositories/type-availability-policy-scope.repository.js +8 -0
- package/dist/modules/type-availability-policies/database/repositories/type-availability-policy-scope.repository.js.map +1 -1
- package/dist/modules/type-availability-policies/package-resolver.d.ts +2 -1
- package/dist/modules/type-availability-policies/package-resolver.js +28 -4
- package/dist/modules/type-availability-policies/package-resolver.js.map +1 -1
- package/dist/modules/type-availability-policies/policy-evaluator.d.ts +1 -0
- package/dist/modules/type-availability-policies/policy-evaluator.js +2 -0
- package/dist/modules/type-availability-policies/policy-evaluator.js.map +1 -1
- package/dist/modules/type-availability-policies/policy-shadow-lint.js +28 -6
- package/dist/modules/type-availability-policies/policy-shadow-lint.js.map +1 -1
- package/dist/modules/type-availability-policies/restricted-node-types.provider.d.ts +15 -0
- package/dist/modules/type-availability-policies/restricted-node-types.provider.js +64 -0
- package/dist/modules/type-availability-policies/restricted-node-types.provider.js.map +1 -0
- package/dist/modules/type-availability-policies/type-availability-policies.module.js +4 -0
- package/dist/modules/type-availability-policies/type-availability-policies.module.js.map +1 -1
- package/dist/modules/type-availability-policies/type-availability-policy.service.d.ts +8 -0
- package/dist/modules/type-availability-policies/type-availability-policy.service.js +75 -21
- package/dist/modules/type-availability-policies/type-availability-policy.service.js.map +1 -1
- package/dist/modules/workflow-index/workflow-dependency-query.service.d.ts +3 -1
- package/dist/modules/workflow-index/workflow-dependency-query.service.js +16 -2
- package/dist/modules/workflow-index/workflow-dependency-query.service.js.map +1 -1
- package/dist/modules/workflow-index/workflow-dependency.controller.js +1 -1
- package/dist/modules/workflow-index/workflow-dependency.controller.js.map +1 -1
- package/dist/node-catalog/index.d.ts +1 -0
- package/dist/node-catalog/index.js +4 -1
- package/dist/node-catalog/index.js.map +1 -1
- package/dist/node-catalog/module-gated-node-types.d.ts +3 -0
- package/dist/node-catalog/module-gated-node-types.js +26 -0
- package/dist/node-catalog/module-gated-node-types.js.map +1 -0
- package/dist/node-catalog/node-catalog.service.d.ts +3 -2
- package/dist/node-catalog/node-catalog.service.js +15 -6
- package/dist/node-catalog/node-catalog.service.js.map +1 -1
- package/dist/node-execution/ephemeral-node-executor.d.ts +5 -1
- package/dist/node-execution/ephemeral-node-executor.js +37 -12
- package/dist/node-execution/ephemeral-node-executor.js.map +1 -1
- package/dist/node-execution/index.d.ts +1 -0
- package/dist/node-execution/index.js +3 -1
- package/dist/node-execution/index.js.map +1 -1
- package/dist/node-execution/resolve-tool-node-type.d.ts +1 -0
- package/dist/node-execution/resolve-tool-node-type.js +19 -0
- package/dist/node-execution/resolve-tool-node-type.js.map +1 -0
- package/dist/policy/policed-agent-nodes.d.ts +3 -0
- package/dist/policy/policed-agent-nodes.js +91 -0
- package/dist/policy/policed-agent-nodes.js.map +1 -0
- package/dist/policy/policy-enforcement-backend.d.ts +2 -1
- package/dist/policy/policy-enforcement.service.d.ts +3 -1
- package/dist/policy/policy-enforcement.service.js +35 -10
- package/dist/policy/policy-enforcement.service.js.map +1 -1
- package/dist/policy/policy-violation.error.js +1 -6
- package/dist/policy/policy-violation.error.js.map +1 -1
- package/dist/posthog/index.js +1 -1
- package/dist/posthog/index.js.map +1 -1
- package/dist/public-api/idempotency-key-cleanup.task.d.ts +14 -0
- package/dist/public-api/idempotency-key-cleanup.task.js +45 -0
- package/dist/public-api/idempotency-key-cleanup.task.js.map +1 -0
- package/dist/public-api/idempotency-key.service.d.ts +7 -0
- package/dist/public-api/idempotency-key.service.js +35 -0
- package/dist/public-api/idempotency-key.service.js.map +1 -0
- package/dist/public-api/index.js +1 -3
- package/dist/public-api/index.js.map +1 -1
- package/dist/public-api/media-types/binary-response.d.ts +3 -0
- package/dist/public-api/media-types/binary-response.js +79 -0
- package/dist/public-api/media-types/binary-response.js.map +1 -0
- package/dist/public-api/public-api-controller.registry.js +6 -0
- package/dist/public-api/public-api-controller.registry.js.map +1 -1
- package/dist/public-api/public-api-route-resolver.d.ts +2 -1
- package/dist/public-api/public-api-route-resolver.js +1 -0
- package/dist/public-api/public-api-route-resolver.js.map +1 -1
- package/dist/public-api/types.d.ts +1 -43
- package/dist/public-api/v1/controllers/credential-type-policies.public.controller.d.ts +10 -10
- package/dist/public-api/v1/controllers/credential-type-policies.public.controller.js +13 -13
- package/dist/public-api/v1/controllers/credential-type-policies.public.controller.js.map +1 -1
- package/dist/public-api/v1/controllers/index.d.ts +1 -0
- package/dist/public-api/v1/controllers/index.js +1 -0
- package/dist/public-api/v1/controllers/index.js.map +1 -1
- package/dist/public-api/v1/controllers/insights.public.controller.d.ts +1 -1
- package/dist/public-api/v1/controllers/insights.public.controller.js +2 -2
- package/dist/public-api/v1/controllers/insights.public.controller.js.map +1 -1
- package/dist/public-api/v1/{handlers/log-streaming → controllers}/log-streaming.mapper.d.ts +20 -20
- package/dist/public-api/v1/{handlers/log-streaming → controllers}/log-streaming.mapper.js +10 -10
- package/dist/public-api/v1/controllers/log-streaming.mapper.js.map +1 -0
- package/dist/public-api/v1/controllers/log-streaming.public.controller.d.ts +23 -1
- package/dist/public-api/v1/controllers/log-streaming.public.controller.js +161 -1
- package/dist/public-api/v1/controllers/log-streaming.public.controller.js.map +1 -1
- package/dist/public-api/v1/controllers/n8n-packages.public.controller.d.ts +13 -0
- package/dist/public-api/v1/controllers/n8n-packages.public.controller.js +134 -0
- package/dist/public-api/v1/controllers/n8n-packages.public.controller.js.map +1 -0
- package/dist/public-api/v1/controllers/node-type-policies.public.controller.js +13 -6
- package/dist/public-api/v1/controllers/node-type-policies.public.controller.js.map +1 -1
- package/dist/public-api/v1/controllers/openapi/n8n-packages.openapi.d.ts +9 -0
- package/dist/public-api/v1/controllers/openapi/n8n-packages.openapi.js +55 -0
- package/dist/public-api/v1/controllers/openapi/n8n-packages.openapi.js.map +1 -0
- package/dist/public-api/v1/controllers/otel.public.controller.js +1 -1
- package/dist/public-api/v1/controllers/otel.public.controller.js.map +1 -1
- package/dist/public-api/v1/controllers/promotions.public.controller.js +6 -5
- package/dist/public-api/v1/controllers/promotions.public.controller.js.map +1 -1
- package/dist/public-api/v1/controllers/workflows.public.controller.d.ts +2 -1
- package/dist/public-api/v1/controllers/workflows.public.controller.js +35 -4
- package/dist/public-api/v1/controllers/workflows.public.controller.js.map +1 -1
- package/dist/public-api/v1/handlers/n8n-packages/n8n-packages.handler.d.ts +2 -20
- package/dist/public-api/v1/handlers/n8n-packages/n8n-packages.handler.js +17 -105
- package/dist/public-api/v1/handlers/n8n-packages/n8n-packages.handler.js.map +1 -1
- package/dist/public-api/v1/openapi-gen/decorator-routes.d.ts +27 -1
- package/dist/public-api/v1/openapi-gen/decorator-routes.js +37 -14
- package/dist/public-api/v1/openapi-gen/decorator-routes.js.map +1 -1
- package/dist/public-api/v1/openapi-gen/generate.js +2 -2
- package/dist/public-api/v1/openapi-gen/generate.js.map +1 -1
- package/dist/public-api/v1/openapi-gen/object-union-type.d.ts +1 -0
- package/dist/public-api/v1/openapi-gen/object-union-type.js +33 -0
- package/dist/public-api/v1/openapi-gen/object-union-type.js.map +1 -0
- package/dist/public-api/v1/openapi-gen/schema-modifiers.d.ts +1 -0
- package/dist/public-api/v1/openapi-gen/schema-modifiers.js +12 -0
- package/dist/public-api/v1/openapi-gen/schema-modifiers.js.map +1 -0
- package/dist/public-api/v1/openapi.yml +10389 -8020
- package/dist/public-api/v1/shared/otel.mapper.js +2 -0
- package/dist/public-api/v1/shared/otel.mapper.js.map +1 -1
- package/dist/public-api/v1/shared/services/pagination.service.js +1 -1
- package/dist/public-api/v1/shared/services/pagination.service.js.map +1 -1
- package/dist/scaling/constants.d.ts +2 -2
- package/dist/scaling/job-processor.d.ts +7 -1
- package/dist/scaling/job-processor.js +32 -26
- package/dist/scaling/job-processor.js.map +1 -1
- package/dist/scaling/job-return.d.ts +3 -0
- package/dist/scaling/job-return.js +33 -0
- package/dist/scaling/job-return.js.map +1 -0
- package/dist/scaling/pubsub/pubsub.event-map.d.ts +1 -0
- package/dist/scaling/pubsub/pubsub.types.d.ts +2 -1
- package/dist/scaling/scaling.service.d.ts +2 -0
- package/dist/scaling/scaling.service.js +37 -3
- package/dist/scaling/scaling.service.js.map +1 -1
- package/dist/scaling/scaling.types.d.ts +1 -0
- package/dist/scheduling/durable-job-provisioner.d.ts +3 -2
- package/dist/scheduling/durable-job-provisioner.js +34 -71
- package/dist/scheduling/durable-job-provisioner.js.map +1 -1
- package/dist/scheduling/durable-scheduler.js +0 -9
- package/dist/scheduling/durable-scheduler.js.map +1 -1
- package/dist/scheduling/poll-trigger-node/poll-trigger-job-registrar.d.ts +1 -0
- package/dist/scheduling/poll-trigger-node/poll-trigger-job-registrar.js +2 -0
- package/dist/scheduling/poll-trigger-node/poll-trigger-job-registrar.js.map +1 -1
- package/dist/scheduling/poll-trigger-node/poll-trigger-task-handler.d.ts +5 -5
- package/dist/scheduling/poll-trigger-node/poll-trigger-task-handler.js +59 -95
- package/dist/scheduling/poll-trigger-node/poll-trigger-task-handler.js.map +1 -1
- package/dist/scheduling/system-tasks/main-system-tasks.js +17 -5
- package/dist/scheduling/system-tasks/main-system-tasks.js.map +1 -1
- package/dist/scheduling/system-tasks/system-task-handler.d.ts +2 -2
- package/dist/scheduling/system-tasks/system-task-handler.js +4 -4
- package/dist/scheduling/system-tasks/system-task-handler.js.map +1 -1
- package/dist/scheduling/system-tasks/system-task-job-registrar.js +2 -1
- package/dist/scheduling/system-tasks/system-task-job-registrar.js.map +1 -1
- package/dist/scheduling/system-tasks/system-task-run-observer.d.ts +3 -3
- package/dist/scheduling/system-tasks/system-task-run-observer.js +14 -6
- package/dist/scheduling/system-tasks/system-task-run-observer.js.map +1 -1
- package/dist/server.d.ts +1 -0
- package/dist/server.js +1 -0
- package/dist/server.js.map +1 -1
- package/dist/services/ai-preference.service.d.ts +2 -1
- package/dist/services/ai-preference.service.js +10 -0
- package/dist/services/ai-preference.service.js.map +1 -1
- package/dist/services/database-independent-routes.service.d.ts +5 -0
- package/dist/services/database-independent-routes.service.js +29 -0
- package/dist/services/database-independent-routes.service.js.map +1 -0
- package/dist/services/frontend.service.d.ts +3 -0
- package/dist/services/frontend.service.js +12 -1
- package/dist/services/frontend.service.js.map +1 -1
- package/dist/services/jwt.service.d.ts +4 -3
- package/dist/services/jwt.service.js +9 -6
- package/dist/services/jwt.service.js.map +1 -1
- package/dist/services/oauth-token-verifier-proxy.service.d.ts +0 -2
- package/dist/services/oauth-token-verifier-proxy.service.js +0 -6
- package/dist/services/oauth-token-verifier-proxy.service.js.map +1 -1
- package/dist/services/ownership-transfer/ownership-transfer.manifest.json +6 -1
- package/dist/services/ownership-transfer/ownership-transfer.service.d.ts +9 -2
- package/dist/services/ownership-transfer/ownership-transfer.service.js +27 -2
- package/dist/services/ownership-transfer/ownership-transfer.service.js.map +1 -1
- package/dist/services/ownership.service.d.ts +4 -6
- package/dist/services/ownership.service.js +7 -38
- package/dist/services/ownership.service.js.map +1 -1
- package/dist/services/project.service.ee.d.ts +2 -0
- package/dist/services/project.service.ee.js +13 -0
- package/dist/services/project.service.ee.js.map +1 -1
- package/dist/services/pruning/execution-pruning-hard-delete.task.d.ts +17 -0
- package/dist/{modules/insights/insights-pruning.task.js → services/pruning/execution-pruning-hard-delete.task.js} +17 -15
- package/dist/services/pruning/execution-pruning-hard-delete.task.js.map +1 -0
- package/dist/services/pruning/execution-pruning-soft-delete.task.d.ts +4 -2
- package/dist/services/pruning/execution-pruning-soft-delete.task.js +4 -2
- package/dist/services/pruning/execution-pruning-soft-delete.task.js.map +1 -1
- package/dist/services/pruning/executions-pruning.service.d.ts +6 -18
- package/dist/services/pruning/executions-pruning.service.js +54 -88
- package/dist/services/pruning/executions-pruning.service.js.map +1 -1
- package/dist/services/pruning/workflow-history-compaction-optimize.task.d.ts +1 -0
- package/dist/services/pruning/workflow-history-compaction-optimize.task.js +1 -0
- package/dist/services/pruning/workflow-history-compaction-optimize.task.js.map +1 -1
- package/dist/services/pruning/workflow-history-compaction-trim.task.d.ts +2 -0
- package/dist/services/pruning/workflow-history-compaction-trim.task.js +8 -6
- package/dist/services/pruning/workflow-history-compaction-trim.task.js.map +1 -1
- package/dist/services/pruning/workflow-history-compaction.service.d.ts +1 -5
- package/dist/services/pruning/workflow-history-compaction.service.js +14 -19
- package/dist/services/pruning/workflow-history-compaction.service.js.map +1 -1
- package/dist/services/pruning/workflow-history-compaction.utils.d.ts +6 -0
- package/dist/services/pruning/workflow-history-compaction.utils.js +14 -0
- package/dist/services/pruning/workflow-history-compaction.utils.js.map +1 -0
- package/dist/services/pruning/workflow-history-pruning.task.d.ts +4 -1
- package/dist/services/pruning/workflow-history-pruning.task.js +5 -2
- package/dist/services/pruning/workflow-history-pruning.task.js.map +1 -1
- package/dist/services/role-mapping-proxy.service.d.ts +53 -0
- package/dist/{modules/favorites/favorite-resource-resolver.registry.js → services/role-mapping-proxy.service.js} +11 -11
- package/dist/services/role-mapping-proxy.service.js.map +1 -0
- package/dist/services/token-purposes.d.ts +2 -0
- package/dist/services/token-purposes.js +2 -0
- package/dist/services/token-purposes.js.map +1 -1
- package/dist/services/user.service.js +1 -0
- package/dist/services/user.service.js.map +1 -1
- package/dist/services/workflow-statistics-rollup.service.d.ts +6 -17
- package/dist/services/workflow-statistics-rollup.service.js +26 -77
- package/dist/services/workflow-statistics-rollup.service.js.map +1 -1
- package/dist/services/workflow-statistics-rollup.task.d.ts +14 -0
- package/dist/services/workflow-statistics-rollup.task.js +43 -0
- package/dist/services/workflow-statistics-rollup.task.js.map +1 -0
- package/dist/services/workflow-statistics.service.js +10 -18
- package/dist/services/workflow-statistics.service.js.map +1 -1
- package/dist/telemetry/index.d.ts +10 -4
- package/dist/telemetry/index.js +51 -30
- package/dist/telemetry/index.js.map +1 -1
- package/dist/tool-generation/hitl-tools.js +5 -0
- package/dist/tool-generation/hitl-tools.js.map +1 -1
- package/dist/user-management/email/templates/agent-budget-alert.handlebars +196 -0
- package/dist/user-management/email/user-management-mailer.d.ts +8 -1
- package/dist/user-management/email/user-management-mailer.js +16 -0
- package/dist/user-management/email/user-management-mailer.js.map +1 -1
- package/dist/utils/strapi-utils.d.ts +1 -1
- package/dist/wait-tracker.js +2 -0
- package/dist/wait-tracker.js.map +1 -1
- package/dist/webhooks/waiting-webhooks.js +7 -6
- package/dist/webhooks/waiting-webhooks.js.map +1 -1
- package/dist/webhooks/webhook-helpers.d.ts +4 -1
- package/dist/webhooks/webhook-helpers.js +21 -3
- package/dist/webhooks/webhook-helpers.js.map +1 -1
- package/dist/workflow-execute-additional-data.d.ts +2 -1
- package/dist/workflow-execute-additional-data.js +17 -8
- package/dist/workflow-execute-additional-data.js.map +1 -1
- package/dist/workflow-runner.d.ts +2 -2
- package/dist/workflow-runner.js +10 -12
- package/dist/workflow-runner.js.map +1 -1
- package/dist/workflows/execution-timeout-validation.d.ts +2 -0
- package/dist/workflows/execution-timeout-validation.js +16 -0
- package/dist/workflows/execution-timeout-validation.js.map +1 -0
- package/dist/workflows/restricted-node-types-provider-proxy.service.d.ts +9 -0
- package/dist/workflows/restricted-node-types-provider-proxy.service.js +26 -0
- package/dist/workflows/restricted-node-types-provider-proxy.service.js.map +1 -0
- package/dist/workflows/triggers/trigger-execution-context.factory.d.ts +8 -5
- package/dist/workflows/triggers/trigger-execution-context.factory.js +19 -13
- package/dist/workflows/triggers/trigger-execution-context.factory.js.map +1 -1
- package/dist/workflows/workflow-execution.service.d.ts +3 -3
- package/dist/workflows/workflow-execution.service.js +4 -2
- package/dist/workflows/workflow-execution.service.js.map +1 -1
- package/dist/workflows/workflow-finder.service.d.ts +9 -3
- package/dist/workflows/workflow-finder.service.js +6 -5
- package/dist/workflows/workflow-finder.service.js.map +1 -1
- package/dist/workflows/workflow-history/workflow-history.controller.d.ts +2 -2
- package/dist/workflows/workflow-history/workflow-history.controller.js +9 -6
- package/dist/workflows/workflow-history/workflow-history.controller.js.map +1 -1
- package/dist/workflows/workflow-history/workflow-history.service.d.ts +27 -11
- package/dist/workflows/workflow-history/workflow-history.service.js +56 -34
- package/dist/workflows/workflow-history/workflow-history.service.js.map +1 -1
- package/dist/workflows/workflow-validation.service.d.ts +1 -1
- package/dist/workflows/workflow-validation.service.js +2 -2
- package/dist/workflows/workflow-validation.service.js.map +1 -1
- package/dist/workflows/workflow.service.d.ts +44 -17
- package/dist/workflows/workflow.service.ee.d.ts +5 -3
- package/dist/workflows/workflow.service.ee.js +35 -9
- package/dist/workflows/workflow.service.ee.js.map +1 -1
- package/dist/workflows/workflow.service.js +81 -24
- package/dist/workflows/workflow.service.js.map +1 -1
- package/dist/workflows/workflows.controller.js +5 -1
- package/dist/workflows/workflows.controller.js.map +1 -1
- package/package.json +44 -42
- package/dist/modules/breaking-changes/migrations/execute-workflow-each-to-loop.migration.d.ts +0 -2
- package/dist/modules/breaking-changes/migrations/execute-workflow-each-to-loop.migration.js +0 -159
- package/dist/modules/breaking-changes/migrations/execute-workflow-each-to-loop.migration.js.map +0 -1
- package/dist/modules/breaking-changes/rules/v3/execute-workflow-each-mode.rule.d.ts +0 -10
- package/dist/modules/breaking-changes/rules/v3/execute-workflow-each-mode.rule.js +0 -47
- package/dist/modules/breaking-changes/rules/v3/execute-workflow-each-mode.rule.js.map +0 -1
- package/dist/modules/favorites/favorite-resource-resolver.registry.d.ts +0 -17
- package/dist/modules/favorites/favorite-resource-resolver.registry.js.map +0 -1
- package/dist/modules/insights/database/entities/insights-by-period.d.ts +0 -17
- package/dist/modules/insights/database/entities/insights-by-period.js +0 -73
- package/dist/modules/insights/database/entities/insights-by-period.js.map +0 -1
- package/dist/modules/insights/database/entities/insights-metadata.d.ts +0 -8
- package/dist/modules/insights/database/entities/insights-metadata.js +0 -40
- package/dist/modules/insights/database/entities/insights-metadata.js.map +0 -1
- package/dist/modules/insights/database/entities/insights-raw.d.ts +0 -13
- package/dist/modules/insights/database/entities/insights-raw.js +0 -61
- package/dist/modules/insights/database/entities/insights-raw.js.map +0 -1
- package/dist/modules/insights/database/entities/insights-shared.d.ts +0 -21
- package/dist/modules/insights/database/entities/insights-shared.js +0 -30
- package/dist/modules/insights/database/entities/insights-shared.js.map +0 -1
- package/dist/modules/insights/database/repositories/insights-by-period-query.helper.d.ts +0 -15
- package/dist/modules/insights/database/repositories/insights-by-period-query.helper.js +0 -45
- package/dist/modules/insights/database/repositories/insights-by-period-query.helper.js.map +0 -1
- package/dist/modules/insights/database/repositories/insights-by-period.repository.d.ts +0 -100
- package/dist/modules/insights/database/repositories/insights-by-period.repository.js +0 -347
- package/dist/modules/insights/database/repositories/insights-by-period.repository.js.map +0 -1
- package/dist/modules/insights/database/repositories/insights-metadata.repository.d.ts +0 -7
- package/dist/modules/insights/database/repositories/insights-metadata.repository.js +0 -36
- package/dist/modules/insights/database/repositories/insights-metadata.repository.js.map +0 -1
- package/dist/modules/insights/database/repositories/insights-raw.repository.d.ts +0 -12
- package/dist/modules/insights/database/repositories/insights-raw.repository.js +0 -36
- package/dist/modules/insights/database/repositories/insights-raw.repository.js.map +0 -1
- package/dist/modules/insights/insights-collection.service.d.ts +0 -30
- package/dist/modules/insights/insights-collection.service.js +0 -280
- package/dist/modules/insights/insights-collection.service.js.map +0 -1
- package/dist/modules/insights/insights-compaction.service.d.ts +0 -19
- package/dist/modules/insights/insights-compaction.service.js +0 -161
- package/dist/modules/insights/insights-compaction.service.js.map +0 -1
- package/dist/modules/insights/insights-compaction.task.d.ts +0 -14
- package/dist/modules/insights/insights-compaction.task.js.map +0 -1
- package/dist/modules/insights/insights-pruning.service.d.ts +0 -11
- package/dist/modules/insights/insights-pruning.service.js +0 -49
- package/dist/modules/insights/insights-pruning.service.js.map +0 -1
- package/dist/modules/insights/insights-pruning.task.d.ts +0 -15
- package/dist/modules/insights/insights-pruning.task.js.map +0 -1
- package/dist/modules/insights/insights.config.d.ts +0 -13
- package/dist/modules/insights/insights.config.js +0 -80
- package/dist/modules/insights/insights.config.js.map +0 -1
- package/dist/modules/insights/insights.constants.d.ts +0 -4
- package/dist/modules/insights/insights.constants.js +0 -24
- package/dist/modules/insights/insights.constants.js.map +0 -1
- package/dist/modules/insights/insights.controller.d.ts +0 -16
- package/dist/modules/insights/insights.controller.js +0 -159
- package/dist/modules/insights/insights.controller.js.map +0 -1
- package/dist/modules/insights/insights.module.d.ts +0 -17
- package/dist/modules/insights/insights.module.js +0 -51
- package/dist/modules/insights/insights.module.js.map +0 -1
- package/dist/modules/insights/insights.service.d.ts +0 -73
- package/dist/modules/insights/insights.service.js +0 -257
- package/dist/modules/insights/insights.service.js.map +0 -1
- package/dist/modules/insights/insights.settings.d.ts +0 -20
- package/dist/modules/insights/insights.settings.js +0 -48
- package/dist/modules/insights/insights.settings.js.map +0 -1
- package/dist/public-api/v1/handlers/log-streaming/log-streaming.handler.d.ts +0 -12
- package/dist/public-api/v1/handlers/log-streaming/log-streaming.handler.js +0 -107
- package/dist/public-api/v1/handlers/log-streaming/log-streaming.handler.js.map +0 -1
- package/dist/public-api/v1/handlers/log-streaming/log-streaming.mapper.js.map +0 -1
- package/dist/public-api/v1/handlers/workflows/workflows.handler.d.ts +0 -7
- package/dist/public-api/v1/handlers/workflows/workflows.handler.js +0 -31
- package/dist/public-api/v1/handlers/workflows/workflows.handler.js.map +0 -1
|
@@ -1,22 +1,29 @@
|
|
|
1
1
|
import { type AgentJsonConfig, type AgentSkill, type AgentSkillMutationResponse } from '@n8n/api-types';
|
|
2
2
|
import { Logger } from '@n8n/backend-common';
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
3
|
+
import { TransactionRunner } from '@n8n/db';
|
|
4
|
+
import { type AgentMutationTelemetryContext } from './agent-modification-telemetry.service';
|
|
5
|
+
import { AgentSaveCompletionService } from './agent-save-completion.service';
|
|
6
|
+
import { AgentSkillRefsService } from './agent-skill-refs.service';
|
|
5
7
|
import { Agent } from './entities/agent.entity';
|
|
6
8
|
import { AgentRepository } from './repositories/agent.repository';
|
|
9
|
+
import { type SkillInstructionEdit } from './utils/skill-instruction-edits';
|
|
7
10
|
export declare class AgentSkillsService {
|
|
8
11
|
private readonly logger;
|
|
9
12
|
private readonly agentRepository;
|
|
10
|
-
private readonly
|
|
11
|
-
private readonly
|
|
12
|
-
|
|
13
|
+
private readonly saveCompletion;
|
|
14
|
+
private readonly agentSkillRefs;
|
|
15
|
+
private readonly transactionRunner;
|
|
16
|
+
constructor(logger: Logger, agentRepository: AgentRepository, saveCompletion: AgentSaveCompletionService, agentSkillRefs: AgentSkillRefsService, transactionRunner: TransactionRunner);
|
|
13
17
|
listSkills(agentId: string, projectId: string): Promise<Record<string, AgentSkill>>;
|
|
14
18
|
getSkill(agentId: string, projectId: string, skillId: string): Promise<AgentSkill>;
|
|
15
19
|
createSkill(agentId: string, projectId: string, skill: AgentSkill, context: AgentMutationTelemetryContext): Promise<AgentSkillMutationResponse>;
|
|
16
|
-
|
|
20
|
+
createAndAttachSkills(agentId: string, projectId: string, skills: AgentSkill[], context: AgentMutationTelemetryContext): Promise<{
|
|
21
|
+
skills: AgentSkillMutationResponse[];
|
|
22
|
+
configHash: string | null;
|
|
23
|
+
}>;
|
|
17
24
|
createAndAttachSkill(agentId: string, projectId: string, skill: AgentSkill, context: AgentMutationTelemetryContext): Promise<AgentSkillMutationResponse>;
|
|
18
25
|
private createSkillsBatch;
|
|
19
|
-
updateSkill(agentId: string, projectId: string, skillId: string, updates: Partial<AgentSkill>, context: AgentMutationTelemetryContext, baseSkillHash?: string): Promise<AgentSkillMutationResponse>;
|
|
26
|
+
updateSkill(agentId: string, projectId: string, skillId: string, updates: Partial<AgentSkill>, context: AgentMutationTelemetryContext, baseSkillHash?: string, instructionEdits?: SkillInstructionEdit[]): Promise<AgentSkillMutationResponse>;
|
|
20
27
|
deleteSkill(agentId: string, projectId: string, skillId: string, context: AgentMutationTelemetryContext): Promise<void>;
|
|
21
28
|
removeUnreferencedSkills(entity: Agent, config: AgentJsonConfig): void;
|
|
22
29
|
private validateSkill;
|
|
@@ -25,6 +32,5 @@ export declare class AgentSkillsService {
|
|
|
25
32
|
private normalizeSkillName;
|
|
26
33
|
private assertBatchSkillNamesAreUnique;
|
|
27
34
|
private attachSkillRef;
|
|
28
|
-
private clearRuntimes;
|
|
29
35
|
private saveSkillChanges;
|
|
30
36
|
}
|
|
@@ -15,23 +15,28 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
15
15
|
exports.AgentSkillsService = void 0;
|
|
16
16
|
const api_types_1 = require("@n8n/api-types");
|
|
17
17
|
const backend_common_1 = require("@n8n/backend-common");
|
|
18
|
+
const db_1 = require("@n8n/db");
|
|
18
19
|
const di_1 = require("@n8n/di");
|
|
19
20
|
const isEqual_1 = __importDefault(require("lodash/isEqual"));
|
|
20
21
|
const n8n_workflow_1 = require("n8n-workflow");
|
|
21
22
|
const errors_1 = require("@n8n/errors");
|
|
22
23
|
const agent_modification_telemetry_service_1 = require("./agent-modification-telemetry.service");
|
|
23
|
-
const
|
|
24
|
+
const agent_save_completion_service_1 = require("./agent-save-completion.service");
|
|
25
|
+
const agent_skill_refs_service_1 = require("./agent-skill-refs.service");
|
|
24
26
|
const agent_draft_utils_1 = require("./utils/agent-draft.utils");
|
|
25
27
|
const agent_repository_1 = require("./repositories/agent.repository");
|
|
26
28
|
const get_agent_or_throw_1 = require("./utils/get-agent-or-throw");
|
|
27
29
|
const agent_config_hash_1 = require("./utils/agent-config-hash");
|
|
30
|
+
const agent_config_composition_1 = require("./json-config/agent-config-composition");
|
|
28
31
|
const agent_resource_id_1 = require("./utils/agent-resource-id");
|
|
32
|
+
const skill_instruction_edits_1 = require("./utils/skill-instruction-edits");
|
|
29
33
|
let AgentSkillsService = class AgentSkillsService {
|
|
30
|
-
constructor(logger, agentRepository,
|
|
34
|
+
constructor(logger, agentRepository, saveCompletion, agentSkillRefs, transactionRunner) {
|
|
31
35
|
this.logger = logger;
|
|
32
36
|
this.agentRepository = agentRepository;
|
|
33
|
-
this.
|
|
34
|
-
this.
|
|
37
|
+
this.saveCompletion = saveCompletion;
|
|
38
|
+
this.agentSkillRefs = agentSkillRefs;
|
|
39
|
+
this.transactionRunner = transactionRunner;
|
|
35
40
|
}
|
|
36
41
|
async listSkills(agentId, projectId) {
|
|
37
42
|
const entity = await (0, get_agent_or_throw_1.getAgentOrThrow)(this.agentRepository, agentId, projectId, 'Agent not found');
|
|
@@ -45,15 +50,19 @@ let AgentSkillsService = class AgentSkillsService {
|
|
|
45
50
|
return skill;
|
|
46
51
|
}
|
|
47
52
|
async createSkill(agentId, projectId, skill, context) {
|
|
48
|
-
const
|
|
49
|
-
return
|
|
53
|
+
const { results } = await this.createSkillsBatch(agentId, projectId, [skill], false, context);
|
|
54
|
+
return results[0];
|
|
50
55
|
}
|
|
51
|
-
async
|
|
52
|
-
|
|
56
|
+
async createAndAttachSkills(agentId, projectId, skills, context) {
|
|
57
|
+
const { results, saved, skillRefs } = await this.createSkillsBatch(agentId, projectId, skills, true, context);
|
|
58
|
+
return {
|
|
59
|
+
skills: results,
|
|
60
|
+
configHash: (0, agent_config_hash_1.getAgentConfigHash)((0, agent_config_composition_1.composeJsonConfig)(saved, skillRefs)),
|
|
61
|
+
};
|
|
53
62
|
}
|
|
54
63
|
async createAndAttachSkill(agentId, projectId, skill, context) {
|
|
55
|
-
const
|
|
56
|
-
return
|
|
64
|
+
const { results } = await this.createSkillsBatch(agentId, projectId, [skill], true, context);
|
|
65
|
+
return results[0];
|
|
57
66
|
}
|
|
58
67
|
async createSkillsBatch(agentId, projectId, skills, attach, context) {
|
|
59
68
|
if (skills.length === 0) {
|
|
@@ -66,25 +75,31 @@ let AgentSkillsService = class AgentSkillsService {
|
|
|
66
75
|
this.validateSkill(skill);
|
|
67
76
|
}
|
|
68
77
|
this.assertBatchSkillNamesAreUnique(entity.skills ?? {}, skills);
|
|
69
|
-
const
|
|
78
|
+
const previousSkillRefs = await this.agentSkillRefs.refsForDraft(entity, {});
|
|
79
|
+
const previous = (0, agent_modification_telemetry_service_1.captureAgentMutation)(entity, previousSkillRefs);
|
|
70
80
|
const results = skills.map((skill) => ({ id: this.addSkill(entity, skill), skill }));
|
|
81
|
+
let skillRefs = previousSkillRefs;
|
|
71
82
|
if (attach) {
|
|
72
83
|
for (const { id } of results)
|
|
73
|
-
this.attachSkillRef(
|
|
84
|
+
skillRefs = this.attachSkillRef(skillRefs, id);
|
|
74
85
|
}
|
|
75
|
-
const saved = await this.saveSkillChanges(entity, projectId, context, previous);
|
|
86
|
+
const saved = await this.saveSkillChanges(entity, projectId, context, previous, previousSkillRefs, attach ? { refs: skillRefs } : undefined);
|
|
76
87
|
this.logger.debug(attach ? 'Created and attached agent skill' : 'Created agent skills', {
|
|
77
88
|
agentId,
|
|
78
89
|
projectId,
|
|
79
90
|
skillIds: results.map((r) => r.id),
|
|
80
91
|
});
|
|
81
|
-
return
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
92
|
+
return {
|
|
93
|
+
results: results.map((r) => ({
|
|
94
|
+
...r,
|
|
95
|
+
skillHash: (0, agent_config_hash_1.getAgentSkillHash)(r.skill),
|
|
96
|
+
versionId: saved.versionId,
|
|
97
|
+
})),
|
|
98
|
+
saved,
|
|
99
|
+
skillRefs,
|
|
100
|
+
};
|
|
86
101
|
}
|
|
87
|
-
async updateSkill(agentId, projectId, skillId, updates, context, baseSkillHash) {
|
|
102
|
+
async updateSkill(agentId, projectId, skillId, updates, context, baseSkillHash, instructionEdits) {
|
|
88
103
|
const entity = await (0, get_agent_or_throw_1.getAgentOrThrow)(this.agentRepository, agentId, projectId, 'Agent not found');
|
|
89
104
|
const existing = entity.skills?.[skillId];
|
|
90
105
|
if (!existing)
|
|
@@ -93,6 +108,12 @@ let AgentSkillsService = class AgentSkillsService {
|
|
|
93
108
|
throw new errors_1.ConflictError('Skill was changed elsewhere; reload to get the latest version');
|
|
94
109
|
}
|
|
95
110
|
const updated = { ...existing, ...updates };
|
|
111
|
+
if (instructionEdits?.length) {
|
|
112
|
+
if (updates.instructions !== undefined) {
|
|
113
|
+
throw new n8n_workflow_1.UserError('Pass either instructions or instructionEdits, not both.');
|
|
114
|
+
}
|
|
115
|
+
updated.instructions = (0, skill_instruction_edits_1.applySkillInstructionEdits)(existing.instructions, instructionEdits);
|
|
116
|
+
}
|
|
96
117
|
if ('allowedTools' in updates && !updates.allowedTools?.length)
|
|
97
118
|
delete updated.allowedTools;
|
|
98
119
|
if ('references' in updates && !updates.references?.length)
|
|
@@ -107,12 +128,13 @@ let AgentSkillsService = class AgentSkillsService {
|
|
|
107
128
|
versionId: entity.versionId,
|
|
108
129
|
};
|
|
109
130
|
}
|
|
110
|
-
const
|
|
131
|
+
const skillRefs = await this.agentSkillRefs.refsForDraft(entity, {});
|
|
132
|
+
const previous = (0, agent_modification_telemetry_service_1.captureAgentMutation)(entity, skillRefs);
|
|
111
133
|
entity.skills = {
|
|
112
134
|
...(entity.skills ?? {}),
|
|
113
135
|
[skillId]: updated,
|
|
114
136
|
};
|
|
115
|
-
const saved = await this.saveSkillChanges(entity, projectId, context, previous);
|
|
137
|
+
const saved = await this.saveSkillChanges(entity, projectId, context, previous, skillRefs);
|
|
116
138
|
this.logger.debug('Updated agent skill', { agentId, projectId, skillId });
|
|
117
139
|
return {
|
|
118
140
|
id: skillId,
|
|
@@ -126,13 +148,13 @@ let AgentSkillsService = class AgentSkillsService {
|
|
|
126
148
|
const skills = { ...(entity.skills ?? {}) };
|
|
127
149
|
if (!skills[skillId])
|
|
128
150
|
throw new errors_1.NotFoundError('Skill not found');
|
|
129
|
-
const
|
|
151
|
+
const previousSkillRefs = await this.agentSkillRefs.refsForDraft(entity, {});
|
|
152
|
+
const previous = (0, agent_modification_telemetry_service_1.captureAgentMutation)(entity, previousSkillRefs);
|
|
130
153
|
delete skills[skillId];
|
|
131
154
|
entity.skills = skills;
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
await this.saveSkillChanges(entity, projectId, context, previous);
|
|
155
|
+
await this.saveSkillChanges(entity, projectId, context, previous, previousSkillRefs, previousSkillRefs
|
|
156
|
+
? { refs: previousSkillRefs.filter((ref) => ref.id !== skillId) }
|
|
157
|
+
: undefined);
|
|
136
158
|
this.logger.debug('Deleted agent skill', { agentId, projectId, skillId });
|
|
137
159
|
}
|
|
138
160
|
removeUnreferencedSkills(entity, config) {
|
|
@@ -181,30 +203,31 @@ let AgentSkillsService = class AgentSkillsService {
|
|
|
181
203
|
seenNames.add(normalizedName);
|
|
182
204
|
}
|
|
183
205
|
}
|
|
184
|
-
attachSkillRef(
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
entity.schema.skills = [
|
|
188
|
-
...(entity.schema.skills ?? []).filter((ref) => ref.id !== skillId),
|
|
206
|
+
attachSkillRef(skillRefs, skillId) {
|
|
207
|
+
return [
|
|
208
|
+
...(skillRefs ?? []).filter((ref) => ref.id !== skillId),
|
|
189
209
|
{ type: 'skill', id: skillId },
|
|
190
210
|
];
|
|
191
211
|
}
|
|
192
|
-
async
|
|
193
|
-
const { AgentRuntimeCacheService } = await import('./agent-runtime-cache.service.js');
|
|
194
|
-
di_1.Container.get(AgentRuntimeCacheService).clearRuntimes(agentId);
|
|
195
|
-
}
|
|
196
|
-
async saveSkillChanges(entity, projectId, context, previous) {
|
|
212
|
+
async saveSkillChanges(entity, projectId, context, previous, currentSkillRefs, nextSkillRefs) {
|
|
197
213
|
(0, agent_draft_utils_1.markAgentDraftDirty)(entity);
|
|
198
|
-
const saved = await (
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
214
|
+
const saved = await this.transactionRunner.run({}, async (ctx) => {
|
|
215
|
+
await (0, agent_draft_utils_1.saveAgentDraftFenced)(this.agentRepository, entity, ctx);
|
|
216
|
+
if (nextSkillRefs) {
|
|
217
|
+
await this.agentSkillRefs.replaceDraftRefs(entity, nextSkillRefs.refs, ctx);
|
|
218
|
+
}
|
|
219
|
+
return entity;
|
|
220
|
+
});
|
|
221
|
+
const savedSkillRefs = nextSkillRefs ? nextSkillRefs.refs : currentSkillRefs;
|
|
222
|
+
await this.saveCompletion.bodySaved((0, agent_modification_telemetry_service_1.buildAgentMutationEvent)(saved, savedSkillRefs, projectId, context, previous, {
|
|
223
|
+
skills: true,
|
|
224
|
+
}), context.pushRef);
|
|
202
225
|
return saved;
|
|
203
226
|
}
|
|
204
227
|
};
|
|
205
228
|
exports.AgentSkillsService = AgentSkillsService;
|
|
206
229
|
exports.AgentSkillsService = AgentSkillsService = __decorate([
|
|
207
230
|
(0, di_1.Service)(),
|
|
208
|
-
__metadata("design:paramtypes", [backend_common_1.Logger, agent_repository_1.AgentRepository,
|
|
231
|
+
__metadata("design:paramtypes", [backend_common_1.Logger, agent_repository_1.AgentRepository, agent_save_completion_service_1.AgentSaveCompletionService, agent_skill_refs_service_1.AgentSkillRefsService, db_1.TransactionRunner])
|
|
209
232
|
], AgentSkillsService);
|
|
210
233
|
//# sourceMappingURL=agent-skills.service.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"agent-skills.service.js","sourceRoot":"","sources":["../../../src/modules/agents/agent-skills.service.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"agent-skills.service.js","sourceRoot":"","sources":["../../../src/modules/agents/agent-skills.service.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA,8CAMwB;AACxB,wDAA6C;AAC7C,gCAA4C;AAC5C,gCAAkC;AAClC,6DAAqC;AACrC,+CAAyC;AAEzC,wCAA2D;AAE3D,iGAKgD;AAChD,mFAA6E;AAC7E,yEAAmE;AACnE,iEAAsF;AAEtF,sEAAkE;AAClE,mEAA6D;AAC7D,iEAAkF;AAClF,qFAA2E;AAE3E,iEAAoE;AACpE,6EAGyC;AAGlC,IAAM,kBAAkB,GAAxB,MAAM,kBAAkB;IAC9B,YACkB,MAAc,EACd,eAAgC,EAChC,cAA0C,EAC1C,cAAqC,EACrC,iBAAoC;sBAJpC,MAAM;+BACN,eAAe;8BACf,cAAc;8BACd,cAAc;iCACd,iBAAiB;IAChC,CAAC;IAEJ,KAAK,CAAC,UAAU,CAAC,OAAe,EAAE,SAAiB;QAClD,MAAM,MAAM,GAAG,MAAM,IAAA,oCAAe,EACnC,IAAI,CAAC,eAAe,EACpB,OAAO,EACP,SAAS,EACT,iBAAiB,CACjB,CAAC;QAEF,OAAO,MAAM,CAAC,MAAM,IAAI,EAAE,CAAC;IAC5B,CAAC;IAED,KAAK,CAAC,QAAQ,CAAC,OAAe,EAAE,SAAiB,EAAE,OAAe;QACjE,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,UAAU,CAAC,OAAO,EAAE,SAAS,CAAC,CAAC;QACzD,MAAM,KAAK,GAAG,MAAM,CAAC,OAAO,CAAC,CAAC;QAC9B,IAAI,CAAC,KAAK;YAAE,MAAM,IAAI,sBAAa,CAAC,iBAAiB,CAAC,CAAC;QAEvD,OAAO,KAAK,CAAC;IACd,CAAC;IAED,KAAK,CAAC,WAAW,CAChB,OAAe,EACf,SAAiB,EACjB,KAAiB,EACjB,OAAsC;QAEtC,MAAM,EAAE,OAAO,EAAE,GAAG,MAAM,IAAI,CAAC,iBAAiB,CAAC,OAAO,EAAE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EAAE,EAAE,OAAO,EAAE;SAC9B,CAAC;IACH,CAAC;IAMO,KAAK,CAAC,gBAAgB,CAC7B,MAAa,EACb,SAAiB,EACjB,OAAsC,EACtC,QAA+B,EAC/B,gBAAgC,EAChC,aAAwC;QAExC,IAAA,uCAAmB,EAAC,MAAM,CAAC,CAAC;QAC5B,MAAM,KAAK,GAAG,MAAM,IAAI,CAAC,iBAAiB,CAAC,GAAG,CAAC,EAAE,EAAE,KAAK,EAAE,GAAG,EAAE,EAAE;YAChE,MAAM,IAAA,wCAAoB,EAAC,IAAI,CAAC,eAAe,EAAE,MAAM,EAAE,GAAG,CAAC,CAAC;YAC9D,IAAI,aAAa,EAAE,CAAC;gBACnB,MAAM,IAAI,CAAC,cAAc,CAAC,gBAAgB,CAAC,MAAM,EAAE,aAAa,CAAC,IAAI,EAAE,GAAG,CAAC,CAAC;YAC7E,CAAC;YACD,OAAO,MAAM,CAAC;QACf,CAAC,CAAC,CAAC;QACH,MAAM,cAAc,GAAG,aAAa,CAAC,CAAC,CAAC,aAAa,CAAC,IAAI,CAAC,CAAC,CAAC,gBAAgB,CAAC;QAC7E,MAAM,IAAI,CAAC,cAAc,CAAC,SAAS,CAClC,IAAA,8DAAuB,EAAC,KAAK,EAAE,cAAc,EAAE,SAAS,EAAE,OAAO,EAAE,QAAQ,EAAE;YAC5E,MAAM,EAAE,IAAI;SACZ,CAAC,EACF,OAAO,CAAC,OAAO,CACf,CAAC;QACF,OAAO,KAAK,CAAC;IACd,CAAC;CACD,CAAA;;6BArVY,kBAAkB;IAD9B,IAAA,YAAO,GAAE;qCAGiB,uBAAM,EACG,kCAAe,EAChB,0DAA0B,EAC1B,gDAAqB,EAClB,sBAAiB;GAN1C,kBAAkB,CAqV9B"}
|
|
@@ -10,4 +10,5 @@ export declare function initSseStream(res: FlushableResponse): {
|
|
|
10
10
|
abortSignal: AbortSignal;
|
|
11
11
|
close: () => void;
|
|
12
12
|
};
|
|
13
|
+
export declare function toChatErrorEvent(error: unknown, fallbackMessage: string): AgentSseEvent;
|
|
13
14
|
export declare function emitChunkEvents(chunk: AgentExecutionStreamChunk, send: (event: AgentSseEvent) => void): void;
|
|
@@ -1,9 +1,12 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.initSseStream = initSseStream;
|
|
4
|
+
exports.toChatErrorEvent = toChatErrorEvent;
|
|
4
5
|
exports.emitChunkEvents = emitChunkEvents;
|
|
5
6
|
const scrub_secrets_1 = require("@n8n/utils/scrub-secrets");
|
|
6
7
|
const n8n_workflow_1 = require("n8n-workflow");
|
|
8
|
+
const agent_n8n_chat_unavailable_error_1 = require("./agent-n8n-chat-unavailable.error");
|
|
9
|
+
const agent_turn_already_running_error_1 = require("./agent-turn-already-running.error");
|
|
7
10
|
const SSE_HEARTBEAT_INTERVAL_MS = 30_000;
|
|
8
11
|
function initSseStream(res) {
|
|
9
12
|
res.setHeader('Content-Type', 'text/event-stream; charset=UTF-8');
|
|
@@ -62,6 +65,18 @@ function initSseStream(res) {
|
|
|
62
65
|
};
|
|
63
66
|
return { send, onChunk, abortSignal: abortController.signal, close };
|
|
64
67
|
}
|
|
68
|
+
function toChatErrorEvent(error, fallbackMessage) {
|
|
69
|
+
let errorCode;
|
|
70
|
+
if (error instanceof agent_turn_already_running_error_1.AgentTurnAlreadyRunningError)
|
|
71
|
+
errorCode = 'turn_already_running';
|
|
72
|
+
if (error instanceof agent_n8n_chat_unavailable_error_1.AgentN8nChatUnavailableError)
|
|
73
|
+
errorCode = 'agent_unavailable';
|
|
74
|
+
return {
|
|
75
|
+
type: 'error',
|
|
76
|
+
message: (0, scrub_secrets_1.scrubSecretsInText)(error instanceof Error ? error.message : fallbackMessage),
|
|
77
|
+
...(errorCode && { errorCode }),
|
|
78
|
+
};
|
|
79
|
+
}
|
|
65
80
|
function toAgentSseMessage(message) {
|
|
66
81
|
if (!('content' in message) || !Array.isArray(message.content))
|
|
67
82
|
return undefined;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"agent-sse-stream.js","sourceRoot":"","sources":["../../../src/modules/agents/agent-sse-stream.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"agent-sse-stream.js","sourceRoot":"","sources":["../../../src/modules/agents/agent-sse-stream.ts"],"names":[],"mappings":";;;;;AAOA,4DAA8D;AAE9D,+CAA2C;AAE3C,yFAAkF;AAClF,yFAAkF;AAKlF,MAAM,yBAAyB,GAAG,MAAM,CAAC;AAGzC,uBAA8B,GAAsB;IACnD,GAAG,CAAC,SAAS,CAAC,cAAc,EAAE,kCAAkC,CAAC,CAAC;IAClE,GAAG,CAAC,SAAS,CAAC,eAAe,EAAE,wBAAwB,CAAC,CAAC;IACzD,GAAG,CAAC,SAAS,CAAC,YAAY,EAAE,YAAY,CAAC,CAAC;IAC1C,GAAG,CAAC,SAAS,CAAC,mBAAmB,EAAE,IAAI,CAAC,CAAC;IACzC,GAAG,CAAC,YAAY,EAAE,CAAC;IACnB,GAAG,CAAC,MAAM,EAAE,UAAU,CAAC,CAAC,CAAC,CAAC;IAC1B,GAAG,CAAC,MAAM,EAAE,UAAU,CAAC,IAAI,CAAC,CAAC;IAC7B,GAAG,CAAC,MAAM,EAAE,YAAY,CAAC,IAAI,CAAC,CAAC;IAC/B,MAAM,eAAe,GAAG,IAAI,eAAe,EAAE,CAAC;IAC9C,MAAM,MAAM,GAAG,GAAG,EAAE;QACnB,eAAe,CAAC,KAAK,EAAE,CAAC;QACxB,aAAa,CAAC,SAAS,CAAC,CAAC;IAC1B,CAAC,CAAC;IACF,MAAM,KAAK,GAAG,CAAC,IAAY,EAAE,EAAE;QAC9B,IAAI,eAAe,CAAC,MAAM,CAAC,OAAO;YAAE,OAAO;QAC3C,IAAI,GAAG,CAAC,aAAa,IAAI,GAAG,CAAC,SAAS;YAAE,OAAO,MAAM,EAAE,CAAC;QACxD,IAAI,CAAC;YACJ,GAAG,CAAC,KAAK,CAAC,IAAI,CAAC,CA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mBAAmB,CAAC,KAAc;IAC1C,MAAM,IAAI,GAAG,gBAAgB,CAAC,KAAK,CAAC,CAAC;IACrC,IAAI,CAAC,IAAI;QAAE,OAAO,SAAS,CAAC;IAC5B,IAAI,CAAC;QACJ,MAAM,MAAM,GAAG,IAAI,CAAC,KAAK,CAAC,IAAI,CAAuD,CAAC;QACtF,OAAO,MAAM,EAAE,KAAK,EAAE,OAAO,IAAI,MAAM,EAAE,OAAO,IAAI,SAAS,CAAC;IAC/D,CAAC;IAAC,MAAM,CAAC;QACR,OAAO,SAAS,CAAC;IAClB,CAAC;AACF,CAAC;AAED,SAAS,cAAc,CAAC,KAAc;IACrC,IAAI,CAAC;QACJ,MAAM,cAAc,GAAG,mBAAmB,CAAC,KAAK,CAAC,CAAC;QAClD,IAAI,cAAc;YAAE,OAAO,cAAc,CAAC;QAC1C,IAAI,KAAK,YAAY,KAAK,EAAE,CAAC;YAC5B,OAAO,KAAK,CAAC,OAAO,CAAC;QACtB,CAAC;QACD,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE,CAAC;YAC/B,OAAO,IAAI,CAAC,SAAS,CAAC,KAAK,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC;QACvC,CAAC;QACD,OAAO,UAAU,MAAM,CAAC,KAAK,CAAC,EAAE,CAAC;IAClC,CAAC;IAAC,MAAM,CAAC;QACR,0BAAW,CAAC,IAAI,CAAC,2CAA2C,CAAC,CAAC;IAC/D,CAAC;IACD,OAAO,eAAe,CAAC;AACxB,CAAC"}
|
|
@@ -1,13 +1,14 @@
|
|
|
1
1
|
import type { AgentTaskDto, CreateAgentTaskDto, UpdateAgentTaskDto } from '@n8n/api-types';
|
|
2
2
|
import { Logger } from '@n8n/backend-common';
|
|
3
3
|
import { GlobalConfig } from '@n8n/config';
|
|
4
|
-
import type
|
|
4
|
+
import { TransactionRunner, type User } from '@n8n/db';
|
|
5
5
|
import { InstanceSettings, ScheduledTaskManager } from 'n8n-core';
|
|
6
6
|
import type { PubSubCommandMap } from '../../scaling/pubsub/pubsub.event-map';
|
|
7
|
-
import {
|
|
7
|
+
import { type AgentMutationTelemetryContext } from './agent-modification-telemetry.service';
|
|
8
8
|
import { AgentExecutionOrchestratorService } from './agent-execution-orchestrator.service';
|
|
9
9
|
import { AgentChangePublisher } from './agent-change-publisher.service';
|
|
10
|
-
import {
|
|
10
|
+
import { AgentSaveCompletionService } from './agent-save-completion.service';
|
|
11
|
+
import { AgentSkillRefsService } from './agent-skill-refs.service';
|
|
11
12
|
import { AgentsSettingsService } from './agents-settings.service';
|
|
12
13
|
import { AgentTaskJobRegistrar } from './scheduling/agent-task-job-registrar';
|
|
13
14
|
import { AgentRepository } from './repositories/agent.repository';
|
|
@@ -25,14 +26,18 @@ export declare class AgentTaskService {
|
|
|
25
26
|
private readonly instanceSettings;
|
|
26
27
|
private readonly scheduledTaskManager;
|
|
27
28
|
private readonly changePublisher;
|
|
28
|
-
private readonly modificationTelemetry;
|
|
29
29
|
private readonly durableJobRegistrar;
|
|
30
|
-
private readonly
|
|
30
|
+
private readonly saveCompletion;
|
|
31
31
|
private readonly settingsService;
|
|
32
|
-
|
|
32
|
+
private readonly transactionRunner;
|
|
33
|
+
private readonly agentSkillRefs;
|
|
34
|
+
constructor(logger: Logger, globalConfig: GlobalConfig, taskRepository: AgentTaskRepository, taskSnapshotRepository: AgentTaskSnapshotRepository, taskRunLockRepository: AgentTaskRunLockRepository, agentRepository: AgentRepository, agentExecutionOrchestratorService: AgentExecutionOrchestratorService, instanceSettings: InstanceSettings, scheduledTaskManager: ScheduledTaskManager, changePublisher: AgentChangePublisher, durableJobRegistrar: AgentTaskJobRegistrar, saveCompletion: AgentSaveCompletionService, settingsService: AgentsSettingsService, transactionRunner: TransactionRunner, agentSkillRefs: AgentSkillRefsService);
|
|
33
35
|
list(agentId: string): Promise<AgentTaskDto[]>;
|
|
34
36
|
create(agentId: string, projectId: string, dto: CreateAgentTaskDto, context: AgentMutationTelemetryContext): Promise<AgentTaskDto>;
|
|
35
|
-
createTasks(agentId: string, projectId: string, dtos: CreateAgentTaskDto[], context: AgentMutationTelemetryContext): Promise<
|
|
37
|
+
createTasks(agentId: string, projectId: string, dtos: CreateAgentTaskDto[], context: AgentMutationTelemetryContext): Promise<{
|
|
38
|
+
tasks: AgentTaskDto[];
|
|
39
|
+
configHash: string | null;
|
|
40
|
+
}>;
|
|
36
41
|
private createTasksBatch;
|
|
37
42
|
update(agentId: string, projectId: string, taskId: string, dto: UpdateAgentTaskDto, context: AgentMutationTelemetryContext): Promise<AgentTaskDto>;
|
|
38
43
|
updateWithChange(agentId: string, projectId: string, taskId: string, dto: UpdateAgentTaskDto, context: AgentMutationTelemetryContext): Promise<{
|
|
@@ -13,6 +13,7 @@ exports.AgentTaskService = void 0;
|
|
|
13
13
|
const api_types_1 = require("@n8n/api-types");
|
|
14
14
|
const backend_common_1 = require("@n8n/backend-common");
|
|
15
15
|
const config_1 = require("@n8n/config");
|
|
16
|
+
const db_1 = require("@n8n/db");
|
|
16
17
|
const decorators_1 = require("@n8n/decorators");
|
|
17
18
|
const di_1 = require("@n8n/di");
|
|
18
19
|
const typeorm_1 = require("@n8n/typeorm");
|
|
@@ -23,13 +24,16 @@ const errors_1 = require("@n8n/errors");
|
|
|
23
24
|
const agent_modification_telemetry_service_1 = require("./agent-modification-telemetry.service");
|
|
24
25
|
const agent_execution_orchestrator_service_1 = require("./agent-execution-orchestrator.service");
|
|
25
26
|
const agent_change_publisher_service_1 = require("./agent-change-publisher.service");
|
|
26
|
-
const
|
|
27
|
+
const agent_save_completion_service_1 = require("./agent-save-completion.service");
|
|
28
|
+
const agent_skill_refs_service_1 = require("./agent-skill-refs.service");
|
|
27
29
|
const agents_settings_service_1 = require("./agents-settings.service");
|
|
28
30
|
const agent_task_job_registrar_1 = require("./scheduling/agent-task-job-registrar");
|
|
29
31
|
const task_timezone_1 = require("./scheduling/task-timezone");
|
|
30
32
|
const cron_validation_1 = require("./integrations/cron-validation");
|
|
31
33
|
const agent_repository_1 = require("./repositories/agent.repository");
|
|
32
34
|
const get_agent_or_throw_1 = require("./utils/get-agent-or-throw");
|
|
35
|
+
const agent_config_hash_1 = require("./utils/agent-config-hash");
|
|
36
|
+
const agent_config_composition_1 = require("./json-config/agent-config-composition");
|
|
33
37
|
const agent_task_run_lock_repository_1 = require("./repositories/agent-task-run-lock.repository");
|
|
34
38
|
const agent_task_snapshot_repository_1 = require("./repositories/agent-task-snapshot.repository");
|
|
35
39
|
const agent_task_repository_1 = require("./repositories/agent-task.repository");
|
|
@@ -44,7 +48,7 @@ const agentTaskScheduleGroup = (agentId) => ({
|
|
|
44
48
|
id: agentId,
|
|
45
49
|
});
|
|
46
50
|
let AgentTaskService = class AgentTaskService {
|
|
47
|
-
constructor(logger, globalConfig, taskRepository, taskSnapshotRepository, taskRunLockRepository, agentRepository, agentExecutionOrchestratorService, instanceSettings, scheduledTaskManager, changePublisher,
|
|
51
|
+
constructor(logger, globalConfig, taskRepository, taskSnapshotRepository, taskRunLockRepository, agentRepository, agentExecutionOrchestratorService, instanceSettings, scheduledTaskManager, changePublisher, durableJobRegistrar, saveCompletion, settingsService, transactionRunner, agentSkillRefs) {
|
|
48
52
|
this.logger = logger;
|
|
49
53
|
this.globalConfig = globalConfig;
|
|
50
54
|
this.taskRepository = taskRepository;
|
|
@@ -55,21 +59,23 @@ let AgentTaskService = class AgentTaskService {
|
|
|
55
59
|
this.instanceSettings = instanceSettings;
|
|
56
60
|
this.scheduledTaskManager = scheduledTaskManager;
|
|
57
61
|
this.changePublisher = changePublisher;
|
|
58
|
-
this.modificationTelemetry = modificationTelemetry;
|
|
59
62
|
this.durableJobRegistrar = durableJobRegistrar;
|
|
60
|
-
this.
|
|
63
|
+
this.saveCompletion = saveCompletion;
|
|
61
64
|
this.settingsService = settingsService;
|
|
65
|
+
this.transactionRunner = transactionRunner;
|
|
66
|
+
this.agentSkillRefs = agentSkillRefs;
|
|
62
67
|
}
|
|
63
68
|
async list(agentId) {
|
|
64
69
|
const tasks = await this.taskRepository.findByAgentId(agentId);
|
|
65
70
|
return tasks.map((task) => this.toDto(task));
|
|
66
71
|
}
|
|
67
72
|
async create(agentId, projectId, dto, context) {
|
|
68
|
-
const
|
|
69
|
-
return
|
|
73
|
+
const { tasks } = await this.createTasksBatch(agentId, projectId, [dto], context);
|
|
74
|
+
return tasks[0];
|
|
70
75
|
}
|
|
71
76
|
async createTasks(agentId, projectId, dtos, context) {
|
|
72
|
-
|
|
77
|
+
const { tasks, agent, skillRefs } = await this.createTasksBatch(agentId, projectId, dtos, context);
|
|
78
|
+
return { tasks, configHash: (0, agent_config_hash_1.getAgentConfigHash)((0, agent_config_composition_1.composeJsonConfig)(agent, skillRefs)) };
|
|
73
79
|
}
|
|
74
80
|
async createTasksBatch(agentId, projectId, dtos, context) {
|
|
75
81
|
if (dtos.length === 0) {
|
|
@@ -82,7 +88,8 @@ let AgentTaskService = class AgentTaskService {
|
|
|
82
88
|
const agent = await (0, get_agent_or_throw_1.getAgentOrThrow)(this.agentRepository, agentId, projectId);
|
|
83
89
|
if (!agent.schema)
|
|
84
90
|
throw new errors_1.BadRequestError('Agent has no config yet');
|
|
85
|
-
const
|
|
91
|
+
const skillRefs = await this.agentSkillRefs.refsForDraft(agent, {});
|
|
92
|
+
const previous = (0, agent_modification_telemetry_service_1.captureAgentMutation)(agent, skillRefs);
|
|
86
93
|
const tasks = dtos.map((dto) => {
|
|
87
94
|
const taskId = (0, agent_resource_id_1.generateAgentResourceId)('task', (agent.schema?.tasks ?? []).map((ref) => ref.id));
|
|
88
95
|
this.attachTaskRef(agent, taskId, dto.enabled ?? true);
|
|
@@ -96,55 +103,52 @@ let AgentTaskService = class AgentTaskService {
|
|
|
96
103
|
});
|
|
97
104
|
});
|
|
98
105
|
(0, agent_draft_utils_1.markAgentDraftDirty)(agent);
|
|
99
|
-
await this.
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
}
|
|
103
|
-
await (0, agent_draft_utils_1.saveAgentDraftFenced)(this.agentRepository, agent, em);
|
|
106
|
+
await this.transactionRunner.run({}, async (ctx) => {
|
|
107
|
+
await (0, agent_draft_utils_1.saveAgentDraftFenced)(this.agentRepository, agent, ctx);
|
|
108
|
+
await this.taskRepository.saveDefinitions(tasks, ctx);
|
|
104
109
|
});
|
|
105
|
-
this.
|
|
106
|
-
this.modificationTelemetry.record((0, agent_modification_telemetry_service_1.buildAgentMutationEvent)(agent, projectId, context, previous, { tasks: true }));
|
|
110
|
+
this.saveCompletion.taskSaved((0, agent_modification_telemetry_service_1.buildAgentMutationEvent)(agent, skillRefs, projectId, context, previous, { tasks: true }), context.pushRef);
|
|
107
111
|
this.logger.debug('[AgentTaskService] Created tasks', {
|
|
108
112
|
agentId,
|
|
109
113
|
taskIds: tasks.map((task) => task.id),
|
|
110
114
|
});
|
|
111
|
-
return tasks.map((task) => this.toDto(task));
|
|
115
|
+
return { tasks: tasks.map((task) => this.toDto(task)), agent, skillRefs };
|
|
112
116
|
}
|
|
113
117
|
async update(agentId, projectId, taskId, dto, context) {
|
|
114
118
|
const { task } = await this.updateWithChange(agentId, projectId, taskId, dto, context);
|
|
115
119
|
return task;
|
|
116
120
|
}
|
|
117
121
|
async updateWithChange(agentId, projectId, taskId, dto, context) {
|
|
122
|
+
const agent = await (0, get_agent_or_throw_1.getAgentOrThrow)(this.agentRepository, agentId, projectId);
|
|
118
123
|
const task = await this.getOrThrow(agentId, taskId);
|
|
119
124
|
const changed = this.applyTaskUpdates(task, dto);
|
|
120
125
|
if (!changed)
|
|
121
126
|
return { task: this.toDto(task), changed: false };
|
|
122
|
-
const
|
|
123
|
-
const previous = (0, agent_modification_telemetry_service_1.captureAgentMutation)(agent);
|
|
124
|
-
const saved = await this.
|
|
125
|
-
const savedTask = await em.save(task);
|
|
127
|
+
const skillRefs = await this.agentSkillRefs.refsForDraft(agent, {});
|
|
128
|
+
const previous = (0, agent_modification_telemetry_service_1.captureAgentMutation)(agent, skillRefs);
|
|
129
|
+
const saved = await this.transactionRunner.run({}, async (ctx) => {
|
|
126
130
|
(0, agent_draft_utils_1.markAgentDraftDirty)(agent);
|
|
127
|
-
await (0, agent_draft_utils_1.saveAgentDraftFenced)(this.agentRepository, agent,
|
|
131
|
+
await (0, agent_draft_utils_1.saveAgentDraftFenced)(this.agentRepository, agent, ctx);
|
|
132
|
+
const [savedTask] = await this.taskRepository.saveDefinitions([task], ctx);
|
|
128
133
|
return savedTask;
|
|
129
134
|
});
|
|
130
|
-
this.
|
|
131
|
-
this.modificationTelemetry.record((0, agent_modification_telemetry_service_1.buildAgentMutationEvent)(agent, projectId, context, previous, { tasks: true }));
|
|
135
|
+
this.saveCompletion.taskSaved((0, agent_modification_telemetry_service_1.buildAgentMutationEvent)(agent, skillRefs, projectId, context, previous, { tasks: true }), context.pushRef);
|
|
132
136
|
return { task: this.toDto(saved), changed: true };
|
|
133
137
|
}
|
|
134
138
|
async delete(agentId, projectId, taskId, context) {
|
|
135
|
-
|
|
139
|
+
await this.getOrThrow(agentId, taskId);
|
|
136
140
|
const agent = await (0, get_agent_or_throw_1.getAgentOrThrow)(this.agentRepository, agentId, projectId);
|
|
137
|
-
const
|
|
141
|
+
const skillRefs = await this.agentSkillRefs.refsForDraft(agent, {});
|
|
142
|
+
const previous = (0, agent_modification_telemetry_service_1.captureAgentMutation)(agent, skillRefs);
|
|
138
143
|
if (agent.schema?.tasks) {
|
|
139
144
|
agent.schema.tasks = agent.schema.tasks.filter((ref) => ref.id !== taskId);
|
|
140
145
|
(0, agent_draft_utils_1.markAgentDraftDirty)(agent);
|
|
141
146
|
}
|
|
142
|
-
await this.
|
|
143
|
-
await
|
|
144
|
-
await
|
|
147
|
+
await this.transactionRunner.run({}, async (ctx) => {
|
|
148
|
+
await (0, agent_draft_utils_1.saveAgentDraftFenced)(this.agentRepository, agent, ctx);
|
|
149
|
+
await this.taskRepository.deleteForAgent(agentId, [taskId], ctx);
|
|
145
150
|
});
|
|
146
|
-
this.
|
|
147
|
-
this.modificationTelemetry.record((0, agent_modification_telemetry_service_1.buildAgentMutationEvent)(agent, projectId, context, previous, { tasks: true }));
|
|
151
|
+
this.saveCompletion.taskSaved((0, agent_modification_telemetry_service_1.buildAgentMutationEvent)(agent, skillRefs, projectId, context, previous, { tasks: true }), context.pushRef);
|
|
148
152
|
this.logger.debug('[AgentTaskService] Deleted task', { agentId, taskId });
|
|
149
153
|
}
|
|
150
154
|
attachTaskRef(agent, taskId, enabled) {
|
|
@@ -504,6 +508,6 @@ __decorate([
|
|
|
504
508
|
], AgentTaskService.prototype, "stopAll", null);
|
|
505
509
|
exports.AgentTaskService = AgentTaskService = __decorate([
|
|
506
510
|
(0, di_1.Service)(),
|
|
507
|
-
__metadata("design:paramtypes", [backend_common_1.Logger, config_1.GlobalConfig, agent_task_repository_1.AgentTaskRepository, agent_task_snapshot_repository_1.AgentTaskSnapshotRepository, agent_task_run_lock_repository_1.AgentTaskRunLockRepository, agent_repository_1.AgentRepository, agent_execution_orchestrator_service_1.AgentExecutionOrchestratorService, n8n_core_1.InstanceSettings, n8n_core_1.ScheduledTaskManager, agent_change_publisher_service_1.AgentChangePublisher,
|
|
511
|
+
__metadata("design:paramtypes", [backend_common_1.Logger, config_1.GlobalConfig, agent_task_repository_1.AgentTaskRepository, agent_task_snapshot_repository_1.AgentTaskSnapshotRepository, agent_task_run_lock_repository_1.AgentTaskRunLockRepository, agent_repository_1.AgentRepository, agent_execution_orchestrator_service_1.AgentExecutionOrchestratorService, n8n_core_1.InstanceSettings, n8n_core_1.ScheduledTaskManager, agent_change_publisher_service_1.AgentChangePublisher, agent_task_job_registrar_1.AgentTaskJobRegistrar, agent_save_completion_service_1.AgentSaveCompletionService, agents_settings_service_1.AgentsSettingsService, db_1.TransactionRunner, agent_skill_refs_service_1.AgentSkillRefsService])
|
|
508
512
|
], AgentTaskService);
|
|
509
513
|
//# sourceMappingURL=agent-task.service.js.map
|