#op84_api
1 messages ยท Page 1 of 1 (latest)
๐ Welcome to your new thread!
โฒ๏ธ We'll be here soon! Typically we respond in a few minutes, but sometimes we might take a bit longer if the server is busy or if you have a particularly tricky question.
โฑ๏ธ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can always start a new thread if you have another question.
๐ This thread will always be available, even after it's closed. You can find it again using Discord's search, or you can save this link: https://discord.com/channels/841573134531821608/1366310657825312840
๐ Have more to share? Add more details, code, screenshots, videos, etc. below.
I think it should be recognized automatically. Do you see otherwise?
there are some payments which fail.. for example bank account closed.. but that wouldnt fix a mandate.. so probably its automatically.. when looking at this customer cus_QkAvZm6YltBvRm i have some incomplete .. there it says i should add the mandate_data.. how can i fix those payments like best practice for the user? add a new payment method and update the payment intent with the new payment method? or wire transfer and it automatically completes the payment intent? and when looking at the payment intent with the api - it has no error.. it says status requires_confirmation.. how to handle that smart?
Okay looking at one example
So you created a SetupIntent seti_1QmtNoClnEzULH8azOno8uFO
On Jan
Then its has pm_1QmtPNClnEzULH8aUe81M1ls, with mandate_1QmtPNClnEzULH8awMGtQxkD, but this mandate was inactive from April 3
Later you try to confirm pi_3R8u7rClnEzULH8a1GCQCA3y using the same mandate, but it's inactive and that's why you received an error
The best practice would be asking the customer for another mandate when you catch this error
so the mandate was inactive because of a failed payment?
and i would then reuse the payment method and present the user with a message where he says i consent of using my bank account basically? or is there something you guys provide.. currently i use stripe elements to create the setup intent which saves the iban and stuff with the mandate message.....
also in some other cases.. the status also the mandate message is the same but the bank account is closed.. so a mandate wouldnt change a thing.. so i would like to create a simple solution for those problems
hi! I'm taking over this thread.
cool hi @crude bronze
so the mandate was inactive because of a failed payment?
no. we sent you a webhook event to notify you that the mandate became inactive on 2025-03-04
also i'm figuring out if i need to save browser and ip of the client when he's creating the setup intent..
so i would like to create a simple solution for those problems
when you get an error due to the mandate, the best option is to re-collect the payment method with a new mandate
also i'm figuring out if i need to save browser and ip of the client when he's creating the setup intent..
why? if you use PaymentElement to collect the payment information, then Stripe will save all the information needed for you.
this would mean i need to update the payment method on the payment intent and then confirm the payment again?
need to update the payment method
you don't update anything. you create a brand new PaymentIntent (or SetupIntent), which will generate a brand new PaymentMethod and Mandate.
awesome - some of you guys said i need to save that and send it with mandate_data to every payment intent.. not in this convo..
Hum... then I recommend to do some tests in test mode to double check if it's working or not.
ok but i want to 'solve' (pay) the incomplete payment intent
I think it would be simpler to create a new one. otherwise yes, you would update the PaymentIntent with the new PaymentMethod.
but if you look for example at pi_3R8u7rClnEzULH8a1GCQCA3y and then pi_3QGBS7ClnEzULH8a1C8jJ47r.. using the same payment method.. one failed and was then paid with bank transfer.. which would be ok for me. and the other one before is in this mandate missing state.. i did not get a new mandate.. for the last payment so its strange
give me a few minutes to look into this
using the same payment method
the two PaymentIntent you just shared are using different Payment Method.
one ispm_1QmtPNClnEzULH8aUe81M1ls, the otherpm_1RCzFjClnEzULH8a7CoMogvn.
are you sure one was paid by bank transfer after failing..
- pi_3R8u7rClnEzULH8a1GCQCA3y was created with pm_1QmtPNClnEzULH8aUe81M1ls in this request: https://dashboard.stripe.com/logs/req_ReNtCxw2o3800J
- pi_3QGBS7ClnEzULH8a1C8jJ47r was created with pm_1Pt2hCClnEzULH8a2lypbkoX in this request https://dashboard.stripe.com/logs/req_35ejeN1dWBOXZa, then it changed to pm_1RCzFjClnEzULH8a7CoMogvn
so yes, completely different payment method were used
pm_1RCzFjClnEzULH8a7CoMogvn but is this the bank transfer?
could i update pi_3R8u7rClnEzULH8a1GCQCA3y this to use bank transfer too? how do i see on the payment intent object that this failed because of mandate missing?
sorry those are the last questions i swear ๐
pm_1RCzFjClnEzULH8a7CoMogvn but is this the bank transfer?
yes
could i update pi_3R8u7rClnEzULH8a1GCQCA3y this to use bank transfer too?
you can try, but not sure if it will work or not
how do i see on the payment intent object that this failed because of mandate missing?
I'm not sure I understand this question
when i look on the payment intent object it says status 'requires_confirmation' not that there was an error..
which PaymentIntent are you talking about?
pi_3R8u7rClnEzULH8a1GCQCA3y for example
you can see it in this request: https://dashboard.stripe.com/logs/req_FzQxnu2X1byPaQ
This PaymentIntent requires a mandate, but no existing mandate was found. Collect mandate acceptance from the customer and try again, providing acceptance data in the mandate_data parameter.
yes i know but there is no error on the payment intent itself.. i would have to go through the requests?
yes, you made a request and Stripe returned a 400 error.
how can i test this mandate missing thing .. https://docs.stripe.com/testing?testing-method=card-numbers&payment-method=sepa-direct-debit doesnt look like there is an iban for that
There's no real way to test that specific error AFAIK as you can't cancel/void an exisitng mandate. I guess the way to test it is using the same method you did to trigger this error