How to change master domain for an account on cPanel server from command line

To change the master domain for an account on a cPanel server from the command line, you can use the cPanel API WHMAPI1. Here are the steps:

– Connect to the server via SSH using your preferred terminal emulator.
– Use the following command to change the master domain for the account:

whmapi1 modifyacct user=USERNAME newdomain=newdomain.com
Read the rest