[Moodle 2.0] Webservices provides too little functionality

[Moodle 2.0] Webservices provides too little functionality

by Stefan Lauer -
Number of replies: 5

Hi there!

We are a team of developers (from Vienna, sorry for bad english :P ) and we are developing an application that allows pupils to submit their programming-projects directly from the IDE eclipse onto moodle. This has to be done as Plug-In for eclipse.


Right now we are testing the possibilities provided by moodle and are confronted with following problems:

  • If you don't know the "id" of a specific course it's hardly possible to get the users enrolled to that course.
  • AFAIK there is no way to submit examples from an external source that communicates with moodle through the webservice-interface.
  • We don't see a way to find out if a user has a specific role in a course (and further WHICH specific role he has).

We are developing the Plug-In in Java and for moodle 2.0. We hope that you can help us with our problems because we don't have too much time (the whole project should be done until May 2011; a prototype that is testing the basic functionality should be finished until next week).

Regards
moo:clipse Developer Team

PS: Attached is a screenshot of the functions provided by the moodle webservice-interfaces that we found.

Average of ratings: -
In reply to Stefan Lauer

Re: [Moodle 2.0] Webservices provides too little functionality

by Antero Aunesluoma -
Hi! We are building an integration with SIS and Moodle 2.x and are curious to know which method you are using for enrolling the students to a course? We'd like to use webservices for all all operations but I'm afraid we are still missing some relevant functions.

For example we are also missing a function that would return a "contextid" based on "courseid". The contextid is needed while using the the function "moodle_role_assign" - any hints for that?

Antero Aunesluoma
University of Helsinki
In reply to Antero Aunesluoma

Re: [Moodle 2.0] Webservices provides too little functionality

by Stefan Lauer -

Hi Antero!

That's the problem we talk about, the moodle webservice-api provides too little functionality so that you can work with it (such as submitting examples, enrol students to course,...).

We are also looking for a solution to "enlarge" this functionality.

Regards

moo:clipse dev team

In reply to Stefan Lauer

Re: [Moodle 2.0] Webservices provides too little functionality

by Antero Aunesluoma -
Hi Stefan!

I'm not sure whether you know that there is also an issue related to this:
http://tracker.moodle.org/browse/MDL-21524

- antero
In reply to Antero Aunesluoma

Re: [Moodle 2.0] Webservices provides too little functionality

by Christian Pfisterer -

Hi,

I guess you have to write your own external functions to get everything you need.

I've created an external function which really enrols users into a course. I've tried it and it works.

I've developed several other functions. Take a look into the attached zip file.

Maybe you can use some of the stuff I've developed!

BR Christian

P.S. If you are not familiar with the development of the moodle web services take a look here:

http://docs.moodle.org/en/Development:Web_services

http://docs.moodle.org/en/Development:External_services_description

http://docs.moodle.org/en/Development:Creating_a_web_service_and_a_web_service_function

http://docs.moodle.org/en/Development:External_services_security#Overview

Average of ratings: Useful (1)