What you need is a Response and not a ClientResponse:
javax.ws.rs.core.Response jsonResponse = client.target(url).request(MediaType.APPLICATION_JSON).get();
Then you can see what comes in your response (debugging is your friend here). Is it by any chance a map of some type? If it is, you can read it by doing e.g.
Map<SomeClassOfYours> entitiesFromResponse = jsonResponse.readEntity(new GenericType<Map<SomeClassOfYours>>() {});
If you've put a normal entity in the response you can simply do something like:
SomeClassOfYours entityFromResponse = jsonResponse.readEntity(SomeClassOfYours.class);
Edit: For this to work you'd also need to define SomeClassOfYours and put the corresponding fields, constructor, getters and setters in there.
Edit2: When in doubt you can always read the jsonResponse as a String.class
and put it in a String
variable.