confirmAcssDebitPayment method

Future<PaymentIntent> confirmAcssDebitPayment(
  1. String paymentIntentClientSecret,
  2. String paymentMethodId
)

Implementation

Future<PaymentIntent> confirmAcssDebitPayment(
  String paymentIntentClientSecret,
  String paymentMethodId,
) async {
  final response = await js.confirmAcssDebitPayment(
    paymentIntentClientSecret,
    data: stripe_js.ConfirmAcssDebitPaymentData(
      paymentMethod: paymentMethodId,
    ),
  );
  if (response.error != null) {
    throw StripeError(
      message: response.error?.message ?? '',
      code: response.error!.code,
    );
  }

  return response.paymentIntent!.parse();
}