January 2018
Intermediate to advanced
340 pages
8h 6m
English
To get started, let's look at making a basic HTTP request and searching for a string using the standard library. First, we will create http.Client and set any custom variables; for example, whether or not the client should follow redirects, what set of cookies it should use, or what transport to use.
The http.Transport type implements the network request operations to perform the HTTP request and get a response. By default, http.RoundTripper is used, and this executes a single HTTP request. For the majority of use cases, the default transport is just fine. By default, the HTTP proxy from the environment is used, but the proxy can also be specified in the transport. This might be useful ...
Read now
Unlock full access