1、requests.get(url, params=None, headers=None, cookies=None, auth=None, timeout=None)
Sends a GET request. Returns Response object.
Parameters:
- url – URL for the new Request object.
- params – (optional) Dictionary of GET Parameters to send with the Request.
- headers – (optional) Dictionary of HTTP Headers to send with the Request.
- cookies – (optional) CookieJar object to send with the Request.
- auth – (optional) AuthObject to enable Basic HTTP Auth.
- timeout – (optional) Float describing the timeout of the request.
requests.get(url,params = None,headers = None,cookies = None,auth = None,timeout =無)
發送GET請求。 返回Response對象。
參數:
- url - 新的Request對象的URL。
- params - (可選)使用請求發送的GET參數字典。
- 頭文件 - (可選)使用請求發送的HTTP頭文件字典。
- Cookie - (可選)使用請求發送的CookieJar對象。
- auth - (可選)AuthObject啟用基本HTTP身份驗證。
- 超時 - (可選)描述請求超時的浮點數。