如何在Flutter中使用Stripe元数据



"可更新的Stripe对象(包括Account、Charge、Customer、PaymentIntent、Refund、Subscription和Transfer(具有元数据参数"[1]

元数据很有用,例如,用于传递我正在添加资金的帐号。

https://pub.dev/documentation/stripe_platform_interface/latest/stripe_platform_interface/PaymentIntent-class.html没有元数据属性或方法。那么,我如何将元数据传递给flutter_stripe创建的付款意向?

PaymentIntent应该在服务器中创建,而不是通过Flutter SDK。

创建PaymentIntent时,传入metadata:https://stripe.com/docs/api/payment_intents/create#create_payment_intent-元数据

您可能想看看示例应用程序作为参考:https://github.com/flutter-stripe/flutter_stripe#run-示例应用

最新更新