Working with session via web service...

Working with session via web service...

by Peter Eliyahu Kornfeld -
Number of replies: 2

Hi,

I have plugin, that used to push data from our main system to MOODLE... It is a web service exposing an API to add courses, users and exams...

Every API call have to have user credentials, that maps to a MOODLE user with proper right (to enable all the activities)...

In most cases API called as a result of a single change in the main database, but there is a case when synchronization occurs in batch...

In this case it would be helpful to do only a single authentication at the beginning and then run with for all the API calls...

There is a way to do so?


Regards,

Peter


Average of ratings: -
In reply to Peter Eliyahu Kornfeld

Re: Working with session via web service...

by Tim Hunt -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers

How are you doing the authentication? There is an option to authenticate web services calls with a token? Have you tried that?

In reply to Tim Hunt

Re: Working with session via web service...

by Peter Eliyahu Kornfeld -

Hi Tim,

I'm using a SOAP based web service that I wrote, and not part of the web service platform of MOODLE... It just didn't fit my needs...

for now I authenticate the user on a call basis, but that's won't be good for batch...

Can you point me toward the proper API for the web services, I may find there something...