Assuming you have a JSON array, each of which has a field labeled “foo”, you get all “foo” fields thusly:

<output JSON string to stdout> | jq '.[] | {"foo"}'

Why do I keep forgetting this?

Hat tip: jq