Answers for "how to read a json resposnse from a link in python"

1

how to read a json resposnse from a link in python

import urllib, json

url = "put url here"
response = urllib.request.urlopen(url)
data = json.loads(response.read())
print (data)
Posted by: Guest on May-05-2020
1

fetch a json from url python

import requests
r = requests.get('url')
print r.json()
Posted by: Guest on May-05-2020

Code answers related to "how to read a json resposnse from a link in python"

Python Answers by Framework

Browse Popular Code Answers by Language