Examples:
JSONPath syntax reference
$— root object.fieldor['field']— child field..field— recursive descent (find field at any depth)[*]— wildcard, all elements of array or object[n]— array index (negative allowed:[-1]= last)[n:m]— array slice[n,m]— array union (multiple indices)[?(@.price<10)]— filter expression (use@for current element)
Common use cases
- Extract specific fields from a deeply nested API response
- Test query syntax before using it in code (jq, Postman, K6, JMeter)
- Debug GraphQL/REST payloads
- Build CI/CD assertions on JSON responses