@appfunnel-dev/sdk 2.0.0 → 2.0.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.
Files changed (38) hide show
  1. package/CHANGELOG.md +41 -3
  2. package/dist/{checkout-BYcOfyg_.d.ts → checkout-B1K6ozwk.d.ts} +6 -0
  3. package/dist/{checkout-BM1T-u6_.d.cts → checkout-C4tFUEdF.d.cts} +6 -0
  4. package/dist/{chunk-MBTHQP4Z.cjs → chunk-DTSLJ24T.cjs} +11 -3
  5. package/dist/chunk-DTSLJ24T.cjs.map +1 -0
  6. package/dist/{chunk-NA7DRFOA.cjs → chunk-E7JXWUNV.cjs} +55 -17
  7. package/dist/chunk-E7JXWUNV.cjs.map +1 -0
  8. package/dist/{chunk-KVMNVX6J.js → chunk-USAECFWO.js} +11 -3
  9. package/dist/chunk-USAECFWO.js.map +1 -0
  10. package/dist/{chunk-PN7CRJAF.js → chunk-WCBVSZHJ.js} +55 -17
  11. package/dist/chunk-WCBVSZHJ.js.map +1 -0
  12. package/dist/driver-paddle.cjs +14 -14
  13. package/dist/driver-paddle.d.cts +1 -1
  14. package/dist/driver-paddle.d.ts +1 -1
  15. package/dist/driver-paddle.js +1 -1
  16. package/dist/driver-stripe.cjs +15 -15
  17. package/dist/driver-stripe.d.cts +1 -1
  18. package/dist/driver-stripe.d.ts +1 -1
  19. package/dist/driver-stripe.js +2 -2
  20. package/dist/index.cjs +78 -67
  21. package/dist/index.cjs.map +1 -1
  22. package/dist/index.d.cts +25 -6
  23. package/dist/index.d.ts +25 -6
  24. package/dist/index.js +13 -2
  25. package/dist/index.js.map +1 -1
  26. package/dist/{manifest-BajvtPWs.d.cts → manifest-Dp1oRvqp.d.cts} +23 -0
  27. package/dist/{manifest-BajvtPWs.d.ts → manifest-Dp1oRvqp.d.ts} +23 -0
  28. package/dist/manifest-entry.cjs +9 -1
  29. package/dist/manifest-entry.cjs.map +1 -1
  30. package/dist/manifest-entry.d.cts +15 -2
  31. package/dist/manifest-entry.d.ts +15 -2
  32. package/dist/manifest-entry.js +9 -1
  33. package/dist/manifest-entry.js.map +1 -1
  34. package/package.json +1 -1
  35. package/dist/chunk-KVMNVX6J.js.map +0 -1
  36. package/dist/chunk-MBTHQP4Z.cjs.map +0 -1
  37. package/dist/chunk-NA7DRFOA.cjs.map +0 -1
  38. package/dist/chunk-PN7CRJAF.js.map +0 -1
package/dist/index.d.cts CHANGED
@@ -1,10 +1,10 @@
1
1
  import * as react from 'react';
2
2
  import { ReactNode, ComponentType, ButtonHTMLAttributes, AnchorHTMLAttributes } from 'react';
