Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Google Pay & Web Payment Request API:

I've been trying to implement Google Pay by following the Google Pay API PaymentRequest Tutorial. I have everything implemented, however when I try to test on my Android phone, I get the following popup:

Request Failed
An unexpected error has occurred. Please try again later.

I've followed the troubleshooting guide, and using ADB I can see the following error:

WalletMerchantError: Error in loadWebPaymentData: PaymentDataRequest.transactionInfo is required

This seems to imply that transactionInfo should be included in my paymentMethods object. However, the tutorial states otherwise:

The transactionInfo property should be omitted. Total price and currency should instead be specified in the details argument passed to PaymentRequest

Any advice?

like image 390
David Mihal Avatar asked Jul 21 '26 10:07

David Mihal


1 Answers

I recently ran into this error myself.

My own experience was that it worked with Chrome Desktop but failed on Chrome Android. I've reached out to the Google Pay team and they have acknowledge that this is a bug. No ETA on resolution for this.

The general advice is to integrate with the using the Google Pay JavaScript library instead (see: https://medium.com/dev-channel/web-payments-payment-request-api-and-google-pay-a1073e405235)

like image 98
Soc Avatar answered Jul 22 '26 22:07

Soc