MDL-68448 mod_h5pactivity: Add new ws get_h5pactivities_by_courses
[moodle.git] / mod / h5pactivity / db / services.php
index db62e5e..ee50c8f 100644 (file)
@@ -53,4 +53,15 @@ $functions = [
         'capabilities'  => 'mod/h5pactivity:view',
         'services'      => [MOODLE_OFFICIAL_MOBILE_SERVICE],
     ],
+    'mod_h5pactivity_get_h5pactivities_by_courses' => [
+        'classname'     => 'mod_h5pactivity\external\get_h5pactivities_by_courses',
+        'methodname'    => 'execute',
+        'classpath'     => '',
+        'description'   => 'Returns a list of h5p activities in a list of
+               provided courses, if no list is provided all h5p activities
+               that the user can view will be returned.',
+        'type'          => 'read',
+        'capabilities'  => 'mod/h5pactivity:view',
+        'services'      => [MOODLE_OFFICIAL_MOBILE_SERVICE],
+    ],
 ];