3
- import { O as Offering, V as VariableValue, a as VariableConfig, A as Acquisition, D as Direction, F as FunnelContext, R as RuntimeExperiment, b as FunnelSnapshot, c as FunnelDefinition, d as buildContext, e as OfferingInput, P as PageMeta, f as PageContext, G as GroupProgress } from './manifest-BajvtPWs.cjs';
4
- export { B as BrowserContext, g as BuildContextOptions, C as ClickIdContext, h as CompileInput, i as Condition, j as ConditionOp, k as DeviceContext, E as EdgeCondition, l as ExperimentArm, m as ExperimentResolution, n as FlowPage, o as FunnelLocales, p as FunnelManifest, q as Gate, I as IdentityContext, r as Interval, L as LocaleContext, M as ManifestEdge, s as ManifestPage, t as ManifestValidation, u as Money, v as OsContext, w as PageComponent, x as PageGroup, y as PageType, z as Predicate, H as ResolvedOffering, J as Route, S as SampleOffering, K as SessionContext, N as SystemContext, U as UtmContext, Q as assignVariant, T as bucketingSeed, W as buildAcquisition, X as buildCatalog, Y as compileManifest, Z as currencyExponent, _ as defineFunnel, $ as definePage, a0 as entryGuard, a1 as evaluateCondition, a2 as evaluateGate, a3 as expectedPathLength, a4 as fnv1a, a5 as formatMoney, a6 as formatOffering, a7 as formatSampleOffering, a8 as groupProgress, a9 as hashToUnit, aa as isRtl, ab as isVariantKey, ac as nextPage, ad as outgoingKeys, ae as pageMeta, af as parseSlotKey, ag as pickByWeight, ah as resolveExperiments, ai as resolveLocale, aj as resolveOffering, ak as resolveRoute } from './manifest-BajvtPWs.cjs';
3
+ import { O as Offering, V as VariableValue, a as VariableConfig, A as Acquisition, D as Direction, F as FunnelContext, R as RuntimeExperiment, b as FunnelSnapshot, c as FunnelDefinition, d as buildContext, e as OfferingInput, P as PageMeta, f as PageContext, G as GroupProgress } from './manifest-Dp1oRvqp.cjs';
4
+ export { B as BrowserContext, g as BuildContextOptions, C as ClickIdContext, h as CompileInput, i as Condition, j as ConditionOp, k as DeviceContext, E as EdgeCondition, l as ExperimentArm, m as ExperimentResolution, n as FlowPage, o as FunnelLocales, p as FunnelManifest, q as Gate, I as IdentityContext, r as Interval, L as LocaleContext, M as ManifestEdge, s as ManifestPage, t as ManifestValidation, u as Money, v as OsContext, w as PageComponent, x as PageGroup, y as PageType, z as Predicate, H as ResolvedOffering, J as Route, S as SampleOffering, K as SessionContext, N as SystemContext, U as UtmContext, Q as assignVariant, T as bucketingSeed, W as buildAcquisition, X as buildCatalog, Y as compileManifest, Z as currencyExponent, _ as defineFunnel, $ as definePage, a0 as entryGuard, a1 as evaluateCondition, a2 as evaluateGate, a3 as expectedPathLength, a4 as fnv1a, a5 as formatMoney, a6 as formatOffering, a7 as formatSampleOffering, a8 as groupProgress, a9 as hashToUnit, aa as isRtl, ab as isVariantKey, ac as nextPage, ad as outgoingKeys, ae as pageMeta, af as parseSlotKey, ag as pickByWeight, ah as resolveExperiments, ai as resolveLocale, aj as resolveOffering, ak as resolveRoute } from './manifest-Dp1oRvqp.cjs';
5
5
  import { NavSnapshot } from './protocol.cjs';
6
- import { a as CheckoutDriver, C as CheckoutDriverContext } from './checkout-BM1T-u6_.cjs';
7
- export { b as Checkout, c as CheckoutAppearance, d as CheckoutButton, e as CheckoutButtonProps, f as CheckoutCallbacks, g as CheckoutClassNames, h as CheckoutCommonProps, i as CheckoutHandle, j as CheckoutInlineProps, k as CheckoutMethods, l as CheckoutProps, m as CheckoutRequest, n as CheckoutResult, o as CheckoutResume, p as CheckoutSpinner, q as CheckoutStatus, F as FailureModalProps, r as FailureRoute, M as MockDriverOptions, O as OnFailedMap, s as OpensAxis, P as PaymentAxis, T as TriggerAxis, t as TriggerState, U as UpsellButton, u as UpsellButtonProps, v as UpsellCommonProps, w as UpsellRecovery, x as UseCheckoutOptions, y as createMockDriver, z as driverWithEmail, A as useCheckout } from './checkout-BM1T-u6_.cjs';
6
+ import { a as CheckoutDriver, C as CheckoutDriverContext } from './checkout-C4tFUEdF.cjs';
7
+ export { b as Checkout, c as CheckoutAppearance, d as CheckoutButton, e as CheckoutButtonProps, f as CheckoutCallbacks, g as CheckoutClassNames, h as CheckoutCommonProps, i as CheckoutHandle, j as CheckoutInlineProps, k as CheckoutMethods, l as CheckoutProps, m as CheckoutRequest, n as CheckoutResult, o as CheckoutResume, p as CheckoutSpinner, q as CheckoutStatus, F as FailureModalProps, r as FailureRoute, M as MockDriverOptions, O as OnFailedMap, s as OpensAxis, P as PaymentAxis, T as TriggerAxis, t as TriggerState, U as UpsellButton, u as UpsellButtonProps, v as UpsellCommonProps, w as UpsellRecovery, x as UseCheckoutOptions, y as createMockDriver, z as driverWithEmail, A as useCheckout } from './checkout-C4tFUEdF.cjs';
8
8
  import { ToasterProps } from 'sonner';
