#devangbhuva97 - delete plans without active subscriptions
1 messages · Page 1 of 1 (latest)
Good question. Looking in to this...
Can I ask why you are looking to avoid this? As the doc says, existing subscribers will not be affected
By mistake we created too many products & prices in our couple of connected accounts. So we want to delete those
Ah, so you want to delete a lot of prices but are not sure which ones you are actually using?
You can check if a plan has active subscriptions by listing all subscriptions and filtering by price https://stripe.com/docs/api/subscriptions/list#list_subscriptions-price
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
You can provide a plan ID to the price parameter as well
No we have data - which price we are using? but we want to confirm before delete
You also might just want to list all subscriptions, go through the list, and make a hash of plans that are in use.
You can confirm it by pulling our data with that list call.
looks like... that api will work!
Awesome!
Thanks @half dust