#有headers的get请求 r = requests.get(url,params=params,headers=headers)
#有headers的get请求 r = requests.get(url,params=params,headers=headers)
import requests
url = "https://httpbin.org/get"
params = {"show_raw":1}
headers = {'User-Agent': 'python-requests/2.18.4'}
r = requests.get(url,params=params,headers=headers)
print(r.status_code)
print(r.json())
print(r.json()["headers"])