Json Path xPath giving me an Error

Good Day

I’m trying to pass a value from the JSON
Which in this case is

Path: x[0].id
id: 25fd4-529d-3d6d-ce6786688844
and on verification
WS.verifyElementPropertyValue(response, ‘[0].id’, 25fd4-529d-3d6d-ce6786688844

my script Statement
def slurper = new groovy.json.JsonSlurper()
def result = slurper.parseText(response1.getResponseBodyContent())
def value = result.[0].id.id

println ("…Value is…"+value)

It’s not reading my path?

How do I fix this?

how about this?

def value = result[0].id

I’ve tried that option too :weary:
I just get java.lang.IllegalArgumentException: Text must not be null or empty

Could you show us the response in JSON itself? You can print it to the Console by the following code.

import groovy.json.JsonOutput

def json = JsonOutput.prettyPrint(response1.getResponseBodyContent())
println "response is :${json}"