Legacy API and allowed IP

I have a few scripts that use the legacy API key. The one in my local environment works fine. But last night I moved my production environment to a new server that has a new IP address, and the legacy calls there that use the same code / methods fail here:

if($app->cfgCon(“connectionName”)){

I noticed in the app there is an “allowed IP List” for the legacy API key that I never noticed before. I’ve never whitelisted any IP addresses and the box is currently empty, but I wondered if the failure I’m getting could be because of the new server IP.

Is there a way to see if there are any whitelisted IPs that aren’t shown in the UI? Any other thoughts on why an environment move would cause this failure?

Hi Andy,

I do not believe that Allowed IP List is the issue here as I have seen previous questions before about problems moving from Development to Production servers.

I recommend that you do a “phpinfo()” (PHP: phpinfo - Manual) and compare what PHP Modules are installed. I would guess that the “cURL” Extension is not installed which the XML-RPC component needs to communicate to the API.

Hope that helps.

Thank you very much.

It turns out the issue was related to the PHP version, the library that I am using breaks with 8.x but 7.x still seems to work just fine.

I just rolled back the PHP version and should be good.

I appreciate your reply Pav!

1 Like