JSON.TYPE
Since 1.1.0JSON
Syntax
JSON.TYPE key [path]Returns the type of each value path matches: object, array, string, integer, number, boolean or null.
Reply
- A JSONPath: an array of types. A legacy path, or none: one type.
Examples
> JSON.SET d $ '{"name":"Ada","age":36,"tags":[],"addr":{},"active":true}'
OK
> JSON.TYPE d
"object"
> JSON.TYPE d $.*
1) "string"
2) "integer"
3) "array"
4) "object"
5) "boolean"