Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[QUESTION] Make totalPriceStatus customizable in GooglePayPaymentMethodLauncherContractV2.Args #10164

Open
hjdealba96 opened this issue Feb 13, 2025 · 2 comments
Labels

Comments

@hjdealba96
Copy link

Summary

We're trying to use GooglePayPaymentMethodLauncher to prompt the Google Pay sheet and collect payment methods for future usage. However, displaying pricing information on it is not convenient for us since we apply a fee based on the payment method type (credit or debit). Our plan is to show the fee information in our UI after the user selects a card from their wallet, allowing us to display accurate pricing.

Since the totalPriceStatus field (see code) is set by default to Estimated, usage of GooglePayPaymentMethodLauncher implies providing a price via the totalPrice field (see code), otherwise, a 0 value will get displayed. We definitely don't want this behavior.

We discovered there's a NotCurrentlyKnown value (see code) for TotalPriceStatus. We experimented with it in a sample Google Pay integration project from Google and it has the effect we want, see this picture:

picture

Here's the sample code used:

private fun getTransactionInfo(): JSONObject =
    JSONObject()
        .put("totalPriceStatus", "NOT_CURRENTLY_KNOWN")
        .put("countryCode", Constants.COUNTRY_CODE)
        .put("currencyCode", Constants.CURRENCY_CODE)

We want to know if there's a chance to make this field parametrizable to support use cases like ours.

@hjdealba96 hjdealba96 changed the title [QUESTION] Is it possible to make totalPriceStatus parametrizable in GooglePayPaymentMethodLauncherContractV2.Args? [QUESTION] Make totalPriceStatus customizable in GooglePayPaymentMethodLauncherContractV2.Args Feb 19, 2025
@cttsai-stripe
Copy link
Contributor

Hi @hjdealba96, Thank you for the suggestion! We'll prioritize evaluating this and revisit our roadmap accordingly.

@hjdealba96
Copy link
Author

Thank you @cttsai-stripe, I would appreciate it and please keep me posted.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants