Creates a [`Client`] that incorporates the optional parameters configured on the builder and the specified required parameters.
(self, config: ClientConfig)
| 61 | /// Creates a [`Client`] that incorporates the optional parameters |
| 62 | /// configured on the builder and the specified required parameters. |
| 63 | pub fn build(self, config: ClientConfig) -> Client { |
| 64 | let inner = reqwest::ClientBuilder::new() |
| 65 | .redirect(reqwest::redirect::Policy::none()) |
| 66 | .timeout(Duration::from_secs(60)) |
| 67 | .build() |
| 68 | .unwrap(); |
| 69 | |
| 70 | Client { |
| 71 | auth_client: config.auth_client, |
| 72 | endpoint: self.endpoint, |
| 73 | inner, |
| 74 | } |
| 75 | } |
| 76 | } |