Skip to content

Instantly share code, notes, and snippets.

@john-auld
Created March 14, 2019 09:47
Show Gist options
  • Save john-auld/d57ee92ef12e4e6a5c07cd88d50be5d1 to your computer and use it in GitHub Desktop.
Save john-auld/d57ee92ef12e4e6a5c07cd88d50be5d1 to your computer and use it in GitHub Desktop.

Json Path pattern

$..groups[?(@.name)].name

json body

{"groups":
  [
    {"name": "g1"},
    {"name": "g2"}
  ]
}

result

[
  "g1",
  "g2"
]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment