Problem/Motivation

The initial implementation of Payment Element only supported the Card payment method type. (The primary difference to the Card Element was this also added GooglePay and ApplePay support.)

The fields for that Payment Method Type were specific to card. When support for other Payment Method Types were added, e.g. ACH and CashApp, it was necessary to create separate payment method types to avoid the card specific fields, add appropriate fields for those types, and also to handle small deltas for each payment method type.

While multiple payment method types have been added over time, we have not caught up to all the payment methods that Stripe already supported, much less the newer ones they continue to add.

The initial development rule was to NOT enable payment method in Stripe that were not support by this module. This has become untenable between developers not heeding this, clients making changes themselves, or, in some cases, Stripe turning on payment methods on client accounts.

In any of these cases, a payment will go through successfully, but we had no way to handle the unsupported payment method, causing the order to be in an inconsistent state.

We have also evolved more of our handling of payment methods, so that the majority of it is signaled by properties and/or states. e.g. The stripe payment intent "processing" status tells us that the payment is NOT complete, until s webhook signals success (or failure). Regardless of capture state, we know not to set the payment to captured until then.

Because of this, we can handle payment method types in a more generic way, and we can therefore (theoretically) support all payment method types using a generic default one.

There are caveats to this. e.g. we know for ACH, we must request "instant" vcerification, as micro-deposit verification won't work. We know that there are issues with CashApp for reusable payments. (Though maybe this one is fixed now?)

We will likely find some new edge scenarios that will need to be addressed, but by implementing the default payment method type, we should be able to handle all payment methods immediately.

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

tomtech created an issue. See original summary.

  • 44f1f54c committed on 2.x
    feat: #3591925 Add default payment method type
    
    By: tomtech
    
tomtech’s picture

Status: Active » Fixed

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.