From d78090d53ff73d98610e72fe9f6483103c849784 Mon Sep 17 00:00:00 2001 From: Alessandro Date: Mon, 20 Jan 2025 17:21:08 +0100 Subject: [PATCH] chore: [IOBP-1141] Added `psp_selected` mixpanel property for the payment flow (#6616) ## Short description This PR adds the `psp_selected` mixpanel property to the outcome errors page if present. ## List of changes proposed in this pull request - Mapped the `psp_selected` property to the mixpanel event when occurs an outcome error. --- ts/features/payments/checkout/analytics/index.ts | 1 + .../payments/checkout/screens/WalletPaymentOutcomeScreen.tsx | 1 + 2 files changed, 2 insertions(+) diff --git a/ts/features/payments/checkout/analytics/index.ts b/ts/features/payments/checkout/analytics/index.ts index bdcfc243497..e55c08fd8ab 100644 --- a/ts/features/payments/checkout/analytics/index.ts +++ b/ts/features/payments/checkout/analytics/index.ts @@ -27,6 +27,7 @@ export type PaymentAnalyticsProps = { payment_method_selected_flag: PaymentAnalyticsSelectedMethodFlag; preselected_psp_flag: PaymentAnalyticsPreselectedPspFlag; selected_psp_flag: PaymentAnalyticsSelectedPspFlag; + psp_selected: string; editing: PaymentAnalyticsEditingType; }; diff --git a/ts/features/payments/checkout/screens/WalletPaymentOutcomeScreen.tsx b/ts/features/payments/checkout/screens/WalletPaymentOutcomeScreen.tsx index 5bc6c5a13ed..40e1f093666 100644 --- a/ts/features/payments/checkout/screens/WalletPaymentOutcomeScreen.tsx +++ b/ts/features/payments/checkout/screens/WalletPaymentOutcomeScreen.tsx @@ -277,6 +277,7 @@ const WalletPaymentOutcomeScreen = () => { service_name: paymentAnalyticsData?.serviceName, attempt: paymentOngoingHistory?.attempt, expiration_date: paymentAnalyticsData?.verifiedData?.dueDate, + psp_selected: paymentAnalyticsData?.selectedPsp, payment_phase: outcome === WalletPaymentOutcomeEnum.GENERIC_ERROR ? getPaymentPhaseFromStep(currentStep)