Top "Jsonpath" questions

JSONPath is a means of using XPath-like syntax to query JSON structures.

How to filter by string in JSONPath?

I have a JSON response from the Facebook API that looks like this: { "data": [ { "name": "Barack Obama", "category": "Politician", "id": "6815841748" }, { "…

json jsonpath
Basic use of JSONPath in Java

I have JSON as a string and a JSONPath as a string. I'd like to query the JSON with the …

java json jsonpath
count members with jsonpath?

Is it possible to count the number of members using JsonPath? Using spring mvc test I'm testing a controller that …

java spring testing jsonpath spring-test-mvc
How to use MockMvcResultMatchers.jsonPath

MvcResult result = this.mockMvc.perform( MockMvcRequestBuilders.get(mockUrl)) .andExpect(MockMvcResultMatchers.status().isOk()) .andExpect(MockMvcResultMatchers.content().contentType("application/ json;charset=UTF-8")) .…

java unit-testing mockito jsonpath
How to test if JSON path does not include a specific element, or if the element is present it is null?

I have been writing some simple unit testing routines for a simple spring web application. When I add @JsonIgnore annotation …

java unit-testing spring-mvc jsonpath mockmvc
Getting a single value from a JSON object using JSONPath

I have the following JSON and I need to get the plain name value using JSONPath: { "single" : { "id" : 1, "name" : "Item …

json jsonpath
Parse JSON array file with JSONPATH

I want to parse this with JSONPath: [ [50.4154134372953,-1.28486558931069,"CLASS B",9,205,0,"UK",431500382,3,4], [50.3058858494047,-0.976070494820637,"CLASS B",9,239,0,"UK",2750350,21,2] ] Can you help with that …

arrays json jsonpath
SpringMVC/ mockMVC/ jsonpath compare list of strings

I am currently writing some unit tests for a Spring MVC project. As the returned media type is JSON, I …

java spring-mvc jsonpath
Array size using jsonpath expression - Stefan Goessner JsonPath

I'm having a problem with finding an array or list size using Stefan Goessner's JsonPath. I'm using the version json-path-2.0.0. …

java arrays json size jsonpath
JsonPath NoClassDefFoundError, or an alternative to JsonPath in Java

For reasons related to the project I'm working on, I'd like an entire query to a JSON file to be …

java json jsonpath