9
9
  export { ToasterProps, toast } from 'sonner';
10
10
  export { C as CheckoutError, a as CheckoutErrorCategory, b as CheckoutIntent, c as CheckoutProvider, d as CheckoutSurface, D as DeviceClass, H as HostedPaymentMode, I as INLINE_SURFACES, M as MANAGED_PROFILES, O as OffSessionReliability, e as OpensIn, P as PAYMENT_RENDERINGS, f as PROVIDER_HOSTED_SURFACES, g as PROVIDER_PROFILES, h as PaymentMode, i as PaymentRendering, j as ProviderProfile, k as ProviderVariant, S as SurfaceCapability, l as SurfacePreference, U as UpsellKind, V as ValidationResult, m as checkoutError, n as isCompleteSurface, o as isInlineSurface, p as isMerchantOfRecord, q as isOrchestrator, r as isProviderHostedSurface, s as isRenderableSurface, t as profileFor, u as renderableSurfaces, v as resolvePayment, w as resolveSurface, x as supportsManaged, y as surfacesFor, z as validateCheckout, A as validateTrialSurface, B as validateUpsell } from './capabilities-BtnJi2JD.cjs';
@@ -193,6 +193,12 @@ interface FunnelEventDataMap {
193
193
  productId?: string;
194
194
  eventId?: string;
195
195
  };
