-
Notifications
You must be signed in to change notification settings - Fork 753
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Delete request for 'price' object #916
Comments
@johnnyperdomo We do not support Price deletion or deleting Products associated to a Price. We instead encourage marking all of those as inactive instead. This ensures that you keep your data present whenever you need to do analysis or reconciliation in the future. I'm going to close this ask because it's not really a bug or a feature request about stripe-node and it's more a question about our API. I'd recommend talking to our support team instead: https://support.stripe.com/contact |
Ok. Makes sense. It seems strange that prices are still able to be deleted in the dashboard. |
@remi-stripe I spoke with support yesterday after trying to figure out if I'd misunderstood the docs and they weren't able to answer why updating a price's
As a workaround I thought I'd delete the price and create a new one (I only want/need one for my scenario) and only found this issue after a lot of digging for a I think a total absence of a prices Could that encouragement to "mark all of those as inactive instead" not be shifted to the docs instead of here? Especially given that you can delete a price or change its amount in the dashboard. FYI, the Plan docs states (emphasis mine):
|
@sheedy We don't support modifying the amount since that prevents reliable reconciliation over time. This has always been true even before we introduced If you want to change the pricing for your business/offering, you should mark the old Price as inactive and just create a new one and start using the new Price for your new customers. You can also optionally migrate your existing customers to the new Price as needed. Both Price objects should be under the same Product so that reporting is aggregated and coherent. |
It's totally logical but why doing this in the unit test then ?
If it's not possible to modify the price amount, I don't understand why putting the unit test with those parameters. Or do I miss something ? |
@sheedy Sorry for the confusion I'll get it fixed. stripe-node unit-tests don't hit our API and are here just to ensure the paths are defined properly. |
I just shipped a small fix in #933 so that we now only update |
@remi-stripe Thanks, that makes sense. I think it would be very helpful to add this reasoning to the Prices section of the docs for others that are looking for these endpoints as it's not mentioned anywhere else other than this issue (as far as I could find). |
@remi-stripe : Why |
And also, method When I tried CURL command for delete
|
The Dashboard has a special exception letting you change a Price if it has never been used. It also lets you delete prices because of the legacy compatibility with Plans but it's not something we want developers to rely on in their code and it's not available in the public API. |
There's currently no delete request for 'price' object with the api. https://stripe.com/docs/api/prices
how do you delete prices? setting to active does not work.
I am trying to delete 'product' object for connect users, but cannot because price is associated with product.
The text was updated successfully, but these errors were encountered: