#benjamin - PaymentIntents and React

1 messages ยท Page 1 of 1 (latest)

cunning granite
#

Hi there! Adding your questions here so we can keep this in a single thread:

#

[2/2] Questions:

1.) The above strategy depends on creating a dummy payment intent, which means we need to set capture_method on the PI to "manual". The docs note that not all payment methods support "manual". We specifically need to support card payments inclusive of google and apple pay at the moment. Will that be a problem with those methods? And more generally, where can I find documentation on this?

2.) I see there is a setup_future_usage parameter for PI. I assume that when creating the initial dummy PI, i'd want this set to false, but if user wants recurring payment, and we plan to do 1 one-time payment followed by subscription (that we create after processing initial one-time payment), should the PI be updated to have setup_future_usage = true before confirming?

3.) Some of our partner orgs want to enable Google and Apple Pay, while others do not. If we're using Elements + PaymentMethod, is this something that should/can be configured by the partner org in their own Stripe dashboard (keeping in mind they will be connected to my org's stripe account which is one handling all these requests), or is this something that needs to be configured when creating PI on backend via payment_method_types parameter (which, i'll note does list apple / google as acceptable option values in docs), or is this something that possibly gets configured in the SPA?

Thanks so much for your continuing help!

#

I'll aim to answer the questions one by one!

weary ingot
#

But how else do i create a "dummy" PI?

#

ohhhhh, i see, it's specifically about the confirmation step, not the initial creation of PI

cunning granite
#

So, in this case, you'd create a PaymentIntent. Upon creation, it'll be in requires_payment_method status, essentially waiting for both payment method details and confirmation

weary ingot
#

can the capture method be updated before confirmation? we have an interstitial step once we know user details where we run their info through a "bad actor API" and flag the contribution if we think a bot. we'd know that after creating initial PI but before having customer confirm.

#

and when we flag, we go ahead and confirm payment, but we manually have to approve those payments and only collect funds after doing this.

#

looks like that's a yes, via API docs, so think question 1 is all answered ๐Ÿ™‚

cunning granite
#

For question 2, yes, if you plan on using the PaymentMethod for future charges without having customers return to your application, you should use setup_future_usage = true

#

For question 3, could you share what type of Connected accounts you're using?

weary ingot
#

FWIW, I'm not original dev on this project so just getting up to speed on the stripe integration. Can you tell me how I'd determine which kind we're using?

#

Asked someone in org, and answer is "Standard"

cunning granite
sly hare
#

Hi there ๐Ÿ‘‹ taking over for @cunning granite

For question 3: you would have to use payment_method_types in the Payment Intent created on the back-end in this case

#

Ah, wait. I think we recently added the functionality to give them access to enabling/disabling via their Dashboard.

#

Just a minute

weary ingot
#

yeah, i actually just got a log in for my org's dashboard, and looks like it's configurable

sly hare
#

Is that screenshot from the standard account's dashboard? Or from the platform's dashboard?

weary ingot
#

that's from platform's

#

but looks like we can configure on settings for connected accounts maybe???

sly hare
weary ingot
#

Got it. So the standard account can manage on their own. That's good. Is that also to say that we can manage for them too? That second screenshot I got. by going to list of connected accounts, clicking on one, then viewing that account's settings, and the URL makes it seem like it's for that account in particular: https://dashboard.stripe.com/test/connect/accounts/acct_1KWT92H4mbMynu69/settings/payment_methods

sly hare
#

Yes. You can individually configure via that dashboard view as well

weary ingot
#

Awesome. And one more question: it sounds like can also configure from the backend via API at payment intent creation time based on what you said before. Is that right?

sly hare
#

Correct

weary ingot
#

So how do you enable for card but not google/apple when creating payment intent? Is that a matter of disabling automatic methods and then only using "card" for the payment methods param?

sly hare
#

I should caveat by mentioning that you would have to be using the Payment Element in order to do it at the Payment Intent level. You'd simply configure the Payment Element by setting wallets[applePay] and wallets[googlePay] to never

#

Payment Intents themselves consider the card payment method type synonymous with G-pay and Apple Pay, so if you accept card payments on the Payment Intent, then automatically you accept wallet payment method types unless overriden by the Payment Element

weary ingot
#

awesome. this is extremely helpful. i appreciate your time.