JeremyDunn / php-fedex-api-wrapper

This library provides a fluid interface for constructing requests to the FedEx web service API.
269 stars 184 forks source link

API with Proxy #83

Closed docelmo closed 5 years ago

docelmo commented 5 years ago

Greetings.. Im having a bit of an issue. I have to install the API behind a proxy. I have setup the proxy by modifying the code but it appears not to be working as it times out on the gateway. Has anyone used this API behind a proxy? If so, can you cite the code changes made to make it work?

JeremyDunn commented 5 years ago

If using a proxy means you have a different URL for the Web service endpoint, you can create your own instance of the SoapClient that each Request object uses.

For example:

$soapClient = new \SoapClient('https://custom-url-to-proxy.wsdl', ['trace' => true]);
$request = new \FedEx\RateService\Request($soapClient);