I am making two different scripts, one that runs a cpanel plugin and is obviously limited to the current user. The other script just runs from a cron job as root, but I am not sure how you specify what cpanel account i want it to fetch the data for. If I am doing something like so:
Is there a way for me to specify the cpanel account as well? I think there might be a way to do all of this using the xmlapi, but I would rather not and since this is running internally, there is no reason to do any type of authentication. Am I missing something?
PHP:
$r = $cpanel->api2('Email', 'listdomainforwards');
var_dump($r);