#mehdi
1 messages · Page 1 of 1 (latest)
Hello! If you don't want to use Test Clocks you would need to create a Subscription with a short interval and then wait.
does a free trial trigger an invoice.upcoming webhook?
What do you mean?
invoice.upcoming will fire X days before a Subscription is scheduled to create an Invoice, where X is determined by your Dashboard settings.
oh yeah
so if I set the X days to be 3 days
and then add 3 days of free trial to a subscription
would that trigger the invoice.upcoming?
I think so... although I've never tried doing it that way.
What's your goal? What are you trying to do exactly?
yeah, we send our own "upcoming subscription renewal"-type emails
that use the invoice.upcoming webhook to trigger them
Why don't you want to use Test Clocks?
our subscriptions are already attached to some other user objects, and have metadata set on them
it would be a bit difficult to copy/replicate
I see. In that case I recommend creating or updating a Subscription with trial_end set to a bit longer than three days in the future to ensure the Subscription exists and has time to trigger the invoice.upcoming Event: https://stripe.com/docs/api/subscriptions/create#create_subscription-trial_end
I would probably start with five minutes, make sure it works, then lower it if needed.
Ah, nice.
thanks for your help!