connect_timeout
Summary
Float describing the number of seconds to wait while trying to connect to a server. Use 0
to wait indefinitely (the default behavior).
Types
float
Default
0
Constant
GuzzleHttp\RequestOptions::CONNECT_TIMEOUT
// Timeout if the client fails to connect to the server in 3.14 seconds.
$client->request('GET', '/delay/5', ['connect_timeout' => 3.14]);
Note
This setting must be supported by the HTTP handler used to send a request. connect_timeout
is currently only supported by the built-in cURL handler.