use Cake\Http\Client;

$http = new Client([
    'proxy' => [
        'proxy' => 'proxy.example:8080',
    ],
]);

Use this Cake\Http\Client instance for requests needing the route. A public HTTP candidate from the HTTP proxy list supplies the host and port for the nested proxy option. If clients come from a service factory or container, put these constructor options there.

For proxy authentication, the nested configuration also accepts username and password from the application's intended configuration source.

A Configure entry stores data; it changes no independently constructed client until code reads and passes it. Defining App.http.client alone therefore leaves this construction path unchanged.

Use request-level options when a particular request needs another route. A subclass can package broader behavior, but setting this default does not require one.

Artihkkalat mat laktásit