gonon/http-symfony

Symfony HTTP Client adapter for the Gonon ecosystem

Maintainers

Package info

github.com/GononLabs/http-symfony

pkg:composer/gonon/http-symfony

Transparency log

Statistics

Installs: 34

Dependents: 1

Suggesters: 0

Stars: 0

Open Issues: 0

1.0.0 2026-07-09 15:51 UTC

This package is auto-updated.

Last update: 2026-07-09 16:54:52 UTC


README

This package provides the default Symfony HTTP Client adapter for the Gonon ecosystem. It acts as the bridge between Gonon\Core\Contracts\HttpClientInterface and symfony/http-client.

Installation

composer require gonon/http-symfony

Usage

This package provides a concrete adapter for the core HTTP client interface.

use Gonon\Core\Http\Client;
use Gonon\Core\Configuration\Config;
use Gonon\Http\Symfony\SymfonyHttpClient;

// 1. Create the Symfony Adapter
$adapter = new SymfonyHttpClient();

// 2. Pass it to the Core HTTP Orchestrator
$client = new Client(adapter: $adapter);

// Now you can pass $client to any Gonon SDK (Tripay, Xendit, etc.)

Customizing the Symfony Client

You can inject a fully configured Symfony HTTP Client instance into the adapter if you need specific options (e.g., proxies, certs).

use Symfony\Component\HttpClient\HttpClient;
use Gonon\Http\Symfony\SymfonyHttpClient;

$symfonyClient = HttpClient::create([
    'max_duration' => 5,
    'proxy' => 'http://proxy.example.com:8080'
]);

$adapter = new SymfonyHttpClient($symfonyClient);