From 41e3f416e89ae81e340330a6b0d20c28e15a73aa Mon Sep 17 00:00:00 2001 From: Deepti Luthra <109640446+deepti-imx@users.noreply.github.com> Date: Wed, 20 Dec 2023 10:42:06 +1000 Subject: [PATCH] [WT-2010] update telemetry prop name (#1301) --- packages/checkout/sdk/src/types/config.ts | 4 ++-- .../src/context/analytics-provider/SetupAnalytics.tsx | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/checkout/sdk/src/types/config.ts b/packages/checkout/sdk/src/types/config.ts index 50e5168e3d..44c38b1be5 100644 --- a/packages/checkout/sdk/src/types/config.ts +++ b/packages/checkout/sdk/src/types/config.ts @@ -152,10 +152,10 @@ export type ImxAddressConfig = { /** * A type representing the telemetry configurations. - * @property {string} publishableApiKey + * @property {string} segmentPublishableKey */ export type TelemetryConfig = { - publishableApiKey: string + segmentPublishableKey: string }; /** diff --git a/packages/checkout/widgets-lib/src/context/analytics-provider/SetupAnalytics.tsx b/packages/checkout/widgets-lib/src/context/analytics-provider/SetupAnalytics.tsx index 349363d76d..c1684e97ba 100644 --- a/packages/checkout/widgets-lib/src/context/analytics-provider/SetupAnalytics.tsx +++ b/packages/checkout/widgets-lib/src/context/analytics-provider/SetupAnalytics.tsx @@ -27,7 +27,7 @@ export function SetupAnalytics( (async () => { const config = await telemetry() as TelemetryConfig; if (!config) return; - updateWriteKey(config.publishableApiKey); + updateWriteKey(config.segmentPublishableKey); })(); }, [telemetry]);