Search code examples
spring-bootwhmcs

Why i need to add my ipaddress to access the whmcs rest api?


i am new to WHMCS API and i just want call WHMCS API from my spring boot rest template and i am tired of adding my ip address to WHMCS->General Setting->Security->API IP Access Restriction.


Solution

  • According to WHMCS docs, it is a requirement:

    API IP Access Restriction

    Advanced. If using the WHMCS API from an off-server location, you must specify the IP address here, otherwise access will be denied.

    You can submit a feature request with your concerns so that they may consider an alternative in the future.

    Edit:

    According to WHMCS developer documentation, you can bypass IP Address restriction by using api access key in the configuration.php file:

    $api_access_key = 'secret_key_passphrase_goes_here';
    

    then access api with the following URL:

    whmc-url.com/includes/api.php?action=xxxx&username=xxx&password=xxx&accesskey=secret_key_passphrase_goes_here