Skip to main content
Version: 4.1

ClientExec

HiTechCloud Enterprise edition ships a ClientExec server plugin alongside the WHMCS, FOSSBilling and Blesta integrations.

The plugin lets ClientExec provision and manage hosting accounts on your HiTechCloud server:

  • Create a new account (and add its domain)
  • Suspend / unsuspend
  • Change package (plan)
  • Change password
  • Terminate
  • Test the connection

Source: hitechcloud-vietnam/hitechcloud-clientexec-module (private repository, shipped as the integrations/clientexec submodule of HiTechCloud Panel).

Requirements​

  • A HiTechCloud server with an Enterprise licence and the API enabled (HiTechAdmin > API, or hitechcloudcli config update api on)
  • An administrator account for the plugin to log in with (we recommend a dedicated one: hitechcloudcli admin new clientexec <password>)
  • ClientExec 6.x or newer

Installation​

  1. SSH into the ClientExec server.
  2. Go to plugins/server inside your ClientExec installation.
  3. Download the plugin into a folder named hitechcloud:
    git clone https://hitechcloud.org hitechcloud
  4. In the ClientExec admin area go to Settings > Servers > Add server and select the HiTechCloud Panel plugin.
  5. Fill in the server hostname, the HiTechAdmin port (default 2087) and the administrator username and password.
  6. Click Test connection.

How it works​

The plugin authenticates against the HiTechAdmin API (POST /api/) with the administrator credentials and uses the returned JWT bearer token for every subsequent call:

ClientExec actionHiTechAdmin API call
CreatePOST /api/users/<username> then POST /api/domains/new
Suspend / UnsuspendPATCH /api/users/<username> with {"action": "suspend"} / {"action": "unsuspend"}
Change passwordPATCH /api/users/<username> with {"password": "..."}
Change packagePUT /api/users/<username> with {"plan_name": "..."}
TerminateDELETE /api/users/<username>

The ClientExec package name must match a plan name on the HiTechCloud server.

Troubleshooting​

On ClientExec:

  1. Enable debug logging for the server plugin and reproduce the action.
  2. Check the plugin log in the ClientExec admin area.

On the HiTechCloud server:

  1. Turn on DEV_MODE (HiTechAdmin > Settings > General or hitechcloudcli config update dev_mode on).
  2. Reproduce the action from ClientExec.
  3. Read /var/log/hitechcloud/admin/api.log.

Updating​

cd path_to_clientexec/plugins/server/hitechcloud
git pull