Exeu/apai-io

Missing option: Request timeout

andreisusanu opened this issue · 2 comments

Hello,

Is it possible to add a request timeout? Some of my calls are taking forever...

http://docs.guzzlephp.org/en/latest/request-options.html#timeout

Thanks!

Exeu commented

Have a look at the guzzle documentation:

http://docs.guzzlephp.org/en/latest/quickstart.html#creating-a-client

There you see:
$client = new Client([ // ... // You can set any number of default request options. 'timeout' => 2.0, ]);

As apiio uses a client object which you have to inject you can use a client with a timeout setting.

Indeed... sorry for the dumb question. Cheers!