Here is the error screenshot
# help
p
Here is the error screenshot
@Tom @Lee Turner Can you please help
t
Hi Pradeep, did you see this when you saved the stub? And what steps had you taken prior to this?
p
Hi @Tom, Yes I get this error when I am trying to save the stub. I was able to save the stub successfully when I select the Body as Equal to Json from the drop down. But I want to receive the response even if the fields in the payload matches and not only for the exact values. so I tried to select "matches" from the drop down and when I hit Save, I got this error
t
matches
uses regular expressions so I suspect what this message is telling you is that there are symbols (or combinations) in there that aren’t valid
If you want to match a JSON document then
equalToJson
is definitely the way to go.
p
I dont want to match all the keys and values in the JSON. I just want to make sure that only keys are matching and the values can be any. In that case also, equal to Json is the only way?
t
It's probably still the best way if you use placeholders for the values
p
ok, Thank you @Tom