ezet / stripe-sdk

A simple and flexible Stripe library for Flutter with complete support for SCA and PSD2.
https://pub.dev/packages/stripe_sdk
Other
137 stars 137 forks source link

stripe_sdk 5.0.0 payment does not complete on Web: Not a valid URL #152

Closed ehcpdeveloper closed 1 year ago

ehcpdeveloper commented 2 years ago

in the details of error on Stripe, it shows return_url is empty. Because new stripe code does not have parameter returnUrlForSca. This code works on mobile. ideally, same code should also work on web, but not... Apparently, the web side of stripe_sdk codebase is not synchronous with mobile part. That is like this: mobile is updated to 5.0.0, but web expects parameters like 4.02, but returnUrlForSca parameter does not exist.

ezet commented 2 years ago

Are you able to test the latest master? As far as I'm aware, web works there.

ezet commented 1 year ago

Web works fine now

vlad-ed-git commented 1 year ago

Can you please add something in the documentation or comment here to elaborate on this.

This is the init method signature

...
  /// [returnUrlForSca] should be used to specify a unique return url for
  /// Strong Customer Authentication (SCA) such as 3DS, 3DS2, BankID and others.
  /// It is required to use your own app specific url scheme and host. This
  /// parameter must match your "android/app/src/main/AndroidManifest.xml"
  /// and "ios/Runner/Info.plist" configuration.
  Stripe(String publishableKey, {String? stripeAccount})
      : api = StripeApi(publishableKey, stripeAccount: stripeAccount);

The parameter returnUrlForSca is not passed anywhere! There is also no way of setting it as far as I can tell from the source code.