This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* | |
* Using a key => value pair with the yield keyword is | |
* the cleanest method I could find to add identifiers or tags | |
* to asynchronous concurrent requests in Guzzle, | |
* so you can identify which response is from which request! | |
*/ | |
$client = new GuzzleHttp\Client(['base_uri' => 'http://httpbin.org']); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"name": "sikofitt/guzzle-example", | |
"description": "Guzzle Example", | |
"type": "project", | |
"require": { | |
"php":">=5.6", | |
"guzzlehttp/guzzle": "^6.2" | |
}, | |
"require-dev": { | |
"symfony/var-dumper": "^3.2", |