#Maira Kanwal
1 messages · Page 1 of 1 (latest)
I'm not familiar with flutter stripe since that's a third party library, but here's our guide for our officially supported libraries:
https://stripe.com/docs/payments/save-and-reuse?platform=ios&ui=payment-sheet
Basically you need to save the payment method id
Looks like: pm_123. You can use that to charge the customer later
And can I save the card to that customer using this method? So he can use it later on future transactions?
The main issue that arises is that I cant find the token for that customer. How can I figure out what token I should be using for the customer? Is it client_secret token?
What guide are you following to implement this?
I am using https://pub.dev/packages/flutter_stripe
Yes but is there a guide you're following to implement this?
I am following this guide
https://medium.com/@Ikay_codes/integrate-payment-in-flutter-with-stripe-13e96fdc2e9e
So you need to both process a payment and save the payment method for future usage all at once?
Yes exactly thats what I want to do
Got it. So you'll want to pass setup_future_usage to achieve this when creating the payment intent: https://stripe.com/docs/api/payment_intents/create#create_payment_intent-setup_future_usage
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
That flags the payment method for future usage
But the flutter stripe library is 3rd party, so I can't support you with that specifically
More general questions about our API and official client libraries I can help with
Thankyou I will try this