From 4a98fae0684246d62275f6c847125eeb6381d1a0 Mon Sep 17 00:00:00 2001 From: BANCHEREAU Caroline Date: Thu, 27 Oct 2022 15:32:41 +0200 Subject: [PATCH 1/2] added card to payment method types in createSetupIntent --- src/integration/billing/stripe/StripeBillingIntegration.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/integration/billing/stripe/StripeBillingIntegration.ts b/src/integration/billing/stripe/StripeBillingIntegration.ts index 64c8ceaea5..c2f884518f 100644 --- a/src/integration/billing/stripe/StripeBillingIntegration.ts +++ b/src/integration/billing/stripe/StripeBillingIntegration.ts @@ -577,7 +577,8 @@ export default class StripeBillingIntegration extends BillingIntegration { try { // Let's create a setupIntent for the stripe customer const setupIntent: Stripe.SetupIntent = await this.stripe.setupIntents.create({ - customer: customerID + customer: customerID, + payment_method_types: ['card'] }); await Logging.logInfo({ tenantID: this.tenant.id, From 9aefc1b8f0bcd25eece965a15683073f11114e1f Mon Sep 17 00:00:00 2001 From: BANCHEREAU Caroline Date: Thu, 27 Oct 2022 15:41:48 +0200 Subject: [PATCH 2/2] comments --- src/integration/billing/stripe/StripeBillingIntegration.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/integration/billing/stripe/StripeBillingIntegration.ts b/src/integration/billing/stripe/StripeBillingIntegration.ts index eca753fdae..cef269acc4 100644 --- a/src/integration/billing/stripe/StripeBillingIntegration.ts +++ b/src/integration/billing/stripe/StripeBillingIntegration.ts @@ -578,7 +578,7 @@ export default class StripeBillingIntegration extends BillingIntegration { // Let's create a setupIntent for the stripe customer const setupIntent: Stripe.SetupIntent = await this.stripe.setupIntents.create({ customer: customerID, - payment_method_types: ['card'] + payment_method_types: ['card'] // 'card' by default but we can add other types here }); await Logging.logInfo({ tenantID: this.tenant.id,