#usamarashad

1 messages · Page 1 of 1 (latest)

brave obsidianBOT
#

Hello! We'll be with you shortly. Below are links to other discussions we've had with you in the past week in case you want to review that information. If your question is related to one of these previous discussions, please provide a comprehensive summary of the current state and what you need help with now. We help many users simultaneously, so a summary allows us to resolve your issue as soon as possible.

sick lagoon
#

At the moment I have created the subscription as suggested to me beforehand. The subscription status shows "Paid".

#

Now,I would like to know what actions should I take in-case a customer's payment method is declined on the next due date of the subscriptions.

#

I am using the Stripe API for integration.

tawdry tartan
sick lagoon
#

Noted. Do I use the PaymentIntents API or the SetupIntent API to create a flow to collect new payments ?

#

Secondly, how can I use a previously stored card, which was supplied by a customer for a one-time payment, and re-use that card for a subscription?

tawdry tartan
#

The steps will be:

  1. Update the Payment Intent of the latest invoice to save the new payment method with setup_future_usage: 'off_session': https://stripe.com/docs/api/payment_intents/update#update_payment_intent-setup_future_usage
  2. Use Payment Intent to collect the payment method details
  3. After the payment method details is collected, the update the default_payment_method of the subscription: https://stripe.com/docs/api/subscriptions/update#update_subscription-default_payment_method
#

Secondly, how can I use a previously stored card, which was supplied by a customer for a one-time payment, and re-use that card for a subscription?
If the payment method has been saved, it can be updated to the default_payment_method of the subscription as well