#Asad

1 messages · Page 1 of 1 (latest)

wintry minnowBOT
steep heath
#

👋 happy to help

stuck cave
#

can you please specify the event name?

#

which is triggered when subscriotion is auto renewed

steep heath
#

did you take the time to read through the doc that I sent you?

#

invoice.upcoming

stuck cave
#

how upcoming will trigger for renew subscription?

steep heath
#

@stuck cave it's really helpful to read through the docs we send you and we're happy to answer any follow up Qs

#

Subscriptions require coordination between your site and Stripe-the success or failure of a customer’s recurring payments determines whether they can continue to access to your product or service.

For typical integrations, you store customers’ credentials and a mapped timestamp value that represents the access expiration date for that customer on your site when a customer subscribes. When the customer logs in, you check whether the timestamp is still in the future. If the timestamp is in the future when the customer logs in, the account is active and the customer should still have access to the service.

When the subscription renews, Stripe bills the customer and tries to collect payment by either automatically charging the payment method on file, or emailing the invoice to customers. Stripe notifies your site of the invoice status through webhooks:

A few days prior to renewal, your site receives an invoice.upcoming event at the webhook endpoint. You can listen for this event to add extra invoice items to the upcoming invoice.

Your site receives an invoice.paid event.

Your webhook endpoint finds the customer the payment was made for.

Your webhook endpoint updates the customer’s access expiration date in your database to the appropriate date in the future (plus a day or two for leeway).

#

from the link I sent you earlier

#

the invoice.upcoming tells you that there's going to be a renew

#

invoice.paid tells you that the new cycle has been paid for