jsonpath-online-evaluator
jsonpath-online-evaluator copied to clipboard
get value for the key "$" fails
trafficstars
assume this json
{"$":123, "$a":456}
the following expression works fine:
$['$a']
however this expression returns the whole json:
$['$']
when it should return 123
hey @dlukyanov , did you found solution for your question? I just came across the same and I've found solution here: https://github.com/s3u/JSONPath
(e.g.,$ to match a property literally named $)
you have to use backtick to escape $, like so:
$.`$