#shainkey
1 messages · Page 1 of 1 (latest)
Hi, it's me again and not sure why our previous convo didn't help. The Subscription sub_1M0HunA1AvSnwwTv23MLhEHF was created with collection_method = "send_invoice", not as you described above
Here is the request you created it: https://dashboard.stripe.com/test/logs/req_Fkmcxq4caMjCut
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
ohhh sorry let me send you recent one
sub_1M29sXA1AvSnwwTvioHjteZO
this one is the new one
Please check for this
https://dashboard.stripe.com/test/customers/cus_MlhHgj5acbng3Y it's because this Customer doesn't have any PaymentMethod.
Sorry for not being clear enough in previous thread, but in order to "automatically" charge the Customer, you need to collect their payment information somehow.
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
After you created this Subscription, you have its latest_invoice = "in_1M29sXA1AvSnwwTv3j2eTcWZ"
Then you can call Retrieve Subscription API (passing in the sub id), expands latest_invoice.payment_intent, to have the Payment Intent Id, then use its secret to collect the Payment on frontend
Please take a look at this Doc: steps by steps: https://stripe.com/docs/billing/subscriptions/build-subscriptions?ui=elements#install-setup
okay if the status of invoice is draft
what does it mean
it will automatically show paid after an hour if we remove days_until_due=30 and collection_method="send_invoice"
a) In this case there is no 1 hour because you already used charge_automatically and this is the first Invoice. You need to collect PaymentMethod for this 1st Invoice.
b) For the 2nd onward Invoice (next month), the Invoice will automatically show "open" after an hour. (draft->open). After 1 hour, depends on if it can charge the Customer using the PaymentMethod collected from 1, it will transfer to either paid or stay in open
I recommend looking at this page for Invoice status transition: https://stripe.com/docs/invoicing/integration/workflow-transitions