Extending the Laravel Http Facade

I’m trying to find the right way to extend the Laravel Http Client Facade. I don’t want to do this every time when I want to get something from the response of my request. I would like to add some more helpers to prevent this. Also I can’t directly extend the client, because I’m using the facade with a macro to ease my life.


>Solution :

This is already built into the client.

$response = Http::get('http://example.com/users/1');

Or even:


Leave a Reply