@erxes/api-shared 0.0.0-stage → 3.2.19-1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE.md +672 -0
- package/core-modules/dist/erxes-api-shared-core-modules.cjs.d.ts +2 -0
- package/core-modules/dist/erxes-api-shared-core-modules.cjs.dev.js +6685 -0
- package/core-modules/dist/erxes-api-shared-core-modules.cjs.js +7 -0
- package/core-modules/dist/erxes-api-shared-core-modules.cjs.prod.js +6685 -0
- package/core-modules/dist/erxes-api-shared-core-modules.esm.js +6298 -0
- package/core-modules/package.json +5 -0
- package/core-types/dist/erxes-api-shared-core-types.cjs.d.ts +2 -0
- package/core-types/dist/erxes-api-shared-core-types.cjs.dev.js +12 -0
- package/core-types/dist/erxes-api-shared-core-types.cjs.js +7 -0
- package/core-types/dist/erxes-api-shared-core-types.cjs.prod.js +12 -0
- package/core-types/dist/erxes-api-shared-core-types.esm.js +8 -0
- package/core-types/package.json +5 -0
- package/dist/declarations/src/core-modules/approval/approvalChangeTypes.d.ts +15 -0
- package/dist/declarations/src/core-modules/approval/approvalChangeTypes.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/approval/checkApprovalLock.d.ts +7 -0
- package/dist/declarations/src/core-modules/approval/checkApprovalLock.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/approval/constants.d.ts +37 -0
- package/dist/declarations/src/core-modules/approval/constants.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/approval/index.d.ts +7 -0
- package/dist/declarations/src/core-modules/approval/index.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/approval/initApproval.d.ts +9 -0
- package/dist/declarations/src/core-modules/approval/initApproval.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/approval/types.d.ts +164 -0
- package/dist/declarations/src/core-modules/approval/types.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/approval/zodSchemas.d.ts +125 -0
- package/dist/declarations/src/core-modules/approval/zodSchemas.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/apps/@types/app.d.ts +15 -0
- package/dist/declarations/src/core-modules/apps/@types/app.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/apps/db/definitions/apps.d.ts +13 -0
- package/dist/declarations/src/core-modules/apps/db/definitions/apps.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/apps/index.d.ts +3 -0
- package/dist/declarations/src/core-modules/apps/index.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/automations/actionErrorPolicy.d.ts +68 -0
- package/dist/declarations/src/core-modules/automations/actionErrorPolicy.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/automations/actionOutcome.d.ts +51 -0
- package/dist/declarations/src/core-modules/automations/actionOutcome.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/automations/constants.d.ts +101 -0
- package/dist/declarations/src/core-modules/automations/constants.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/automations/definitions/aiAgents.d.ts +141 -0
- package/dist/declarations/src/core-modules/automations/definitions/aiAgents.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/automations/definitions/automations.d.ts +868 -0
- package/dist/declarations/src/core-modules/automations/definitions/automations.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/automations/definitions/executions.d.ts +316 -0
- package/dist/declarations/src/core-modules/automations/definitions/executions.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/automations/definitions/index.d.ts +4 -0
- package/dist/declarations/src/core-modules/automations/definitions/index.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/automations/index.d.ts +14 -0
- package/dist/declarations/src/core-modules/automations/index.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/automations/outputResolvers.d.ts +67 -0
- package/dist/declarations/src/core-modules/automations/outputResolvers.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/automations/reEnrollment.d.ts +23 -0
- package/dist/declarations/src/core-modules/automations/reEnrollment.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/automations/segmentMembership.d.ts +19 -0
- package/dist/declarations/src/core-modules/automations/segmentMembership.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/automations/sendAutomationMessage.d.ts +51 -0
- package/dist/declarations/src/core-modules/automations/sendAutomationMessage.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/automations/setupAutomationProducers.d.ts +4 -0
- package/dist/declarations/src/core-modules/automations/setupAutomationProducers.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/automations/typeUtils.d.ts +2 -0
- package/dist/declarations/src/core-modules/automations/typeUtils.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/automations/types.d.ts +474 -0
- package/dist/declarations/src/core-modules/automations/types.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/automations/utils.d.ts +38 -0
- package/dist/declarations/src/core-modules/automations/utils.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/automations/workflowValidation.d.ts +3 -0
- package/dist/declarations/src/core-modules/automations/workflowValidation.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/automations/zodTypes.d.ts +2366 -0
- package/dist/declarations/src/core-modules/automations/zodTypes.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/client-portals/definitions/clientPortal.d.ts +375 -0
- package/dist/declarations/src/core-modules/client-portals/definitions/clientPortal.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/client-portals/definitions/comment.d.ts +53 -0
- package/dist/declarations/src/core-modules/client-portals/definitions/comment.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/client-portals/definitions/cpNotification.d.ts +110 -0
- package/dist/declarations/src/core-modules/client-portals/definitions/cpNotification.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/client-portals/definitions/cpUser.d.ts +828 -0
- package/dist/declarations/src/core-modules/client-portals/definitions/cpUser.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/client-portals/index.d.ts +5 -0
- package/dist/declarations/src/core-modules/client-portals/index.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/common/db/definitions/common.d.ts +77 -0
- package/dist/declarations/src/core-modules/common/db/definitions/common.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/common/eventHandlers/createEventHandlers.d.ts +8 -0
- package/dist/declarations/src/core-modules/common/eventHandlers/createEventHandlers.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/common/eventHandlers/generateEventHandlers.d.ts +4 -0
- package/dist/declarations/src/core-modules/common/eventHandlers/generateEventHandlers.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/common/eventHandlers/index.d.ts +5 -0
- package/dist/declarations/src/core-modules/common/eventHandlers/index.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/common/eventHandlers/runtimeContext.d.ts +9 -0
- package/dist/declarations/src/core-modules/common/eventHandlers/runtimeContext.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/common/eventHandlers/schemas.d.ts +82 -0
- package/dist/declarations/src/core-modules/common/eventHandlers/schemas.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/common/eventHandlers/types.d.ts +87 -0
- package/dist/declarations/src/core-modules/common/eventHandlers/types.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/common/index.d.ts +5 -0
- package/dist/declarations/src/core-modules/common/index.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/common/references/getRecordReferenceFields.d.ts +57 -0
- package/dist/declarations/src/core-modules/common/references/getRecordReferenceFields.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/common/references/index.d.ts +6 -0
- package/dist/declarations/src/core-modules/common/references/index.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/common/references/initRecordReferences.d.ts +4 -0
- package/dist/declarations/src/core-modules/common/references/initRecordReferences.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/common/references/resolveRecordReferencePlaceholders.d.ts +12 -0
- package/dist/declarations/src/core-modules/common/references/resolveRecordReferencePlaceholders.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/common/references/resolveRecordReferenceValue.d.ts +6 -0
- package/dist/declarations/src/core-modules/common/references/resolveRecordReferenceValue.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/common/references/types.d.ts +63 -0
- package/dist/declarations/src/core-modules/common/references/types.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/common/routeToModuleProducer.d.ts +55 -0
- package/dist/declarations/src/core-modules/common/routeToModuleProducer.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/email-content/blocksToHtml.d.ts +72 -0
- package/dist/declarations/src/core-modules/email-content/blocksToHtml.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/email-content/constants.d.ts +5 -0
- package/dist/declarations/src/core-modules/email-content/constants.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/email-content/emailFooter.d.ts +5 -0
- package/dist/declarations/src/core-modules/email-content/emailFooter.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/email-content/expandRepeatRows.d.ts +9 -0
- package/dist/declarations/src/core-modules/email-content/expandRepeatRows.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/email-content/index.d.ts +9 -0
- package/dist/declarations/src/core-modules/email-content/index.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/email-content/renderEmailContent.d.ts +19 -0
- package/dist/declarations/src/core-modules/email-content/renderEmailContent.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/email-content/replacePlaceholders.d.ts +36 -0
- package/dist/declarations/src/core-modules/email-content/replacePlaceholders.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/email-content/types.d.ts +48 -0
- package/dist/declarations/src/core-modules/email-content/types.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/email-content/unresolvedPlaceholders.d.ts +4 -0
- package/dist/declarations/src/core-modules/email-content/unresolvedPlaceholders.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/forms/index.d.ts +3 -0
- package/dist/declarations/src/core-modules/forms/index.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/forms/types.d.ts +55 -0
- package/dist/declarations/src/core-modules/forms/types.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/forms/utils.d.ts +4 -0
- package/dist/declarations/src/core-modules/forms/utils.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/import-export/index.d.ts +8 -0
- package/dist/declarations/src/core-modules/import-export/index.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/import-export/types.d.ts +181 -0
- package/dist/declarations/src/core-modules/import-export/types.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/import-export/utils/exportCursor.d.ts +14 -0
- package/dist/declarations/src/core-modules/import-export/utils/exportCursor.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/import-export/utils/headerMatcher.d.ts +32 -0
- package/dist/declarations/src/core-modules/import-export/utils/headerMatcher.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/import-export/utils/importExportRuntime.d.ts +32 -0
- package/dist/declarations/src/core-modules/import-export/utils/importExportRuntime.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/import-export/utils/importUtils.d.ts +25 -0
- package/dist/declarations/src/core-modules/import-export/utils/importUtils.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/import-export/worker.d.ts +8 -0
- package/dist/declarations/src/core-modules/import-export/worker.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/import-export/zodSchemas.d.ts +111 -0
- package/dist/declarations/src/core-modules/import-export/zodSchemas.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/index.d.ts +16 -0
- package/dist/declarations/src/core-modules/index.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/logs/activityLog/builder.d.ts +3 -0
- package/dist/declarations/src/core-modules/logs/activityLog/builder.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/logs/activityLog/index.d.ts +5 -0
- package/dist/declarations/src/core-modules/logs/activityLog/index.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/logs/activityLog/sharedBuilders.d.ts +18 -0
- package/dist/declarations/src/core-modules/logs/activityLog/sharedBuilders.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/logs/activityLog/types.d.ts +21 -0
- package/dist/declarations/src/core-modules/logs/activityLog/types.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/logs/activityLog/utils.d.ts +10 -0
- package/dist/declarations/src/core-modules/logs/activityLog/utils.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/logs/activityLogUtils.d.ts +72 -0
- package/dist/declarations/src/core-modules/logs/activityLogUtils.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/logs/definitions/activityLog.d.ts +84 -0
- package/dist/declarations/src/core-modules/logs/definitions/activityLog.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/logs/definitions/logs.d.ts +39 -0
- package/dist/declarations/src/core-modules/logs/definitions/logs.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/logs/index.d.ts +6 -0
- package/dist/declarations/src/core-modules/logs/index.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/logs/types.d.ts +15 -0
- package/dist/declarations/src/core-modules/logs/types.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/notifications/definitions/emailAddresses.d.ts +73 -0
- package/dist/declarations/src/core-modules/notifications/definitions/emailAddresses.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/notifications/definitions/emailDeliveries.d.ts +115 -0
- package/dist/declarations/src/core-modules/notifications/definitions/emailDeliveries.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/notifications/definitions/emailRamp.d.ts +65 -0
- package/dist/declarations/src/core-modules/notifications/definitions/emailRamp.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/notifications/definitions/emailSenders.d.ts +58 -0
- package/dist/declarations/src/core-modules/notifications/definitions/emailSenders.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/notifications/definitions/notificationSettings.d.ts +66 -0
- package/dist/declarations/src/core-modules/notifications/definitions/notificationSettings.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/notifications/definitions/notifications.d.ts +89 -0
- package/dist/declarations/src/core-modules/notifications/definitions/notifications.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/notifications/index.d.ts +8 -0
- package/dist/declarations/src/core-modules/notifications/index.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/notifications/utils.d.ts +85 -0
- package/dist/declarations/src/core-modules/notifications/utils.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/permissions/db/definitions/permissions.d.ts +60 -0
- package/dist/declarations/src/core-modules/permissions/db/definitions/permissions.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/permissions/index.d.ts +4 -0
- package/dist/declarations/src/core-modules/permissions/index.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/permissions/user-actions-map.d.ts +4 -0
- package/dist/declarations/src/core-modules/permissions/user-actions-map.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/permissions/utils.d.ts +22 -0
- package/dist/declarations/src/core-modules/permissions/utils.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/properties/filter.d.ts +5 -0
- package/dist/declarations/src/core-modules/properties/filter.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/properties/importExport.d.ts +18 -0
- package/dist/declarations/src/core-modules/properties/importExport.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/properties/index.d.ts +10 -0
- package/dist/declarations/src/core-modules/properties/index.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/properties/keys.d.ts +46 -0
- package/dist/declarations/src/core-modules/properties/keys.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/properties/mergeRows.d.ts +8 -0
- package/dist/declarations/src/core-modules/properties/mergeRows.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/properties/operators.d.ts +6 -0
- package/dist/declarations/src/core-modules/properties/operators.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/properties/options.d.ts +10 -0
- package/dist/declarations/src/core-modules/properties/options.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/properties/setupPropertyProducers.d.ts +4 -0
- package/dist/declarations/src/core-modules/properties/setupPropertyProducers.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/properties/types.d.ts +14 -0
- package/dist/declarations/src/core-modules/properties/types.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/properties/valueUsage.d.ts +56 -0
- package/dist/declarations/src/core-modules/properties/valueUsage.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/segments/dependencies.d.ts +6 -0
- package/dist/declarations/src/core-modules/segments/dependencies.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/segments/evaluate.d.ts +11 -0
- package/dist/declarations/src/core-modules/segments/evaluate.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/segments/evaluateBatch.d.ts +42 -0
- package/dist/declarations/src/core-modules/segments/evaluateBatch.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/segments/evaluateFieldsRouter.d.ts +29 -0
- package/dist/declarations/src/core-modules/segments/evaluateFieldsRouter.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/segments/evaluateOwned.d.ts +27 -0
- package/dist/declarations/src/core-modules/segments/evaluateOwned.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/segments/events.d.ts +45 -0
- package/dist/declarations/src/core-modules/segments/events.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/segments/fieldBuilders.d.ts +35 -0
- package/dist/declarations/src/core-modules/segments/fieldBuilders.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/segments/fieldMeta.d.ts +62 -0
- package/dist/declarations/src/core-modules/segments/fieldMeta.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/segments/fieldRequests.d.ts +33 -0
- package/dist/declarations/src/core-modules/segments/fieldRequests.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/segments/fingerprint.d.ts +6 -0
- package/dist/declarations/src/core-modules/segments/fingerprint.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/segments/index.d.ts +31 -0
- package/dist/declarations/src/core-modules/segments/index.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/segments/joinChanges.d.ts +11 -0
- package/dist/declarations/src/core-modules/segments/joinChanges.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/segments/materialized.d.ts +9 -0
- package/dist/declarations/src/core-modules/segments/materialized.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/segments/measureRelations.d.ts +18 -0
- package/dist/declarations/src/core-modules/segments/measureRelations.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/segments/memberQuery.d.ts +13 -0
- package/dist/declarations/src/core-modules/segments/memberQuery.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/segments/membership.d.ts +24 -0
- package/dist/declarations/src/core-modules/segments/membership.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/segments/mongoFilter.d.ts +15 -0
- package/dist/declarations/src/core-modules/segments/mongoFilter.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/segments/nodeRefs.d.ts +5 -0
- package/dist/declarations/src/core-modules/segments/nodeRefs.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/segments/nodes.d.ts +42 -0
- package/dist/declarations/src/core-modules/segments/nodes.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/segments/operators.d.ts +46 -0
- package/dist/declarations/src/core-modules/segments/operators.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/segments/ownedSource.d.ts +7 -0
- package/dist/declarations/src/core-modules/segments/ownedSource.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/segments/plan.d.ts +35 -0
- package/dist/declarations/src/core-modules/segments/plan.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/segments/relationRegistry.d.ts +33 -0
- package/dist/declarations/src/core-modules/segments/relationRegistry.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/segments/setupSegmentProducers.d.ts +4 -0
- package/dist/declarations/src/core-modules/segments/setupSegmentProducers.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/segments/subjectsReachedBy.d.ts +11 -0
- package/dist/declarations/src/core-modules/segments/subjectsReachedBy.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/segments/timeZone.d.ts +2 -0
- package/dist/declarations/src/core-modules/segments/timeZone.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/segments/types.d.ts +67 -0
- package/dist/declarations/src/core-modules/segments/types.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/segments/utils.d.ts +4 -0
- package/dist/declarations/src/core-modules/segments/utils.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/segments/walkNodes.d.ts +9 -0
- package/dist/declarations/src/core-modules/segments/walkNodes.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/segments/zodSchemas.d.ts +532 -0
- package/dist/declarations/src/core-modules/segments/zodSchemas.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/segments/zonedTime.d.ts +25 -0
- package/dist/declarations/src/core-modules/segments/zonedTime.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/templates/index.d.ts +2 -0
- package/dist/declarations/src/core-modules/templates/index.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/templates/utils.d.ts +11 -0
- package/dist/declarations/src/core-modules/templates/utils.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/users/constants.d.ts +114 -0
- package/dist/declarations/src/core-modules/users/constants.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/users/db/definitions/users.d.ts +24 -0
- package/dist/declarations/src/core-modules/users/db/definitions/users.d.ts.map +1 -0
- package/dist/declarations/src/core-modules/users/index.d.ts +3 -0
- package/dist/declarations/src/core-modules/users/index.d.ts.map +1 -0
- package/dist/declarations/src/core-types/common.d.ts +149 -0
- package/dist/declarations/src/core-types/common.d.ts.map +1 -0
- package/dist/declarations/src/core-types/index.d.ts +20 -0
- package/dist/declarations/src/core-types/index.d.ts.map +1 -0
- package/dist/declarations/src/core-types/modules/app/app.d.ts +12 -0
- package/dist/declarations/src/core-types/modules/app/app.d.ts.map +1 -0
- package/dist/declarations/src/core-types/modules/automations/automations.d.ts +19 -0
- package/dist/declarations/src/core-types/modules/automations/automations.d.ts.map +1 -0
- package/dist/declarations/src/core-types/modules/contacts/company.d.ts +53 -0
- package/dist/declarations/src/core-types/modules/contacts/company.d.ts.map +1 -0
- package/dist/declarations/src/core-types/modules/contacts/contacts-common.d.ts +32 -0
- package/dist/declarations/src/core-types/modules/contacts/contacts-common.d.ts.map +1 -0
- package/dist/declarations/src/core-types/modules/contacts/customer.d.ts +74 -0
- package/dist/declarations/src/core-types/modules/contacts/customer.d.ts.map +1 -0
- package/dist/declarations/src/core-types/modules/emailTemplates/emailTemplate.d.ts +18 -0
- package/dist/declarations/src/core-types/modules/emailTemplates/emailTemplate.d.ts.map +1 -0
- package/dist/declarations/src/core-types/modules/logs/logs.d.ts +28 -0
- package/dist/declarations/src/core-types/modules/logs/logs.d.ts.map +1 -0
- package/dist/declarations/src/core-types/modules/permissions/permission.d.ts +56 -0
- package/dist/declarations/src/core-types/modules/permissions/permission.d.ts.map +1 -0
- package/dist/declarations/src/core-types/modules/permissions/role.d.ts +21 -0
- package/dist/declarations/src/core-types/modules/permissions/role.d.ts.map +1 -0
- package/dist/declarations/src/core-types/modules/products/product.d.ts +76 -0
- package/dist/declarations/src/core-types/modules/products/product.d.ts.map +1 -0
- package/dist/declarations/src/core-types/modules/products/productCategory.d.ts +26 -0
- package/dist/declarations/src/core-types/modules/products/productCategory.d.ts.map +1 -0
- package/dist/declarations/src/core-types/modules/products/productConfig.d.ts +9 -0
- package/dist/declarations/src/core-types/modules/products/productConfig.d.ts.map +1 -0
- package/dist/declarations/src/core-types/modules/products/uom.d.ts +11 -0
- package/dist/declarations/src/core-types/modules/products/uom.d.ts.map +1 -0
- package/dist/declarations/src/core-types/modules/relations/relations.d.ts +13 -0
- package/dist/declarations/src/core-types/modules/relations/relations.d.ts.map +1 -0
- package/dist/declarations/src/core-types/modules/saas/organization.d.ts +8 -0
- package/dist/declarations/src/core-types/modules/saas/organization.d.ts.map +1 -0
- package/dist/declarations/src/core-types/modules/tags/tag.d.ts +16 -0
- package/dist/declarations/src/core-types/modules/tags/tag.d.ts.map +1 -0
- package/dist/declarations/src/core-types/modules/team-member/structure.d.ts +19 -0
- package/dist/declarations/src/core-types/modules/team-member/structure.d.ts.map +1 -0
- package/dist/declarations/src/core-types/modules/team-member/user.d.ts +90 -0
- package/dist/declarations/src/core-types/modules/team-member/user.d.ts.map +1 -0
- package/dist/declarations/src/index.d.ts +3 -0
- package/dist/declarations/src/index.d.ts.map +1 -0
- package/dist/declarations/src/utils/agent-tools/auth.d.ts +18 -0
- package/dist/declarations/src/utils/agent-tools/auth.d.ts.map +1 -0
- package/dist/declarations/src/utils/agent-tools/endpoints.d.ts +16 -0
- package/dist/declarations/src/utils/agent-tools/endpoints.d.ts.map +1 -0
- package/dist/declarations/src/utils/agent-tools/index.d.ts +6 -0
- package/dist/declarations/src/utils/agent-tools/index.d.ts.map +1 -0
- package/dist/declarations/src/utils/agent-tools/manifest.d.ts +11 -0
- package/dist/declarations/src/utils/agent-tools/manifest.d.ts.map +1 -0
- package/dist/declarations/src/utils/agent-tools/responseLimit.d.ts +26 -0
- package/dist/declarations/src/utils/agent-tools/responseLimit.d.ts.map +1 -0
- package/dist/declarations/src/utils/agent-tools/types.d.ts +48 -0
- package/dist/declarations/src/utils/agent-tools/types.d.ts.map +1 -0
- package/dist/declarations/src/utils/apollo/beforeResolvers.d.ts +41 -0
- package/dist/declarations/src/utils/apollo/beforeResolvers.d.ts.map +1 -0
- package/dist/declarations/src/utils/apollo/commonTypeDefs.d.ts +7 -0
- package/dist/declarations/src/utils/apollo/commonTypeDefs.d.ts.map +1 -0
- package/dist/declarations/src/utils/apollo/constants.d.ts +3 -0
- package/dist/declarations/src/utils/apollo/constants.d.ts.map +1 -0
- package/dist/declarations/src/utils/apollo/customScalars.d.ts +6 -0
- package/dist/declarations/src/utils/apollo/customScalars.d.ts.map +1 -0
- package/dist/declarations/src/utils/apollo/expectedErrorPlugin.d.ts +11 -0
- package/dist/declarations/src/utils/apollo/expectedErrorPlugin.d.ts.map +1 -0
- package/dist/declarations/src/utils/apollo/index.d.ts +10 -0
- package/dist/declarations/src/utils/apollo/index.d.ts.map +1 -0
- package/dist/declarations/src/utils/apollo/runBeforeResolvers.d.ts +27 -0
- package/dist/declarations/src/utils/apollo/runBeforeResolvers.d.ts.map +1 -0
- package/dist/declarations/src/utils/apollo/utils.d.ts +5 -0
- package/dist/declarations/src/utils/apollo/utils.d.ts.map +1 -0
- package/dist/declarations/src/utils/apollo/wrapperMutations.d.ts +8 -0
- package/dist/declarations/src/utils/apollo/wrapperMutations.d.ts.map +1 -0
- package/dist/declarations/src/utils/apollo/wrapperResolvers.d.ts +8 -0
- package/dist/declarations/src/utils/apollo/wrapperResolvers.d.ts.map +1 -0
- package/dist/declarations/src/utils/bulkUtils.d.ts +7 -0
- package/dist/declarations/src/utils/bulkUtils.d.ts.map +1 -0
- package/dist/declarations/src/utils/constants.d.ts +40 -0
- package/dist/declarations/src/utils/constants.d.ts.map +1 -0
- package/dist/declarations/src/utils/editor.d.ts +45 -0
- package/dist/declarations/src/utils/editor.d.ts.map +1 -0
- package/dist/declarations/src/utils/email/address.d.ts +10 -0
- package/dist/declarations/src/utils/email/address.d.ts.map +1 -0
- package/dist/declarations/src/utils/email/attachments.d.ts +12 -0
- package/dist/declarations/src/utils/email/attachments.d.ts.map +1 -0
- package/dist/declarations/src/utils/email/config.d.ts +10 -0
- package/dist/declarations/src/utils/email/config.d.ts.map +1 -0
- package/dist/declarations/src/utils/email/constants.d.ts +6 -0
- package/dist/declarations/src/utils/email/constants.d.ts.map +1 -0
- package/dist/declarations/src/utils/email/index.d.ts +12 -0
- package/dist/declarations/src/utils/email/index.d.ts.map +1 -0
- package/dist/declarations/src/utils/email/providers/sendgrid.d.ts +17 -0
- package/dist/declarations/src/utils/email/providers/sendgrid.d.ts.map +1 -0
- package/dist/declarations/src/utils/email/providers/sendgridEvents.d.ts +18 -0
- package/dist/declarations/src/utils/email/providers/sendgridEvents.d.ts.map +1 -0
- package/dist/declarations/src/utils/email/providers/ses.d.ts +19 -0
- package/dist/declarations/src/utils/email/providers/ses.d.ts.map +1 -0
- package/dist/declarations/src/utils/email/providers/smtp.d.ts +14 -0
- package/dist/declarations/src/utils/email/providers/smtp.d.ts.map +1 -0
- package/dist/declarations/src/utils/email/resolveProvider.d.ts +6 -0
- package/dist/declarations/src/utils/email/resolveProvider.d.ts.map +1 -0
- package/dist/declarations/src/utils/email/service.d.ts +50 -0
- package/dist/declarations/src/utils/email/service.d.ts.map +1 -0
- package/dist/declarations/src/utils/email/types.d.ts +87 -0
- package/dist/declarations/src/utils/email/types.d.ts.map +1 -0
- package/dist/declarations/src/utils/errorClassifier.d.ts +56 -0
- package/dist/declarations/src/utils/errorClassifier.d.ts.map +1 -0
- package/dist/declarations/src/utils/file/read.d.ts +14 -0
- package/dist/declarations/src/utils/file/read.d.ts.map +1 -0
- package/dist/declarations/src/utils/file/upload.d.ts +10 -0
- package/dist/declarations/src/utils/file/upload.d.ts.map +1 -0
- package/dist/declarations/src/utils/graphqlPubSub.d.ts +3 -0
- package/dist/declarations/src/utils/graphqlPubSub.d.ts.map +1 -0
- package/dist/declarations/src/utils/headers/get-hostname.d.ts +5 -0
- package/dist/declarations/src/utils/headers/get-hostname.d.ts.map +1 -0
- package/dist/declarations/src/utils/headers/index.d.ts +5 -0
- package/dist/declarations/src/utils/headers/index.d.ts.map +1 -0
- package/dist/declarations/src/utils/headers/sanitize.d.ts +3 -0
- package/dist/declarations/src/utils/headers/sanitize.d.ts.map +1 -0
- package/dist/declarations/src/utils/headers/subdomain.d.ts +4 -0
- package/dist/declarations/src/utils/headers/subdomain.d.ts.map +1 -0
- package/dist/declarations/src/utils/headers/user.d.ts +14 -0
- package/dist/declarations/src/utils/headers/user.d.ts.map +1 -0
- package/dist/declarations/src/utils/index.d.ts +28 -0
- package/dist/declarations/src/utils/index.d.ts.map +1 -0
- package/dist/declarations/src/utils/knowledge.d.ts +50 -0
- package/dist/declarations/src/utils/knowledge.d.ts.map +1 -0
- package/dist/declarations/src/utils/logs/index.d.ts +103 -0
- package/dist/declarations/src/utils/logs/index.d.ts.map +1 -0
- package/dist/declarations/src/utils/mongo/cursor-util.d.ts +41 -0
- package/dist/declarations/src/utils/mongo/cursor-util.d.ts.map +1 -0
- package/dist/declarations/src/utils/mongo/generate-models.d.ts +4 -0
- package/dist/declarations/src/utils/mongo/generate-models.d.ts.map +1 -0
- package/dist/declarations/src/utils/mongo/index.d.ts +6 -0
- package/dist/declarations/src/utils/mongo/index.d.ts.map +1 -0
- package/dist/declarations/src/utils/mongo/mongo-connection.d.ts +5 -0
- package/dist/declarations/src/utils/mongo/mongo-connection.d.ts.map +1 -0
- package/dist/declarations/src/utils/mongo/mongoose-types.d.ts +22 -0
- package/dist/declarations/src/utils/mongo/mongoose-types.d.ts.map +1 -0
- package/dist/declarations/src/utils/mongo/mongoose-utils.d.ts +30 -0
- package/dist/declarations/src/utils/mongo/mongoose-utils.d.ts.map +1 -0
- package/dist/declarations/src/utils/mongo/search-tokens.d.ts +21 -0
- package/dist/declarations/src/utils/mongo/search-tokens.d.ts.map +1 -0
- package/dist/declarations/src/utils/mq-worker.d.ts +19 -0
- package/dist/declarations/src/utils/mq-worker.d.ts.map +1 -0
- package/dist/declarations/src/utils/random.d.ts +3 -0
- package/dist/declarations/src/utils/random.d.ts.map +1 -0
- package/dist/declarations/src/utils/redis.d.ts +4 -0
- package/dist/declarations/src/utils/redis.d.ts.map +1 -0
- package/dist/declarations/src/utils/saas/index.d.ts +3 -0
- package/dist/declarations/src/utils/saas/index.d.ts.map +1 -0
- package/dist/declarations/src/utils/saas/saas-mongo-connection.d.ts +59 -0
- package/dist/declarations/src/utils/saas/saas-mongo-connection.d.ts.map +1 -0
- package/dist/declarations/src/utils/saas/types.d.ts +96 -0
- package/dist/declarations/src/utils/saas/types.d.ts.map +1 -0
- package/dist/declarations/src/utils/sanitize.d.ts +3 -0
- package/dist/declarations/src/utils/sanitize.d.ts.map +1 -0
- package/dist/declarations/src/utils/sentry-init.d.ts +15 -0
- package/dist/declarations/src/utils/sentry-init.d.ts.map +1 -0
- package/dist/declarations/src/utils/sentry-instrument.d.ts +2 -0
- package/dist/declarations/src/utils/sentry-instrument.d.ts.map +1 -0
- package/dist/declarations/src/utils/serializablePayload.d.ts +11 -0
- package/dist/declarations/src/utils/serializablePayload.d.ts.map +1 -0
- package/dist/declarations/src/utils/service-discovery.d.ts +25 -0
- package/dist/declarations/src/utils/service-discovery.d.ts.map +1 -0
- package/dist/declarations/src/utils/start-plugin.d.ts +85 -0
- package/dist/declarations/src/utils/start-plugin.d.ts.map +1 -0
- package/dist/declarations/src/utils/string.d.ts +82 -0
- package/dist/declarations/src/utils/string.d.ts.map +1 -0
- package/dist/declarations/src/utils/trpc/index.d.ts +79 -0
- package/dist/declarations/src/utils/trpc/index.d.ts.map +1 -0
- package/dist/declarations/src/utils/trpc/sendCoreModuleProducer.d.ts +53 -0
- package/dist/declarations/src/utils/trpc/sendCoreModuleProducer.d.ts.map +1 -0
- package/dist/declarations/src/utils/utils.d.ts +69 -0
- package/dist/declarations/src/utils/utils.d.ts.map +1 -0
- package/dist/erxes-api-shared.cjs.d.ts +3 -0
- package/dist/erxes-api-shared.cjs.dev.js +7 -0
- package/dist/erxes-api-shared.cjs.js +7 -0
- package/dist/erxes-api-shared.cjs.prod.js +7 -0
- package/dist/erxes-api-shared.esm.js +3 -0
- package/dist/start-plugin-576e707d.cjs.prod.js +23223 -0
- package/dist/start-plugin-6e76556c.esm.js +22742 -0
- package/dist/start-plugin-89fa2bd2.cjs.dev.js +23225 -0
- package/package.json +105 -4
- package/src/common-modules/payment/worker.ts +53 -0
- package/src/core-modules/approval/approvalChangeTypes.ts +31 -0
- package/src/core-modules/approval/checkApprovalLock.ts +85 -0
- package/src/core-modules/approval/constants.ts +45 -0
- package/src/core-modules/approval/index.ts +6 -0
- package/src/core-modules/approval/initApproval.ts +59 -0
- package/src/core-modules/approval/types.ts +206 -0
- package/src/core-modules/approval/zodSchemas.ts +55 -0
- package/src/core-modules/apps/@types/app.ts +15 -0
- package/src/core-modules/apps/db/definitions/apps.ts +30 -0
- package/src/core-modules/apps/index.ts +2 -0
- package/src/core-modules/automations/actionErrorPolicy.test.ts +125 -0
- package/src/core-modules/automations/actionErrorPolicy.ts +162 -0
- package/src/core-modules/automations/actionInputs.test.ts +70 -0
- package/src/core-modules/automations/actionOutcome.test.ts +87 -0
- package/src/core-modules/automations/actionOutcome.ts +128 -0
- package/src/core-modules/automations/constants.ts +181 -0
- package/src/core-modules/automations/definitions/aiAgents.ts +343 -0
- package/src/core-modules/automations/definitions/automations.ts +207 -0
- package/src/core-modules/automations/definitions/executions.ts +190 -0
- package/src/core-modules/automations/definitions/index.ts +3 -0
- package/src/core-modules/automations/getValueByPath.test.ts +49 -0
- package/src/core-modules/automations/index.ts +13 -0
- package/src/core-modules/automations/outputResolvers.test.ts +97 -0
- package/src/core-modules/automations/outputResolvers.ts +1238 -0
- package/src/core-modules/automations/reEnrollment.ts +34 -0
- package/src/core-modules/automations/segmentMembership.ts +34 -0
- package/src/core-modules/automations/sendAutomationMessage.ts +219 -0
- package/src/core-modules/automations/setPropertyOutcome.test.ts +105 -0
- package/src/core-modules/automations/setPropertyRows.test.ts +61 -0
- package/src/core-modules/automations/setupAutomationProducers.ts +187 -0
- package/src/core-modules/automations/typeUtils.ts +3 -0
- package/src/core-modules/automations/types.ts +577 -0
- package/src/core-modules/automations/utils.ts +1128 -0
- package/src/core-modules/automations/workflowValidation.ts +32 -0
- package/src/core-modules/automations/zodTypes.ts +221 -0
- package/src/core-modules/client-portals/definitions/clientPortal.ts +230 -0
- package/src/core-modules/client-portals/definitions/comment.ts +26 -0
- package/src/core-modules/client-portals/definitions/cpNotification.ts +112 -0
- package/src/core-modules/client-portals/definitions/cpUser.ts +236 -0
- package/src/core-modules/client-portals/index.ts +4 -0
- package/src/core-modules/common/db/definitions/common.ts +43 -0
- package/src/core-modules/common/eventHandlers/createEventHandlers.ts +236 -0
- package/src/core-modules/common/eventHandlers/generateEventHandlers.ts +37 -0
- package/src/core-modules/common/eventHandlers/index.ts +11 -0
- package/src/core-modules/common/eventHandlers/runtimeContext.ts +36 -0
- package/src/core-modules/common/eventHandlers/schemas.ts +53 -0
- package/src/core-modules/common/eventHandlers/types.ts +97 -0
- package/src/core-modules/common/eventHandlers/utils.ts +113 -0
- package/src/core-modules/common/index.ts +4 -0
- package/src/core-modules/common/references/fetchRecordReferenceTargets.ts +43 -0
- package/src/core-modules/common/references/getRecordReferenceFields.ts +243 -0
- package/src/core-modules/common/references/index.ts +9 -0
- package/src/core-modules/common/references/initRecordReferences.ts +84 -0
- package/src/core-modules/common/references/normalizeRecordReferenceConfig.ts +59 -0
- package/src/core-modules/common/references/resolveRecordReferencePath.ts +473 -0
- package/src/core-modules/common/references/resolveRecordReferencePlaceholders.ts +173 -0
- package/src/core-modules/common/references/resolveRecordReferenceValue.ts +41 -0
- package/src/core-modules/common/references/resolveRecordRelationIds.ts +57 -0
- package/src/core-modules/common/references/types.ts +78 -0
- package/src/core-modules/common/references/utils.ts +60 -0
- package/src/core-modules/common/references/zodInputs.ts +13 -0
- package/src/core-modules/common/routeToModuleProducer.ts +118 -0
- package/src/core-modules/email-content/blocksToHtml.ts +551 -0
- package/src/core-modules/email-content/constants.ts +4 -0
- package/src/core-modules/email-content/emailFooter.ts +17 -0
- package/src/core-modules/email-content/expandRepeatRows.test.ts +36 -0
- package/src/core-modules/email-content/expandRepeatRows.ts +59 -0
- package/src/core-modules/email-content/index.ts +8 -0
- package/src/core-modules/email-content/renderEmailContent.ts +88 -0
- package/src/core-modules/email-content/replacePlaceholders.ts +143 -0
- package/src/core-modules/email-content/types.ts +49 -0
- package/src/core-modules/email-content/unresolvedPlaceholders.ts +27 -0
- package/src/core-modules/forms/index.ts +2 -0
- package/src/core-modules/forms/types.ts +86 -0
- package/src/core-modules/forms/utils.ts +34 -0
- package/src/core-modules/import-export/index.ts +7 -0
- package/src/core-modules/import-export/types.ts +204 -0
- package/src/core-modules/import-export/utils/createCoreImportClient.ts +131 -0
- package/src/core-modules/import-export/utils/exportBatchProcess.ts +560 -0
- package/src/core-modules/import-export/utils/exportCursor.ts +47 -0
- package/src/core-modules/import-export/utils/headerMatcher.test.ts +90 -0
- package/src/core-modules/import-export/utils/headerMatcher.ts +229 -0
- package/src/core-modules/import-export/utils/importBatchProcess.ts +780 -0
- package/src/core-modules/import-export/utils/importExportError.ts +71 -0
- package/src/core-modules/import-export/utils/importExportRuntime.ts +96 -0
- package/src/core-modules/import-export/utils/importUtils.ts +59 -0
- package/src/core-modules/import-export/utils/progressUpdate.ts +25 -0
- package/src/core-modules/import-export/utils/tempWorkspace.ts +34 -0
- package/src/core-modules/import-export/worker.ts +215 -0
- package/src/core-modules/import-export/zodSchemas.ts +63 -0
- package/src/core-modules/index.ts +15 -0
- package/src/core-modules/logs/activityLog/builder.ts +232 -0
- package/src/core-modules/logs/activityLog/index.ts +4 -0
- package/src/core-modules/logs/activityLog/sharedBuilders.ts +95 -0
- package/src/core-modules/logs/activityLog/types.ts +26 -0
- package/src/core-modules/logs/activityLog/utils.ts +61 -0
- package/src/core-modules/logs/activityLogUtils.ts +677 -0
- package/src/core-modules/logs/definitions/activityLog.ts +71 -0
- package/src/core-modules/logs/definitions/logs.ts +49 -0
- package/src/core-modules/logs/index.ts +5 -0
- package/src/core-modules/logs/types.ts +16 -0
- package/src/core-modules/notifications/definitions/emailAddresses.ts +105 -0
- package/src/core-modules/notifications/definitions/emailDeliveries.ts +188 -0
- package/src/core-modules/notifications/definitions/emailRamp.ts +83 -0
- package/src/core-modules/notifications/definitions/emailSenders.ts +84 -0
- package/src/core-modules/notifications/definitions/notificationConfigs.ts +110 -0
- package/src/core-modules/notifications/definitions/notificationSettings.ts +67 -0
- package/src/core-modules/notifications/definitions/notifications.ts +130 -0
- package/src/core-modules/notifications/emailUtils.ts +88 -0
- package/src/core-modules/notifications/index.ts +7 -0
- package/src/core-modules/notifications/utils.ts +143 -0
- package/src/core-modules/permissions/db/definitions/permissions.ts +82 -0
- package/src/core-modules/permissions/index.ts +3 -0
- package/src/core-modules/permissions/oauth-scopes.test.ts +102 -0
- package/src/core-modules/permissions/user-actions-map.ts +170 -0
- package/src/core-modules/permissions/utils.ts +317 -0
- package/src/core-modules/properties/README.md +161 -0
- package/src/core-modules/properties/filter.test.ts +74 -0
- package/src/core-modules/properties/filter.ts +156 -0
- package/src/core-modules/properties/importExport.ts +159 -0
- package/src/core-modules/properties/index.ts +9 -0
- package/src/core-modules/properties/keys.test.ts +71 -0
- package/src/core-modules/properties/keys.ts +128 -0
- package/src/core-modules/properties/mergePropertyData.test.ts +65 -0
- package/src/core-modules/properties/mergeRows.ts +93 -0
- package/src/core-modules/properties/operators.ts +91 -0
- package/src/core-modules/properties/options.test.ts +119 -0
- package/src/core-modules/properties/options.ts +55 -0
- package/src/core-modules/properties/setupPropertyProducers.ts +32 -0
- package/src/core-modules/properties/types.ts +31 -0
- package/src/core-modules/properties/valueUsage.test.ts +158 -0
- package/src/core-modules/properties/valueUsage.ts +153 -0
- package/src/core-modules/segments/anniversary.test.ts +122 -0
- package/src/core-modules/segments/dependencies.test.ts +173 -0
- package/src/core-modules/segments/dependencies.ts +70 -0
- package/src/core-modules/segments/evaluate.test.ts +339 -0
- package/src/core-modules/segments/evaluate.ts +388 -0
- package/src/core-modules/segments/evaluateBatch.test.ts +233 -0
- package/src/core-modules/segments/evaluateBatch.ts +263 -0
- package/src/core-modules/segments/evaluateFieldsRouter.test.ts +148 -0
- package/src/core-modules/segments/evaluateFieldsRouter.ts +94 -0
- package/src/core-modules/segments/evaluateOwned.ts +162 -0
- package/src/core-modules/segments/events.ts +142 -0
- package/src/core-modules/segments/fieldBuilders.ts +152 -0
- package/src/core-modules/segments/fieldMeta.ts +96 -0
- package/src/core-modules/segments/fieldRequests.test.ts +302 -0
- package/src/core-modules/segments/fieldRequests.ts +172 -0
- package/src/core-modules/segments/fieldSources.test.ts +99 -0
- package/src/core-modules/segments/fingerprint.test.ts +111 -0
- package/src/core-modules/segments/fingerprint.ts +70 -0
- package/src/core-modules/segments/index.ts +30 -0
- package/src/core-modules/segments/joinChanges.test.ts +96 -0
- package/src/core-modules/segments/joinChanges.ts +67 -0
- package/src/core-modules/segments/materialized.ts +23 -0
- package/src/core-modules/segments/measureRelations.test.ts +222 -0
- package/src/core-modules/segments/measureRelations.ts +322 -0
- package/src/core-modules/segments/memberQuery.test.ts +60 -0
- package/src/core-modules/segments/memberQuery.ts +45 -0
- package/src/core-modules/segments/membership.ts +170 -0
- package/src/core-modules/segments/mongoFilter.test.ts +326 -0
- package/src/core-modules/segments/mongoFilter.ts +355 -0
- package/src/core-modules/segments/nodeRefs.ts +29 -0
- package/src/core-modules/segments/nodes.ts +48 -0
- package/src/core-modules/segments/operators.ts +243 -0
- package/src/core-modules/segments/ownedSource.ts +16 -0
- package/src/core-modules/segments/plan.test.ts +172 -0
- package/src/core-modules/segments/plan.ts +155 -0
- package/src/core-modules/segments/relationRegistry.test.ts +64 -0
- package/src/core-modules/segments/relationRegistry.ts +198 -0
- package/src/core-modules/segments/segmentReference.test.ts +142 -0
- package/src/core-modules/segments/setupSegmentProducers.ts +77 -0
- package/src/core-modules/segments/subjectsReachedBy.ts +70 -0
- package/src/core-modules/segments/timeZone.ts +56 -0
- package/src/core-modules/segments/types.ts +97 -0
- package/src/core-modules/segments/utils.ts +122 -0
- package/src/core-modules/segments/walkNodes.ts +76 -0
- package/src/core-modules/segments/zodSchemas.ts +130 -0
- package/src/core-modules/segments/zonedTime.test.ts +163 -0
- package/src/core-modules/segments/zonedTime.ts +198 -0
- package/src/core-modules/templates/index.ts +1 -0
- package/src/core-modules/templates/utils.ts +91 -0
- package/src/core-modules/users/constants.ts +318 -0
- package/src/core-modules/users/db/definitions/users.ts +226 -0
- package/src/core-modules/users/index.ts +2 -0
- package/src/core-types/common.ts +183 -0
- package/src/core-types/index.ts +19 -0
- package/src/core-types/modules/app/app.ts +13 -0
- package/src/core-types/modules/automations/automations.ts +23 -0
- package/src/core-types/modules/contacts/company.ts +70 -0
- package/src/core-types/modules/contacts/contacts-common.ts +32 -0
- package/src/core-types/modules/contacts/customer.ts +94 -0
- package/src/core-types/modules/emailTemplates/emailTemplate.ts +19 -0
- package/src/core-types/modules/emailTemplates/index.ts +1 -0
- package/src/core-types/modules/logs/logs.ts +30 -0
- package/src/core-types/modules/permissions/permission.ts +63 -0
- package/src/core-types/modules/permissions/role.ts +24 -0
- package/src/core-types/modules/products/product.ts +100 -0
- package/src/core-types/modules/products/productCategory.ts +27 -0
- package/src/core-types/modules/products/productConfig.ts +10 -0
- package/src/core-types/modules/products/uom.ts +12 -0
- package/src/core-types/modules/relations/relations.ts +14 -0
- package/src/core-types/modules/saas/organization.ts +7 -0
- package/src/core-types/modules/structure/structure.ts +29 -0
- package/src/core-types/modules/tags/tag.ts +17 -0
- package/src/core-types/modules/team-member/structure.ts +23 -0
- package/src/core-types/modules/team-member/user.ts +93 -0
- package/src/index.ts +1 -0
- package/src/utils/agent-tools/auth.ts +129 -0
- package/src/utils/agent-tools/endpoints.ts +274 -0
- package/src/utils/agent-tools/index.ts +5 -0
- package/src/utils/agent-tools/manifest.ts +152 -0
- package/src/utils/agent-tools/responseLimit.test.ts +99 -0
- package/src/utils/agent-tools/responseLimit.ts +66 -0
- package/src/utils/agent-tools/types.ts +52 -0
- package/src/utils/apollo/beforeResolvers.ts +117 -0
- package/src/utils/apollo/commonTypeDefs.ts +78 -0
- package/src/utils/apollo/constants.ts +16 -0
- package/src/utils/apollo/customScalars.ts +69 -0
- package/src/utils/apollo/expectedErrorPlugin.ts +83 -0
- package/src/utils/apollo/index.ts +10 -0
- package/src/utils/apollo/runBeforeResolvers.ts +214 -0
- package/src/utils/apollo/utils.ts +80 -0
- package/src/utils/apollo/wrapperMutations.ts +75 -0
- package/src/utils/apollo/wrapperResolvers.ts +182 -0
- package/src/utils/bulkUtils.ts +62 -0
- package/src/utils/constants.ts +99 -0
- package/src/utils/editor.ts +412 -0
- package/src/utils/email/address.ts +42 -0
- package/src/utils/email/attachments.ts +74 -0
- package/src/utils/email/config.ts +46 -0
- package/src/utils/email/constants.ts +25 -0
- package/src/utils/email/index.ts +11 -0
- package/src/utils/email/providers/sendgrid.ts +280 -0
- package/src/utils/email/providers/sendgridEvents.ts +48 -0
- package/src/utils/email/providers/ses.ts +250 -0
- package/src/utils/email/providers/smtp.ts +99 -0
- package/src/utils/email/resolveProvider.ts +75 -0
- package/src/utils/email/service.ts +192 -0
- package/src/utils/email/types.ts +127 -0
- package/src/utils/errorClassifier.test.ts +231 -0
- package/src/utils/errorClassifier.ts +458 -0
- package/src/utils/file/read.ts +464 -0
- package/src/utils/file/upload.ts +531 -0
- package/src/utils/graphqlPubSub.ts +28 -0
- package/src/utils/headers/get-hostname.ts +18 -0
- package/src/utils/headers/index.ts +4 -0
- package/src/utils/headers/sanitize.ts +9 -0
- package/src/utils/headers/subdomain.ts +13 -0
- package/src/utils/headers/user.test.ts +76 -0
- package/src/utils/headers/user.ts +113 -0
- package/src/utils/index.ts +27 -0
- package/src/utils/knowledge.ts +107 -0
- package/src/utils/logs/index.ts +247 -0
- package/src/utils/mongo/cursor-util.ts +153 -0
- package/src/utils/mongo/generate-models.ts +97 -0
- package/src/utils/mongo/index.ts +5 -0
- package/src/utils/mongo/mongo-connection.ts +42 -0
- package/src/utils/mongo/mongoose-types.ts +26 -0
- package/src/utils/mongo/mongoose-utils.ts +329 -0
- package/src/utils/mongo/search-tokens.ts +193 -0
- package/src/utils/mq-worker.ts +150 -0
- package/src/utils/random.ts +6 -0
- package/src/utils/redis.ts +23 -0
- package/src/utils/saas/constants.ts +32 -0
- package/src/utils/saas/definition.ts +318 -0
- package/src/utils/saas/index.ts +2 -0
- package/src/utils/saas/saas-mongo-connection.ts +595 -0
- package/src/utils/saas/types.ts +107 -0
- package/src/utils/sanitize.ts +73 -0
- package/src/utils/sentry-init.ts +128 -0
- package/src/utils/sentry-instrument.ts +5 -0
- package/src/utils/serializablePayload.test.ts +65 -0
- package/src/utils/serializablePayload.ts +44 -0
- package/src/utils/service-discovery.ts +256 -0
- package/src/utils/start-plugin.ts +482 -0
- package/src/utils/string.ts +159 -0
- package/src/utils/trpc/index.ts +278 -0
- package/src/utils/trpc/sendCoreModuleProducer.ts +146 -0
- package/src/utils/trpc/trpc-setup.ts +91 -0
- package/src/utils/utils.ts +669 -0
- package/utils/dist/erxes-api-shared-utils.cjs.d.ts +2 -0
- package/utils/dist/erxes-api-shared-utils.cjs.dev.js +3066 -0
- package/utils/dist/erxes-api-shared-utils.cjs.js +7 -0
- package/utils/dist/erxes-api-shared-utils.cjs.prod.js +3066 -0
- package/utils/dist/erxes-api-shared-utils.esm.js +2776 -0
- package/utils/package.json +5 -0
- package/README.md +0 -3
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"automations.d.ts","sourceRoot":"../../../../../../src/core-modules/automations/definitions","sources":["automations.ts"],"names":[],"mappings":"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"}
|
|
@@ -0,0 +1,316 @@
|
|
|
1
|
+
import { TCreatedVia } from "../../../core-types/common.js";
|
|
2
|
+
import { Document, Schema } from 'mongoose';
|
|
3
|
+
export interface IAutomationExecAction {
|
|
4
|
+
createdAt?: string;
|
|
5
|
+
startedAt?: string;
|
|
6
|
+
finishedAt?: string;
|
|
7
|
+
durationMs?: number;
|
|
8
|
+
status?: 'success' | 'skipped' | 'error' | 'waiting' | 'queued' | 'standby' | 'dropped';
|
|
9
|
+
actionId: string;
|
|
10
|
+
actionType: string;
|
|
11
|
+
actionConfig?: any;
|
|
12
|
+
nextActionId?: string;
|
|
13
|
+
result?: any;
|
|
14
|
+
errorCode?: string;
|
|
15
|
+
skipReason?: string;
|
|
16
|
+
attempt?: number;
|
|
17
|
+
childExecutionId?: string;
|
|
18
|
+
jobId?: string;
|
|
19
|
+
queuedAt?: Date | string;
|
|
20
|
+
expiresAt?: Date | string;
|
|
21
|
+
}
|
|
22
|
+
export interface IAutomationExecution {
|
|
23
|
+
createdAt?: string;
|
|
24
|
+
modifiedAt?: string;
|
|
25
|
+
automationId: string;
|
|
26
|
+
triggerId: string;
|
|
27
|
+
triggerType: string;
|
|
28
|
+
triggerConfig: any;
|
|
29
|
+
/**
|
|
30
|
+
* What set this run going. A caller that addressed the automation on
|
|
31
|
+
* someone's behalf declares its own — a campaign names itself and whoever
|
|
32
|
+
* put it live — and the runner stamps the run's own id onto it. Records the
|
|
33
|
+
* run creates carry it onward.
|
|
34
|
+
*/
|
|
35
|
+
createdVia?: TCreatedVia;
|
|
36
|
+
nextActionId?: string;
|
|
37
|
+
targetId: string;
|
|
38
|
+
target: any;
|
|
39
|
+
watched?: Record<string, unknown>;
|
|
40
|
+
status: string;
|
|
41
|
+
description: string;
|
|
42
|
+
actions?: IAutomationExecAction[];
|
|
43
|
+
failedActionId?: string;
|
|
44
|
+
failedActionType?: string;
|
|
45
|
+
errorCode?: string;
|
|
46
|
+
handledFailureActionIds?: string[];
|
|
47
|
+
startWaitingDate?: Date;
|
|
48
|
+
waitingActionId?: string;
|
|
49
|
+
objToCheck?: any;
|
|
50
|
+
responseActionId?: string;
|
|
51
|
+
parentExecutionId?: string;
|
|
52
|
+
workflowId?: string;
|
|
53
|
+
inputs?: Record<string, any>;
|
|
54
|
+
depth?: number;
|
|
55
|
+
}
|
|
56
|
+
export interface IAutomationExecutionDocument extends IAutomationExecution, Document {
|
|
57
|
+
_id: string;
|
|
58
|
+
}
|
|
59
|
+
export declare const AUTOMATION_EXECUTION_STATUS: {
|
|
60
|
+
ACTIVE: string;
|
|
61
|
+
WAITING: string;
|
|
62
|
+
STANDBY: string;
|
|
63
|
+
ERROR: string;
|
|
64
|
+
MISSID: string;
|
|
65
|
+
COMPLETE: string;
|
|
66
|
+
ALL: string[];
|
|
67
|
+
};
|
|
68
|
+
export declare const automationExecutionSchema: Schema<any, import("mongoose").Model<any, any, any, any, any, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, {
|
|
69
|
+
createdAt: NativeDate;
|
|
70
|
+
status: string;
|
|
71
|
+
description: string;
|
|
72
|
+
modifiedAt: NativeDate;
|
|
73
|
+
automationId: string;
|
|
74
|
+
triggerId: string;
|
|
75
|
+
targetId: string;
|
|
76
|
+
actions: import("mongoose").Types.DocumentArray<{
|
|
77
|
+
createdAt: NativeDate;
|
|
78
|
+
durationMs?: number | null | undefined;
|
|
79
|
+
jobId?: string | null | undefined;
|
|
80
|
+
result?: any;
|
|
81
|
+
status?: "success" | "waiting" | "error" | "standby" | "skipped" | "queued" | "dropped" | null | undefined;
|
|
82
|
+
actionType?: string | null | undefined;
|
|
83
|
+
nextActionId?: string | null | undefined;
|
|
84
|
+
startedAt?: NativeDate | null | undefined;
|
|
85
|
+
finishedAt?: NativeDate | null | undefined;
|
|
86
|
+
actionId?: string | null | undefined;
|
|
87
|
+
actionConfig?: any;
|
|
88
|
+
skipReason?: string | null | undefined;
|
|
89
|
+
attempt?: number | null | undefined;
|
|
90
|
+
queuedAt?: NativeDate | null | undefined;
|
|
91
|
+
expiresAt?: NativeDate | null | undefined;
|
|
92
|
+
childExecutionId?: string | null | undefined;
|
|
93
|
+
errorCode?: string | null | undefined;
|
|
94
|
+
}, import("mongoose").Types.Subdocument<import("mongoose").Types.ObjectId, any, {
|
|
95
|
+
createdAt: NativeDate;
|
|
96
|
+
durationMs?: number | null | undefined;
|
|
97
|
+
jobId?: string | null | undefined;
|
|
98
|
+
result?: any;
|
|
99
|
+
status?: "success" | "waiting" | "error" | "standby" | "skipped" | "queued" | "dropped" | null | undefined;
|
|
100
|
+
actionType?: string | null | undefined;
|
|
101
|
+
nextActionId?: string | null | undefined;
|
|
102
|
+
startedAt?: NativeDate | null | undefined;
|
|
103
|
+
finishedAt?: NativeDate | null | undefined;
|
|
104
|
+
actionId?: string | null | undefined;
|
|
105
|
+
actionConfig?: any;
|
|
106
|
+
skipReason?: string | null | undefined;
|
|
107
|
+
attempt?: number | null | undefined;
|
|
108
|
+
queuedAt?: NativeDate | null | undefined;
|
|
109
|
+
expiresAt?: NativeDate | null | undefined;
|
|
110
|
+
childExecutionId?: string | null | undefined;
|
|
111
|
+
errorCode?: string | null | undefined;
|
|
112
|
+
}> & {
|
|
113
|
+
createdAt: NativeDate;
|
|
114
|
+
durationMs?: number | null | undefined;
|
|
115
|
+
jobId?: string | null | undefined;
|
|
116
|
+
result?: any;
|
|
117
|
+
status?: "success" | "waiting" | "error" | "standby" | "skipped" | "queued" | "dropped" | null | undefined;
|
|
118
|
+
actionType?: string | null | undefined;
|
|
119
|
+
nextActionId?: string | null | undefined;
|
|
120
|
+
startedAt?: NativeDate | null | undefined;
|
|
121
|
+
finishedAt?: NativeDate | null | undefined;
|
|
122
|
+
actionId?: string | null | undefined;
|
|
123
|
+
actionConfig?: any;
|
|
124
|
+
skipReason?: string | null | undefined;
|
|
125
|
+
attempt?: number | null | undefined;
|
|
126
|
+
queuedAt?: NativeDate | null | undefined;
|
|
127
|
+
expiresAt?: NativeDate | null | undefined;
|
|
128
|
+
childExecutionId?: string | null | undefined;
|
|
129
|
+
errorCode?: string | null | undefined;
|
|
130
|
+
}>;
|
|
131
|
+
handledFailureActionIds: string[];
|
|
132
|
+
depth: number;
|
|
133
|
+
createdVia?: any;
|
|
134
|
+
target?: any;
|
|
135
|
+
nextActionId?: string | null | undefined;
|
|
136
|
+
workflowId?: string | null | undefined;
|
|
137
|
+
triggerType?: string | null | undefined;
|
|
138
|
+
triggerConfig?: any;
|
|
139
|
+
startWaitingDate?: NativeDate | null | undefined;
|
|
140
|
+
waitingActionId?: string | null | undefined;
|
|
141
|
+
objToCheck?: any;
|
|
142
|
+
responseActionId?: string | null | undefined;
|
|
143
|
+
inputs?: any;
|
|
144
|
+
errorCode?: string | null | undefined;
|
|
145
|
+
watched?: any;
|
|
146
|
+
failedActionId?: string | null | undefined;
|
|
147
|
+
failedActionType?: string | null | undefined;
|
|
148
|
+
parentExecutionId?: string | null | undefined;
|
|
149
|
+
}, Document<unknown, {}, import("mongoose").FlatRecord<{
|
|
150
|
+
createdAt: NativeDate;
|
|
151
|
+
status: string;
|
|
152
|
+
description: string;
|
|
153
|
+
modifiedAt: NativeDate;
|
|
154
|
+
automationId: string;
|
|
155
|
+
triggerId: string;
|
|
156
|
+
targetId: string;
|
|
157
|
+
actions: import("mongoose").Types.DocumentArray<{
|
|
158
|
+
createdAt: NativeDate;
|
|
159
|
+
durationMs?: number | null | undefined;
|
|
160
|
+
jobId?: string | null | undefined;
|
|
161
|
+
result?: any;
|
|
162
|
+
status?: "success" | "waiting" | "error" | "standby" | "skipped" | "queued" | "dropped" | null | undefined;
|
|
163
|
+
actionType?: string | null | undefined;
|
|
164
|
+
nextActionId?: string | null | undefined;
|
|
165
|
+
startedAt?: NativeDate | null | undefined;
|
|
166
|
+
finishedAt?: NativeDate | null | undefined;
|
|
167
|
+
actionId?: string | null | undefined;
|
|
168
|
+
actionConfig?: any;
|
|
169
|
+
skipReason?: string | null | undefined;
|
|
170
|
+
attempt?: number | null | undefined;
|
|
171
|
+
queuedAt?: NativeDate | null | undefined;
|
|
172
|
+
expiresAt?: NativeDate | null | undefined;
|
|
173
|
+
childExecutionId?: string | null | undefined;
|
|
174
|
+
errorCode?: string | null | undefined;
|
|
175
|
+
}, import("mongoose").Types.Subdocument<import("mongoose").Types.ObjectId, any, {
|
|
176
|
+
createdAt: NativeDate;
|
|
177
|
+
durationMs?: number | null | undefined;
|
|
178
|
+
jobId?: string | null | undefined;
|
|
179
|
+
result?: any;
|
|
180
|
+
status?: "success" | "waiting" | "error" | "standby" | "skipped" | "queued" | "dropped" | null | undefined;
|
|
181
|
+
actionType?: string | null | undefined;
|
|
182
|
+
nextActionId?: string | null | undefined;
|
|
183
|
+
startedAt?: NativeDate | null | undefined;
|
|
184
|
+
finishedAt?: NativeDate | null | undefined;
|
|
185
|
+
actionId?: string | null | undefined;
|
|
186
|
+
actionConfig?: any;
|
|
187
|
+
skipReason?: string | null | undefined;
|
|
188
|
+
attempt?: number | null | undefined;
|
|
189
|
+
queuedAt?: NativeDate | null | undefined;
|
|
190
|
+
expiresAt?: NativeDate | null | undefined;
|
|
191
|
+
childExecutionId?: string | null | undefined;
|
|
192
|
+
errorCode?: string | null | undefined;
|
|
193
|
+
}> & {
|
|
194
|
+
createdAt: NativeDate;
|
|
195
|
+
durationMs?: number | null | undefined;
|
|
196
|
+
jobId?: string | null | undefined;
|
|
197
|
+
result?: any;
|
|
198
|
+
status?: "success" | "waiting" | "error" | "standby" | "skipped" | "queued" | "dropped" | null | undefined;
|
|
199
|
+
actionType?: string | null | undefined;
|
|
200
|
+
nextActionId?: string | null | undefined;
|
|
201
|
+
startedAt?: NativeDate | null | undefined;
|
|
202
|
+
finishedAt?: NativeDate | null | undefined;
|
|
203
|
+
actionId?: string | null | undefined;
|
|
204
|
+
actionConfig?: any;
|
|
205
|
+
skipReason?: string | null | undefined;
|
|
206
|
+
attempt?: number | null | undefined;
|
|
207
|
+
queuedAt?: NativeDate | null | undefined;
|
|
208
|
+
expiresAt?: NativeDate | null | undefined;
|
|
209
|
+
childExecutionId?: string | null | undefined;
|
|
210
|
+
errorCode?: string | null | undefined;
|
|
211
|
+
}>;
|
|
212
|
+
handledFailureActionIds: string[];
|
|
213
|
+
depth: number;
|
|
214
|
+
createdVia?: any;
|
|
215
|
+
target?: any;
|
|
216
|
+
nextActionId?: string | null | undefined;
|
|
217
|
+
workflowId?: string | null | undefined;
|
|
218
|
+
triggerType?: string | null | undefined;
|
|
219
|
+
triggerConfig?: any;
|
|
220
|
+
startWaitingDate?: NativeDate | null | undefined;
|
|
221
|
+
waitingActionId?: string | null | undefined;
|
|
222
|
+
objToCheck?: any;
|
|
223
|
+
responseActionId?: string | null | undefined;
|
|
224
|
+
inputs?: any;
|
|
225
|
+
errorCode?: string | null | undefined;
|
|
226
|
+
watched?: any;
|
|
227
|
+
failedActionId?: string | null | undefined;
|
|
228
|
+
failedActionType?: string | null | undefined;
|
|
229
|
+
parentExecutionId?: string | null | undefined;
|
|
230
|
+
}>> & import("mongoose").FlatRecord<{
|
|
231
|
+
createdAt: NativeDate;
|
|
232
|
+
status: string;
|
|
233
|
+
description: string;
|
|
234
|
+
modifiedAt: NativeDate;
|
|
235
|
+
automationId: string;
|
|
236
|
+
triggerId: string;
|
|
237
|
+
targetId: string;
|
|
238
|
+
actions: import("mongoose").Types.DocumentArray<{
|
|
239
|
+
createdAt: NativeDate;
|
|
240
|
+
durationMs?: number | null | undefined;
|
|
241
|
+
jobId?: string | null | undefined;
|
|
242
|
+
result?: any;
|
|
243
|
+
status?: "success" | "waiting" | "error" | "standby" | "skipped" | "queued" | "dropped" | null | undefined;
|
|
244
|
+
actionType?: string | null | undefined;
|
|
245
|
+
nextActionId?: string | null | undefined;
|
|
246
|
+
startedAt?: NativeDate | null | undefined;
|
|
247
|
+
finishedAt?: NativeDate | null | undefined;
|
|
248
|
+
actionId?: string | null | undefined;
|
|
249
|
+
actionConfig?: any;
|
|
250
|
+
skipReason?: string | null | undefined;
|
|
251
|
+
attempt?: number | null | undefined;
|
|
252
|
+
queuedAt?: NativeDate | null | undefined;
|
|
253
|
+
expiresAt?: NativeDate | null | undefined;
|
|
254
|
+
childExecutionId?: string | null | undefined;
|
|
255
|
+
errorCode?: string | null | undefined;
|
|
256
|
+
}, import("mongoose").Types.Subdocument<import("mongoose").Types.ObjectId, any, {
|
|
257
|
+
createdAt: NativeDate;
|
|
258
|
+
durationMs?: number | null | undefined;
|
|
259
|
+
jobId?: string | null | undefined;
|
|
260
|
+
result?: any;
|
|
261
|
+
status?: "success" | "waiting" | "error" | "standby" | "skipped" | "queued" | "dropped" | null | undefined;
|
|
262
|
+
actionType?: string | null | undefined;
|
|
263
|
+
nextActionId?: string | null | undefined;
|
|
264
|
+
startedAt?: NativeDate | null | undefined;
|
|
265
|
+
finishedAt?: NativeDate | null | undefined;
|
|
266
|
+
actionId?: string | null | undefined;
|
|
267
|
+
actionConfig?: any;
|
|
268
|
+
skipReason?: string | null | undefined;
|
|
269
|
+
attempt?: number | null | undefined;
|
|
270
|
+
queuedAt?: NativeDate | null | undefined;
|
|
271
|
+
expiresAt?: NativeDate | null | undefined;
|
|
272
|
+
childExecutionId?: string | null | undefined;
|
|
273
|
+
errorCode?: string | null | undefined;
|
|
274
|
+
}> & {
|
|
275
|
+
createdAt: NativeDate;
|
|
276
|
+
durationMs?: number | null | undefined;
|
|
277
|
+
jobId?: string | null | undefined;
|
|
278
|
+
result?: any;
|
|
279
|
+
status?: "success" | "waiting" | "error" | "standby" | "skipped" | "queued" | "dropped" | null | undefined;
|
|
280
|
+
actionType?: string | null | undefined;
|
|
281
|
+
nextActionId?: string | null | undefined;
|
|
282
|
+
startedAt?: NativeDate | null | undefined;
|
|
283
|
+
finishedAt?: NativeDate | null | undefined;
|
|
284
|
+
actionId?: string | null | undefined;
|
|
285
|
+
actionConfig?: any;
|
|
286
|
+
skipReason?: string | null | undefined;
|
|
287
|
+
attempt?: number | null | undefined;
|
|
288
|
+
queuedAt?: NativeDate | null | undefined;
|
|
289
|
+
expiresAt?: NativeDate | null | undefined;
|
|
290
|
+
childExecutionId?: string | null | undefined;
|
|
291
|
+
errorCode?: string | null | undefined;
|
|
292
|
+
}>;
|
|
293
|
+
handledFailureActionIds: string[];
|
|
294
|
+
depth: number;
|
|
295
|
+
createdVia?: any;
|
|
296
|
+
target?: any;
|
|
297
|
+
nextActionId?: string | null | undefined;
|
|
298
|
+
workflowId?: string | null | undefined;
|
|
299
|
+
triggerType?: string | null | undefined;
|
|
300
|
+
triggerConfig?: any;
|
|
301
|
+
startWaitingDate?: NativeDate | null | undefined;
|
|
302
|
+
waitingActionId?: string | null | undefined;
|
|
303
|
+
objToCheck?: any;
|
|
304
|
+
responseActionId?: string | null | undefined;
|
|
305
|
+
inputs?: any;
|
|
306
|
+
errorCode?: string | null | undefined;
|
|
307
|
+
watched?: any;
|
|
308
|
+
failedActionId?: string | null | undefined;
|
|
309
|
+
failedActionType?: string | null | undefined;
|
|
310
|
+
parentExecutionId?: string | null | undefined;
|
|
311
|
+
}> & {
|
|
312
|
+
_id: import("mongoose").Types.ObjectId;
|
|
313
|
+
} & {
|
|
314
|
+
__v: number;
|
|
315
|
+
}>;
|
|
316
|
+
//# sourceMappingURL=executions.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"executions.d.ts","sourceRoot":"../../../../../../src/core-modules/automations/definitions","sources":["executions.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,sCAAmC;AACzD,OAAO,EAAE,QAAQ,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAE5C,MAAM,WAAW,qBAAqB;IACpC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,MAAM,CAAC,EACH,SAAS,GACT,SAAS,GACT,OAAO,GACP,SAAS,GACT,QAAQ,GACR,SAAS,GACT,SAAS,CAAC;IACd,QAAQ,EAAE,MAAM,CAAC;IACjB,UAAU,EAAE,MAAM,CAAC;IACnB,YAAY,CAAC,EAAE,GAAG,CAAC;IACnB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,MAAM,CAAC,EAAE,GAAG,CAAC;IAEb,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB,UAAU,CAAC,EAAE,MAAM,CAAC;IAEpB,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAG1B,KAAK,CAAC,EAAE,MAAM,CAAC;IAGf,QAAQ,CAAC,EAAE,IAAI,GAAG,MAAM,CAAC;IAEzB,SAAS,CAAC,EAAE,IAAI,GAAG,MAAM,CAAC;CAC3B;AAED,MAAM,WAAW,oBAAoB;IACnC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,YAAY,EAAE,MAAM,CAAC;IACrB,SAAS,EAAE,MAAM,CAAC;IAClB,WAAW,EAAE,MAAM,CAAC;IACpB,aAAa,EAAE,GAAG,CAAC;IACnB;;;;;OAKG;IACH,UAAU,CAAC,EAAE,WAAW,CAAC;IACzB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,GAAG,CAAC;IAEZ,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAClC,MAAM,EAAE,MAAM,CAAC;IACf,WAAW,EAAE,MAAM,CAAC;IACpB,OAAO,CAAC,EAAE,qBAAqB,EAAE,CAAC;IAClC,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,SAAS,CAAC,EAAE,MAAM,CAAC;IAInB,uBAAuB,CAAC,EAAE,MAAM,EAAE,CAAC;IACnC,gBAAgB,CAAC,EAAE,IAAI,CAAC;IACxB,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,UAAU,CAAC,EAAE,GAAG,CAAC;IACjB,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAG1B,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,UAAU,CAAC,EAAE,MAAM,CAAC;IAGpB,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;IAC7B,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,WAAW,4BACf,SAAQ,oBAAoB,EAC1B,QAAQ;IACV,GAAG,EAAE,MAAM,CAAC;CACb;AAED,eAAO,MAAM,2BAA2B;;;;;;;;CASvC,CAAC;AAiCF,eAAO,MAAM,yBAAyB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAiCpC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"../../../../../../src/core-modules/automations/definitions","sources":["index.ts"],"names":[],"mappings":"AAAA,iCAA8B;AAC9B,gCAA6B;AAC7B,8BAA2B"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
export * from "./utils.js";
|
|
2
|
+
export * from "./setupAutomationProducers.js";
|
|
3
|
+
export * from "./actionErrorPolicy.js";
|
|
4
|
+
export * from "./actionOutcome.js";
|
|
5
|
+
export * from "./constants.js";
|
|
6
|
+
export * from "./types.js";
|
|
7
|
+
export * from "./definitions/index.js";
|
|
8
|
+
export * from "./outputResolvers.js";
|
|
9
|
+
export * from "./workflowValidation.js";
|
|
10
|
+
export * from "./zodTypes.js";
|
|
11
|
+
export * from "./sendAutomationMessage.js";
|
|
12
|
+
export * from "./segmentMembership.js";
|
|
13
|
+
export * from "./reEnrollment.js";
|
|
14
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"../../../../../src/core-modules/automations","sources":["index.ts"],"names":[],"mappings":"AAAA,2BAAwB;AACxB,8CAA2C;AAC3C,uCAAoC;AACpC,mCAAgC;AAChC,+BAA4B;AAC5B,2BAAwB;AACxB,uCAA8B;AAC9B,qCAAkC;AAClC,wCAAqC;AACrC,8BAA2B;AAC3B,2CAAwC;AACxC,uCAAoC;AACpC,kCAA+B"}
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
import { IAutomationExecution } from "./definitions/index.js";
|
|
2
|
+
import { AutomationConstants, IAutomationsActionConfig, IAutomationsTriggerConfig, TAutomationOutputDefinition, TAutomationRuntimeOutputDefinition } from "./types.js";
|
|
3
|
+
type TAutomationNodeConfig = IAutomationsTriggerConfig | IAutomationsActionConfig;
|
|
4
|
+
type TAutomationOutputSource = Record<string, unknown>;
|
|
5
|
+
export declare const resolveFromSourceField: (sourceField: string, resolver: (args: {
|
|
6
|
+
subdomain: string;
|
|
7
|
+
source: TAutomationOutputSource;
|
|
8
|
+
path: string;
|
|
9
|
+
value: unknown;
|
|
10
|
+
defaultValue?: unknown;
|
|
11
|
+
}) => Promise<unknown>) => ({ subdomain, source, path, defaultValue, }: {
|
|
12
|
+
subdomain: string;
|
|
13
|
+
source: TAutomationOutputSource;
|
|
14
|
+
path: string;
|
|
15
|
+
defaultValue?: unknown;
|
|
16
|
+
}) => Promise<unknown>;
|
|
17
|
+
export declare const matchAutomationResolverKey: (resolverKey: string, path: string) => boolean;
|
|
18
|
+
export declare const getValueByPath: (source: TAutomationOutputSource, path: string) => {
|
|
19
|
+
found: boolean;
|
|
20
|
+
value?: undefined;
|
|
21
|
+
} | {
|
|
22
|
+
found: boolean;
|
|
23
|
+
value: unknown;
|
|
24
|
+
};
|
|
25
|
+
/** `list.$count`: how many items a list output holds. */
|
|
26
|
+
export declare const AUTOMATION_OUTPUT_ITEM_COUNT = "$count";
|
|
27
|
+
/** Whether the trigger's own plugin lets an automation re-run on every event. */
|
|
28
|
+
export declare const isReEnrollableTrigger: (triggerType: string) => Promise<boolean>;
|
|
29
|
+
/** Whether the trigger's own plugin declared every event a new run. */
|
|
30
|
+
export declare const isReEnrollingTrigger: (triggerType: string) => Promise<boolean>;
|
|
31
|
+
/**
|
|
32
|
+
* Fills an action's inputs from the trigger that started the run, through the
|
|
33
|
+
* mapping the trigger's own plugin declared. Nothing is returned when the
|
|
34
|
+
* trigger declares no mapping for that action.
|
|
35
|
+
*/
|
|
36
|
+
export declare const resolveAutomationActionInputs: ({ subdomain, triggerType, actionType, target, }: {
|
|
37
|
+
subdomain: string;
|
|
38
|
+
triggerType: string;
|
|
39
|
+
actionType: string;
|
|
40
|
+
target: TAutomationOutputSource;
|
|
41
|
+
}) => Promise<Record<string, unknown> | undefined>;
|
|
42
|
+
export declare const resolveOutputPathsByNodeType: ({ subdomain, nodeType, source, paths, defaultValue, runtimeOutputs, }: {
|
|
43
|
+
subdomain: string;
|
|
44
|
+
nodeType: string;
|
|
45
|
+
source: TAutomationOutputSource;
|
|
46
|
+
paths: string[];
|
|
47
|
+
defaultValue?: unknown;
|
|
48
|
+
runtimeOutputs?: Record<string, TAutomationRuntimeOutputDefinition>;
|
|
49
|
+
}) => Promise<any>;
|
|
50
|
+
export declare const replaceOutputPlaceholders: ({ subdomain, execution, values, defaultValue, runtimeOutputs, keepUnresolvedPlaceholders, }: {
|
|
51
|
+
subdomain: string;
|
|
52
|
+
execution: IAutomationExecution;
|
|
53
|
+
values: Record<string, unknown>;
|
|
54
|
+
defaultValue?: unknown;
|
|
55
|
+
runtimeOutputs?: Record<string, TAutomationRuntimeOutputDefinition>;
|
|
56
|
+
keepUnresolvedPlaceholders?: boolean;
|
|
57
|
+
}) => Promise<Record<string, unknown>>;
|
|
58
|
+
export declare const getAutomationNodeType: ({ pluginName, node, kind, }: {
|
|
59
|
+
pluginName: string;
|
|
60
|
+
node: TAutomationNodeConfig;
|
|
61
|
+
kind: "trigger" | "action";
|
|
62
|
+
}) => string;
|
|
63
|
+
export declare const toTransportOutput: (output?: TAutomationRuntimeOutputDefinition) => TAutomationOutputDefinition | undefined;
|
|
64
|
+
export declare const normalizeAutomationConstantsForTransport: (pluginName: string, constants?: AutomationConstants) => AutomationConstants;
|
|
65
|
+
export declare const buildRuntimeOutputsIndex: (pluginName: string, constants?: AutomationConstants) => Record<string, TAutomationRuntimeOutputDefinition>;
|
|
66
|
+
export {};
|
|
67
|
+
//# sourceMappingURL=outputResolvers.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"outputResolvers.d.ts","sourceRoot":"../../../../../src/core-modules/automations","sources":["outputResolvers.ts"],"names":[],"mappings":"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"}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/** The re-enrollment rule that matches every new event, not a field change. */
|
|
2
|
+
export declare const AUTOMATION_RE_ENROLL_EVERY_TIME = "*";
|
|
3
|
+
type TReEnrollmentConfig = {
|
|
4
|
+
reEnrollment?: boolean;
|
|
5
|
+
reEnrollmentRules?: string[];
|
|
6
|
+
once?: boolean;
|
|
7
|
+
} | null;
|
|
8
|
+
/** Whether a trigger's config asks to run again on every event. */
|
|
9
|
+
export declare const reEnrollsEveryTime: (config?: TReEnrollmentConfig) => boolean;
|
|
10
|
+
/**
|
|
11
|
+
* Segment membership runs every time unless told otherwise. Before the shared
|
|
12
|
+
* re-enrollment setting it was told with `once`, which still counts while the
|
|
13
|
+
* automation has not been saved with the new setting.
|
|
14
|
+
*/
|
|
15
|
+
export declare const segmentMembershipRunsEveryTime: (config?: TReEnrollmentConfig) => boolean;
|
|
16
|
+
/**
|
|
17
|
+
* A rule watching one of the trigger segment's relation conditions — a sum
|
|
18
|
+
* of the customer's deals — by its place in the tree: `relation:children.0`.
|
|
19
|
+
*/
|
|
20
|
+
export declare const AUTOMATION_RE_ENROLL_RELATION_PREFIX = "relation:";
|
|
21
|
+
export declare const reEnrollmentRelationPaths: (rules?: string[]) => string[];
|
|
22
|
+
export {};
|
|
23
|
+
//# sourceMappingURL=reEnrollment.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"reEnrollment.d.ts","sourceRoot":"../../../../../src/core-modules/automations","sources":["reEnrollment.ts"],"names":[],"mappings":"AAAA,+EAA+E;AAC/E,eAAO,MAAM,+BAA+B,MAAM,CAAC;AAEnD,KAAK,mBAAmB,GAAG;IACzB,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,iBAAiB,CAAC,EAAE,MAAM,EAAE,CAAC;IAC7B,IAAI,CAAC,EAAE,OAAO,CAAC;CAChB,GAAG,IAAI,CAAC;AAET,mEAAmE;AACnE,eAAO,MAAM,kBAAkB,GAAI,SAAS,mBAAmB,YAEQ,CAAC;AAExE;;;;GAIG;AACH,eAAO,MAAM,8BAA8B,GAAI,SAAS,mBAAmB,YAG3C,CAAC;AAEjC;;;GAGG;AACH,eAAO,MAAM,oCAAoC,cAAc,CAAC;AAEhE,eAAO,MAAM,yBAAyB,GAAI,QAAO,MAAM,EAAO,aAGa,CAAC"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { SegmentMembershipTransition } from "../segments/types.js";
|
|
2
|
+
/**
|
|
3
|
+
* A trigger that fires when a record enters or leaves a materialized segment.
|
|
4
|
+
* Its type stays the record's own type, so every action reads the target as
|
|
5
|
+
* usual; the marker and the two exits live in the config.
|
|
6
|
+
*/
|
|
7
|
+
export declare const AUTOMATION_SEGMENT_MEMBERSHIP_EVENT = "segmentMembership";
|
|
8
|
+
export declare const AUTOMATION_SEGMENT_MEMBERSHIP_FOLKS: readonly ["joined", "left"];
|
|
9
|
+
export type TAutomationSegmentMembershipFolk = (typeof AUTOMATION_SEGMENT_MEMBERSHIP_FOLKS)[number];
|
|
10
|
+
export type TAutomationSegmentMembershipJob = {
|
|
11
|
+
contentType: string;
|
|
12
|
+
transitions: SegmentMembershipTransition[];
|
|
13
|
+
};
|
|
14
|
+
export declare const isSegmentMembershipTrigger: (trigger?: {
|
|
15
|
+
config?: Record<string, any>;
|
|
16
|
+
}) => boolean;
|
|
17
|
+
/** Hands the segment worker's joins and leaves to the automations service. */
|
|
18
|
+
export declare const sendSegmentMembershipToAutomations: (subdomain: string, data: TAutomationSegmentMembershipJob) => Promise<void | import("bullmq").Job<any, any, string>>;
|
|
19
|
+
//# sourceMappingURL=segmentMembership.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"segmentMembership.d.ts","sourceRoot":"../../../../../src/core-modules/automations","sources":["segmentMembership.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,2BAA2B,EAAE,6BAA0B;AAEhE;;;;GAIG;AACH,eAAO,MAAM,mCAAmC,sBAAsB,CAAC;AAEvE,eAAO,MAAM,mCAAmC,6BAA8B,CAAC;AAE/E,MAAM,MAAM,gCAAgC,GAC1C,CAAC,OAAO,mCAAmC,CAAC,CAAC,MAAM,CAAC,CAAC;AAEvD,MAAM,MAAM,+BAA+B,GAAG;IAC5C,WAAW,EAAE,MAAM,CAAC;IACpB,WAAW,EAAE,2BAA2B,EAAE,CAAC;CAC5C,CAAC;AAEF,eAAO,MAAM,0BAA0B,GAAI,UAAU;IACnD,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;CAC9B,YAAmE,CAAC;AAErE,8EAA8E;AAC9E,eAAO,MAAM,kCAAkC,GAC7C,WAAW,MAAM,EACjB,MAAM,+BAA+B,2DAMjC,CAAC"}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { TCreatedVia } from "../../core-types/common.js";
|
|
2
|
+
import type { DefaultJobOptions } from 'bullmq';
|
|
3
|
+
type TSendAutomationTriggerProps = {
|
|
4
|
+
transport?: 'bullmq' | 'trpc';
|
|
5
|
+
jobOptions?: DefaultJobOptions;
|
|
6
|
+
};
|
|
7
|
+
export declare const sendAutomationTrigger: (subdomain: string, { type, targets, repeatOptions, recordType, eventUpdateDescription, }: {
|
|
8
|
+
type: string;
|
|
9
|
+
targets: any;
|
|
10
|
+
repeatOptions?: {
|
|
11
|
+
executionId: string;
|
|
12
|
+
actionId: string;
|
|
13
|
+
optionalConnectId?: string;
|
|
14
|
+
};
|
|
15
|
+
recordType?: "new" | "existing";
|
|
16
|
+
eventUpdateDescription?: Record<string, any>;
|
|
17
|
+
}, { transport, jobOptions }?: TSendAutomationTriggerProps) => void;
|
|
18
|
+
/**
|
|
19
|
+
* Runs one named automation against one target the caller already chose.
|
|
20
|
+
*
|
|
21
|
+
* Unlike `sendAutomationTrigger`, which announces an event and lets the
|
|
22
|
+
* service decide which automations enrol which targets, this addresses an
|
|
23
|
+
* automation directly. The caller is responsible for choosing the target and
|
|
24
|
+
* for its own idempotency.
|
|
25
|
+
*/
|
|
26
|
+
export declare const sendAutomationRun: (subdomain: string, { automationId, target, triggerId, createdVia, }: {
|
|
27
|
+
automationId: string;
|
|
28
|
+
target: Record<string, any>;
|
|
29
|
+
triggerId?: string;
|
|
30
|
+
/**
|
|
31
|
+
* What is asking for this run — the caller's own configuration and whoever
|
|
32
|
+
* set it going. Only the caller knows: to the automations service this is
|
|
33
|
+
* just an automation being addressed.
|
|
34
|
+
*/
|
|
35
|
+
createdVia?: TCreatedVia;
|
|
36
|
+
}, { transport, jobOptions }?: TSendAutomationTriggerProps) => void;
|
|
37
|
+
export type TDeferredCompletion = {
|
|
38
|
+
executionId: string;
|
|
39
|
+
actionId: string;
|
|
40
|
+
jobId: string;
|
|
41
|
+
status: 'success' | 'error' | 'dropped';
|
|
42
|
+
result?: any;
|
|
43
|
+
};
|
|
44
|
+
/**
|
|
45
|
+
* Reports a deferred action back to the automations service. The plugin that
|
|
46
|
+
* queued the work owns the callback, so this is the other half of the marker
|
|
47
|
+
* returned from `receiveActions`.
|
|
48
|
+
*/
|
|
49
|
+
export declare const sendAutomationDeferredCompletion: (subdomain: string, completion: TDeferredCompletion) => Promise<void>;
|
|
50
|
+
export {};
|
|
51
|
+
//# sourceMappingURL=sendAutomationMessage.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sendAutomationMessage.d.ts","sourceRoot":"../../../../../src/core-modules/automations","sources":["sendAutomationMessage.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,mCAAgC;AAEtD,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,QAAQ,CAAC;AAQhD,KAAK,2BAA2B,GAAG;IACjC,SAAS,CAAC,EAAE,QAAQ,GAAG,MAAM,CAAC;IAC9B,UAAU,CAAC,EAAE,iBAAiB,CAAC;CAChC,CAAC;AAEF,eAAO,MAAM,qBAAqB,GAChC,WAAW,MAAM,EACjB,uEAMG;IACD,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,GAAG,CAAC;IACb,aAAa,CAAC,EAAE;QACd,WAAW,EAAE,MAAM,CAAC;QACpB,QAAQ,EAAE,MAAM,CAAC;QACjB,iBAAiB,CAAC,EAAE,MAAM,CAAC;KAC5B,CAAC;IACF,UAAU,CAAC,EAAE,KAAK,GAAG,UAAU,CAAC;IAChC,sBAAsB,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;CAC9C,EACD,4BAAsC,2BAAgC,KACrE,IAgEF,CAAC;AAEF;;;;;;;GAOG;AACH,eAAO,MAAM,iBAAiB,GAC5B,WAAW,MAAM,EACjB,kDAKG;IACD,YAAY,EAAE,MAAM,CAAC;IACrB,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;IAC5B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;;;OAIG;IACH,UAAU,CAAC,EAAE,WAAW,CAAC;CAC1B,EACD,4BAAsC,2BAAgC,KACrE,IA+CF,CAAC;AAEF,MAAM,MAAM,mBAAmB,GAAG;IAChC,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,EAAE,MAAM,CAAC;IACjB,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,SAAS,GAAG,OAAO,GAAG,SAAS,CAAC;IACxC,MAAM,CAAC,EAAE,GAAG,CAAC;CACd,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,gCAAgC,GAC3C,WAAW,MAAM,EACjB,YAAY,mBAAmB,KAC9B,OAAO,CAAC,IAAI,CAyBd,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"setupAutomationProducers.d.ts","sourceRoot":"../../../../../src/core-modules/automations","sources":["setupAutomationProducers.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,OAAO,EAAE,MAAM,SAAS,CAAC;AAUlC,OAAO,EACL,iBAAiB,EAGlB,mBAAgB;AA0DjB,eAAO,MAAM,gBAAgB,GAC3B,KAAK,OAAO,EACZ,YAAY,MAAM,EAClB,QAAQ,iBAAiB,kBA6G1B,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"typeUtils.d.ts","sourceRoot":"../../../../../src/core-modules/automations","sources":["typeUtils.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,SAAS,GAAI,MAAM,MAAM,aAErC,CAAC"}
|