pixelfed/zttp

A developer-experience focused HTTP client, optimized for most common use cases.

Maintainers

Details

github.com/pixelfed/zttp

Source

Installs: 8 647

Dependents: 1

Suggesters: 0

Security: 0

Stars: 0

Watchers: 1

Forks: 103

v0.4.1 2018-07-30 05:04 UTC

This package is auto-updated.

Last update: 2020-03-11 09:58:29 UTC


README

Zttp is a simple Guzzle wrapper designed to provide a really pleasant development experience for most common use cases.

If you need more functionality, just use Guzzle :)

Real documentation is in the works, but for now read the tests.

$response = Zttp::withHeaders(['Fancy' => 'Pants'])->post($url, [
    'foo' => 'bar',
    'baz' => 'qux',
]);

$response->json();
// => [
//  'whatever' => 'was returned',
// ];

Installation

composer require kitetail/zttp