0

I'm trying to traslate shell script bash to pyhton. I use jq to extract fileds of json response but with jsonresponse I can't do it with python. Someone knows? My bash line

jq -r '.search_objects[].price' file

I'm trying with

print(jsonResponse["search_objects"]["price"])

But fails :-(

defekas17
  • 155
  • 1
  • 9

1 Answers1

0

Maybe this

HTTP requests and JSON parsing in Python

import json

data = json.loads(jsonResponse)
Johnny
  • 687
  • 1
  • 6
  • 22