Giving discounts to yearly subscribers

1,207 views
Skip to first unread message

Wyatt Weisensel

unread,
Aug 13, 2015, 8:22:39 AM8/13/15
to Stripe API Discussion
I have a monthly and a yearly subscription. For the monthly, its very straightforward how a coupon would work when applied to a customers subscription. But how would this work when applied to a yearly subscription, especially if the coupon reoccurs for multiple months? What I'm doing is giving a free month to people who use the coupon, but I don't see a way to give a discount to yearly subscribers; which makes sense because they already paid for a whole year so it would be a long time before they see that discount. Is it possible to give yearly subscribers a partial refund of 1/12th of what their subscription cost was (which seems hackish)? Or am I probably better off not giving discounts to yearly subscribers?

Thanks in advance!

Remi J.

unread,
Aug 13, 2015, 8:40:41 AM8/13/15
to api-d...@lists.stripe.com
Hey Wyatt,

When you add a coupon to a customer, it automatically applies to any
invoice created on that customer until it expires and is removed
automatically. The coupon has no insight into the plan itself and how
long it lasts. Instead, it just applies to the invoice total and
discounts it as expected.

This means that if you create a $90 monthly plan and a 100% coupon
valid for 6 months, then the first 6 invoices for that customers will
be $0 and starting from the 7th, the coupon will be removed and the
invoice will charge $90 to your customer automatically.

On the other hand, if you create a $120 yearly plan with a 100% off
coupon valid for 6 months, the first yearly invoice is discounted
fully so the customer doesn't pay anything then. Then, a year later,
when the subscription renews the coupon doesn't exist anymore and the
customer is charged $120 for the new year that just started.

If you want to give one month free to your yearly customers, you have
multiple solutions:

1/ Create a specific $10 off coupon valid once that your code only
applies to the yearly subscription. That way you add it when you
create the yearly subscription and the customer gets charged $110 in
then end which means he got a month free.

2/ Set the account balance of your customer to `-1000` before creating
the subscription. That means that he already has a $10 credit in his
account that would be applied to his first invoice and he would end up
being charged $120-$10=$110 on the first invoice.

3/ Create a negative invoice item [1] for -$10 on the customer before
creating the subscription. When you then create the subscription it
will be pulled into the invoice automatically and charge for $110 in
the end. This solution is similar to the previous one except that you
have better traceability with invoice items and you can add a
description that makes sense for your customer especially if you use
our email receipts.

4/ Use a trial period [2] to offer the first month free. When you
create the yearly subscription you pass the `trial_end` parameter set
to the timestamp of the date you want their next charge to happen.
This means that today I subscribe but don't pay anything for a month.
Then, in a month I get charged $120 for a full year starting on that
day. The main caveat here is that your customer did not pay for the
yearly plan yet and the charge could fail in a month.

Hope this helps!
Rémi

[1] https://stripe.com/docs/guides/subscriptions#adding-invoice-items
[2] https://stripe.com/docs/guides/subscriptions#working-with-trials
> --
> You received this message because you are subscribed to the Google Groups
> "Stripe API Discussion" group.
> To post to this group, send email to api-d...@lists.stripe.com.
> Visit this group at
> http://groups.google.com/a/lists.stripe.com/group/api-discuss/.
>
> To unsubscribe from this group and stop receiving emails from it, send an
> email to api-discuss...@lists.stripe.com.

Wyatt Weisensel

unread,
Aug 13, 2015, 2:52:23 PM8/13/15
to Stripe API Discussion
So all of those methods you described involve applying a coupon or setting the customers account balance BEFORE the invoice is created, either when the customer subscribes or when a trial period is over? What I will probably do then is allow yearly subscribers to apply coupons (we are giving discounts for referrals) before their trial period is up, but then they will no longer be able to use discounts (who wants to wait a year to get a discount?). 

This brings up another question. What happens if you apply a coupon during a trial period? Will it apply towards the next invoice (when the trial is over) or will I have to give the customer a negative account balance? 

Remi J.

unread,
Aug 13, 2015, 3:02:56 PM8/13/15
to api-d...@lists.stripe.com
When you add a coupon to a customer it applies automatically to the
future invoice created on that customer. This means that if you have a
subscription in the trial period and you add a coupon, then the
following invoice will be discounted by that coupon.
Reply all
Reply to author
Forward
0 new messages