#carboncopper_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/1391687987686801429
đ Have more to share? Add more details, code, screenshots, videos, etc. below.
Could you share your Stripe account id? acct_xxx
acct_1RdQSeHXP3ftfQJi
I'm working with https://js.stripe.com/v3/?ver=3.23.0 , if that makes a difference.
I think that error is likely a red herring. Are you sure createConfirmationToken never resolves?
Yes. I've tried many times. Nothing happens even after hours of waiting.
Are you initialising the Element with or without a client secret?
Without.
Let me quickly try to reproduce
Cna you share the full options hash you pass to stripe.elements()? currency, etc
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',
}
}
}
}
});
Do you get the mandate dialog when you call createConfirmationToken?
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.
Yeah that is weird. It works for me using your exact setup
That's definitely a possibility, I'd check the DOM for that modal dialog being added when you call createConfirmationToken
It's likely buried
Is there a way to put the Stripe dialog into a custom DIV?
Afraid not
Okay. Thanks for your help. I found the Stripe dialog underneath my platform's own modals. I have a way forward now.