@RvdAuth @GET @Path("{name}/wavs") @Produces(MediaType.APPLICATION_JSON) public Response listWavs(@PathParam("name") String name) throws StorageException, ProjectDoesNotExist { assertProjectAvailable(name); List<WavItem> items; try { items = projectService.getWavs(name); Gson gson = new Gson(); return Response.ok(gson.toJson(items), MediaType.APPLICATION_JSON).build(); } catch (BadWorkspaceDirectoryStructure e) { logger.error(e.getMessage(), e); return Response.status(Status.INTERNAL_SERVER_ERROR).build(); } catch (StorageException e) { logger.error("Error getting wav list for project '" + name + "'", e); return Response.status(Status.INTERNAL_SERVER_ERROR).build(); } }