Server Sync Tool
The server sync tool can be used to syncronise records within WHMCS with a remote web server or module.
It allows you to easily identify and resolve discrepancies in the following contexts:
- Accounts that exist on the remote system (typically a web server) but that do not exist within WHMCS
- Service records that are active within WHMCS but that do not exist on the remote system
- Service records that exist within WHMCS but have differing info to the remote system
The sync tool has a 3 step process, first analysing accounts and providing you with an informative report that highlights any discrepancies, and giving you the opportunity to review and either resolve discrepancies manually, or have the tool automatically correct them for you.
Performing a Sync
To perform a sync, follow the steps below.
- Begin by navigating to Setup > Products/Services > Servers
- Click the Sync Accounts button for the server you wish to analyse. Note that this button will only appear for servers assigned to modules that support the Sync functionality. At the time of writing this includes: cPanel, Plesk and DirectAdmin modules.
- WHMCS will make an API call to the remote web server to fetch an up-to-date list of account records. This may take a few seconds.
- Upon completion, an analysis summary report will be displayed to you that looks something like the following.
From here you can review the discrepancies between the service records within WHMCS and the records on the remote system.
The report UI is broken up into two columns. On the left is the data retrieved from the remote system, and on the right are the service record matches found within WHMCS. Any differences will be highlighted in red. Exact matches will be highlighted in green.
The ID column within the WHMCS service record area of the UI provides a link to the manage service screen for those records. This can be used to jump to a service within WHMCS and make quick manual edits.
Choosing items to be Imported/Synced
The Import/Sync checkbox on the far right of the review table can be checked in order to have a service automatically updated by the Sync Tool. There are 3 possible scenarios:
- Partial Match - Service record exists in WHMCS but there are some discrepancies in data - checking the Import/Sync checkbox for a service like this will result in the service being modified to match the information returned from the remote system. This can include updating any of the following: domain, primary IP, username, product, status and/or creation date.
- Missing within WHMCS - This occurs when an account exists on the remote system, but no matching service record can be found within WHMCS. Select the Import/Sync option for a record like this will result in a new service record being created. WHMCS will attempt to use an existing product if a match is found, otherwise it will create a new product also.
- Missing on Remote System - This occurs when a service record exists within WHMCS but not on the remote system. Selecting the Import/Sync option for a record like this will cause the service to be set to Terminated within WHMCS.
Once you have made your selections of the accounts you wish to import/sync, click Continue. This will take you to a Review step.
Reviewing Import/Sync Items
After selecting the records you wish to sync on the Analyse step, you will be presented with a Review step as pictured below.
The review summary will be broken up into the 3 categories described above, making clear what actions are about to be performed for each of the records you selected.
If you want to make any changes, hit the Back button located to the bottom left of the review screen. Once you are happy, hit the Continue button to execute the Sync process.
Upon completion, you will be presented with a summary of the sync process. Further details indicating what records have been updated or changes will be available in the activity log. Navigate to Utilities > System > Activity Log to review it.