Answer the question
In order to leave comments, you need to log in
How to do delete multiple items in RESTApi CRUD (DELETE or POST method)?
Hello, I usually encountered the need to remove elements one at a time.
To do this, I used @DeleteMapping ("users/{id}"), which is familiar to me.
Now I need to delete several elements at once through one request.
I can make a Post-method, in which I will pass the list of id for deletion in the body.
Or make a Delete method, to which I will pass several id array/list to the query (in the query string)?
Which approach is preferred?
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question