
Originally Posted by
k_shehadeh
I'm trying to understand why my primary user on a WHM server is unable to get a listing of a domain in a separate account. I think I don't understand the different relationships between users and WHM accounts. Here's the situation:
I have a WHM account with a user "user1". In this WHM account there are two cPanel accounts (sorry if I'm using the wrong words here). The first is for domain "mydomain1.com" and the second is for "mydomain2.com". The primary user for the "mydomain1.com" account is "user1" and the primary user for the "mydomain2.com" account is "user2".
So:
WHM Account >> "user1"
"mydomain1.com" >> "user1"
"mydomain2.com" >> "user2"
Now, I'm using the Email::listpopswithdisk to try and retrieve email accounts for a domain. The problem is when I login as "user1" with the API and try to retrieve email accounts for "mydomain2.com", I get nothing back. This kind of makes since that account is owned by "user2". But what confuses me then is why one of the arguments for this API call is "domain" when the logged in user can apparently only access the domain of their own account (even if the user is the WHM account holder).
I know this is a convoluted question but I can't think of a better way to ask it. Any help getting me to understand would be very much appreciated.
Thanks,
Karim