I am trying to use a JSONPath expression which has filter expressions. I validated the JSONPATH online using a online validator and it’s correct but upon using the same in the postman I get a syntax error. Not sure what I am doing wrong and I am unable to find any info or posts regrading the same.
Here is line of code where I am trying to store the NAME of the player whose ID is ‘56782’.
Note: The response I receive is in XML and PLAYERS is an array.
var responseJson = xml2Json(responseBody);
var JuniorLeaguePlayer = responseJson.RSP.ACTIVE.PLAYERS[?(@.ID=="56782")].NAME;