- Oct 2015
-
guzzle.readthedocs.org guzzle.readthedocs.org
-
echo $res->getStatusCode();
This did not work for me. Had an array as response, coming form service descriptor configuration. Therefore, I used the location statusCode to retrieve what was needed.
-
$res = $client->get('/status/500', ['exceptions' => false]);
Make sure Guzzle does not throw exceptions !!! Deal with them by yourself !!!
-
-
-
statusCode
use this location to retrieve message status code when you do not let Guzzle throw exceptions. Something like
"properties": { "httpStatus": { "location": "statusCode", "type": "string" } ...
-
- Sep 2015
-
blog.8thlight.com blog.8thlight.com
-
Internationalize Your Way to Cleaner Code
What a pretty way to put it !
-
-
blog.8thlight.com blog.8thlight.com
-
Make the Magic go away.
Clever indeed...
-
- May 2015
-
www.vinaysahni.com www.vinaysahni.com
-
if the client is incapable of working with HTTP headers
OK... So in fact the wrapper I am implementing for recs ecommerce API is overkill - it is redundant with http. I'll keep it though, since I like to define my own error codes.
-
I'm a big fan of the approach that Stripe has taken to API versioning -
Ouch ! :/ I read somewhere else that this was in fact very bad practice...
-
-
restcookbook.com restcookbook.com
-
RFC 7235 - Access Authentication Framework RFC 2617 - HTTP Authentication: Basic and Digest Access Authentication
Further readings...
Tags
Annotators
URL
-