#TESLA_17
1 messages · Page 1 of 1 (latest)
Hi there, can you share with me the relevant code?
it roughly looks like this
const { error } = await initPaymentSheet({
merchantDisplayName: 'Nivoda',
customerId: stripeConfig.customer_stripe_id,
paymentIntentClientSecret: paymentIntent,
// Set `allowsDelayedPaymentMethods` to true if your business can handle payment
// methods that complete payment after a delay, like SEPA Debit and Sofort.
allowsDelayedPaymentMethods: true,
appearance: CustomStripeAppearance(theme),
});
and i am opening the sheet like this
const { error } = await presentPaymentSheet();
if (error) {
if (error.code === PaymentSheetError.Canceled) // handle cancel;
if (error.code === PaymentSheetError.Failed) {
// ERROR SHOWS HERE FOR SEPA/BACS
console.log('Failed ! stripe', error.message);
}
} else {
// Alert.alert('Success', 'Your order is confirmed!');
}
the card / us_bank_account payments works fine, but SEPA/BACS doesn't, and we setup_future_usage: off_session set on the creation of the intent
So you mean you have this problem when using setup_future_usage in payment intent?
i believe this the reason for SEPA payments after doing research, but i can't found anything about BACS
https://stripe.com/docs/payments/payment-methods/integration-options#support-bank-debits bacs_debit is not yet supported in mobile payment element (aka paymentsheet)
is there an alternative solution to accept BACS payment on mobile, can i build my own UI ?
Yes you can create a UI by yourself.
I can't find an example in stripe-react-native repo, but this is an example from android repo https://github.com/stripe/stripe-android/blob/master/example/src/main/java/com/stripe/example/activity/BacsDebitPaymentMethodActivity.kt