问题
I am integrating Magento and Moodle. Does moodle provides APIs to register users, assign user groups, create/edit/delete courses etc?
回答1:
There is a web services api - http://docs.moodle.org/20/en/How_to_create_and_enable_a_web_service
In summary:
Enable the protocol - go to site admin -> plugins -> web services -> manage protocols and select the protocol required, eg REST.
On the same page check Web services documentation and save changes.
Read through the API documentation at site admin -> plugins -> web services -> api documentation - to find the functions required.
Create an external service and add the required functions for user registration, create courses etc. site admin -> plugins -> web services -> external service
Then create a token to access the service site admin -> plugins -> web services -> manage tokens
来源:https://stackoverflow.com/questions/24378790/moodle-api-for-user-registration