#oleg.moseiko
1 messages ยท Page 1 of 1 (latest)
Hello ๐
Is this extra storage plan a one-time add on OR recurring?
So just to make sure I am on the same page, the customer would be charged $10 as usual plus the additional amount $5 for extra storage plan correct?
yes
In that case you'd want to create a subscription item for the additional price, this would allow you to add a new item to an existing sub
https://stripe.com/docs/api/subscription_items/create
Hello! I'm taking over and catching up...
Yeah, they can choose if you build a UI for them to do that, then make the approprate Subscription updates based on their selection.
No, we don't have a UI component available that would let someone select options the way you've described.
You would have to build it on your end.
but if customer choose 10TB in my UI then i will subscription_items/create but there is not enough money on the customer's card?
Then you'll get a decline.
Cardholders are typically aware of how much money they have available to spend.
๐ฉ
i think subscription_items/create must work like CheckoutSession
where customer can choose
'quantity' => $params['minimum'] ?? 1,
'adjustable_quantity' => [
'enabled' => true,
'minimum'=> $params['minimum'] ?? 1,
]
Not sure I understand?
if i use CheckoutSession it return me url
Yes.
and i can open dialog
Dialog?
where user can choose quantity
Yeah, you can do adjustable quantities in Checkout.
but why for subscription_items i can'N have the same
You can? I'm not following, sorry. Have you tried this?
As I understand it you want people to be able to add arbitrary items to a Subscription in Checkout, right?
Not adjust quantities?
no
i would like to get url after call subscription_items and use it to open stripe UI where user can chose quantities
I thought you said earlier:
For this case i have Extra Storage Plan with with month price $5.
i don't want to create my own UI where customer will cheose quantity
If you just want to let people change quantities you can do that in Checkout: https://stripe.com/docs/api/checkout/sessions/create#create_checkout_session-line_items-adjustable_quantity
cool idea but before i need to add new subscription_item with ExtraStorage price
and to do it need CREATE MY OWN UI where user will choose quantity
Yeah, because that's not a quantity change, that's adding an entirely new item.
i woul be good if i can have url from subscription_items
to show stripe dialog with quantity
like Checkout
You can configure a Checkout Session to allow your customers to change the quantity of existing items, but we don't have the ability for your customers to add new items.