Remote WSDL loading can happen inside the SoapClient constructor. Supply the proxy before that first retrieval:

$client = new SoapClient('https://service.example.com/api?wsdl', [
    'proxy_host' => '203.0.113.10',
    'proxy_port' => 8080,
    'proxy_login' => getenv('PROXY_USER'),
    'proxy_password' => getenv('PROXY_PASSWORD'),
    'connection_timeout' => 5,
    'exceptions' => true,
]);

Use the real WSDL, proxy host/port and intended credential source. The host field is an address, with its port separate.

When it failsRequest or operation to inspect
Client constructionWSDL retrieval or document processing.
Imported document/schema processingThe actual additional retrieval URL.
A SOAP method callThe service endpoint declared in the WSDL, possibly on another host.

A worker using cached WSDL may skip the request that fails on another machine. Keep cache configuration and the actual failed URL with the comparison rather than change the proxy based only on construction success.

proxy_login/proxy_password authenticate the intermediary. Destination login/password and SOAP-level service authentication serve other layers. Use the dedicated options rather than put account-like headers into User-Agent; required application headers belong in a supported header interface.

Record the operation, target and party issuing a challenge with secrets removed. connection_timeout bounds connection establishment, not the complete duration of a long SOAP operation.

Allakkat attuumassuteqartut