Quantcast
Channel: Web services
Viewing all articles
Browse latest Browse all 2362

Create a user for a webservice automatically

$
0
0
by Pablo Platt.  

My plugin need to let an external web service talk to moodle. Asking the admin do all the steps manually is a bit cumbersome and much more difficult than just configuring three fields for a usual plugin. Is it ok to do the following automatically in the plugin install.php or are there technical or security issues?

 

  • Create a webservice user
  • Create a system role with the required capabilities
  • Assign the system role to the user
  • Give the user permission to use the web service
  • Generate a token for that user

Is there an example that does a similar thing?Am I missing some steps?

Thanks


Viewing all articles
Browse latest Browse all 2362

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>