1. 程式人生 > >#含有引數的post請求 r = requests.post(url,data=data,params=params)

#含有引數的post請求 r = requests.post(url,data=data,params=params)

#含有引數的post請求 r = requests.post(url,data=data,params=params)
import requests
url = "https://httpbin.org/post"

params = {"show_env":1}
data = {"a":"巧吧軟體測試","form":"form_data"}

r = requests.post(url,params=params,data=data)
print(r.headers)
print(r.text)
print(r.json()["form"])