How to retrieve the JSON message body in JAX-RS REST method?
I have the following JSON that will be passed as part of a HTTP request, in the message body. { "names": [ { "id":"<number>", "name":"<string>", "type":"<string>", } ] } My current REST handler is below. I am able to get the Id and `Version that is passed in as path params, but I am not sure how to retrieve the contents on the message body ? @PUT @Path("/Id/{Id}/version/{version}/addPerson") public Response addPerson(@PathParam("Id") String Id, @PathParam("version") String version) { if (isNull(Id) || isEmpty(version)) { return ResponseBuilder.badRequest().build(); } //HOW TO RECIEVE MESSAGE