I am trying to get some data from an API but have been getting the error 'dict' object has no attribute 'META' when I try to print it. I am using Requests module for this. Here is the code:
url = "https://coronavirus-map.p.rapidapi.com/v1/summary/region"
querystring = {"region":"Bangladesh"}
headers = {
'x-rapidapi-host': "coronavirus-map.p.rapidapi.com",
'x-rapidapi-key': "leaving this out :P"
}
request = requests.get(url, headers=headers, params=querystring).json()
print(request.text)
Everything works on Postman. Can anyone help?
paramslooks suspicious here, isn'tjson=ordata=?