0

I have to extract value of book title using JsonPath in RestAssured in Java from following json response

  { 
   "spec": {
        "groups": [
          {
            "name": "book",
            "title": "classic-books:1.0.2"
           },.......
          ]
         }
     } 

I am looking to use contains to get the book with a specific title.Please help.

tom redfern
  • 30,562
  • 14
  • 91
  • 126
trial999
  • 1,646
  • 6
  • 21
  • 36

1 Answers1

1

Assume you have response with JSON in it:

response.body().jsonPath().get("spec.groups[i].title");
dsmt
  • 11
  • 2