#sise_error

1 messages ยท Page 1 of 1 (latest)

tardy dockBOT
#

๐Ÿ‘‹ 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.

dawn furnace
#

hi?

#

Would you help me?

#

I'm in trouble

sick bay
#

๐Ÿ‘‹ Happy to help!

#

Iโ€™m using Stripeโ€™s test card 4000002500003155 for testing.
Waht is the issue exactly you are facing ?

dawn furnace
#

Okay just a second

#

Can you check on test mode too?

#

I'm using test mode

sick bay
#

Yes sure

dawn furnace
#

I can't find request id....
but find event id

#

Evnet_id is evt_3ReBHSDtCzoOF5mQ1PRwHK8S

sick bay
#

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)

dawn furnace
#

Um,,, In my source on backend...
I was request it

                    customer: customer.id,
                    payment_method: stripeMethod.id,
                    usage: "off_session"
                })```
#

Is it not correct?

sick bay
#

No you should create the SetupIntent in order to collect the PaymentMethod

dawn furnace
#

I was read that documents...๐Ÿ˜ญ

#

Sorry but Can you check another event_id?

#

This is real stage event

sick bay
#

Yeah sure,

dawn furnace
#

Event_id: evt_3ReB7SDtCzoOF5mQ20vVWMyJ

sick bay
#

It's the same flow with the other

dawn furnace
#

As i see this payment method, was passed 3ds auth

sick bay
#

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 ?

sick bay
dawn furnace
#

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

sick bay
#

That's the point, you need to create the SetupIntent then collect the PaymentMethod

#

Please follow the guide I shared step by step

dawn furnace
#

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.

sick bay
#

what is the content of params ?

dawn furnace
#
                    customer: customer.id,
                    payment_method: paymentMethod.id,
                    automatic_payment_methods: {
                        enabled: true
                    },
                    usage: "off_session"
                }```
This is params
sick bay
#

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..

dawn furnace
#

Ah When create SetupIntent, not necessary payment method.....

tardy dockBOT