-
Notifications
You must be signed in to change notification settings - Fork 493
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
Is a delete file endpoint available? #3913
Comments
On second thought, I like the way this issue is worded and how it's from a real user rather than me so I'm re-opening it and closing the duplicate #3419 |
FWIW: #7149 is about adding the ability to replace files in draft versions, so it addresses the original use case above. (working on a PR) |
I am interested in the last use case "deleting files from a (draft) version similar to the UI". Would it make sense to have a new API endpoint similar to "replace" but which deletes the file from the current draft (and creates a draft if the last version is a published version)? I imagine calling that endpoint would look like this for persistent IDs.
And for database IDs:
|
@janvanmansum yes, that makes perfect sense. Thanks for leaving a comment here. As I mentioned in the thread on the mailing list, the current work around is to use the SWORD API: http://guides.dataverse.org/en/5.1.1/api/sword.html#delete-a-file-by-database-id |
I'm doing this comment here just to let you know that there is +1 user wanting this feature of deleting files using the Native API. |
Yet another user who would also like this capability in the Native API. |
I also concur. It would be a useful feature to be able to delete files using the native API. |
Just adding another comment to mention that we're seeing tickets from Harvard Dataverse users asking for this ability using the Native API |
I need to programmatically delete a lot of files now so this would be really helpful! I guess it's time to learn to use SWORD. |
Thanks all. I just added it to the community backlog column in the new global backlog board: https://github.com/orgs/IQSS/projects/34/views/1 However, it's currently at the bottom of that column because I'm prioritizing pull requests. (If the work is already done, we should get those improvements in, right?) Speaking of pull requests, is anyone out there interested in making one for this issue? If so, please get in touch! 😄 |
Rather than the order in the datasets, which seems to be undeterministic. Not sure.
The native API currently allows file update (and now file replace) operations but it doesn't appear to allow file delete. This means that because replace only works on published files, it is not possible to update the file contents of a draft dataset without going through the GUI to manually delete the staged file or to delete the entire draft (all files and metadata) through the API. It would be great to be able to delete both unpublished/draft files and to delete files generally from a version (in the way that is currently possible through the GUI).
The text was updated successfully, but these errors were encountered: