I have a report.json generated by a gitlab pipeline. It looks like: {"version":"14.0.4","vulnerabilities":[{"id":"64e69d1185ecc48a1943141dcb6dbd628548e725f7cef7
Using jq on JSON data ... I'm trying to select records where FromPort is 80 and CidrIp is 0.0.0.0/0 within the same element of the record. Here is the query: ca
I have this JSON: { "time": "2022-02-28T22:00:55.196Z", "severity": "INFO", "params": [ {"key": "state", "value": "pending"}, {"key"
Please help me to figure that one out... I want to get the ID where the name is - terraform-02 jq '.[] | map(select(.name == "terraform-02"))' - didn't work, to
Given a basic json { "notKnown": { "alpha" : { "hello":"world" } } } and then using getpath with a wildcard as an object
I have an json file as follows below- { "key1": [ "value1" ], "key2": [ "value2" ], "key3": [ "value3" ], "key4": { "name": "value
I have a json file with data as below : { "0cef7017-e6af-4c92-9e7c-4db1d7afc733": { "Show": [ "TEST1", "TEST2" ], "data1": 12345,
I have this input data: [ { "attributes": { "created": "2021-10-18T12:02:39+00:00", "enabled": true, "expires": null, "notBefore":
The 1 liner to grab the ticker works fine from commandline, but i get this error running in a script. I run the 1 liner that grabs TICKERD from commandline, th
(I’m not sure the technical terms to use but can update the question if someone can clarify the terminology I’m lacking for what I'm trying to do. I
I am trying to read each cell of CSV and treat it as an input for the JQ command. Below is my code: line.csv | Line | |:---- | | 11 | | 22 | | 33 | Cod
I need to replace part of a value from a json output. I could easily do this using sed -i however it would also replace other parts of the file I don't want it
I want to convert JSON string into an array in bash. The JSON string is passed to the bash script as an argument (it doesn't exist in a file). Is there a way o
I want to convert JSON string into an array in bash. The JSON string is passed to the bash script as an argument (it doesn't exist in a file). Is there a way o
Assuming I have the following JSON object (which is just an example): { "foo": 1, "bar": 2, "baz": 3 } And the following JSON array (another example)
I return a few json values from an API feed using this command: curl -s -u user:pass -H 'my header' https://example.com/data.json | jq -cr '.[] | {id: .id, con
I have json data that looks like [ { "session": "ffe887f3f150", "src_ip": "81.71.87.156" }, { "session": "fff42102e329", "src_ip": "143.19
I can create a json object with an array using jq like this echo '{"input":{"names":[]}}' | jq --arg val "alice" '.input.names[0] += $val'| jq --arg val "bob"
I have a json file I am parsing with jq. This is a sample of the file [{ "key1":{...}, "key2":{...} }] [{ "key1":{...}, "key2":{...} }] ... each line is a list
How to construct a name of a variable from data and access that variable? For example it should somehow give the content of the alpha-file: jq '$.var"-file"' --