JCRequest
v1.2.0
Another Guzzle wrapper
$ composer require jaredchu/jc-request
use JCHttpClientJCRequest;
$response = JCRequest::get($url);
echo $response->status();
echo $response->body();
var_dump($response->json());
$response = JCRequest::post($url, $params, $headers);
echo $response->status();
echo $response->body();
var_dump($response->json());
$response = JCRequest::post($url, json_encode($params), $headers);
var_dump($response->json());
$response = JCRequest::get($url, $params, $headers, [
'auth' => [$userName, $passwd]
]);
$response = JCRequest::get($url, $params, $headers, [
'connect_timeout' => 2,
'timeout' => 2
]);
$ git checkout -b feature/your-new-feature
$ git commit -am 'Add some feature'
$ git push origin feature/your-new-feature
MIT License