Missing domains - WHM API get_domain_info doesn't return all domains
-
Testing this and I'm definitely getting all domains on the server returned regardless of the owner of the domain. How are you running it? In short I'm [root@server cgi-bin]# whmapi1 get_domain_info |grep "domain:" |wc -l 142
[root@server cgi-bin]# whmapi1 get_domain_info |grep "user_owner: root" |wc -l 39 [root@server cgi-bin]# whmapi1 get_domain_info |grep "user: root" |wc -l 00 -
I'm using PHP and this package: previewtechs/cpanel-whm-api - Packagist It sends a GET request to /json-api/get_domain_info with an Authorization header that looks like this "whm root apitoken" If I run the commands you supplied I get all of the domains, so maybe it's the JSON API? 0 -
I figured out the problem - the API token needs to have root access Thanks 0
Please sign in to leave a comment.
Comments
3 comments