-
Notifications
You must be signed in to change notification settings - Fork 135
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
Add enableLegacyCheckout
option to PaymentOptions.
#365
Conversation
Currently, when a payer cannot or does not want to choose one of the payment methods provided in the PaymentRequest, they must cancel it. However, it could be that they can still complete the payment on the payee website via a custom checkout experience (and their shipping information could still be propagated). Requiring the payer to cancel the PaymentRequest in these circumstances is less than graceful. This patch adds an option to tell the user agent to provide an option (on the user interface) to complete checkout on the payee's website if they can't or do not want to select a payment method. The payer can make this selection when necessary instead of canceling the PaymentRequest.
I am not really sure I understand the idea here: what's basic card payment if not legacy payment? Does it make any sense for a merchant to say 'I'm going to update my site to use this new API, but not support basic card payment and fall back to my legacy form field checkout instead'? Putting that aside, does it not make more sense for legacy checkout to just be another |
I'm not comfortable with this proposal, though I need to think about it a bit more. It seems that it's again something that HTML's form auto fill should satisfy. |
There's more discussion following the original proposal here: #316 (comment) As @ianbjacobs mentioned, there was support for this feature on the most recent call. It could be seen as a more privacy aware alternative to |
I'm afraid I still don't really understand the need for it: it would make more sense if canMakePayment had been rejected. Sites can use canMakePayment to determine whether their accepted methods of payment (including basic card) are available. So they should already know ahead of time whether the user can pay successfully, meaning this legacy fallback isn't required. And again, the argument it's more privacy aware would only really be relevant if we hadn't agreed to take canMakePayment. Like Marco I think I'm going to need to think about it some more before being comfortable with it...I have a number of reservations and it seems to be a solution for a problem we already solved. |
My understanding is that In other words, this feature can be seen as an alternative to |
This feature is particularly useful at the present time, since Payment Request only supports Basic card (and digital wallets), and Payment Apps aren’t quite a “thing” yet. Consider the use case where a German merchant accepts credit cards, as well as Giropay and Sofort (both redirect-based payment methods which don't exist as Payment Apps yet). At the present time, if we call Allowing some form of “Pay via other payment method” link provides a better user experience. It is especially useful in the early days of Payment Apps, when there is a scarcity of payment apps that support Payment Request (however, I agree with a point that was made, which is that this could actually slow adoption of payment request (payment providers won’t necessarily be in a hurry to provide support for Payment Request if they have a “way out”). |
I do understand the problem WorldPay are talking about - but a much better way to solve this is just to make the legacy payment option another payment method just like basic card. The problem with this change as it stands is it's incompatible with our charter. From your pull request (emphasis mine):
And from the WG charter:
So I can't see how we can take this since it very clearly defines a user interface requirement, which the WG has explicitly said it's not going to do. Currently the spec is quite careful to always refer to UI in generic terms ("some kind of user interface", "show a user interface that allows a user to interact with a payment request"), and where we do specify UI requirements they're qualified with |
We can always use different language. I thought "provide an option on the user interface" was just as generic as "show some kind of user interface". Note, even in the examples you site, vague UI requirements are implied:
Both of these impose UI requirements that the user be able to interact with the payment request process or to facilitate it. We have plenty of other statements about "users providing shipping addresses" and so forth that could similarly be taken as UI requirements. We need to at least say why a user interface is necessary. We can change the language here to direct implementers to show some kind of user interface to let the user exit the payment request process without rejecting it (and without accepting a payment method). Or we can just say "if the user decided to do X" without mentioning user interface at all. Note that we don't need to say anything about the shape of the user interface. So I don't see how this substantively different (wrt to the charter) from other statements already made in the spec. As you said, we could alternatively create a special "legacy payment method" to capture this intent if that's really necessary, but it raises corner cases that must be addressed like dealing with payment apps asserting that they support this method. |
It's intriguing to think about "return to merchant legacy page" as a payment method, and
Why I don't think it's exactly a payment method:
If I understood the proposal, what is desired is:
Assuming for a moment that there are use cases to motivate this, do browser vendors think Ian |
I don't think that we should be adding either the |
That being said, if someone defines a payment method called |
Having discussed with the editors/implementers, we are not able to envision a good user experience for enabling the "legacy checkout flow". We are closing this issue, but happy to continue discussion. |
Currently, when a payer cannot or does not want to choose one of the payment methods provided in the PaymentRequest, they must cancel it. However, it could be that they can still complete the payment on the payee website via a custom checkout experience (and their shipping information could still be propagated). Requiring the payer to cancel the PaymentRequest in these circumstances is less than graceful.
This proposal adds a flag to tell the user agent to provide an option (on the user interface) to complete checkout on the payee's website if the payer can't or does not want to select a payment method. The payer can make this selection when necessary instead of canceling the PaymentRequest.
We may also want to consider adding options to the
show()
method instead of adding an option to the PaymentRequest constructor. That would allow other calls to be made on the PaymentRequest instance before a decision is made as to whether or not the legacy checkout option should be shown.The
enableLegacyCheckout
name is open to bikeshedding.The current version of this proposal sets the
methodName
on the PaymentResponse tonull
to indicate that no payment method was selected (instead, legacy checkout was selected) by the user. I'd like to know if that seems reasonable to implementers or if they have a better approach. Note that the user can still provide their shipping information through this mechanism (as currently proposed), even if they handle the payment via the legacy checkout.