#gkiokan-discount
1 messages · Page 1 of 1 (latest)
it's because the next invoice is more than three months away and the coupon is only valid for 3 months
that applicability/duration works differently than you're thinking
In my Stripe Dashboard I can see it even correctly calculated. It shows payment total summ as 195,33. I would expect the same amount on total when I try to get the upcoming invoice
But instead I get the default plan without the coupon itself
You can see here the api response from the upcoming invoice. It don't have the coupon applied to the subscription
yep, I think I explained though
the upcoming invoice won't have the coupon, because the coupon lasts 3 months, but the subscription plan is for a year. The coupon won't apply in a year since it's been more than three months
Ah okay my fault. As it is yearly the current (or last) invoice should have the discount applied
ofc the next year woouln't have the coupon added, okay my bad. I need to check the last invoice. Thanks for the hint
Could you check this invoice? in_1LAZSUHa5WPIKK5IkmZkm13m
I have a 100% discount setup for that coupon but only for 3 months
This is a test customer I've created and updated the subscription from a 0 EUR tier to paid tier with coupon
Hello 👋
Stepping in here as karllekko needs to step away soon
Give me a moment to catch up 🙂
Can you give me a short summary of your question?
Sure
I've updated the subscription with a coupon but the coupon is only for 3 months to discount 100%.
The invoice in_1LAZSUHa5WPIKK5IkmZkm13m seems to apply 100% for the full year instead.
shouldnt the invoice have less then 224,91 EUR (for 12 months)?
I would expect somewhere around 170 EUR with the coupon
Or maybe I am wrong and the coupon didn't even got though?
gimme 1 sec, I will create a new customer. I think I mixed up something
sub_1LAZm1Ha5WPIKK5IWLGpQ64n
Oh here it is.
See here in_1LAZm1Ha5WPIKK5IxZPLvyFD
You can see 100% discount but for all of the year
looking
Okay! I'm seeing the same behavior for the coupon with a yearly subscription
Let me dig into why that's happening
At least one good sign, we found a bug. Looking forward for your solution.
I don't think its a bug but it is currently the expected behavior
Our coupons don’t focus on the subscription’s billing cycle as much. They simply apply to an invoice’s subtotal that is created while the coupon is valid.
With a yearly subscription, there's only one invoice generated. So a coupon of 100% off will apply to the first invoice which is what's happening right now. It doesn't create prorations.
But why do we have a coupon duration then?
I would guess it will work for the monthly subscriptions
I believe those are for monthly subs, yes
puh that makes it hard
I could probably create a custom coupon and validate it before updating the subscription
like if user adde coupon for 3 months but is in yearly sub, I change it programmatically to another one with 30%
yeah that sounds reasonable
Ok. I will test that and catch you up if there is any issues
Actually there is one thing. If I have a subscriptions with a coupon already applied, how does that behave if I update the subscription to another tier?
Not sure to be honest as I haven't tested this flow personally.
I'd recommend running a simulation in test mode 🙂