#SMED
1 messages · Page 1 of 1 (latest)
Hello! You can add a trial by setting the parameter subscription_data.trial_period_days: 30 (see https://stripe.com/docs/api/checkout/sessions/create?event_types-payment_intent.payment_failed#create_checkout_session-subscription_data-trial_period_days)
I see, it worked 👍 , i have another question tho, i see we can get multiple free trial and it just makes the service free, how can I add a limit of free trial so each user can only do free trial one time, is that possible with stripe or i need to do it server-side + how does it work for the subscription_data.trial_period_days: 30
Can you clarify what you mean by multiple free trial? Where are you seeing that?
like after the free trial ends, you can take another one
at least if i cancel it i can
How are you taking another free trial? By going through the checkout process again and creating a whole new subscription?
yes
So that's something you'd have to add logic to handle on your end - before redirecting to checkout you need to check your existing customers/subscriptions and see whether they've already signed up, and if they have you shouldn't send them to the Checkout page to create a new Subscription
Alright, thanks for the help, you can close this issue