Hi,
Does anyone have or know where there is an example of a SOAP message to create user accounts or courses using the standard Moodle web services?
If so, can someone point them out or provide an example?
Regards
Hi,
Does anyone have or know where there is an example of a SOAP message to create user accounts or courses using the standard Moodle web services?
If so, can someone point them out or provide an example?
Regards
Sorted!
I added a few lines to the moodle/lib/zend/Zend/Soap/Server.php at around line 807
public function handle($request = null)
{
if (null === $request) {
$request = file_get_contents('php://input');
}
//Added code
$fp=fopen("/somewriteablepath/soaptest.txt","w");
fputs($fp,print_r($request,1));
fclose($fp);
//End added code
Then do a test from within Moodle to create a user through SOAP web services.
From the resulting output I was able to form a SOAP message using SAAJ to create a simple course, see the attachment. Will extend this to create a Java SOAP library.