196
+ 'subscription.trial_started': {
197
+ amount?: number;
198
+ currency?: string;
199
+ productId?: string;
200
+ eventId?: string;
201
+ };
196
202
  'experiment.exposure': {
197
203
  experimentId: string;
198
204
  variant: string;
@@ -352,9 +358,12 @@ declare function attachBus(bus: FunnelBus): () => void;
352
358
  * versioned + published with the funnel. The dashboard's manual translation
353
359
  * table edits exactly these catalogs.
354
360
  *
355
- * Lookup walks a **fallback chain** (active → fallback → default) so a missing
361
+ * Lookup walks a **fallback chain** (active → fallback → default), widening each
362
+ * step from a regional tag to its language (`en-US` → the `en` catalog) exactly
363
+ * as {@link ./locale}'s `resolveLocale` matches supported locales, so a missing
356
364
  * string never blanks — it falls through, and only as a last resort returns the
357
- * key (flagged in dev). Interpolation is simple `{{var}}`; plurals use the
365
+ * key (flagged in dev). See {@link lookupMessage} for why that widening is not
366
+ * optional. Interpolation is simple `{{var}}`; plurals use the
358
367
  * built-in `Intl.PluralRules`; numbers/dates/percent use `Intl`. No ICU, no rich
359
368
  * markup (markup stays in TSX).
360
369
  */
@@ -1401,6 +1410,16 @@ declare const EVENT_CATALOG: {
1401
1410
  readonly tracking: true;
1402
1411
  readonly integrations: true;
1403
1412
  };
1413
+ readonly 'subscription.trial_started': {
1414
+ readonly sources: ["backend"];
1415
+ readonly tracking: true;
1416
+ readonly integrations: true;
1417
+ };
1418
+ readonly 'subscription.trial_converted': {
1419
+ readonly sources: ["backend"];
1420
+ readonly tracking: true;
1421
+ readonly integrations: true;
1422
+ };
1404
1423
  readonly 'subscription.renewal': {
1405
1424
  readonly sources: ["backend"];
1406
1425
  readonly tracking: true;
package/dist/index.d.ts CHANGED
@@ -1,10 +1,10 @@
1
1
  import * as react from 'react';
2
2
  import { ReactNode, ComponentType, ButtonHTMLAttributes, AnchorHTMLAttributes } from 'react';
3
- import { O as Offering, V as VariableValue, a as VariableConfig, A as Acquisition, D as Direction, F as FunnelContext, R as RuntimeExperiment, b as FunnelSnapshot, c as FunnelDefinition, d as buildContext, e as OfferingInput, P as PageMeta, f as PageContext, G as GroupProgress } from './manifest-BajvtPWs.js';
4
- export { B as BrowserContext, g as BuildContextOptions, C as ClickIdContext, h as CompileInput, i as Condition, j as ConditionOp, k as DeviceContext, E as EdgeCondition, l as ExperimentArm, m as ExperimentResolution, n as FlowPage, o as FunnelLocales, p as FunnelManifest, q as Gate, I as IdentityContext, r as Interval, L as LocaleContext, M as ManifestEdge, s as ManifestPage, t as ManifestValidation, u as Money, v as OsContext, w as PageComponent, x as PageGroup, y as PageType, z as Predicate, H as ResolvedOffering, J as Route, S as SampleOffering, K as SessionContext, N as SystemContext, U as UtmContext, Q as assignVariant, T as bucketingSeed, W as buildAcquisition, X as buildCatalog, Y as compileManifest, Z as currencyExponent, _ as defineFunnel, $ as definePage, a0 as entryGuard, a1 as evaluateCondition, a2 as evaluateGate, a3 as expectedPathLength, a4 as fnv1a, a5 as formatMoney, a6 as formatOffering, a7 as formatSampleOffering, a8 as groupProgress, a9 as hashToUnit, aa as isRtl, ab as isVariantKey, ac as nextPage, ad as outgoingKeys, ae as pageMeta, af as parseSlotKey, ag as pickByWeight, ah as resolveExperiments, ai as resolveLocale, aj as resolveOffering, ak as resolveRoute } from './manifest-BajvtPWs.js';
3
+ import { O as Offering, V as VariableValue, a as VariableConfig, A as Acquisition, D as Direction, F as FunnelContext, R as RuntimeExperiment, b as FunnelSnapshot, c as FunnelDefinition, d as buildContext, e as OfferingInput, P as PageMeta, f as PageContext, G as GroupProgress } from './manifest-Dp1oRvqp.js';
4
+ export { B as BrowserContext, g as BuildContextOptions, C as ClickIdContext, h as CompileInput, i as Condition, j as ConditionOp, k as DeviceContext, E as EdgeCondition, l as ExperimentArm, m as ExperimentResolution, n as FlowPage, o as FunnelLocales, p as FunnelManifest, q as Gate, I as IdentityContext, r as Interval, L as LocaleContext, M as ManifestEdge, s as ManifestPage, t as ManifestValidation, u as Money, v as OsContext, w as PageComponent, x as PageGroup, y as PageType, z as Predicate, H as ResolvedOffering, J as Route, S as SampleOffering, K as SessionContext, N as SystemContext, U as UtmContext, Q as assignVariant, T as bucketingSeed, W as buildAcquisition, X as buildCatalog, Y as compileManifest, Z as currencyExponent, _ as defineFunnel, $ as definePage, a0 as entryGuard, a1 as evaluateCondition, a2 as evaluateGate, a3 as expectedPathLength, a4 as fnv1a, a5 as formatMoney, a6 as formatOffering, a7 as formatSampleOffering, a8 as groupProgress, a9 as hashToUnit, aa as isRtl, ab as isVariantKey, ac as nextPage, ad as outgoingKeys, ae as pageMeta, af as parseSlotKey, ag as pickByWeight, ah as resolveExperiments, ai as resolveLocale, aj as resolveOffering, ak as resolveRoute } from './manifest-Dp1oRvqp.js';
5
5
  import { NavSnapshot } from './protocol.js';
6
- import { a as CheckoutDriver, C as CheckoutDriverContext } from './checkout-BYcOfyg_.js';
7
- export { b as Checkout, c as CheckoutAppearance, d as CheckoutButton, e as CheckoutButtonProps, f as CheckoutCallbacks, g as CheckoutClassNames, h as CheckoutCommonProps, i as CheckoutHandle, j as CheckoutInlineProps, k as CheckoutMethods, l as CheckoutProps, m as CheckoutRequest, n as CheckoutResult, o as CheckoutResume, p as CheckoutSpinner, q as CheckoutStatus, F as FailureModalProps, r as FailureRoute, M as MockDriverOptions, O as OnFailedMap, s as OpensAxis, P as PaymentAxis, T as TriggerAxis, t as TriggerState, U as UpsellButton, u as UpsellButtonProps, v as UpsellCommonProps, w as UpsellRecovery, x as UseCheckoutOptions, y as createMockDriver, z as driverWithEmail, A as useCheckout } from './checkout-BYcOfyg_.js';
6
+ import { a as CheckoutDriver, C as CheckoutDriverContext } from './checkout-B1K6ozwk.js';
7
+ export { b as Checkout, c as CheckoutAppearance, d as CheckoutButton, e as CheckoutButtonProps, f as CheckoutCallbacks, g as CheckoutClassNames, h as CheckoutCommonProps, i as CheckoutHandle, j as CheckoutInlineProps, k as CheckoutMethods, l as CheckoutProps, m as CheckoutRequest, n as CheckoutResult, o as CheckoutResume, p as CheckoutSpinner, q as CheckoutStatus, F as FailureModalProps, r as FailureRoute, M as MockDriverOptions, O as OnFailedMap, s as OpensAxis, P as PaymentAxis, T as TriggerAxis, t as TriggerState, U as UpsellButton, u as UpsellButtonProps, v as UpsellCommonProps, w as UpsellRecovery, x as UseCheckoutOptions, y as createMockDriver, z as driverWithEmail, A as useCheckout } from './checkout-B1K6ozwk.js';
8
8
  import { ToasterProps } from 'sonner';
9
9
  export { ToasterProps, toast } from 'sonner';
10
10
  export { C as CheckoutError, a as CheckoutErrorCategory, b as CheckoutIntent, c as CheckoutProvider, d as CheckoutSurface, D as DeviceClass, H as HostedPaymentMode, I as INLINE_SURFACES, M as MANAGED_PROFILES, O as OffSessionReliability, e as OpensIn, P as PAYMENT_RENDERINGS, f as PROVIDER_HOSTED_SURFACES, g as PROVIDER_PROFILES, h as PaymentMode, i as PaymentRendering, j as ProviderProfile, k as ProviderVariant, S as SurfaceCapability, l as SurfacePreference, U as UpsellKind, V as ValidationResult, m as checkoutError, n as isCompleteSurface, o as isInlineSurface, p as isMerchantOfRecord, q as isOrchestrator, r as isProviderHostedSurface, s as isRenderableSurface, t as profileFor, u as renderableSurfaces, v as resolvePayment, w as resolveSurface, x as supportsManaged, y as surfacesFor, z as validateCheckout, A as validateTrialSurface, B as validateUpsell } from './capabilities-BtnJi2JD.js';
@@ -193,6 +193,12 @@ interface FunnelEventDataMap {
193
193
  productId?: string;
194
194
  eventId?: string;
195
195
  };
196
+ 'subscription.trial_started': {
197
+ amount?: number;
198
+ currency?: string;
199
+ productId?: string;
200
+ eventId?: string;
201
+ };
196
202
  'experiment.exposure': {
197
203
  experimentId: string;
198
204
  variant: string;
@@ -352,9 +358,12 @@ declare function attachBus(bus: FunnelBus): () => void;
352
358
  * versioned + published with the funnel. The dashboard's manual translation
353
359
  * table edits exactly these catalogs.
354
360
  *
355
- * Lookup walks a **fallback chain** (active → fallback → default) so a missing
361
+ * Lookup walks a **fallback chain** (active → fallback → default), widening each
362
+ * step from a regional tag to its language (`en-US` → the `en` catalog) exactly
363
+ * as {@link ./locale}'s `resolveLocale` matches supported locales, so a missing
356
364
  * string never blanks — it falls through, and only as a last resort returns the
357
- * key (flagged in dev). Interpolation is simple `{{var}}`; plurals use the
365
+ * key (flagged in dev). See {@link lookupMessage} for why that widening is not
366
+ * optional. Interpolation is simple `{{var}}`; plurals use the
358
367
  * built-in `Intl.PluralRules`; numbers/dates/percent use `Intl`. No ICU, no rich
359
368
  * markup (markup stays in TSX).
360
369
  */
@@ -1401,6 +1410,16 @@ declare const EVENT_CATALOG: {
1401
1410
  readonly tracking: true;
1402
1411
  readonly integrations: true;
1403
1412
  };
1413
+ readonly 'subscription.trial_started': {
1414
+ readonly sources: ["backend"];
1415
+ readonly tracking: true;
1416
+ readonly integrations: true;
1417
+ };
1418
+ readonly 'subscription.trial_converted': {
1419
+ readonly sources: ["backend"];
1420
+ readonly tracking: true;
1421
+ readonly integrations: true;
1422
+ };
1404
1423
  readonly 'subscription.renewal': {
1405
1424
  readonly sources: ["backend"];
1406
1425
  readonly tracking: true;
package/dist/index.js CHANGED
@@ -1,6 +1,6 @@
1
1
  export { compileManifest } from './chunk-BOO6HJ4Y.js';
2
- import { useLocale, createConsoleTracker, exposurePayload, FunnelProvider, FunnelView, useField, useNavigation, useFunnel, CheckoutResume, EmbedBridge } from './chunk-PN7CRJAF.js';
3
- export { Checkout, CheckoutButton, CheckoutResume, CheckoutSpinner, FunnelProvider, FunnelToaster, FunnelView, Modal, Sheet, UpsellButton, VariableStore, attachBus, buildAcquisition, buildContext, createBus, createConsoleTracker, createFunnelStore, createMockDriver, defineModal, dismissAllModals, driverWithEmail, hideModal, isValidEmail, newEventId, registerModal, removeModal, showModal, toast, unregisterModal, useActiveLocale, useCheckout, useClickIds, useContextValue, useData, useDevice, useExperiment, useField, useFunnel, useGroupProgress, useLocale, useMarketingConsent, useModal, useNavigation, useOffering, useOfferings, usePage, useResponse, useSystem, useTracker, useTranslation, useUserAttribute, useUtm, withBus } from './chunk-PN7CRJAF.js';
2
+ import { useLocale, createConsoleTracker, exposurePayload, FunnelProvider, FunnelView, useField, useNavigation, useFunnel, CheckoutResume, EmbedBridge } from './chunk-WCBVSZHJ.js';
3
+ export { Checkout, CheckoutButton, CheckoutResume, CheckoutSpinner, FunnelProvider, FunnelToaster, FunnelView, Modal, Sheet, UpsellButton, VariableStore, attachBus, buildAcquisition, buildContext, createBus, createConsoleTracker, createFunnelStore, createMockDriver, defineModal, dismissAllModals, driverWithEmail, hideModal, isValidEmail, newEventId, registerModal, removeModal, showModal, toast, unregisterModal, useActiveLocale, useCheckout, useClickIds, useContextValue, useData, useDevice, useExperiment, useField, useFunnel, useGroupProgress, useLocale, useMarketingConsent, useModal, useNavigation, useOffering, useOfferings, usePage, useResponse, useSystem, useTracker, useTranslation, useUserAttribute, useUtm, withBus } from './chunk-WCBVSZHJ.js';
4
4
  export { assignVariant, bucketingSeed, buildCatalog, currencyExponent, defineFunnel, definePage, entryGuard, evaluateCondition, evaluateGate, expectedPathLength, fnv1a, formatMoney, formatOffering, formatSampleOffering, groupProgress, hashToUnit, isRtl, isVariantKey, nextPage, outgoingKeys, pageMeta, parseSlotKey, pickByWeight, resolveExperiments, resolveLocale, resolveOffering, resolveRoute } from './chunk-WIFTHXF5.js';
5
5
  import './chunk-U5R4ILJT.js';
6
6
  import './chunk-XEIWE7NY.js';
@@ -649,6 +649,17 @@ var EVENT_CATALOG = {
649
649
  "purchase.complete": { sources: ["backend"], tracking: true, integrations: true },
650
650
  "customer.first_purchase": { sources: ["backend"], tracking: true, integrations: true },
651
651
  "subscription.created": { sources: ["backend"], tracking: true, integrations: true },
652
+ // A trial START — free or paid. Fires INSTEAD OF purchase.complete/subscription.created for a
653
+ // trial settlement: one event per settlement, and a taxonomy that can distinguish a trial from
654
+ // an outright sale. Value is the money that moved (0 free / fee paid), never the sticker price
655
+ // of the subscription behind it. Ad networks map it back onto `Purchase` with every other
656
+ // acquisition; the distinction is kept for analytics/GTM/customer.io.
657
+ "subscription.trial_started": { sources: ["backend"], tracking: true, integrations: true },
658
+ // A recurring charge and the FIRST charge after a trial are economically different events, and
659
+ // neither is an initial purchase. Keeping them apart is load-bearing for ad networks: collapsing
660
+ // them onto the same name as `purchase.complete` double-counts one customer in the ad account's
661
+ // Purchase column, trains the bidder on money no click caused, and inflates reported ROAS.
662
+ "subscription.trial_converted": { sources: ["backend"], tracking: true, integrations: true },
652
663
  "subscription.renewal": { sources: ["backend"], tracking: true, integrations: true }
653
664
  };
654
665
  function isTrackableEvent(name) {