JSON.OBJKEYS

    Return the keys in the object that’s referenced by

    Required arguments

    is key to parse. Returns null for nonexistent keys.

    path

    Return

    JSON.OBJKEYS returns an array of array replies for each path, an array of the key names in the object as a bulk string reply, or nil if the matching JSON value is not an object. For more information about replies, see .

    1. dragonfly> JSON.SET doc $ '{"a":[3], "nested": {"a": {"b":2, "c": 1}}}'
    2. dragonfly> JSON.OBJKEYS doc $..a
    3. 2) 1) "b"

    See also

    JSON.ARRINDEX | JSON.ARRINSERT