JSONPath Matcher
JSONPath matching is used to test for the existence of JSON based on a JSONPath query. If a query is specified that returns a result (any result) after being run against the request body payload, then it matches.
JSONPath Matching example:
Matcher value
Positive payload
Non match payload
$.name
{
"name": "John",
"surname": "Doe"
}
{
"age": 30,
"surname": "Doe"
}
$.people[0].age
{
"people": [
{
"name": "John",
"surname": "Doe",
"age": 30
}
]
}
{
"people": [
{
"name": "John",
"surname": "Doe"
}
]
}
Last updated