#sise_error
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/1387721140780138546
๐ Have more to share? Add more details, code, screenshots, videos, etc. below.
๐ Happy to help!
Iโm using Stripeโs test card 4000002500003155 for testing.
Waht is the issue exactly you are facing ?
Can you share the ID (req_xxx) of the failing API request?
https://support.stripe.com/questions/finding-the-id-for-an-api-request
Yes sure
I can't find request id....
but find event id
Evnet_id is evt_3ReBHSDtCzoOF5mQ1PRwHK8S
That was generated from this request: req_JXyYpJHmOe1pRB
That request was made using this PaymentMethod pm_1ReBHHDtCzoOF5mQ3jPeIg8y req_SM48AivayWeLpM
Which didn't passed the 3DS
you need to use Setupintent in order to collect the payment method correctly (with 3Ds)
Um,,, In my source on backend...
I was request it
customer: customer.id,
payment_method: stripeMethod.id,
usage: "off_session"
})```
Is it not correct?
No you should create the SetupIntent in order to collect the PaymentMethod
I invite you to follow this guide:
https://docs.stripe.com/payments/save-and-reuse
In order to set the flow correctly
I was read that documents...๐ญ
Sorry but Can you check another event_id?
This is real stage event
Yeah sure,
Event_id: evt_3ReB7SDtCzoOF5mQ20vVWMyJ
It's the same flow with the other
As i see this payment method, was passed 3ds auth
You are not using SetupIntent in order to collect the Payment Method
Can you start a fresh new test integration and follow that guide step by step ?
In the guide I shared, when creating the SetupIntent, you shouldn't pass the pyament method Id
Ah sorry, I'll show you more lines my code.
const stripeMethod = await this.stripe.withCountry(country).getPaymentMethod(body.paymentMethodId)
const customerParams: Stripe.CustomerCreateParams = {
email: owner.email,
name: _organization.name,
payment_method: stripeMethod.id
}
// ์ด์ pshyg๋์ ์ปค๋ฉํธ: Create a customer and register a paymentMethod, otherwise the paymentMethod can only be used once for a payment.
const customer = await this.stripe.withCountry(country).newCustomer(customerParams)
// 3ds ์ธ์ฆ์ ์ํ client_secret ๋ฐ๊ธ
// threeDSUsage ๊ฐ์ด true ์ผ ๋๋ง 3ds ์ธ์ฆ์ ์ํ client_secret ๋ฐ๊ธ
const setupIntent = body.threeDSUsage
? await this.stripe.withCountry(country).newSetupIntent({
customer: customer.id,
payment_method: stripeMethod.id,
automatic_payment_methods: {
enabled: true
},
usage: "off_session"
})
: undefined`````
I'm using paymentMethod Id when create setup intent
That is backend source apart
That's the point, you need to create the SetupIntent then collect the PaymentMethod
Please follow the guide I shared step by step
Just check one more please
newSetupIntent function is
async newSetupIntent(params: Stripe.SetupIntentCreateParams) {
return await this.instance.setupIntents.create(params)
}```
Is that correct using call api?
I'll read document again.
what is the content of params ?
customer: customer.id,
payment_method: paymentMethod.id,
automatic_payment_methods: {
enabled: true
},
usage: "off_session"
}```
This is params
You need to remove payment_method: paymentMethod.id,
The PaymentMethod will be created when you confirm the SetupIntent using Stripe Elements
First you create the SetupIntent then you collect the PaymentMethod by confirming it..
Ah When create SetupIntent, not necessary payment method.....