HTTP protocol and methods of Requests library
The main method of the requests library: requests.request() constructs a request
requests.get() is the main method for obtaining HTML pages, corresponding to HTTP GET
The method of requests.head() to get the HTML page header, corresponding to the HTTP HEAD
requests.post() submits a POST request to a web page, corresponding to HTTP POST
requests.put() submits a PUT request to an HTML web page, corresponding to HTTP PUT
requests.patch() submits a partial modification request to an HTML page, corresponding to HTTP PATCH
requests.delete() deletes requests to HTML pages, corresponding to HTTP DELETE
Note: Consistent with HTTP operation
The HTTP protocol uses URL as an identifier for locating network resources
Format: http://host[:port][path]
host: a valid hostname or IP address
port: port number, default is 80
path: the path of the requested resource
Understand the difference between PSTCH and PUT
Use headers to get header information, and text is empty