0

Json

{
    "Id": "1234",
    "AValue": {
        "qId": "ABCD",
        "aType": "DATE",
        "value": {
            "eType": "ENCRYPTED",
            "eValue": "XXXXXXX"
        }
    }

}

How to write a jsonpath expression to get eValue only if "qId in AValue is ABCD"

Clark Ngo
  • 343
  • 4
  • 14
parhau
  • 87
  • 2
  • 7
  • 1
    what have you tried until now? Check some example here https://jsonpath.herokuapp.com/?path=$.store.bicycle[?(@.color==%22red%22)].price – Akshay G Sep 21 '22 at 09:19

1 Answers1

0

We can use conditions

$.AValue[?(@.qId =="ABCD")].value.eValue
Dharman
  • 30,962
  • 25
  • 85
  • 135
parhau
  • 87
  • 2
  • 7