In SOAP::Lite, the first argument to proxy() is the SOAP endpoint. A forward network proxy goes in the HTTP transport options:

use SOAP::Lite;

my $soap = SOAP::Lite->new;
$soap->proxy(
    'https://service.example/soap',
    proxy => ['https' => 'http://gateway.example:8080'],
    timeout => 15,
);

The outer method selects the service. The nested map gives the LWP-based transport an HTTP proxy for HTTPS destinations, using CONNECT. Apply this option where the application's actual SOAP::Lite object is constructed, including when a wrapper creates it. For a public SOAP endpoint where an unauthenticated public intermediary is permitted, the HTTP proxy list offers candidates for the nested proxy URL.

Keep the service namespace configured for its SOAP messages. That URI identifies XML names and does not replace either network endpoint.

Related articles