gojq

Pure Go implementation of jq for parsing and transforming JSON

brewmacoslinux
Try with needOr install directly
Source

About

Pure Go implementation of jq

Commands

gojq

Examples

Pretty-print JSON with indentation$ gojq . input.json
Extract specific field from JSON$ gojq '.users[].name' data.json
Filter and transform JSON objects$ gojq 'map(select(.age > 21) | {name, age})' users.json