#BaileyH

1 messages · Page 1 of 1 (latest)

weary wolfBOT
sonic finch
#

Can you share an example test payment that isn't doing what you expect?

velvet warren
#

In this case we are using invoices which trigger a payment when a users trial is ended, this transaction occurs outside of our platform when stripe creates and finalizes the invoice after we update the users subscription end date.

#

Would it help to link an ID or part of the invoice object?

sonic finch
#

this transaction occurs outside of our platform when stripe creates and finalizes the invoice after we update the users subscription end date.
Can you explain more about this?

#

Sure, an example invoice or payment where this didnt happen as you expect would be great

velvet warren
#

If you have access to the dashboard: https://dashboard.stripe.com/test/payments/pi_3MUF34CEQnHi4E9W0sLqRrZc
The activity follows:
We call stripeClient.subscriptions.update with {trial_end: 'now'}
A payment intent is created by stripe for this invoice as a response to our post.

The payment intent fails with 'requires_action', requiring 3d auth. This payment is triggered from stripe. When I click on the user profile, they have a card set as default with a setup for future intent, and the invoice shows that card to have been used

#

If it helps to remove the complexity with the invoice, we are also able to recreate this issue with a $1 payment intent creation/confirmation with the same card, the card also having already been setup for future intent but the payment being rejected.

sonic finch
#

Let me take a lok at that payment

velvet warren
#

This results in the user getting two prompts, a prompt for future intent, and another prompt for 3d authorization for the charge. I expected this 2nd prompt to not exist due to the setup intent from the first call

sonic finch
#

Interesting

#

Can you share one of those example payment intents using the setup PM that it happens to?

velvet warren
#

One thing that tips me off, and im not sure if this is just a display choice, the payment method box on this payment intent does not have the 'setup for use' field, but the card under the customer does. This may just be intended UI though.

sonic finch
#

First off, you should not do that -- thats what the setup intent does

#

Ah, it looks like you're sending setup_future_usage: "off_session", when you create the PI, even though it was already set up -- that might be triggering this (unsure about the subscription payment, though)

If you set up the card with a setup intent, you don't need to do setup_future_usage

#

Can you do a test PI without that, after the PM is created & setup via setup intent?

#

But as I said, creating payments like this following setup is not recommended. You should either set up via a setup intent without payment, or using a payment intent if taking payment up front

velvet warren
#

First off, you should not do that -- thats what the setup intent does
We also use it to verify the card is real with a balance of at least $1, we have had a lot of fraudulent signups with no-balance cards. Is there an alternative or is this not recommended to do?

#

I will definitely try removing that field, but the primary issue is that we make nearly all of our transactions off session and with invoices/subscriptions

sonic finch
#

Note that even when set up, future (real) payments can always lead to authentication, this is at the banks discretion

#

In test mode there should not be an additional auth, though, for that card

velvet warren
#

Yep, that is why I was rather confused that this card listed as 'requires unless setup' was always prompting for payment. I will look into removing that intent and seeing if that fixes anything, thanks for your help and looking into this

sonic finch
#

I do note that the trial end request is different, and you're not sending the setup param there, so i'd expect it to work as described

velvet warren
#

Is there any obvious fix to that if the capture is set to automatic and never hits our servers?

sonic finch
#

What do you mean by that?

velvet warren
#

Well sorry, I suppose my question is how do we link an invoice/subscription to an authorized future intent if that isn't happening now? Is this something we need to set at the invoice level once the user confirms their card?

#

I do note that the trial end request is different, and you're not sending the setup param there, so i'd expect it to work as described
I took this as you expect the invoices to fail because it is missing the intent, I may have misunderstood

sonic finch
#

No i mean i would expect it to work since it doesn't include that extra parameter that may be causing issues

velvet warren
#

Ah okay, I will go ahead and remove that extra PI and test the whole flow again, thank you

sonic finch
#

NP