'Best way to model my mixed monthly/yearly subscription with Stripe payments
The subscription plan
I have a subscription plan available at my app which I need to model with Stripe.
The subscription plan details are the following:
- A fixed amount of $20/month or $200/year (discounted) that the user must pay.
- With the previous fixed amount the user can consume 2500 units of the product per month.
- If the user consume more than 2500 units in one month every additional unit has a value of $0,01.
Examples
- A user choose the subscription plan with the $20/month option and in the first month he/she consumes 2520 units.
The total amount to pay for the first month of the subscription for this user is:
- $20 fixed amount
- 20 additional units * $0,01 = $0,2
- Total to pay: $20 + $0,2 = $20,2
- A user choose the subscription plan with the $200/year option. In the first month he/she consumes 500 units. In the second month he/she consumes 5000 units.
For the first month this user needs to pay:
- $200 because is starting the subscription
- No additional units.
- Total to pay: $200
For the second month this user needs to pay:
- No fixed amount because the fixed yearly quantity has already been paid.
- 2500 additional units * $0,01 = $25
- Total to pay: $25
Problems
My biggest problem modeling this with Stripe payments is that is not possible to have prices with different intervals in the same subscription.
If the user chooses the yearly fixed price is not possible to create a subscription on Stripe that has a fixed yearly pay (of $200 in this case) and a monthly graduated price (for the additional consumed units).
I have seen that the subscription upsell feature is something very similar to what a I need. But once it's activated I can't find any way on the API to enable it when the subscription is created (I'm not using checkout).
I have seen also that it's possible to create two subscriptions, one for the yearly pay and another one for the monthly units. But creating two subscriptions make everything really difficult, you need to take into account two subscription states and callbacks are more difficult this way too.
Questions
What is the best and simple way to model this subscription plan using Stripe?
Note: I'm doing a custom integration with Stripe, so the subscriptions and customer are created via API. I'm not using Stripe checkout.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
