#carboncopper_api

1 messages ¡ Page 1 of 1 (latest)

crystal veldtBOT
#

👋 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/1391687987686801429

📝 Have more to share? Add more details, code, screenshots, videos, etc. below.

tacit ermine
#

Could you share your Stripe account id? acct_xxx

sacred lily
#

acct_1RdQSeHXP3ftfQJi

crystal veldtBOT
sacred lily
#

I'm working with https://js.stripe.com/v3/?ver=3.23.0 , if that makes a difference.

jolly forum
#

I think that error is likely a red herring. Are you sure createConfirmationToken never resolves?

sacred lily
#

Yes. I've tried many times. Nothing happens even after hours of waiting.

jolly forum
#

Are you initialising the Element with or without a client secret?

sacred lily
#

Without.

jolly forum
#

Let me quickly try to reproduce

#

Cna you share the full options hash you pass to stripe.elements()? currency, etc

sacred lily
#
const elements = stripe.elements({
    mode: 'payment',
    currency: 'gbp',
    payment_method_types: ['bacs_debit'],
    amount: 1000,
    appearance: {
        variables: {
            colorText: $input.css('color'),
            colorTextSecondary: $(document.body).css('color'),
            colorBackground: $input.css('backgroundColor'),
            fontFamily: $input.css('fontFamily'),
            borderRadius: $input.css('borderRadius'),
        },
        rules: {
            '.Input': {
                borderColor: $input.css('borderColor'),
            },
            '.CheckboxInput': {
                borderColor: '#777777',
                borderRadius: '3px',
            },
            '.CheckboxLabel': {
                fontWeight: 'bold',
            }
        }
    }
});
#
const paymentElement = elements.create('payment', {
    fields: {
        billingDetails: 'never'
    }
});
#
            return stripe.createConfirmationToken({
                elements,
                params: {
                    payment_method_data: {
                        billing_details: {
                            name: 'John Doe',
                            email: 'john.doe@example.com',
                            phone: '18005551234',
                            address: {
                                city: 'Beverly Hills',
                                country: 'US',
                                line1: '123 Main St',
                                line2: '',
                                postal_code: '90210',
                                state: 'CA',
                            }
                        }
                    }
                }
            });
jolly forum
#

Do you get the mandate dialog when you call createConfirmationToken?

sacred lily
#

No.

#

I'm working with a platform that has its own modal dialogs. Now that I see there's a dialog from Stripe.js, I'm thinking my platform dialog's z-index might be blocking Stripe's.

jolly forum
#

Yeah that is weird. It works for me using your exact setup

jolly forum
#

It's likely buried

sacred lily
#

Is there a way to put the Stripe dialog into a custom DIV?

jolly forum
#

Afraid not

sacred lily
#

Okay. Thanks for your help. I found the Stripe dialog underneath my platform's own modals. I have a way forward now.