how to add google pay pass into wallet app in android using JWTToken

318 Views Asked by At

I have been working on the Apple wallet pass and google wallet pass for my react native project. For iOS we are good with apple wallet pass implementation, but for android somethings are still not clear.

We have done all the set up from the google wallet api console and finally got the JWT token for the google wallet pass, but the library which I'm using to add the passes from the application to device is accepting the base64 data of the pass.

Now I think the base64 of JTW token will not work which has url embed into it.

  1. How do I load the jwt token with react native code? Do I need user android native code for that ?
  2. Can I use the same .pkpass file of the iOS in android also ? Will it prompt the user to add into their google wallet for android devices ?

Any suggestions or help is appreciated.

Thanks.

1

There are 1 best solutions below

0
grundyoso On

So that library appears to only support pkpass file generation. If you want to use pkpass compatible wallet installed such as WalletPasses. In your scenario, it seems like you have the pay.google.com link with the JWT at the end, you'd need to open a webview OR redirect to the browser with that URL.

Alternatively, you can use a service like PassNinja whose API is entirely web based and keep a uniform experience across platforms.