I've created a Web Service user and a Web Service role, to which the Web Service user is assigned. This role has every single possible permission enabled. Yet, when I do a simple call to moodle_user_get_users_by_id using Zend's XML-RPC client, it fails. I get back a Zend_Xml_Rpc_Client_FaultException with the message property that says "Access control exception".
Right, so if I add my Web Service user to the Administrators group, my script works fine and returns the users, as requested! So, this has to be a permissions problem in Moodle.
Reading through more documentation, I go back and look at the list of functions defined for my web service. The "moodle_user_get_users_by_id" function requires "moodle/user:viewdetails". So I go back to my Web Service role and make sure that this is enabled. It is set to Allow!
So, what is the deal here? At this point I would just leave the user as an Administrator, but then I can't view the documentation. (Very annoying by the way. Equally annoying that there isn't a mirror of the documentation for the standard functions on Moodle.org somewhere. Sure, I get that these are changing, but how hard would it be to copy/paste and have this documentation at least somewhat up to date on Moodle's website? I'd volunteer to do it myself if I could ever this working.)
So, any thoughts on where I should begin to track down my permissions problem?
Any help or advice you can give is most appreciated.