I want to implement endpoint for deleting a list if IDs
@DeleteMapping("/contracts/remove/{id}")
public ResponseEntity<?> remove(@PathVariable Integer id) {
contractsTerminalsService.delete(id);
return ResponseEntity.noContent().build();
}
How I can send a list of IDs like this:
POST /api/contracts/bulk_delete
with body { ids: [1,5,6] }
What is the proper way to implement this?