I am developing Apple Pay. After the payment window is opened, it is stuck in the processing state for about 30 seconds and does not progress to "payment is not completed." My development environment can only be checked by the 'alert window', so I ask for your help.
var promise = ApplePaySession.canmakePaymentsWithActiveCard(merchantIdentifier);
if(promise){ session.onvalidatemerchant = function(event){ const url = event.validationURL; alert(url);// url is well generated myFuntion(url, function(merchantSession){ session.completeMerchantValidation(merchantSession);}) }
session.onpaymentauthorized = function(event){alert("); //This does not occur. }
The order of occurrence is as follows.
- session.begin();
- Payment window and card opened normally .
- Stuck during processing
- "Payment not completed" about 30 seconds later
- The payment window closes automatically
- Onvalidatemeerchant event Url is alerted
- Function in session.oncancel executed
I only used the essential onvalidatemeerchat, onpayment authorized for events. Merchant Id was also entered correctly. Is there anything else I can check here? Help me.