AddonDomain::listaddondomains XML-API issue

chrislarge305

Registered
Dec 2, 2009
3
0
51
Hi there,

Trying to use the API to add a domain but also trying to list the current domains but having an issue.

/xml-api/cpanel?user=*****&xmlin=<cpanelaction><module>AddonDomain</module><func>listaddondomains</func></cpanelaction>
IS there something wrong with that because the error I am getting is

XML Parsing Error: junk after document element
Location: https://******:2083/xml-api/cpanel?...ins&cpanel_xmlapi_version=2&domain=domain.tld
Line Number 1, Column 95:<fatalerror>[a fatal error or timeout occurred while processing this directive]</fatalerror> <cpanelresult>
Thanks for your help

Regards

Chris
 
Last edited:

MattDees

Well-Known Member
Apr 29, 2005
416
1
243
Houston, TX
cPanel Access Level
Root Administrator
Chris, THis is a known issue in 11.24 and older versions of 11.25.

Please try using the Park module for this (they both have listaddondomains available to them)
 

agmorrison

Registered
Jun 1, 2010
1
0
51
Is there a way to get a full list of all the parked and addon domains for an entire server?

AddonDomain::listaddondomains indicates that it can be done but I cannot figure out how.
 

MattDees

Well-Known Member
Apr 29, 2005
416
1
243
Houston, TX
cPanel Access Level
Root Administrator
you would need to run /xml-api/listaccts and then execute

/xml-api/cpanel?cpanel_xmlapi_module=AddonDomain&cpanel_xmlapi_func=listaddondomains&user=$username

for each username.