sendwend 0.0.0-stage → 12.7.3
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 +21 -0
- package/README.md +2082 -2
- package/dist/_virtual/_rolldown/runtime.cjs +22 -0
- package/dist/apns-relay.cjs +91 -0
- package/dist/apns-relay.cjs.map +1 -0
- package/dist/apns-relay.d.cts +26 -0
- package/dist/apns-relay.d.cts.map +1 -0
- package/dist/apns-relay.d.mts +26 -0
- package/dist/apns-relay.d.mts.map +1 -0
- package/dist/apns-relay.mjs +90 -0
- package/dist/apns-relay.mjs.map +1 -0
- package/dist/apns.cjs +215 -0
- package/dist/apns.cjs.map +1 -0
- package/dist/apns.d.cts +110 -0
- package/dist/apns.d.cts.map +1 -0
- package/dist/apns.d.mts +110 -0
- package/dist/apns.d.mts.map +1 -0
- package/dist/apns.mjs +207 -0
- package/dist/apns.mjs.map +1 -0
- package/dist/aws/engine-step.cjs +105 -0
- package/dist/aws/engine-step.cjs.map +1 -0
- package/dist/aws/engine-step.d.cts +42 -0
- package/dist/aws/engine-step.d.cts.map +1 -0
- package/dist/aws/engine-step.d.mts +42 -0
- package/dist/aws/engine-step.d.mts.map +1 -0
- package/dist/aws/engine-step.mjs +103 -0
- package/dist/aws/engine-step.mjs.map +1 -0
- package/dist/aws/function-url.cjs +53 -0
- package/dist/aws/function-url.cjs.map +1 -0
- package/dist/aws/function-url.d.cts +36 -0
- package/dist/aws/function-url.d.cts.map +1 -0
- package/dist/aws/function-url.d.mts +36 -0
- package/dist/aws/function-url.d.mts.map +1 -0
- package/dist/aws/function-url.mjs +50 -0
- package/dist/aws/function-url.mjs.map +1 -0
- package/dist/aws/index.cjs +232 -0
- package/dist/aws/index.cjs.map +1 -0
- package/dist/aws/index.d.cts +73 -0
- package/dist/aws/index.d.cts.map +1 -0
- package/dist/aws/index.d.mts +73 -0
- package/dist/aws/index.d.mts.map +1 -0
- package/dist/aws/index.mjs +218 -0
- package/dist/aws/index.mjs.map +1 -0
- package/dist/aws/instances.cjs +218 -0
- package/dist/aws/instances.cjs.map +1 -0
- package/dist/aws/instances.d.cts +102 -0
- package/dist/aws/instances.d.cts.map +1 -0
- package/dist/aws/instances.d.mts +102 -0
- package/dist/aws/instances.d.mts.map +1 -0
- package/dist/aws/instances.mjs +214 -0
- package/dist/aws/instances.mjs.map +1 -0
- package/dist/aws/lambda-api.cjs +86 -0
- package/dist/aws/lambda-api.cjs.map +1 -0
- package/dist/aws/lambda-api.d.cts +41 -0
- package/dist/aws/lambda-api.d.cts.map +1 -0
- package/dist/aws/lambda-api.d.mts +41 -0
- package/dist/aws/lambda-api.d.mts.map +1 -0
- package/dist/aws/lambda-api.mjs +85 -0
- package/dist/aws/lambda-api.mjs.map +1 -0
- package/dist/client.cjs +216 -0
- package/dist/client.cjs.map +1 -0
- package/dist/client.d.cts +193 -0
- package/dist/client.d.cts.map +1 -0
- package/dist/client.d.mts +193 -0
- package/dist/client.d.mts.map +1 -0
- package/dist/client.mjs +212 -0
- package/dist/client.mjs.map +1 -0
- package/dist/cloudflare/bindings.cjs +49 -0
- package/dist/cloudflare/bindings.cjs.map +1 -0
- package/dist/cloudflare/bindings.d.cts +31 -0
- package/dist/cloudflare/bindings.d.cts.map +1 -0
- package/dist/cloudflare/bindings.d.mts +31 -0
- package/dist/cloudflare/bindings.d.mts.map +1 -0
- package/dist/cloudflare/bindings.mjs +46 -0
- package/dist/cloudflare/bindings.mjs.map +1 -0
- package/dist/cloudflare/index.cjs +73 -0
- package/dist/cloudflare/index.d.cts +25 -0
- package/dist/cloudflare/index.d.mts +25 -0
- package/dist/cloudflare/index.mjs +20 -0
- package/dist/cloudflare/runner.cjs +200 -0
- package/dist/cloudflare/runner.cjs.map +1 -0
- package/dist/cloudflare/runner.d.cts +83 -0
- package/dist/cloudflare/runner.d.cts.map +1 -0
- package/dist/cloudflare/runner.d.mts +83 -0
- package/dist/cloudflare/runner.d.mts.map +1 -0
- package/dist/cloudflare/runner.mjs +199 -0
- package/dist/cloudflare/runner.mjs.map +1 -0
- package/dist/cloudflare/worker.cjs +106 -0
- package/dist/cloudflare/worker.cjs.map +1 -0
- package/dist/cloudflare/worker.d.cts +52 -0
- package/dist/cloudflare/worker.d.cts.map +1 -0
- package/dist/cloudflare/worker.d.mts +52 -0
- package/dist/cloudflare/worker.d.mts.map +1 -0
- package/dist/cloudflare/worker.mjs +104 -0
- package/dist/cloudflare/worker.mjs.map +1 -0
- package/dist/cloudflare/workers.d.cjs +0 -0
- package/dist/cloudflare/workers.d.cts +42 -0
- package/dist/cloudflare/workers.d.cts.map +1 -0
- package/dist/cloudflare/workers.d.mts +42 -0
- package/dist/cloudflare/workers.d.mts.map +1 -0
- package/dist/config.cjs +257 -0
- package/dist/config.cjs.map +1 -0
- package/dist/config.d.cts +184 -0
- package/dist/config.d.cts.map +1 -0
- package/dist/config.d.mts +184 -0
- package/dist/config.d.mts.map +1 -0
- package/dist/config.mjs +246 -0
- package/dist/config.mjs.map +1 -0
- package/dist/contract.cjs +222 -0
- package/dist/contract.cjs.map +1 -0
- package/dist/contract.d.cts +110 -0
- package/dist/contract.d.cts.map +1 -0
- package/dist/contract.d.mts +110 -0
- package/dist/contract.d.mts.map +1 -0
- package/dist/contract.mjs +216 -0
- package/dist/contract.mjs.map +1 -0
- package/dist/date-time.cjs +22 -0
- package/dist/date-time.cjs.map +1 -0
- package/dist/date-time.d.cts +10 -0
- package/dist/date-time.d.cts.map +1 -0
- package/dist/date-time.d.mts +10 -0
- package/dist/date-time.d.mts.map +1 -0
- package/dist/date-time.mjs +21 -0
- package/dist/date-time.mjs.map +1 -0
- package/dist/dsl/action.cjs +25 -0
- package/dist/dsl/action.cjs.map +1 -0
- package/dist/dsl/action.d.cts +63 -0
- package/dist/dsl/action.d.cts.map +1 -0
- package/dist/dsl/action.d.mts +63 -0
- package/dist/dsl/action.d.mts.map +1 -0
- package/dist/dsl/action.mjs +24 -0
- package/dist/dsl/action.mjs.map +1 -0
- package/dist/dsl/base.cjs +33 -0
- package/dist/dsl/base.cjs.map +1 -0
- package/dist/dsl/base.d.cts +43 -0
- package/dist/dsl/base.d.cts.map +1 -0
- package/dist/dsl/base.d.mts +43 -0
- package/dist/dsl/base.d.mts.map +1 -0
- package/dist/dsl/base.mjs +29 -0
- package/dist/dsl/base.mjs.map +1 -0
- package/dist/dsl/bundle.cjs +287 -0
- package/dist/dsl/bundle.cjs.map +1 -0
- package/dist/dsl/bundle.d.cts +33 -0
- package/dist/dsl/bundle.d.cts.map +1 -0
- package/dist/dsl/bundle.d.mts +33 -0
- package/dist/dsl/bundle.d.mts.map +1 -0
- package/dist/dsl/bundle.mjs +284 -0
- package/dist/dsl/bundle.mjs.map +1 -0
- package/dist/dsl/condition.cjs +200 -0
- package/dist/dsl/condition.cjs.map +1 -0
- package/dist/dsl/condition.d.cts +151 -0
- package/dist/dsl/condition.d.cts.map +1 -0
- package/dist/dsl/condition.d.mts +151 -0
- package/dist/dsl/condition.d.mts.map +1 -0
- package/dist/dsl/condition.mjs +178 -0
- package/dist/dsl/condition.mjs.map +1 -0
- package/dist/dsl/flow.cjs +335 -0
- package/dist/dsl/flow.cjs.map +1 -0
- package/dist/dsl/flow.d.cts +278 -0
- package/dist/dsl/flow.d.cts.map +1 -0
- package/dist/dsl/flow.d.mts +278 -0
- package/dist/dsl/flow.d.mts.map +1 -0
- package/dist/dsl/flow.mjs +331 -0
- package/dist/dsl/flow.mjs.map +1 -0
- package/dist/dsl/index.cjs +37 -0
- package/dist/dsl/index.d.cts +34 -0
- package/dist/dsl/index.d.mts +34 -0
- package/dist/dsl/index.mjs +9 -0
- package/dist/dsl/refs.cjs +101 -0
- package/dist/dsl/refs.cjs.map +1 -0
- package/dist/dsl/refs.d.cts +127 -0
- package/dist/dsl/refs.d.cts.map +1 -0
- package/dist/dsl/refs.d.mts +127 -0
- package/dist/dsl/refs.d.mts.map +1 -0
- package/dist/dsl/refs.mjs +93 -0
- package/dist/dsl/refs.mjs.map +1 -0
- package/dist/dsl/template.cjs +19 -0
- package/dist/dsl/template.cjs.map +1 -0
- package/dist/dsl/template.d.cts +30 -0
- package/dist/dsl/template.d.cts.map +1 -0
- package/dist/dsl/template.d.mts +30 -0
- package/dist/dsl/template.d.mts.map +1 -0
- package/dist/dsl/template.mjs +18 -0
- package/dist/dsl/template.mjs.map +1 -0
- package/dist/dsl/trigger.cjs +53 -0
- package/dist/dsl/trigger.cjs.map +1 -0
- package/dist/dsl/trigger.d.cts +112 -0
- package/dist/dsl/trigger.d.cts.map +1 -0
- package/dist/dsl/trigger.d.mts +112 -0
- package/dist/dsl/trigger.d.mts.map +1 -0
- package/dist/dsl/trigger.mjs +52 -0
- package/dist/dsl/trigger.mjs.map +1 -0
- package/dist/dsl/workflow.cjs +143 -0
- package/dist/dsl/workflow.cjs.map +1 -0
- package/dist/dsl/workflow.d.cts +88 -0
- package/dist/dsl/workflow.d.cts.map +1 -0
- package/dist/dsl/workflow.d.mts +88 -0
- package/dist/dsl/workflow.d.mts.map +1 -0
- package/dist/dsl/workflow.mjs +142 -0
- package/dist/dsl/workflow.mjs.map +1 -0
- package/dist/email-context.cjs +28 -0
- package/dist/email-context.cjs.map +1 -0
- package/dist/email-context.d.cts +9 -0
- package/dist/email-context.d.cts.map +1 -0
- package/dist/email-context.d.mts +9 -0
- package/dist/email-context.d.mts.map +1 -0
- package/dist/email-context.mjs +26 -0
- package/dist/email-context.mjs.map +1 -0
- package/dist/email-sender.cjs +93 -0
- package/dist/email-sender.cjs.map +1 -0
- package/dist/email-sender.d.cts +88 -0
- package/dist/email-sender.d.cts.map +1 -0
- package/dist/email-sender.d.mts +88 -0
- package/dist/email-sender.d.mts.map +1 -0
- package/dist/email-sender.mjs +90 -0
- package/dist/email-sender.mjs.map +1 -0
- package/dist/email.cjs +73 -0
- package/dist/email.cjs.map +1 -0
- package/dist/email.d.cts +59 -0
- package/dist/email.d.cts.map +1 -0
- package/dist/email.d.mts +59 -0
- package/dist/email.d.mts.map +1 -0
- package/dist/email.mjs +68 -0
- package/dist/email.mjs.map +1 -0
- package/dist/engine/actions.cjs +19 -0
- package/dist/engine/actions.cjs.map +1 -0
- package/dist/engine/actions.d.cts +27 -0
- package/dist/engine/actions.d.cts.map +1 -0
- package/dist/engine/actions.d.mts +27 -0
- package/dist/engine/actions.d.mts.map +1 -0
- package/dist/engine/actions.mjs +18 -0
- package/dist/engine/actions.mjs.map +1 -0
- package/dist/engine/bucket.cjs +71 -0
- package/dist/engine/bucket.cjs.map +1 -0
- package/dist/engine/bucket.d.cts +30 -0
- package/dist/engine/bucket.d.cts.map +1 -0
- package/dist/engine/bucket.d.mts +30 -0
- package/dist/engine/bucket.d.mts.map +1 -0
- package/dist/engine/bucket.mjs +68 -0
- package/dist/engine/bucket.mjs.map +1 -0
- package/dist/engine/condition.cjs +199 -0
- package/dist/engine/condition.cjs.map +1 -0
- package/dist/engine/condition.d.cts +76 -0
- package/dist/engine/condition.d.cts.map +1 -0
- package/dist/engine/condition.d.mts +76 -0
- package/dist/engine/condition.d.mts.map +1 -0
- package/dist/engine/condition.mjs +192 -0
- package/dist/engine/condition.mjs.map +1 -0
- package/dist/engine/duration.cjs +33 -0
- package/dist/engine/duration.cjs.map +1 -0
- package/dist/engine/duration.d.cts +3 -0
- package/dist/engine/duration.d.cts.map +1 -0
- package/dist/engine/duration.d.mts +3 -0
- package/dist/engine/duration.d.mts.map +1 -0
- package/dist/engine/duration.mjs +32 -0
- package/dist/engine/duration.mjs.map +1 -0
- package/dist/engine/index.cjs +33 -0
- package/dist/engine/index.d.cts +10 -0
- package/dist/engine/index.d.mts +10 -0
- package/dist/engine/index.mjs +9 -0
- package/dist/engine/interpreter.cjs +613 -0
- package/dist/engine/interpreter.cjs.map +1 -0
- package/dist/engine/interpreter.d.cts +4 -0
- package/dist/engine/interpreter.d.cts.map +1 -0
- package/dist/engine/interpreter.d.mts +4 -0
- package/dist/engine/interpreter.d.mts.map +1 -0
- package/dist/engine/interpreter.mjs +612 -0
- package/dist/engine/interpreter.mjs.map +1 -0
- package/dist/engine/ports.cjs +0 -0
- package/dist/engine/ports.d.cts +373 -0
- package/dist/engine/ports.d.cts.map +1 -0
- package/dist/engine/ports.d.mts +373 -0
- package/dist/engine/ports.d.mts.map +1 -0
- package/dist/engine/ports.mjs +1 -0
- package/dist/engine/recipient.cjs +22 -0
- package/dist/engine/recipient.cjs.map +1 -0
- package/dist/engine/recipient.d.cts +11 -0
- package/dist/engine/recipient.d.cts.map +1 -0
- package/dist/engine/recipient.d.mts +11 -0
- package/dist/engine/recipient.d.mts.map +1 -0
- package/dist/engine/recipient.mjs +21 -0
- package/dist/engine/recipient.mjs.map +1 -0
- package/dist/engine/retry.cjs +106 -0
- package/dist/engine/retry.cjs.map +1 -0
- package/dist/engine/retry.d.cts +73 -0
- package/dist/engine/retry.d.cts.map +1 -0
- package/dist/engine/retry.d.mts +73 -0
- package/dist/engine/retry.d.mts.map +1 -0
- package/dist/engine/retry.mjs +98 -0
- package/dist/engine/retry.mjs.map +1 -0
- package/dist/engine/time-scale.cjs +153 -0
- package/dist/engine/time-scale.cjs.map +1 -0
- package/dist/engine/time-scale.d.cts +41 -0
- package/dist/engine/time-scale.d.cts.map +1 -0
- package/dist/engine/time-scale.d.mts +41 -0
- package/dist/engine/time-scale.d.mts.map +1 -0
- package/dist/engine/time-scale.mjs +150 -0
- package/dist/engine/time-scale.mjs.map +1 -0
- package/dist/engine/time-window.cjs +148 -0
- package/dist/engine/time-window.cjs.map +1 -0
- package/dist/engine/time-window.d.cts +20 -0
- package/dist/engine/time-window.d.cts.map +1 -0
- package/dist/engine/time-window.d.mts +20 -0
- package/dist/engine/time-window.d.mts.map +1 -0
- package/dist/engine/time-window.mjs +146 -0
- package/dist/engine/time-window.mjs.map +1 -0
- package/dist/fcm.cjs +208 -0
- package/dist/fcm.cjs.map +1 -0
- package/dist/fcm.d.cts +89 -0
- package/dist/fcm.d.cts.map +1 -0
- package/dist/fcm.d.mts +89 -0
- package/dist/fcm.d.mts.map +1 -0
- package/dist/fcm.mjs +202 -0
- package/dist/fcm.mjs.map +1 -0
- package/dist/hash.cjs +244 -0
- package/dist/hash.cjs.map +1 -0
- package/dist/hash.d.cts +28 -0
- package/dist/hash.d.cts.map +1 -0
- package/dist/hash.d.mts +28 -0
- package/dist/hash.d.mts.map +1 -0
- package/dist/hash.mjs +238 -0
- package/dist/hash.mjs.map +1 -0
- package/dist/host/auth.cjs +48 -0
- package/dist/host/auth.cjs.map +1 -0
- package/dist/host/auth.d.cts +33 -0
- package/dist/host/auth.d.cts.map +1 -0
- package/dist/host/auth.d.mts +33 -0
- package/dist/host/auth.d.mts.map +1 -0
- package/dist/host/auth.mjs +45 -0
- package/dist/host/auth.mjs.map +1 -0
- package/dist/host/batch.cjs +178 -0
- package/dist/host/batch.cjs.map +1 -0
- package/dist/host/batch.d.cts +92 -0
- package/dist/host/batch.d.cts.map +1 -0
- package/dist/host/batch.d.mts +92 -0
- package/dist/host/batch.d.mts.map +1 -0
- package/dist/host/batch.mjs +169 -0
- package/dist/host/batch.mjs.map +1 -0
- package/dist/host/channels.cjs +256 -0
- package/dist/host/channels.cjs.map +1 -0
- package/dist/host/channels.d.cts +66 -0
- package/dist/host/channels.d.cts.map +1 -0
- package/dist/host/channels.d.mts +66 -0
- package/dist/host/channels.d.mts.map +1 -0
- package/dist/host/channels.mjs +252 -0
- package/dist/host/channels.mjs.map +1 -0
- package/dist/host/execute.cjs +102 -0
- package/dist/host/execute.cjs.map +1 -0
- package/dist/host/execute.d.cts +38 -0
- package/dist/host/execute.d.cts.map +1 -0
- package/dist/host/execute.d.mts +38 -0
- package/dist/host/execute.d.mts.map +1 -0
- package/dist/host/execute.mjs +101 -0
- package/dist/host/execute.mjs.map +1 -0
- package/dist/host/fresh-read.cjs +29 -0
- package/dist/host/fresh-read.cjs.map +1 -0
- package/dist/host/fresh-read.d.cts +16 -0
- package/dist/host/fresh-read.d.cts.map +1 -0
- package/dist/host/fresh-read.d.mts +16 -0
- package/dist/host/fresh-read.d.mts.map +1 -0
- package/dist/host/fresh-read.mjs +28 -0
- package/dist/host/fresh-read.mjs.map +1 -0
- package/dist/host/http.cjs +393 -0
- package/dist/host/http.cjs.map +1 -0
- package/dist/host/http.d.cts +61 -0
- package/dist/host/http.d.cts.map +1 -0
- package/dist/host/http.d.mts +61 -0
- package/dist/host/http.d.mts.map +1 -0
- package/dist/host/http.mjs +389 -0
- package/dist/host/http.mjs.map +1 -0
- package/dist/host/ingest.cjs +1210 -0
- package/dist/host/ingest.cjs.map +1 -0
- package/dist/host/ingest.d.cts +497 -0
- package/dist/host/ingest.d.cts.map +1 -0
- package/dist/host/ingest.d.mts +497 -0
- package/dist/host/ingest.d.mts.map +1 -0
- package/dist/host/ingest.mjs +1172 -0
- package/dist/host/ingest.mjs.map +1 -0
- package/dist/host/journey-host.cjs +223 -0
- package/dist/host/journey-host.cjs.map +1 -0
- package/dist/host/journey-host.d.cts +118 -0
- package/dist/host/journey-host.d.cts.map +1 -0
- package/dist/host/journey-host.d.mts +118 -0
- package/dist/host/journey-host.d.mts.map +1 -0
- package/dist/host/journey-host.mjs +219 -0
- package/dist/host/journey-host.mjs.map +1 -0
- package/dist/host/platform.cjs +20 -0
- package/dist/host/platform.cjs.map +1 -0
- package/dist/host/platform.d.cts +120 -0
- package/dist/host/platform.d.cts.map +1 -0
- package/dist/host/platform.d.mts +120 -0
- package/dist/host/platform.d.mts.map +1 -0
- package/dist/host/platform.mjs +18 -0
- package/dist/host/platform.mjs.map +1 -0
- package/dist/host/senders.cjs +71 -0
- package/dist/host/senders.cjs.map +1 -0
- package/dist/host/senders.d.cts +34 -0
- package/dist/host/senders.d.cts.map +1 -0
- package/dist/host/senders.d.mts +34 -0
- package/dist/host/senders.d.mts.map +1 -0
- package/dist/host/senders.mjs +67 -0
- package/dist/host/senders.mjs.map +1 -0
- package/dist/host/workflow-cache.cjs +47 -0
- package/dist/host/workflow-cache.cjs.map +1 -0
- package/dist/host/workflow-cache.d.cts +21 -0
- package/dist/host/workflow-cache.d.cts.map +1 -0
- package/dist/host/workflow-cache.d.mts +21 -0
- package/dist/host/workflow-cache.d.mts.map +1 -0
- package/dist/host/workflow-cache.mjs +46 -0
- package/dist/host/workflow-cache.mjs.map +1 -0
- package/dist/http2-client.cjs +89 -0
- package/dist/http2-client.cjs.map +1 -0
- package/dist/http2-client.d.cts +45 -0
- package/dist/http2-client.d.cts.map +1 -0
- package/dist/http2-client.d.mts +45 -0
- package/dist/http2-client.d.mts.map +1 -0
- package/dist/http2-client.mjs +87 -0
- package/dist/http2-client.mjs.map +1 -0
- package/dist/index.cjs +130 -0
- package/dist/index.d.cts +21 -0
- package/dist/index.d.mts +21 -0
- package/dist/index.mjs +20 -0
- package/dist/inflight.cjs +116 -0
- package/dist/inflight.cjs.map +1 -0
- package/dist/inflight.d.cts +49 -0
- package/dist/inflight.d.cts.map +1 -0
- package/dist/inflight.d.mts +49 -0
- package/dist/inflight.d.mts.map +1 -0
- package/dist/inflight.mjs +113 -0
- package/dist/inflight.mjs.map +1 -0
- package/dist/ir.cjs +429 -0
- package/dist/ir.cjs.map +1 -0
- package/dist/ir.d.cts +593 -0
- package/dist/ir.d.cts.map +1 -0
- package/dist/ir.d.mts +593 -0
- package/dist/ir.d.mts.map +1 -0
- package/dist/ir.mjs +404 -0
- package/dist/ir.mjs.map +1 -0
- package/dist/jwt.cjs +17 -0
- package/dist/jwt.cjs.map +1 -0
- package/dist/jwt.d.cts +7 -0
- package/dist/jwt.d.cts.map +1 -0
- package/dist/jwt.d.mts +7 -0
- package/dist/jwt.d.mts.map +1 -0
- package/dist/jwt.mjs +15 -0
- package/dist/jwt.mjs.map +1 -0
- package/dist/node/index.cjs +231 -0
- package/dist/node/index.cjs.map +1 -0
- package/dist/node/index.d.cts +59 -0
- package/dist/node/index.d.cts.map +1 -0
- package/dist/node/index.d.mts +59 -0
- package/dist/node/index.d.mts.map +1 -0
- package/dist/node/index.mjs +225 -0
- package/dist/node/index.mjs.map +1 -0
- package/dist/node/runs.cjs +222 -0
- package/dist/node/runs.cjs.map +1 -0
- package/dist/node/runs.d.cts +93 -0
- package/dist/node/runs.d.cts.map +1 -0
- package/dist/node/runs.d.mts +93 -0
- package/dist/node/runs.d.mts.map +1 -0
- package/dist/node/runs.mjs +221 -0
- package/dist/node/runs.mjs.map +1 -0
- package/dist/node/runtime.cjs +351 -0
- package/dist/node/runtime.cjs.map +1 -0
- package/dist/node/runtime.d.cts +96 -0
- package/dist/node/runtime.d.cts.map +1 -0
- package/dist/node/runtime.d.mts +96 -0
- package/dist/node/runtime.d.mts.map +1 -0
- package/dist/node/runtime.mjs +348 -0
- package/dist/node/runtime.mjs.map +1 -0
- package/dist/plan.cjs +221 -0
- package/dist/plan.cjs.map +1 -0
- package/dist/plan.d.cts +68 -0
- package/dist/plan.d.cts.map +1 -0
- package/dist/plan.d.mts +68 -0
- package/dist/plan.d.mts.map +1 -0
- package/dist/plan.mjs +218 -0
- package/dist/plan.mjs.map +1 -0
- package/dist/postgres-js.cjs +51 -0
- package/dist/postgres-js.cjs.map +1 -0
- package/dist/postgres-js.d.cts +32 -0
- package/dist/postgres-js.d.cts.map +1 -0
- package/dist/postgres-js.d.mts +32 -0
- package/dist/postgres-js.d.mts.map +1 -0
- package/dist/postgres-js.mjs +46 -0
- package/dist/postgres-js.mjs.map +1 -0
- package/dist/provenance.cjs +66 -0
- package/dist/provenance.cjs.map +1 -0
- package/dist/provenance.d.cts +40 -0
- package/dist/provenance.d.cts.map +1 -0
- package/dist/provenance.d.mts +40 -0
- package/dist/provenance.d.mts.map +1 -0
- package/dist/provenance.mjs +64 -0
- package/dist/provenance.mjs.map +1 -0
- package/dist/push.cjs +11 -0
- package/dist/push.cjs.map +1 -0
- package/dist/push.d.cts +14 -0
- package/dist/push.d.cts.map +1 -0
- package/dist/push.d.mts +14 -0
- package/dist/push.d.mts.map +1 -0
- package/dist/push.mjs +10 -0
- package/dist/push.mjs.map +1 -0
- package/dist/react-email.cjs +56 -0
- package/dist/react-email.cjs.map +1 -0
- package/dist/react-email.d.cts +5 -0
- package/dist/react-email.d.cts.map +1 -0
- package/dist/react-email.d.mts +5 -0
- package/dist/react-email.d.mts.map +1 -0
- package/dist/react-email.mjs +55 -0
- package/dist/react-email.mjs.map +1 -0
- package/dist/reporting/classify.cjs +46 -0
- package/dist/reporting/classify.cjs.map +1 -0
- package/dist/reporting/classify.d.cts +65 -0
- package/dist/reporting/classify.d.cts.map +1 -0
- package/dist/reporting/classify.d.mts +65 -0
- package/dist/reporting/classify.d.mts.map +1 -0
- package/dist/reporting/classify.mjs +42 -0
- package/dist/reporting/classify.mjs.map +1 -0
- package/dist/reporting/observer.cjs +137 -0
- package/dist/reporting/observer.cjs.map +1 -0
- package/dist/reporting/observer.d.cts +31 -0
- package/dist/reporting/observer.d.cts.map +1 -0
- package/dist/reporting/observer.d.mts +31 -0
- package/dist/reporting/observer.d.mts.map +1 -0
- package/dist/reporting/observer.mjs +134 -0
- package/dist/reporting/observer.mjs.map +1 -0
- package/dist/reporting/tracking.cjs +185 -0
- package/dist/reporting/tracking.cjs.map +1 -0
- package/dist/reporting/tracking.d.cts +63 -0
- package/dist/reporting/tracking.d.cts.map +1 -0
- package/dist/reporting/tracking.d.mts +63 -0
- package/dist/reporting/tracking.d.mts.map +1 -0
- package/dist/reporting/tracking.mjs +182 -0
- package/dist/reporting/tracking.mjs.map +1 -0
- package/dist/runtime.cjs +18 -0
- package/dist/runtime.cjs.map +1 -0
- package/dist/runtime.d.cts +44 -0
- package/dist/runtime.d.cts.map +1 -0
- package/dist/runtime.d.mts +44 -0
- package/dist/runtime.d.mts.map +1 -0
- package/dist/runtime.mjs +17 -0
- package/dist/runtime.mjs.map +1 -0
- package/dist/store/condition-sql.cjs +145 -0
- package/dist/store/condition-sql.cjs.map +1 -0
- package/dist/store/condition-sql.d.cts +38 -0
- package/dist/store/condition-sql.d.cts.map +1 -0
- package/dist/store/condition-sql.d.mts +38 -0
- package/dist/store/condition-sql.d.mts.map +1 -0
- package/dist/store/condition-sql.mjs +144 -0
- package/dist/store/condition-sql.mjs.map +1 -0
- package/dist/store/erasure.cjs +21 -0
- package/dist/store/erasure.cjs.map +1 -0
- package/dist/store/erasure.d.cts +16 -0
- package/dist/store/erasure.d.cts.map +1 -0
- package/dist/store/erasure.d.mts +16 -0
- package/dist/store/erasure.d.mts.map +1 -0
- package/dist/store/erasure.mjs +20 -0
- package/dist/store/erasure.mjs.map +1 -0
- package/dist/store/facts.cjs +79 -0
- package/dist/store/facts.cjs.map +1 -0
- package/dist/store/facts.d.cts +41 -0
- package/dist/store/facts.d.cts.map +1 -0
- package/dist/store/facts.d.mts +41 -0
- package/dist/store/facts.d.mts.map +1 -0
- package/dist/store/facts.mjs +77 -0
- package/dist/store/facts.mjs.map +1 -0
- package/dist/store/identity.cjs +34 -0
- package/dist/store/identity.cjs.map +1 -0
- package/dist/store/identity.d.cts +13 -0
- package/dist/store/identity.d.cts.map +1 -0
- package/dist/store/identity.d.mts +13 -0
- package/dist/store/identity.d.mts.map +1 -0
- package/dist/store/identity.mjs +30 -0
- package/dist/store/identity.mjs.map +1 -0
- package/dist/store/index.cjs +35 -0
- package/dist/store/index.cjs.map +1 -0
- package/dist/store/index.d.cts +766 -0
- package/dist/store/index.d.cts.map +1 -0
- package/dist/store/index.d.mts +766 -0
- package/dist/store/index.d.mts.map +1 -0
- package/dist/store/index.mjs +22 -0
- package/dist/store/index.mjs.map +1 -0
- package/dist/store/postgres-reporting.cjs +327 -0
- package/dist/store/postgres-reporting.cjs.map +1 -0
- package/dist/store/postgres-reporting.d.cts +95 -0
- package/dist/store/postgres-reporting.d.cts.map +1 -0
- package/dist/store/postgres-reporting.d.mts +95 -0
- package/dist/store/postgres-reporting.d.mts.map +1 -0
- package/dist/store/postgres-reporting.mjs +326 -0
- package/dist/store/postgres-reporting.mjs.map +1 -0
- package/dist/store/postgres.cjs +1173 -0
- package/dist/store/postgres.cjs.map +1 -0
- package/dist/store/postgres.d.cts +199 -0
- package/dist/store/postgres.d.cts.map +1 -0
- package/dist/store/postgres.d.mts +199 -0
- package/dist/store/postgres.d.mts.map +1 -0
- package/dist/store/postgres.mjs +1170 -0
- package/dist/store/postgres.mjs.map +1 -0
- package/dist/store/sql.cjs +24 -0
- package/dist/store/sql.cjs.map +1 -0
- package/dist/store/sql.d.cts +26 -0
- package/dist/store/sql.d.cts.map +1 -0
- package/dist/store/sql.d.mts +26 -0
- package/dist/store/sql.d.mts.map +1 -0
- package/dist/store/sql.mjs +23 -0
- package/dist/store/sql.mjs.map +1 -0
- package/dist/store/tables.cjs +660 -0
- package/dist/store/tables.cjs.map +1 -0
- package/dist/store/tables.d.cts +103 -0
- package/dist/store/tables.d.cts.map +1 -0
- package/dist/store/tables.d.mts +103 -0
- package/dist/store/tables.d.mts.map +1 -0
- package/dist/store/tables.mjs +653 -0
- package/dist/store/tables.mjs.map +1 -0
- package/dist/store/user-lock.cjs +42 -0
- package/dist/store/user-lock.cjs.map +1 -0
- package/dist/store/user-lock.d.cts +30 -0
- package/dist/store/user-lock.d.cts.map +1 -0
- package/dist/store/user-lock.d.mts +30 -0
- package/dist/store/user-lock.d.mts.map +1 -0
- package/dist/store/user-lock.mjs +39 -0
- package/dist/store/user-lock.mjs.map +1 -0
- package/dist/template-rules.cjs +94 -0
- package/dist/template-rules.cjs.map +1 -0
- package/dist/template-rules.d.cts +80 -0
- package/dist/template-rules.d.cts.map +1 -0
- package/dist/template-rules.d.mts +80 -0
- package/dist/template-rules.d.mts.map +1 -0
- package/dist/template-rules.mjs +86 -0
- package/dist/template-rules.mjs.map +1 -0
- package/dist/templates.cjs +375 -0
- package/dist/templates.cjs.map +1 -0
- package/dist/templates.d.cts +358 -0
- package/dist/templates.d.cts.map +1 -0
- package/dist/templates.d.mts +358 -0
- package/dist/templates.d.mts.map +1 -0
- package/dist/templates.mjs +353 -0
- package/dist/templates.mjs.map +1 -0
- package/dist/transports/cloudflare-email.cjs +69 -0
- package/dist/transports/cloudflare-email.cjs.map +1 -0
- package/dist/transports/cloudflare-email.d.cts +63 -0
- package/dist/transports/cloudflare-email.d.cts.map +1 -0
- package/dist/transports/cloudflare-email.d.mts +63 -0
- package/dist/transports/cloudflare-email.d.mts.map +1 -0
- package/dist/transports/cloudflare-email.mjs +67 -0
- package/dist/transports/cloudflare-email.mjs.map +1 -0
- package/dist/transports/ses.cjs +142 -0
- package/dist/transports/ses.cjs.map +1 -0
- package/dist/transports/ses.d.cts +49 -0
- package/dist/transports/ses.d.cts.map +1 -0
- package/dist/transports/ses.d.mts +49 -0
- package/dist/transports/ses.d.mts.map +1 -0
- package/dist/transports/ses.mjs +139 -0
- package/dist/transports/ses.mjs.map +1 -0
- package/dist/transports/sigv4.cjs +86 -0
- package/dist/transports/sigv4.cjs.map +1 -0
- package/dist/transports/sigv4.d.cts +25 -0
- package/dist/transports/sigv4.d.cts.map +1 -0
- package/dist/transports/sigv4.d.mts +25 -0
- package/dist/transports/sigv4.d.mts.map +1 -0
- package/dist/transports/sigv4.mjs +85 -0
- package/dist/transports/sigv4.mjs.map +1 -0
- package/dist/webhooks.cjs +97 -0
- package/dist/webhooks.cjs.map +1 -0
- package/dist/webhooks.d.cts +23 -0
- package/dist/webhooks.d.cts.map +1 -0
- package/dist/webhooks.d.mts +23 -0
- package/dist/webhooks.d.mts.map +1 -0
- package/dist/webhooks.mjs +95 -0
- package/dist/webhooks.mjs.map +1 -0
- package/dist/webpush.cjs +361 -0
- package/dist/webpush.cjs.map +1 -0
- package/dist/webpush.d.cts +135 -0
- package/dist/webpush.d.cts.map +1 -0
- package/dist/webpush.d.mts +135 -0
- package/dist/webpush.d.mts.map +1 -0
- package/dist/webpush.mjs +350 -0
- package/dist/webpush.mjs.map +1 -0
- package/package.json +279 -3
- package/src/cloudflare/workers.d.ts +44 -0
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Cohort bucketing — deterministic assignment of a user to an A/B arm.
|
|
3
|
+
*
|
|
4
|
+
* MurmurHash3 (x86, 32-bit, seed 0) over the UTF-8 bytes of the key, the same
|
|
5
|
+
* construction A/B systems like Unleash use: excellent avalanche behaviour
|
|
6
|
+
* (sequential user ids spread evenly, where FNV-1a showed low-bit bias) and a
|
|
7
|
+
* frozen, widely cross-checked algorithm. Hand-written on purpose: the engine
|
|
8
|
+
* core stays dependency-free, and the known-answer tests pin this
|
|
9
|
+
* implementation against the reference vectors — a stronger guarantee than
|
|
10
|
+
* trusting an npm package's variant.
|
|
11
|
+
*
|
|
12
|
+
* The bucket function is a permanent contract: changing it reshuffles every
|
|
13
|
+
* in-flight cohort, so it must never change once production traffic exists.
|
|
14
|
+
*/
|
|
15
|
+
/** MurmurHash3 x86 32-bit over raw bytes; seed 0. Returns an unsigned 32-bit integer. */
|
|
16
|
+
export declare function murmur3(bytes: Uint8Array, seed?: number): number;
|
|
17
|
+
/**
|
|
18
|
+
* Bucket resolution: basis points, i.e. hundredths of a percent. Weights are
|
|
19
|
+
* compared on the same integer grid (weight% × 100), so fractional splits like
|
|
20
|
+
* 33.3/33.3/33.4 are honoured exactly and the whole path stays float-free —
|
|
21
|
+
* the Optimizely/Statsig construction.
|
|
22
|
+
*/
|
|
23
|
+
export declare const BUCKET_RESOLUTION = 10000;
|
|
24
|
+
/**
|
|
25
|
+
* Map a bucketing key (`${userId}:${cohortKey}`) to [0, 10000). Keys hash
|
|
26
|
+
* their UTF-8 bytes, so results agree with any standard Murmur3 implementation
|
|
27
|
+
* regardless of the user id's alphabet.
|
|
28
|
+
*/
|
|
29
|
+
export declare function hashToBucket(input: string): number;
|
|
30
|
+
//# sourceMappingURL=bucket.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"bucket.d.cts","names":[],"sources":["../../src/engine/bucket.ts"],"mappings":";;;;;;;;;;;;;;;wBAgBgB,QAAQ,OAAO,YAAY;;;;;;;qBA6C9B;;;;;;wBAOG,aAAa"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Cohort bucketing — deterministic assignment of a user to an A/B arm.
|
|
3
|
+
*
|
|
4
|
+
* MurmurHash3 (x86, 32-bit, seed 0) over the UTF-8 bytes of the key, the same
|
|
5
|
+
* construction A/B systems like Unleash use: excellent avalanche behaviour
|
|
6
|
+
* (sequential user ids spread evenly, where FNV-1a showed low-bit bias) and a
|
|
7
|
+
* frozen, widely cross-checked algorithm. Hand-written on purpose: the engine
|
|
8
|
+
* core stays dependency-free, and the known-answer tests pin this
|
|
9
|
+
* implementation against the reference vectors — a stronger guarantee than
|
|
10
|
+
* trusting an npm package's variant.
|
|
11
|
+
*
|
|
12
|
+
* The bucket function is a permanent contract: changing it reshuffles every
|
|
13
|
+
* in-flight cohort, so it must never change once production traffic exists.
|
|
14
|
+
*/
|
|
15
|
+
/** MurmurHash3 x86 32-bit over raw bytes; seed 0. Returns an unsigned 32-bit integer. */
|
|
16
|
+
export declare function murmur3(bytes: Uint8Array, seed?: number): number;
|
|
17
|
+
/**
|
|
18
|
+
* Bucket resolution: basis points, i.e. hundredths of a percent. Weights are
|
|
19
|
+
* compared on the same integer grid (weight% × 100), so fractional splits like
|
|
20
|
+
* 33.3/33.3/33.4 are honoured exactly and the whole path stays float-free —
|
|
21
|
+
* the Optimizely/Statsig construction.
|
|
22
|
+
*/
|
|
23
|
+
export declare const BUCKET_RESOLUTION = 10000;
|
|
24
|
+
/**
|
|
25
|
+
* Map a bucketing key (`${userId}:${cohortKey}`) to [0, 10000). Keys hash
|
|
26
|
+
* their UTF-8 bytes, so results agree with any standard Murmur3 implementation
|
|
27
|
+
* regardless of the user id's alphabet.
|
|
28
|
+
*/
|
|
29
|
+
export declare function hashToBucket(input: string): number;
|
|
30
|
+
//# sourceMappingURL=bucket.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"bucket.d.mts","names":[],"sources":["../../src/engine/bucket.ts"],"mappings":";;;;;;;;;;;;;;;wBAgBgB,QAAQ,OAAO,YAAY;;;;;;;qBA6C9B;;;;;;wBAOG,aAAa"}
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
// src/engine/bucket.ts
|
|
2
|
+
/**
|
|
3
|
+
* Cohort bucketing — deterministic assignment of a user to an A/B arm.
|
|
4
|
+
*
|
|
5
|
+
* MurmurHash3 (x86, 32-bit, seed 0) over the UTF-8 bytes of the key, the same
|
|
6
|
+
* construction A/B systems like Unleash use: excellent avalanche behaviour
|
|
7
|
+
* (sequential user ids spread evenly, where FNV-1a showed low-bit bias) and a
|
|
8
|
+
* frozen, widely cross-checked algorithm. Hand-written on purpose: the engine
|
|
9
|
+
* core stays dependency-free, and the known-answer tests pin this
|
|
10
|
+
* implementation against the reference vectors — a stronger guarantee than
|
|
11
|
+
* trusting an npm package's variant.
|
|
12
|
+
*
|
|
13
|
+
* The bucket function is a permanent contract: changing it reshuffles every
|
|
14
|
+
* in-flight cohort, so it must never change once production traffic exists.
|
|
15
|
+
*/
|
|
16
|
+
/** MurmurHash3 x86 32-bit over raw bytes; seed 0. Returns an unsigned 32-bit integer. */
|
|
17
|
+
function murmur3(bytes, seed = 0) {
|
|
18
|
+
const c1 = 0xcc9e2d51;
|
|
19
|
+
const c2 = 461845907;
|
|
20
|
+
let h = seed >>> 0;
|
|
21
|
+
const tail = bytes.length & -4;
|
|
22
|
+
for (let i = 0; i < tail; i += 4) {
|
|
23
|
+
let k = bytes[i] | bytes[i + 1] << 8 | bytes[i + 2] << 16 | bytes[i + 3] << 24;
|
|
24
|
+
k = Math.imul(k, c1);
|
|
25
|
+
k = k << 15 | k >>> 17;
|
|
26
|
+
k = Math.imul(k, c2);
|
|
27
|
+
h ^= k;
|
|
28
|
+
h = h << 13 | h >>> 19;
|
|
29
|
+
h = Math.imul(h, 5) + 0xe6546b64 >>> 0;
|
|
30
|
+
}
|
|
31
|
+
let k = 0;
|
|
32
|
+
const remainder = bytes.length & 3;
|
|
33
|
+
if (remainder === 3) k ^= bytes[tail + 2] << 16;
|
|
34
|
+
if (remainder >= 2) k ^= bytes[tail + 1] << 8;
|
|
35
|
+
if (remainder >= 1) {
|
|
36
|
+
k ^= bytes[tail];
|
|
37
|
+
k = Math.imul(k, c1);
|
|
38
|
+
k = k << 15 | k >>> 17;
|
|
39
|
+
k = Math.imul(k, c2);
|
|
40
|
+
h ^= k;
|
|
41
|
+
}
|
|
42
|
+
h ^= bytes.length;
|
|
43
|
+
h ^= h >>> 16;
|
|
44
|
+
h = Math.imul(h, 0x85ebca6b);
|
|
45
|
+
h ^= h >>> 13;
|
|
46
|
+
h = Math.imul(h, 0xc2b2ae35);
|
|
47
|
+
h ^= h >>> 16;
|
|
48
|
+
return h >>> 0;
|
|
49
|
+
}
|
|
50
|
+
const utf8 = new TextEncoder();
|
|
51
|
+
/**
|
|
52
|
+
* Bucket resolution: basis points, i.e. hundredths of a percent. Weights are
|
|
53
|
+
* compared on the same integer grid (weight% × 100), so fractional splits like
|
|
54
|
+
* 33.3/33.3/33.4 are honoured exactly and the whole path stays float-free —
|
|
55
|
+
* the Optimizely/Statsig construction.
|
|
56
|
+
*/
|
|
57
|
+
const BUCKET_RESOLUTION = 1e4;
|
|
58
|
+
/**
|
|
59
|
+
* Map a bucketing key (`${userId}:${cohortKey}`) to [0, 10000). Keys hash
|
|
60
|
+
* their UTF-8 bytes, so results agree with any standard Murmur3 implementation
|
|
61
|
+
* regardless of the user id's alphabet.
|
|
62
|
+
*/
|
|
63
|
+
function hashToBucket(input) {
|
|
64
|
+
return murmur3(utf8.encode(input)) % BUCKET_RESOLUTION;
|
|
65
|
+
}
|
|
66
|
+
export { BUCKET_RESOLUTION, hashToBucket, murmur3 };
|
|
67
|
+
|
|
68
|
+
//# sourceMappingURL=bucket.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"bucket.mjs","names":[],"sources":["../../src/engine/bucket.ts"],"sourcesContent":["/**\n * Cohort bucketing — deterministic assignment of a user to an A/B arm.\n *\n * MurmurHash3 (x86, 32-bit, seed 0) over the UTF-8 bytes of the key, the same\n * construction A/B systems like Unleash use: excellent avalanche behaviour\n * (sequential user ids spread evenly, where FNV-1a showed low-bit bias) and a\n * frozen, widely cross-checked algorithm. Hand-written on purpose: the engine\n * core stays dependency-free, and the known-answer tests pin this\n * implementation against the reference vectors — a stronger guarantee than\n * trusting an npm package's variant.\n *\n * The bucket function is a permanent contract: changing it reshuffles every\n * in-flight cohort, so it must never change once production traffic exists.\n */\n\n/** MurmurHash3 x86 32-bit over raw bytes; seed 0. Returns an unsigned 32-bit integer. */\nexport function murmur3(bytes: Uint8Array, seed = 0): number {\n const c1 = 0xcc9e2d51;\n const c2 = 0x1b873593;\n let h = seed >>> 0;\n\n const tail = bytes.length & ~3;\n for (let i = 0; i < tail; i += 4) {\n let k = bytes[i] | (bytes[i + 1] << 8) | (bytes[i + 2] << 16) | (bytes[i + 3] << 24);\n k = Math.imul(k, c1);\n k = (k << 15) | (k >>> 17);\n k = Math.imul(k, c2);\n h ^= k;\n h = (h << 13) | (h >>> 19);\n h = (Math.imul(h, 5) + 0xe6546b64) >>> 0;\n }\n\n let k = 0;\n const remainder = bytes.length & 3;\n if (remainder === 3) k ^= bytes[tail + 2] << 16;\n if (remainder >= 2) k ^= bytes[tail + 1] << 8;\n if (remainder >= 1) {\n k ^= bytes[tail];\n k = Math.imul(k, c1);\n k = (k << 15) | (k >>> 17);\n k = Math.imul(k, c2);\n h ^= k;\n }\n\n h ^= bytes.length;\n h ^= h >>> 16;\n h = Math.imul(h, 0x85ebca6b);\n h ^= h >>> 13;\n h = Math.imul(h, 0xc2b2ae35);\n h ^= h >>> 16;\n return h >>> 0;\n}\n\nconst utf8 = new TextEncoder();\n\n/**\n * Bucket resolution: basis points, i.e. hundredths of a percent. Weights are\n * compared on the same integer grid (weight% × 100), so fractional splits like\n * 33.3/33.3/33.4 are honoured exactly and the whole path stays float-free —\n * the Optimizely/Statsig construction.\n */\nexport const BUCKET_RESOLUTION = 10_000;\n\n/**\n * Map a bucketing key (`${userId}:${cohortKey}`) to [0, 10000). Keys hash\n * their UTF-8 bytes, so results agree with any standard Murmur3 implementation\n * regardless of the user id's alphabet.\n */\nexport function hashToBucket(input: string): number {\n return murmur3(utf8.encode(input)) % BUCKET_RESOLUTION;\n}\n"],"mappings":";;;;;;;;;;;;;;;;AAgBA,SAAgB,QAAQ,OAAmB,OAAO,GAAW;CAC3D,MAAM,KAAK;CACX,MAAM,KAAK;CACX,IAAI,IAAI,SAAS;CAEjB,MAAM,OAAO,MAAM,SAAS;CAC5B,KAAK,IAAI,IAAI,GAAG,IAAI,MAAM,KAAK,GAAG;EAChC,IAAI,IAAI,MAAM,KAAM,MAAM,IAAI,MAAM,IAAM,MAAM,IAAI,MAAM,KAAO,MAAM,IAAI,MAAM;EACjF,IAAI,KAAK,KAAK,GAAG,EAAE;EACnB,IAAK,KAAK,KAAO,MAAM;EACvB,IAAI,KAAK,KAAK,GAAG,EAAE;EACnB,KAAK;EACL,IAAK,KAAK,KAAO,MAAM;EACvB,IAAK,KAAK,KAAK,GAAG,CAAC,IAAI,eAAgB;CACzC;CAEA,IAAI,IAAI;CACR,MAAM,YAAY,MAAM,SAAS;CACjC,IAAI,cAAc,GAAG,KAAK,MAAM,OAAO,MAAM;CAC7C,IAAI,aAAa,GAAG,KAAK,MAAM,OAAO,MAAM;CAC5C,IAAI,aAAa,GAAG;EAClB,KAAK,MAAM;EACX,IAAI,KAAK,KAAK,GAAG,EAAE;EACnB,IAAK,KAAK,KAAO,MAAM;EACvB,IAAI,KAAK,KAAK,GAAG,EAAE;EACnB,KAAK;CACP;CAEA,KAAK,MAAM;CACX,KAAK,MAAM;CACX,IAAI,KAAK,KAAK,GAAG,UAAU;CAC3B,KAAK,MAAM;CACX,IAAI,KAAK,KAAK,GAAG,UAAU;CAC3B,KAAK,MAAM;CACX,OAAO,MAAM;AACf;AAEA,MAAM,OAAO,IAAI,YAAY;;;;;;;AAQ7B,MAAa,oBAAoB;;;;;;AAOjC,SAAgB,aAAa,OAAuB;CAClD,OAAO,QAAQ,KAAK,OAAO,KAAK,CAAC,IAAI;AACvC"}
|
|
@@ -0,0 +1,199 @@
|
|
|
1
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
+
const require_engine_recipient = require("./recipient.cjs");
|
|
3
|
+
// src/engine/condition.ts
|
|
4
|
+
/**
|
|
5
|
+
* ConditionIR evaluation: pure logic, with facts injected through FactSource,
|
|
6
|
+
* so the store-backed implementation and the in-memory test one share a single set of
|
|
7
|
+
* semantics and cannot drift into two evaluators.
|
|
8
|
+
*/
|
|
9
|
+
async function evaluateCondition(condition, facts, nowMs, opts) {
|
|
10
|
+
return evaluate(condition, facts, nowMs, opts, []);
|
|
11
|
+
}
|
|
12
|
+
/**
|
|
13
|
+
* `enclosing` is the chain of segment names currently being expanded. A
|
|
14
|
+
* segment that reaches itself has no truth value to converge on, and left
|
|
15
|
+
* unchecked the recursion runs until memory gives out, one store round trip per
|
|
16
|
+
* level — inside a step, so Workflows retries it and the instance never gets
|
|
17
|
+
* out. Failing immediately keeps it bounded, and the message names the cycle
|
|
18
|
+
* because only a deployed bundle can fix it. Only the *path* is tracked, so a
|
|
19
|
+
* diamond (two branches referencing one segment) still evaluates twice.
|
|
20
|
+
*/
|
|
21
|
+
async function evaluate(condition, facts, nowMs, opts, enclosing) {
|
|
22
|
+
switch (condition.type) {
|
|
23
|
+
case "and":
|
|
24
|
+
for (const child of condition.conditions) if (!await evaluate(child, facts, nowMs, opts, enclosing)) return false;
|
|
25
|
+
return true;
|
|
26
|
+
case "or":
|
|
27
|
+
for (const child of condition.conditions) if (await evaluate(child, facts, nowMs, opts, enclosing)) return true;
|
|
28
|
+
return false;
|
|
29
|
+
case "not": return !await evaluate(condition.condition, facts, nowMs, opts, enclosing);
|
|
30
|
+
case "segment": {
|
|
31
|
+
if (enclosing.includes(condition.segment)) throw new Error(`segment '${condition.segment}' references itself: ${[...enclosing, condition.segment].join(" -> ")}`);
|
|
32
|
+
const def = await facts.getSegmentCondition(condition.segment);
|
|
33
|
+
if (def === void 0) throw new Error(`Unknown segment: '${condition.segment}' (bundle not deployed?)`);
|
|
34
|
+
return evaluate(def, facts, nowMs, opts, [...enclosing, condition.segment]);
|
|
35
|
+
}
|
|
36
|
+
case "performed": {
|
|
37
|
+
const bounds = [];
|
|
38
|
+
if (condition.within !== void 0) bounds.push(nowMs - condition.within.ms);
|
|
39
|
+
if (opts?.anchorMs !== void 0) bounds.push(opts.anchorMs);
|
|
40
|
+
if (opts?.after !== void 0 && opts.after.event === condition.event) bounds.push(opts.after.ms + 1);
|
|
41
|
+
const sinceMs = bounds.length > 0 ? Math.max(...bounds) : void 0;
|
|
42
|
+
const atLeast = condition.count ?? 1;
|
|
43
|
+
return await facts.countEvents(condition.event, {
|
|
44
|
+
...sinceMs !== void 0 ? { sinceMs } : {},
|
|
45
|
+
...opts?.untilMs !== void 0 ? { untilMs: opts.untilMs } : {},
|
|
46
|
+
...condition.where !== void 0 ? { where: condition.where } : {},
|
|
47
|
+
atLeast
|
|
48
|
+
}) >= atLeast;
|
|
49
|
+
}
|
|
50
|
+
case "property": return compareProperty(condition, await facts.getProperty(condition.path));
|
|
51
|
+
case "reachable": {
|
|
52
|
+
if (await facts.isSuppressed?.(condition.channel)) return false;
|
|
53
|
+
if (condition.channel === "push") return (await facts.listDevices()).length > 0;
|
|
54
|
+
const path = require_engine_recipient.RECIPIENT_PROPERTY[condition.channel];
|
|
55
|
+
return path === void 0 || await facts.getProperty(path) !== void 0;
|
|
56
|
+
}
|
|
57
|
+
case "trigger_payload":
|
|
58
|
+
if (opts?.triggerPayload === void 0) throw new Error("trigger payload conditions are only valid in the workflow their event triggers");
|
|
59
|
+
return comparePayload(condition, opts.triggerPayload);
|
|
60
|
+
case "payload": throw new Error("payload conditions are only valid inside performed({ where }) or a trigger where clause");
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
/**
|
|
64
|
+
* Evaluate a where tree against one event's payload. Shared by performed
|
|
65
|
+
* counting (FactSource implementations) and the ingest router's trigger gate.
|
|
66
|
+
* Dotted paths descend nested objects; a missing or non-scalar leaf behaves
|
|
67
|
+
* like a missing property (exists sees objects, comparisons do not).
|
|
68
|
+
*/
|
|
69
|
+
function matchesWhere(payload, where) {
|
|
70
|
+
switch (where.type) {
|
|
71
|
+
case "and": return where.conditions.every((child) => matchesWhere(payload, child));
|
|
72
|
+
case "or": return where.conditions.some((child) => matchesWhere(payload, child));
|
|
73
|
+
case "not": return !matchesWhere(payload, where.condition);
|
|
74
|
+
case "payload": return comparePayload(where, payload);
|
|
75
|
+
default: throw new Error(`where clause may not contain a '${where.type}' condition`);
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
/** One predicate against one payload: exists sees objects, comparisons see scalars only. */
|
|
79
|
+
function comparePayload(condition, payload) {
|
|
80
|
+
const raw = valueAtPath(payload, condition.path);
|
|
81
|
+
if (condition.op === "exists") return raw !== void 0 && raw !== null;
|
|
82
|
+
if (condition.op === "not_exists") return raw === void 0 || raw === null;
|
|
83
|
+
return compareProperty(condition, scalarOf(raw));
|
|
84
|
+
}
|
|
85
|
+
const scalarOf = (raw) => typeof raw === "string" || typeof raw === "number" || typeof raw === "boolean" ? raw : void 0;
|
|
86
|
+
/** The scalar at a dotted path of a payload; undefined when it is missing or not a scalar. */
|
|
87
|
+
function payloadScalar(payload, path) {
|
|
88
|
+
return scalarOf(valueAtPath(payload, path));
|
|
89
|
+
}
|
|
90
|
+
function valueAtPath(payload, path) {
|
|
91
|
+
let current = payload;
|
|
92
|
+
for (const key of path.split(".")) {
|
|
93
|
+
if (current === null || typeof current !== "object") return void 0;
|
|
94
|
+
current = current[key];
|
|
95
|
+
}
|
|
96
|
+
return current;
|
|
97
|
+
}
|
|
98
|
+
function compareProperty(condition, actual) {
|
|
99
|
+
const { op, value, values } = condition;
|
|
100
|
+
switch (op) {
|
|
101
|
+
case "exists": return actual !== void 0;
|
|
102
|
+
case "not_exists": return actual === void 0;
|
|
103
|
+
case "eq": return actual === value;
|
|
104
|
+
case "ne": return actual !== value;
|
|
105
|
+
case "gt": return actual !== void 0 && value !== void 0 && actual > value;
|
|
106
|
+
case "gte": return actual !== void 0 && value !== void 0 && actual >= value;
|
|
107
|
+
case "lt": return actual !== void 0 && value !== void 0 && actual < value;
|
|
108
|
+
case "lte": return actual !== void 0 && value !== void 0 && actual <= value;
|
|
109
|
+
case "between": return isBetween(actual, values);
|
|
110
|
+
case "not_between": return !isBetween(actual, values);
|
|
111
|
+
case "in_array": return actual !== void 0 && (values ?? []).includes(actual);
|
|
112
|
+
case "not_in_array": return actual === void 0 || !(values ?? []).includes(actual);
|
|
113
|
+
case "contains": return typeof actual === "string" && typeof value === "string" && actual.includes(value);
|
|
114
|
+
case "not_contains": return !(typeof actual === "string" && typeof value === "string" && actual.includes(value));
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
function isBetween(actual, values) {
|
|
118
|
+
if (actual === void 0 || values === void 0 || values.length < 2) return false;
|
|
119
|
+
const [min, max] = values;
|
|
120
|
+
return actual >= min && actual <= max;
|
|
121
|
+
}
|
|
122
|
+
/**
|
|
123
|
+
* Wake-up channel for profile changes: a property predicate has no event name
|
|
124
|
+
* of its own, so subscriptions use this reserved name and the ingest router
|
|
125
|
+
* fires it on every profile merge. The '$' prefix marks internal names — real
|
|
126
|
+
* events may never use it (the router rejects them).
|
|
127
|
+
*/
|
|
128
|
+
const PROFILE_UPDATED_EVENT = "$profile_updated";
|
|
129
|
+
/**
|
|
130
|
+
* The wake-up channel for one profile property: `$profile_updated:<path>`. A property predicate
|
|
131
|
+
* subscribes to its own property's channel, and a merge fires one per property it patched —
|
|
132
|
+
* so an identify that touches `plan` does not wake a wait on `email`.
|
|
133
|
+
*/
|
|
134
|
+
function profileUpdatedEvent(path) {
|
|
135
|
+
return `${PROFILE_UPDATED_EVENT}:${path}`;
|
|
136
|
+
}
|
|
137
|
+
/**
|
|
138
|
+
* Wake-up channel for device changes: a device registered for the user, moved to another account
|
|
139
|
+
* or was unbound or removed (`POST /devices`, `/devices/unbind`, `/devices/remove`). `reachable('push')` subscribes to it.
|
|
140
|
+
*/
|
|
141
|
+
const DEVICES_UPDATED_EVENT = "$devices_updated";
|
|
142
|
+
/**
|
|
143
|
+
* The set of event names a condition cares about — what wait_until subscribes
|
|
144
|
+
* to for wake-ups. `performed` contributes its event; a property predicate
|
|
145
|
+
* contributes its property's channel (`profileUpdatedEvent(path)`, so an
|
|
146
|
+
* a merge touching that property wakes the wait and one touching another
|
|
147
|
+
* does not); `reachable` contributes the recipient property's channel, or the
|
|
148
|
+
* device channel for push (in_app, slack and discord have no address to wait
|
|
149
|
+
* on). Segment references are expanded, which is why a FactSource is needed to
|
|
150
|
+
* resolve their definitions.
|
|
151
|
+
*/
|
|
152
|
+
async function relevantEvents(condition, facts) {
|
|
153
|
+
const found = /* @__PURE__ */ new Set();
|
|
154
|
+
const expanded = /* @__PURE__ */ new Set();
|
|
155
|
+
async function walk(c) {
|
|
156
|
+
switch (c.type) {
|
|
157
|
+
case "and":
|
|
158
|
+
case "or":
|
|
159
|
+
for (const child of c.conditions) await walk(child);
|
|
160
|
+
break;
|
|
161
|
+
case "not":
|
|
162
|
+
await walk(c.condition);
|
|
163
|
+
break;
|
|
164
|
+
case "performed":
|
|
165
|
+
found.add(c.event);
|
|
166
|
+
break;
|
|
167
|
+
case "segment": {
|
|
168
|
+
if (expanded.has(c.segment)) break;
|
|
169
|
+
expanded.add(c.segment);
|
|
170
|
+
const def = await facts.getSegmentCondition(c.segment);
|
|
171
|
+
if (def) await walk(def);
|
|
172
|
+
break;
|
|
173
|
+
}
|
|
174
|
+
case "property":
|
|
175
|
+
found.add(profileUpdatedEvent(c.path));
|
|
176
|
+
break;
|
|
177
|
+
case "reachable": {
|
|
178
|
+
if (c.channel === "push") {
|
|
179
|
+
found.add(DEVICES_UPDATED_EVENT);
|
|
180
|
+
break;
|
|
181
|
+
}
|
|
182
|
+
const path = require_engine_recipient.RECIPIENT_PROPERTY[c.channel];
|
|
183
|
+
if (path !== void 0) found.add(profileUpdatedEvent(path));
|
|
184
|
+
break;
|
|
185
|
+
}
|
|
186
|
+
}
|
|
187
|
+
}
|
|
188
|
+
await walk(condition);
|
|
189
|
+
return [...found];
|
|
190
|
+
}
|
|
191
|
+
exports.DEVICES_UPDATED_EVENT = DEVICES_UPDATED_EVENT;
|
|
192
|
+
exports.PROFILE_UPDATED_EVENT = PROFILE_UPDATED_EVENT;
|
|
193
|
+
exports.evaluateCondition = evaluateCondition;
|
|
194
|
+
exports.matchesWhere = matchesWhere;
|
|
195
|
+
exports.payloadScalar = payloadScalar;
|
|
196
|
+
exports.profileUpdatedEvent = profileUpdatedEvent;
|
|
197
|
+
exports.relevantEvents = relevantEvents;
|
|
198
|
+
|
|
199
|
+
//# sourceMappingURL=condition.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"condition.cjs","names":["RECIPIENT_PROPERTY"],"sources":["../../src/engine/condition.ts"],"sourcesContent":["import type { ConditionIR, PropertyOperatorIR, ScalarIR } from '../ir';\nimport type { FactSource } from './ports';\nimport { RECIPIENT_PROPERTY } from './recipient';\n\n/**\n * Evaluation options.\n * - anchorMs: the earliest instant `performed` counts events from — the goal\n * guard anchors at workflow entry (a conversion must happen *after* entry),\n * waitUntil at the moment the wait began (a wake must not be satisfied by\n * pre-existing history). Combined with `within` by taking the later bound.\n * - untilMs: the latest instant `performed` counts events up to — the goal's\n * attribution window ends there, so an event after it is no conversion even\n * when the check runs later (a resumed instance, a delayed wake).\n * - triggerPayload: see the field.\n * - after: one occurrence `performed` must not count — the event that started the instance.\n * The entry anchor is that event's own time and the window's bounds are inclusive, so\n * without this a goal on the trigger's event (a repeat purchase) holds at entry, by the\n * very purchase that entered. Only events of that name, strictly later, count.\n */\nexport interface EvaluateOptions {\n anchorMs?: number;\n untilMs?: number;\n after?: { event: string; ms: number } | undefined;\n /**\n * The payload of the event that started the journey — what a `trigger_payload` predicate\n * reads. Only a running journey has one: evaluating such a predicate without it (a segment,\n * a trigger filter) is an error, not a miss.\n */\n triggerPayload?: unknown;\n}\n\n/**\n * ConditionIR evaluation: pure logic, with facts injected through FactSource,\n * so the store-backed implementation and the in-memory test one share a single set of\n * semantics and cannot drift into two evaluators.\n */\nexport async function evaluateCondition(\n condition: ConditionIR,\n facts: FactSource,\n nowMs: number,\n opts?: EvaluateOptions\n): Promise<boolean> {\n return evaluate(condition, facts, nowMs, opts, []);\n}\n\n/**\n * `enclosing` is the chain of segment names currently being expanded. A\n * segment that reaches itself has no truth value to converge on, and left\n * unchecked the recursion runs until memory gives out, one store round trip per\n * level — inside a step, so Workflows retries it and the instance never gets\n * out. Failing immediately keeps it bounded, and the message names the cycle\n * because only a deployed bundle can fix it. Only the *path* is tracked, so a\n * diamond (two branches referencing one segment) still evaluates twice.\n */\nasync function evaluate(\n condition: ConditionIR,\n facts: FactSource,\n nowMs: number,\n opts: EvaluateOptions | undefined,\n enclosing: readonly string[]\n): Promise<boolean> {\n switch (condition.type) {\n case 'and': {\n for (const child of condition.conditions) {\n if (!(await evaluate(child, facts, nowMs, opts, enclosing))) return false;\n }\n return true;\n }\n case 'or': {\n for (const child of condition.conditions) {\n if (await evaluate(child, facts, nowMs, opts, enclosing)) return true;\n }\n return false;\n }\n case 'not':\n return !(await evaluate(condition.condition, facts, nowMs, opts, enclosing));\n case 'segment': {\n if (enclosing.includes(condition.segment)) {\n throw new Error(\n `segment '${condition.segment}' references itself: ${[...enclosing, condition.segment].join(' -> ')}`\n );\n }\n const def = await facts.getSegmentCondition(condition.segment);\n if (def === undefined) {\n throw new Error(`Unknown segment: '${condition.segment}' (bundle not deployed?)`);\n }\n return evaluate(def, facts, nowMs, opts, [...enclosing, condition.segment]);\n }\n case 'performed': {\n const bounds: number[] = [];\n if (condition.within !== undefined) bounds.push(nowMs - condition.within.ms);\n if (opts?.anchorMs !== undefined) bounds.push(opts.anchorMs);\n if (opts?.after !== undefined && opts.after.event === condition.event) {\n bounds.push(opts.after.ms + 1);\n }\n const sinceMs = bounds.length > 0 ? Math.max(...bounds) : undefined;\n const atLeast = condition.count ?? 1;\n const count = await facts.countEvents(condition.event, {\n ...(sinceMs !== undefined ? { sinceMs } : {}),\n ...(opts?.untilMs !== undefined ? { untilMs: opts.untilMs } : {}),\n ...(condition.where !== undefined ? { where: condition.where } : {}),\n atLeast,\n });\n return count >= atLeast;\n }\n case 'property': {\n const actual = await facts.getProperty(condition.path);\n return compareProperty(condition, actual);\n }\n case 'reachable': {\n // The channel-wide opt-out only: a user opted out of one topic (an email topic, a push\n // topic) is still reachable on the channel, so `exitWhen: not(reachable('email'))` does\n // not fire on it\n if (await facts.isSuppressed?.(condition.channel)) return false;\n if (condition.channel === 'push') return (await facts.listDevices()).length > 0;\n const path = RECIPIENT_PROPERTY[condition.channel];\n // in_app, slack and discord need no address: a signed-in user is reachable in the app, and\n // the webhook channels post to a team channel, not to the user\n return path === undefined || (await facts.getProperty(path)) !== undefined;\n }\n case 'trigger_payload':\n // Placement is validated at compile; reaching here without one means hand-built IR\n if (opts?.triggerPayload === undefined) {\n throw new Error(\n 'trigger payload conditions are only valid in the workflow their event triggers'\n );\n }\n return comparePayload(condition, opts.triggerPayload);\n case 'payload':\n // Placement is validated at compile; reaching here means hand-built IR\n throw new Error(\n 'payload conditions are only valid inside performed({ where }) or a trigger where clause'\n );\n }\n}\n\n/**\n * Evaluate a where tree against one event's payload. Shared by performed\n * counting (FactSource implementations) and the ingest router's trigger gate.\n * Dotted paths descend nested objects; a missing or non-scalar leaf behaves\n * like a missing property (exists sees objects, comparisons do not).\n */\nexport function matchesWhere(payload: unknown, where: ConditionIR): boolean {\n switch (where.type) {\n case 'and':\n return where.conditions.every((child) => matchesWhere(payload, child));\n case 'or':\n return where.conditions.some((child) => matchesWhere(payload, child));\n case 'not':\n return !matchesWhere(payload, where.condition);\n case 'payload':\n return comparePayload(where, payload);\n default:\n // compileBundle rejects these; defend against hand-built IR\n throw new Error(`where clause may not contain a '${where.type}' condition`);\n }\n}\n\n/** One predicate against one payload: exists sees objects, comparisons see scalars only. */\nfunction comparePayload(\n condition: {\n path: string;\n op: PropertyOperatorIR;\n value?: ScalarIR | undefined;\n values?: ScalarIR[] | undefined;\n },\n payload: unknown\n): boolean {\n const raw = valueAtPath(payload, condition.path);\n if (condition.op === 'exists') return raw !== undefined && raw !== null;\n if (condition.op === 'not_exists') return raw === undefined || raw === null;\n return compareProperty(condition, scalarOf(raw));\n}\n\nconst scalarOf = (raw: unknown): ScalarIR | undefined =>\n typeof raw === 'string' || typeof raw === 'number' || typeof raw === 'boolean' ? raw : undefined;\n\n/** The scalar at a dotted path of a payload; undefined when it is missing or not a scalar. */\nexport function payloadScalar(payload: unknown, path: string): ScalarIR | undefined {\n return scalarOf(valueAtPath(payload, path));\n}\n\nfunction valueAtPath(payload: unknown, path: string): unknown {\n let current: unknown = payload;\n for (const key of path.split('.')) {\n if (current === null || typeof current !== 'object') return undefined;\n current = (current as Record<string, unknown>)[key];\n }\n return current;\n}\n\nfunction compareProperty(\n condition: {\n op: PropertyOperatorIR;\n value?: ScalarIR | undefined;\n values?: ScalarIR[] | undefined;\n },\n actual: ScalarIR | undefined\n): boolean {\n const { op, value, values } = condition;\n switch (op) {\n case 'exists':\n return actual !== undefined;\n case 'not_exists':\n return actual === undefined;\n case 'eq':\n return actual === value;\n case 'ne':\n return actual !== value;\n case 'gt':\n return actual !== undefined && value !== undefined && actual > value;\n case 'gte':\n return actual !== undefined && value !== undefined && actual >= value;\n case 'lt':\n return actual !== undefined && value !== undefined && actual < value;\n case 'lte':\n return actual !== undefined && value !== undefined && actual <= value;\n case 'between':\n return isBetween(actual, values);\n case 'not_between':\n // A missing property is outside any range, mirroring not_in_array.\n return !isBetween(actual, values);\n case 'in_array':\n return actual !== undefined && (values ?? []).includes(actual);\n case 'not_in_array':\n return actual === undefined || !(values ?? []).includes(actual);\n case 'contains':\n return typeof actual === 'string' && typeof value === 'string' && actual.includes(value);\n case 'not_contains':\n return !(typeof actual === 'string' && typeof value === 'string' && actual.includes(value));\n }\n}\n\nfunction isBetween(actual: ScalarIR | undefined, values: ScalarIR[] | undefined): boolean {\n if (actual === undefined || values === undefined || values.length < 2) return false;\n const [min, max] = values;\n return actual >= min && actual <= max;\n}\n\n/**\n * Wake-up channel for profile changes: a property predicate has no event name\n * of its own, so subscriptions use this reserved name and the ingest router\n * fires it on every profile merge. The '$' prefix marks internal names — real\n * events may never use it (the router rejects them).\n */\nexport const PROFILE_UPDATED_EVENT = '$profile_updated';\n\n/**\n * The wake-up channel for one profile property: `$profile_updated:<path>`. A property predicate\n * subscribes to its own property's channel, and a merge fires one per property it patched —\n * so an identify that touches `plan` does not wake a wait on `email`.\n */\nexport function profileUpdatedEvent(path: string): string {\n return `${PROFILE_UPDATED_EVENT}:${path}`;\n}\n\n/**\n * Wake-up channel for device changes: a device registered for the user, moved to another account\n * or was unbound or removed (`POST /devices`, `/devices/unbind`, `/devices/remove`). `reachable('push')` subscribes to it.\n */\nexport const DEVICES_UPDATED_EVENT = '$devices_updated';\n\n/**\n * The set of event names a condition cares about — what wait_until subscribes\n * to for wake-ups. `performed` contributes its event; a property predicate\n * contributes its property's channel (`profileUpdatedEvent(path)`, so an\n * a merge touching that property wakes the wait and one touching another\n * does not); `reachable` contributes the recipient property's channel, or the\n * device channel for push (in_app, slack and discord have no address to wait\n * on). Segment references are expanded, which is why a FactSource is needed to\n * resolve their definitions.\n */\nexport async function relevantEvents(condition: ConditionIR, facts: FactSource): Promise<string[]> {\n const found = new Set<string>();\n // Names already expanded. The result is a union, so re-walking a segment can\n // only add what is already there — and a segment that reaches itself would\n // otherwise recurse until the stack blows, taking a store read per level.\n const expanded = new Set<string>();\n async function walk(c: ConditionIR): Promise<void> {\n switch (c.type) {\n case 'and':\n case 'or':\n for (const child of c.conditions) await walk(child);\n break;\n case 'not':\n await walk(c.condition);\n break;\n case 'performed':\n found.add(c.event);\n break;\n case 'segment': {\n if (expanded.has(c.segment)) break;\n expanded.add(c.segment);\n const def = await facts.getSegmentCondition(c.segment);\n if (def) await walk(def);\n break;\n }\n case 'property':\n found.add(profileUpdatedEvent(c.path));\n break;\n case 'reachable': {\n if (c.channel === 'push') {\n found.add(DEVICES_UPDATED_EVENT);\n break;\n }\n const path = RECIPIENT_PROPERTY[c.channel];\n if (path !== undefined) found.add(profileUpdatedEvent(path));\n break;\n }\n case 'payload':\n break; // only appears inside performed.where, which is not walked\n case 'trigger_payload':\n break; // fixed at entry: nothing that happens later changes it\n }\n }\n await walk(condition);\n return [...found];\n}\n"],"mappings":"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"}
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
import { ConditionIR, ScalarIR } from "../ir.cjs";
|
|
2
|
+
import { FactSource } from "./ports.cjs";
|
|
3
|
+
/**
|
|
4
|
+
* Evaluation options.
|
|
5
|
+
* - anchorMs: the earliest instant `performed` counts events from — the goal
|
|
6
|
+
* guard anchors at workflow entry (a conversion must happen *after* entry),
|
|
7
|
+
* waitUntil at the moment the wait began (a wake must not be satisfied by
|
|
8
|
+
* pre-existing history). Combined with `within` by taking the later bound.
|
|
9
|
+
* - untilMs: the latest instant `performed` counts events up to — the goal's
|
|
10
|
+
* attribution window ends there, so an event after it is no conversion even
|
|
11
|
+
* when the check runs later (a resumed instance, a delayed wake).
|
|
12
|
+
* - triggerPayload: see the field.
|
|
13
|
+
* - after: one occurrence `performed` must not count — the event that started the instance.
|
|
14
|
+
* The entry anchor is that event's own time and the window's bounds are inclusive, so
|
|
15
|
+
* without this a goal on the trigger's event (a repeat purchase) holds at entry, by the
|
|
16
|
+
* very purchase that entered. Only events of that name, strictly later, count.
|
|
17
|
+
*/
|
|
18
|
+
export interface EvaluateOptions {
|
|
19
|
+
anchorMs?: number;
|
|
20
|
+
untilMs?: number;
|
|
21
|
+
after?: {
|
|
22
|
+
event: string;
|
|
23
|
+
ms: number;
|
|
24
|
+
} | undefined;
|
|
25
|
+
/**
|
|
26
|
+
* The payload of the event that started the journey — what a `trigger_payload` predicate
|
|
27
|
+
* reads. Only a running journey has one: evaluating such a predicate without it (a segment,
|
|
28
|
+
* a trigger filter) is an error, not a miss.
|
|
29
|
+
*/
|
|
30
|
+
triggerPayload?: unknown;
|
|
31
|
+
}
|
|
32
|
+
/**
|
|
33
|
+
* ConditionIR evaluation: pure logic, with facts injected through FactSource,
|
|
34
|
+
* so the store-backed implementation and the in-memory test one share a single set of
|
|
35
|
+
* semantics and cannot drift into two evaluators.
|
|
36
|
+
*/
|
|
37
|
+
export declare function evaluateCondition(condition: ConditionIR, facts: FactSource, nowMs: number, opts?: EvaluateOptions): Promise<boolean>;
|
|
38
|
+
/**
|
|
39
|
+
* Evaluate a where tree against one event's payload. Shared by performed
|
|
40
|
+
* counting (FactSource implementations) and the ingest router's trigger gate.
|
|
41
|
+
* Dotted paths descend nested objects; a missing or non-scalar leaf behaves
|
|
42
|
+
* like a missing property (exists sees objects, comparisons do not).
|
|
43
|
+
*/
|
|
44
|
+
export declare function matchesWhere(payload: unknown, where: ConditionIR): boolean;
|
|
45
|
+
/** The scalar at a dotted path of a payload; undefined when it is missing or not a scalar. */
|
|
46
|
+
export declare function payloadScalar(payload: unknown, path: string): ScalarIR | undefined;
|
|
47
|
+
/**
|
|
48
|
+
* Wake-up channel for profile changes: a property predicate has no event name
|
|
49
|
+
* of its own, so subscriptions use this reserved name and the ingest router
|
|
50
|
+
* fires it on every profile merge. The '$' prefix marks internal names — real
|
|
51
|
+
* events may never use it (the router rejects them).
|
|
52
|
+
*/
|
|
53
|
+
export declare const PROFILE_UPDATED_EVENT = "$profile_updated";
|
|
54
|
+
/**
|
|
55
|
+
* The wake-up channel for one profile property: `$profile_updated:<path>`. A property predicate
|
|
56
|
+
* subscribes to its own property's channel, and a merge fires one per property it patched —
|
|
57
|
+
* so an identify that touches `plan` does not wake a wait on `email`.
|
|
58
|
+
*/
|
|
59
|
+
export declare function profileUpdatedEvent(path: string): string;
|
|
60
|
+
/**
|
|
61
|
+
* Wake-up channel for device changes: a device registered for the user, moved to another account
|
|
62
|
+
* or was unbound or removed (`POST /devices`, `/devices/unbind`, `/devices/remove`). `reachable('push')` subscribes to it.
|
|
63
|
+
*/
|
|
64
|
+
export declare const DEVICES_UPDATED_EVENT = "$devices_updated";
|
|
65
|
+
/**
|
|
66
|
+
* The set of event names a condition cares about — what wait_until subscribes
|
|
67
|
+
* to for wake-ups. `performed` contributes its event; a property predicate
|
|
68
|
+
* contributes its property's channel (`profileUpdatedEvent(path)`, so an
|
|
69
|
+
* a merge touching that property wakes the wait and one touching another
|
|
70
|
+
* does not); `reachable` contributes the recipient property's channel, or the
|
|
71
|
+
* device channel for push (in_app, slack and discord have no address to wait
|
|
72
|
+
* on). Segment references are expanded, which is why a FactSource is needed to
|
|
73
|
+
* resolve their definitions.
|
|
74
|
+
*/
|
|
75
|
+
export declare function relevantEvents(condition: ConditionIR, facts: FactSource): Promise<string[]>;
|
|
76
|
+
//# sourceMappingURL=condition.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"condition.d.cts","names":[],"sources":["../../src/engine/condition.ts"],"mappings":";;;;;;;;;;;;;;;;;iBAmBiB;EACf;EACA;EACA;IAAU;IAAe;;;;;;;EAMzB;;;;;;;wBAQoB,kBACpB,WAAW,aACX,OAAO,YACP,eACA,OAAO,kBACN;;;;;;;wBAqGa,aAAa,kBAAkB,OAAO;;wBAoCtC,cAAc,kBAAkB,eAAe;;;;;;;qBAmElD;;;;;;wBAOG,oBAAoB;;;;;qBAQvB;;;;;;;;;;;wBAYS,eAAe,WAAW,aAAa,OAAO,aAAa"}
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
import { ConditionIR, ScalarIR } from "../ir.mjs";
|
|
2
|
+
import { FactSource } from "./ports.mjs";
|
|
3
|
+
/**
|
|
4
|
+
* Evaluation options.
|
|
5
|
+
* - anchorMs: the earliest instant `performed` counts events from — the goal
|
|
6
|
+
* guard anchors at workflow entry (a conversion must happen *after* entry),
|
|
7
|
+
* waitUntil at the moment the wait began (a wake must not be satisfied by
|
|
8
|
+
* pre-existing history). Combined with `within` by taking the later bound.
|
|
9
|
+
* - untilMs: the latest instant `performed` counts events up to — the goal's
|
|
10
|
+
* attribution window ends there, so an event after it is no conversion even
|
|
11
|
+
* when the check runs later (a resumed instance, a delayed wake).
|
|
12
|
+
* - triggerPayload: see the field.
|
|
13
|
+
* - after: one occurrence `performed` must not count — the event that started the instance.
|
|
14
|
+
* The entry anchor is that event's own time and the window's bounds are inclusive, so
|
|
15
|
+
* without this a goal on the trigger's event (a repeat purchase) holds at entry, by the
|
|
16
|
+
* very purchase that entered. Only events of that name, strictly later, count.
|
|
17
|
+
*/
|
|
18
|
+
export interface EvaluateOptions {
|
|
19
|
+
anchorMs?: number;
|
|
20
|
+
untilMs?: number;
|
|
21
|
+
after?: {
|
|
22
|
+
event: string;
|
|
23
|
+
ms: number;
|
|
24
|
+
} | undefined;
|
|
25
|
+
/**
|
|
26
|
+
* The payload of the event that started the journey — what a `trigger_payload` predicate
|
|
27
|
+
* reads. Only a running journey has one: evaluating such a predicate without it (a segment,
|
|
28
|
+
* a trigger filter) is an error, not a miss.
|
|
29
|
+
*/
|
|
30
|
+
triggerPayload?: unknown;
|
|
31
|
+
}
|
|
32
|
+
/**
|
|
33
|
+
* ConditionIR evaluation: pure logic, with facts injected through FactSource,
|
|
34
|
+
* so the store-backed implementation and the in-memory test one share a single set of
|
|
35
|
+
* semantics and cannot drift into two evaluators.
|
|
36
|
+
*/
|
|
37
|
+
export declare function evaluateCondition(condition: ConditionIR, facts: FactSource, nowMs: number, opts?: EvaluateOptions): Promise<boolean>;
|
|
38
|
+
/**
|
|
39
|
+
* Evaluate a where tree against one event's payload. Shared by performed
|
|
40
|
+
* counting (FactSource implementations) and the ingest router's trigger gate.
|
|
41
|
+
* Dotted paths descend nested objects; a missing or non-scalar leaf behaves
|
|
42
|
+
* like a missing property (exists sees objects, comparisons do not).
|
|
43
|
+
*/
|
|
44
|
+
export declare function matchesWhere(payload: unknown, where: ConditionIR): boolean;
|
|
45
|
+
/** The scalar at a dotted path of a payload; undefined when it is missing or not a scalar. */
|
|
46
|
+
export declare function payloadScalar(payload: unknown, path: string): ScalarIR | undefined;
|
|
47
|
+
/**
|
|
48
|
+
* Wake-up channel for profile changes: a property predicate has no event name
|
|
49
|
+
* of its own, so subscriptions use this reserved name and the ingest router
|
|
50
|
+
* fires it on every profile merge. The '$' prefix marks internal names — real
|
|
51
|
+
* events may never use it (the router rejects them).
|
|
52
|
+
*/
|
|
53
|
+
export declare const PROFILE_UPDATED_EVENT = "$profile_updated";
|
|
54
|
+
/**
|
|
55
|
+
* The wake-up channel for one profile property: `$profile_updated:<path>`. A property predicate
|
|
56
|
+
* subscribes to its own property's channel, and a merge fires one per property it patched —
|
|
57
|
+
* so an identify that touches `plan` does not wake a wait on `email`.
|
|
58
|
+
*/
|
|
59
|
+
export declare function profileUpdatedEvent(path: string): string;
|
|
60
|
+
/**
|
|
61
|
+
* Wake-up channel for device changes: a device registered for the user, moved to another account
|
|
62
|
+
* or was unbound or removed (`POST /devices`, `/devices/unbind`, `/devices/remove`). `reachable('push')` subscribes to it.
|
|
63
|
+
*/
|
|
64
|
+
export declare const DEVICES_UPDATED_EVENT = "$devices_updated";
|
|
65
|
+
/**
|
|
66
|
+
* The set of event names a condition cares about — what wait_until subscribes
|
|
67
|
+
* to for wake-ups. `performed` contributes its event; a property predicate
|
|
68
|
+
* contributes its property's channel (`profileUpdatedEvent(path)`, so an
|
|
69
|
+
* a merge touching that property wakes the wait and one touching another
|
|
70
|
+
* does not); `reachable` contributes the recipient property's channel, or the
|
|
71
|
+
* device channel for push (in_app, slack and discord have no address to wait
|
|
72
|
+
* on). Segment references are expanded, which is why a FactSource is needed to
|
|
73
|
+
* resolve their definitions.
|
|
74
|
+
*/
|
|
75
|
+
export declare function relevantEvents(condition: ConditionIR, facts: FactSource): Promise<string[]>;
|
|
76
|
+
//# sourceMappingURL=condition.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"condition.d.mts","names":[],"sources":["../../src/engine/condition.ts"],"mappings":";;;;;;;;;;;;;;;;;iBAmBiB;EACf;EACA;EACA;IAAU;IAAe;;;;;;;EAMzB;;;;;;;wBAQoB,kBACpB,WAAW,aACX,OAAO,YACP,eACA,OAAO,kBACN;;;;;;;wBAqGa,aAAa,kBAAkB,OAAO;;wBAoCtC,cAAc,kBAAkB,eAAe;;;;;;;qBAmElD;;;;;;wBAOG,oBAAoB;;;;;qBAQvB;;;;;;;;;;;wBAYS,eAAe,WAAW,aAAa,OAAO,aAAa"}
|