Quick question. Is there a way within the PWA code to identify if the user is viewing the app in a regular web browser vs the TWA downloaded app from the play store? It would be great if we identify if the user should be offered a different payment method in the case they're not using the Google Play TWA. Or, is it recommended to upload a different version of my PWA to the Google Play store that only features the Google Play payment API implementation and no backup service?
At the moment, window.getDigitalGoodsService('...') will be undefined if it is not in a context where the API can be used. It will also fail to return the requested service if it is not available, at which point you could try a different one or fall back to using the plain PaymentRequest API.
The now productive Digital Goods API v2.1 does not have an acknowledge, that was only in API v1.0 (now deprecated). It needs to be done in the backend. Purchase Type cannot be indicated in the play developer api (androidpublisher API).
If i set up my PWA with stripe or paypal to protect premium content, then submit to the playstore with bubblewrap, will it get rejected because Google Play billings is not activated? Can you set up Play Billing after the PWA is submitted via bubblewrap?
How can I debug this locally? Is the only way to deloy it and open in TWA on my android phone? It's super inconveneint in terms of development. Is there a way to simulate TWA in localhost?