#usama_sa
1 messages · Page 1 of 1 (latest)
Let's chat here
Sure
Here is the scenario,
I'm working on a project were users subscribe to the application using 3 packages (this is done on a different application then where I'm adding a subscription update feature). Now on the 2nd application we allow the subscriber to select their usage limit, the system calculates the amount for new usage and we need to update their subscription package.
My question is what is the best approach for this, we can't update our basic subscription packages. So how do we update subscriptions for individual users on stripe without effecting other users subscribed to the same package.
I found 2 solutions...
- Create a new subscription package for users based on their new usage limit.
- Add multiple prices in the subscription package and assign them to the user based on their needs.
Which way is better from the stripes point of view, if you can offer a better approach let me know
We are using stripe connect as well as this is a multivendor web application.
Sorry things got busy, @uncut patrol will jump in and help you out in a sec.
Appreciate your patience
Hello, is there a specific Stripe API variable that you are using to set this maximum? I am not seeing a way to set that in our docs at the moment
Let me clarify things a bit more the main subscription is done on a different website created by another dev and I don't have the access to the codebase there. They are using a subscription api there
Now I need to add a subscription upgrade feature on my website where users can choose their usage variable, we calculate new prices and I hit stripe api to upgrade their subscription.
Now what is the best way to do that without changing the main package they subscribed to when they signed up. How do I change the subscription package price for 1 user without changing it for all other subscribed users
Ah, so Prices in Stripe actually cannot have their amount updated and the pricing on subscriptions needs to be updated subscription by subscription. So here you would create a new Price object at the price that you want and then update the specific subscriptions that you want to with that new Price object
So create a new price in the product and create a new subscription for the specific user, right?
You can update the Price on your existing Subscription, which would be easier than creating a new one https://stripe.com/docs/billing/subscriptions/upgrade-downgrade
I have checked this, but upgrading the subscription for 1 customer will not affect the subscription price for other users/customers right, it'll only change it for the specific user/customer?
Correct, just the one subscription that you update. Other subscriptions, even other subscriptions on the same Customer, will not be affected
Ok, the. I'll test it out and come back if I need more clarifications thank you
Much appreciated your help with this
@uncut patrol can we also add new products with price in current subscription? If we add a new product how will stripe handle that new products charge if the customer paid for previous products in subscription?
Yes, you can add new items to your subscription. How Stripe handles this depends on the proration_behavior that you pass in when making your update call https://stripe.com/docs/api/subscriptions/update#update_subscription-proration_behavior
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
That simplifies it further I can just add new products when customers choose the usage limit. That will not require us to update the subscription basic price