You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, I just have a quick question.
I'm working with the Polar.sh SDK in my application and need guidance on the best way to implement a quantity-based subscription model.
My goal is to have a single product, for example, a "Pro Seat" that costs $8/month. I want a customer to be able to subscribe to a variable quantity of this product, for instance, 5 seats.
The ideal checkout flow would be:
The customer chooses to buy 5 seats.
My application creates a checkout session.
The Polar checkout page shows the calculated total price upfront: 5 seats * $8 = $40/month.
The customer pays this $40 total immediately to start the subscription for all 5 seats.
I've explored the documentation, and while I see clear support for one-time payments and post-paid Metered Billing, I can't find a direct example of passing a quantity parameter to api.checkouts.create() to achieve this upfront calculation.
My question is: What is the recommended pattern in Polar to create a checkout for a single subscription product with a specific quantity, where the total price is calculated and charged upfront?
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
Hi, I just have a quick question.
I'm working with the Polar.sh SDK in my application and need guidance on the best way to implement a quantity-based subscription model.
My goal is to have a single product, for example, a "Pro Seat" that costs $8/month. I want a customer to be able to subscribe to a variable quantity of this product, for instance, 5 seats.
The ideal checkout flow would be:
The customer chooses to buy 5 seats.
My application creates a checkout session.
The Polar checkout page shows the calculated total price upfront: 5 seats * $8 = $40/month.
The customer pays this $40 total immediately to start the subscription for all 5 seats.
I've explored the documentation, and while I see clear support for one-time payments and post-paid Metered Billing, I can't find a direct example of passing a quantity parameter to api.checkouts.create() to achieve this upfront calculation.
My question is: What is the recommended pattern in Polar to create a checkout for a single subscription product with a specific quantity, where the total price is calculated and charged upfront?
Beta Was this translation helpful? Give feedback.
All reactions