#Ferecium
1 messages ยท Page 1 of 1 (latest)
Hi there,
Could you please share more details about your issue, is this an API response error? if so,
Can you share the ID (req_xxx) of the failing API request?
https://support.stripe.com/questions/finding-the-id-for-an-api-request
Of corse, the request id: req_K9hdjhiHcKe5ct
thanks for sharing let me check
What I'm trying to do is setting up a Customer Portal, allowing customer to change his subscription plan. We usually have three prices by product, one monthly, one yearly and one "premium" that is also yearly charged
Indeed, the error seems pretty descriptive to me. The portal only allows configuring 1x price per interval for each product
You've passed 2 price_xxx IDs which are both yearly intervals
You'd probably want to model your products/prices differently
So no workaround, there's no way I can let my customer upgrade from annually to premium plan if both are charged annually?
Yep, you'd model the 'premium' plan as a different Product
Not a different Price under the same Product
They're all listed as prices for prod_MwjDqbmDec8JTx. Generally a product is a representation of each 'plan' (i.e. basic, premium). Then you have n Prices per interval (i.e. monthly, yearly)
But then in the Customer Portal, the customer won't be able to "upgrade" his plan right? He will have to unsubscribe from the "normal" product to subscribe to the premium one
Nope, they can switch between products
You just need to configure the products allowed as part of update when creating the session: https://stripe.com/docs/api/customer_portal/configurations/create#create_portal_configuration-features-subscription_update-products
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
How can they do that? In the Portal Configuration I'll have to pass the two product ids I guess, then an "upgrade" button will be there?
Yep, exactly. You need to take a step back and re-model your products/prices in your Stripe account
Alright, I see, the "upgrade" is more changing product than changing plans I guess.
It's too bad I didn't understand this earlier, I'll have a hard work changing production products ๐
But thanks a lot for the information!
Can I ask a last question about the customer portal?
If your 'plan' correlates to a different level of service (e.g. different features, different cost) then it should be modelled as a product in Stripe yes
In our flow, a customer can have subscriptions for many products. When I show the customer portal, it seems every subscriptions are shown. Is there a solution to show the subscriptions only for one product? Or two if I do separate the premium
Not currently. It will surface all subscriptions for the related cus_xxx
np!
I realize that customer portal just don't suits my need I guess. It shows every subscriptions of the customer, and with the upgrade for which I pass two products (a normal and a premium), it let the customer switch from a normal product to a premium one that has nothing to do.
We need that the customer can change from a given "normal" product to the "premium" one that is linked, not any premium one. I don't know if I explaining myself correctly, it's hard to explain in another language that my native.
Even if it's not the customer portal, have you a suggestion to do that? I'm a bit lost.
I don't really understand the use case you're describing. What do you mean by 'linked'?
I should say, we use "connect". We are a kind of market place. We allow sellers to create newsletters. Each seller can create one or more newsletter. When they create a newsletter, we automatically create three prices for the newsletter (the newsletter is the product). A price for a monthly subscription, a price for the yearly and a premium price.
As a customer, I can subscribe to one or more newsletter, so I can have subscriptions for several newsletter that come from different sellers.
So with what we just discuss, we can imagine instead of one product by newsletter, I can create two, a normal and a premium one.
When I try to set up the portal for a customer, I can only set a list of products that can be upgraded. When I try to set two products, the normal and the premium products for a given newsletter, the customer is able to upgrade any of his subscriptions for any of the newsletter with the premium price of a the given newsletter I set up in the portal.
I'm looking for a way to allow my customer to upgrade his plan from monthly, to annually to premium, for a given newsletter only. With a prorata calculation and a nice interface that gives him the remaining price he have to pay for the upgrade.
Checkout Session don't allow subscriptions update, Customer Portal seems way out of my needs... Have you a solution, a product, a portal or anything that can help me achieve this?
Unfortunately not, you'd need to build your own if you require that level of control
Customer portal does all that, but as you note it shows all Subscriptions for the Customer and that's no way around that with how you're using Connect
A lead on how to build my own?
Something like that maybe? https://stripe.com/docs/billing/subscriptions/prorations