DirectAdmin

The DirectAdmin module allows you to add and manage DirectAdmin servers in WHMCS.

Supported Features

CreateSuspendUnsuspendTerminate
Change PackageChange PasswordUsage UpdatesClient Area Link

Make sure to open the following ports for outbound connections from your WHMCS server:

  • 2222

Adding a Server

To set up a DirectAdmin server in WHMCS:

  1. Go to Configuration () > System Settings > Servers.
  2. Click Add New Server.
  3. Select DirectAdmin from the menu.
  4. Enter the hostname or IP address, username, password, and access hash.
    • The username and password must be for a reseller on the server.
    • You can also use a Login Key instead of the reseller password.
      If you see a WHMCS Host Server IP is Blacklisted error, it may indicate invalid login credentials. Resolve this issue, and then remove the WHMCS server IP address from the /usr/local/directadmin/data/admin/ip_blacklist file on the DirectAdmin server and try again.
  5. Click Test Connection.
    If you see a 56 - Recv failure: Connection reset by peer error, the DirectAdmin server requires an SSL connection.
  6. Enter the desired additional server details.
  7. Examine the displayed default port. If your server uses a different port, check Override with Custom Port and enter the correct port.
    For more information, see Server Port Overrides.
  8. Click Save Changes.
  9. If this is the only DirectAdmin server that is currently in WHMCS, click on the name and ensure that it results in an asterisk (*) next to it. This indicates that it is the default to use when any other non-specific configuration doesn’t apply.

Creating a DirectAdmin Product

You can create a product that provisions accounts on your DirectAdmin server at Configuration () > System Settings > Products/Services.

For account creation to work successfully with DirectAdmin, you must correctly configure your packages in the DirectAdmin control panel.

After you create your product, you must:

  1. Log in to your DirectAdmin Server.
  2. Click Manage User Packages.
  3. Copy the package name from the list or create the package.
  4. In WHMCS, enter the package name in the product’s Module Settings tab exactly as it appears in DirectAdmin.

API Token Permissions

You can restrict the actions that a DirectAdmin API token can perform.

For these operations, WHMCS requires the following permissions:

CMD_API_PACKAGES_RESELLERCMD_API_PACKAGES_USERCMD_API_ADDITIONAL_DOMAINS
CMD_API_SHOW_ALL_USERSCMD_API_SHOW_USERSCMD_API_SHOW_RESELLERS
CMD_API_DNS_CONTROLCMD_API_DNS_MXCMD_API_FTP
CMD_API_SHOW_USER_CONFIGCMD_API_SYSTEM_INFOCMD_API_SHOW_RESELLER_IPS
CMD_API_ACCOUNT_USERCMD_SELECT_USERSCMD_API_USER_PASSWD
CMD_API_MODIFY_RESELLERCMD_API_MODIFY_USERCMD_API_SHOW_USER_USAGE
CMD_API_RESELLER_STATS
The Sync Accounts feature requires the CMD_API_SHOW_RESELLERS permission. However, without this permission, the system can still perform other actions.

WHMCS Connect

This module does not support WHMCS Connect.

Last modified: October 30, 2024