#pavlina_unexpected
1 messages ¡ Page 1 of 1 (latest)
đ Welcome to your new thread!
â˛ď¸ We'll be here soon! Typically we respond in a few minutes, but sometimes we might take a bit longer if the server is busy or if you have a particularly tricky question.
âąď¸ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can always start a new thread if you have another question.
đ This thread will always be available, even after it's closed. You can find it again using Discord's search, or you can save this link: https://discord.com/channels/841573134531821608/1357000230062522630
đ Have more to share? Add more details, code, screenshots, videos, etc. below.
Below are links to other discussions we've had with you in the past week in case you want to review that information. If your question is related to one of these previous discussions, please provide a comprehensive summary of the current state and what you need help with now. We help many users simultaneously, so a summary allows us to resolve your issue as soon as possible.
- pavlina_code, 2 hours ago, 9 messages
Can you share the subscription id where this happened?
sub_1R9S0eAZplvGSnJja7XAisc9
It's worth mentioning that the coupon I've set up is valid for 3 months; I've not added any more restrictions
What do you mean by transferred to the other subscription?
It's the same subscription id
Right?
Or did you create a new Subscription?
I have multiple prices, so the customer subscribed to another price
Via the same subscription though
You didn't create a new Subscription (as far as I can tell)
So since it's on the same Subscription, the promo code applies
You should be able to apply promotion codes only at subscription item level instead: https://docs.stripe.com/api/subscriptions/update#update_subscription-items-discounts-promotion_code
To set it only on the price you want
You set it subscription-wide: https://docs.stripe.com/api/subscriptions/update#update_subscription-discounts-promotion_code
so when I update the subscription if I pass an empty string for a promotion code it will remove the promotion?
Yes
I just did it for this subscription sub_1R9SorAZplvGSnJjfrg4cfu3 but the promo code is still visible on the invoice
I just did it as so
$accountOwner->subscription(SubscriptionPackage::SUBSCRIPTION_TYPE_CASHIER)->swapAndInvoice($newPlan['subscription_price_ids'][SubscriptionPackagePrice::PRICE_TYPE_MONTHLY])
->withPromotionCode('')
->addMeteredPrice($newPlan['subscription_price_ids'][SubscriptionPackagePrice::PRICE_TYPE_USAGE_BASED]);
I'm using laravel cashier, but I can't see an event where it was an empty string
That's a third party sdk
So idk what it's doing under the hood
With our official sdk you can set an empty string to unset params
Ok, thanks, I'll try it with your sdk