Misleading documentation for whmapi1 modifyacct

gryzli

Well-Known Member
Jul 23, 2012
49
6
58
cPanel Access Level
Root Administrator
Hi guys,

I didn't find any other place to report that, that's why I'm doing it here.

The documentation for whmap1->modifyacct is misleading, regarding changing the main domain for an account.

Link: Update cPanel account · cPanel & WHM Developer Portal

In the doc it says one must use the 'dns=' parameter, but it doesn't work.

The right way to change an account main domain is by providing the 'domain=NEWDOMAIN...' parameter, which seems to work correctly.
 
Last edited by a moderator:

cPRex

Jurassic Moderator
Staff member
Oct 19, 2014
7,418
999
313
cPanel Access Level
Root Administrator
Hey there! This seems more like an omission than a bad entry for DNS. The DNS field is meant to list the primary entry for the account inside the /var/cpanel/users/dbtest file, and is optional.

I did confirm the following will update the domain name of an account properly:

Code:
whmapi1 modifyacct user=username domain=someotherdomain.com
so I'll be getting that documentation updated shortly.
 
  • Like
Reactions: gryzli

gryzli

Well-Known Member
Jul 23, 2012
49
6
58
cPanel Access Level
Root Administrator
Hey there! This seems more like an omission than a bad entry for DNS. The DNS field is meant to list the primary entry for the account inside the /var/cpanel/users/dbtest file, and is optional.

I did confirm the following will update the domain name of an account properly:

Code:
whmapi1 modifyacct user=username domain=someotherdomain.com
so I'll be getting that documentation updated shortly.
Thanks !