Custom Request Timeouts
To modify request timeouts (connect or total, in seconds) you’ll need to tell the API client to use a CurlClient other than its default. You’ll set the timeouts in that CurlClient.Custom cURL Options (proxies)
Need to set a proxy for your requests? Pass in the requisiteCURLOPT_* array to the CurlClient constructor, using the same syntax as curl_stopt_array(). This will set the default cURL options for each HTTP request made by the SDK, though many more common options (e.g. timeouts; see above on how to set those) will be overridden by the client even if set here.
testDefaultOptions() in tests/CurlClientTest.php for an example of this behavior. Note that the callable is called at the beginning of every API request, before the request is sent.
Configuring a Logger
The library does minimal logging, but it can be configured with a [PSR-3 compatible logger][psr3] so that messages
end up there instead of error_log: