MDL-49793 url: Move logging and completion to new API
[moodle.git] / lib / db / services.php
CommitLineData
9a0df45a 1<?php
9a0df45a 2// This file is part of Moodle - http://moodle.org/
3//
4// Moodle is free software: you can redistribute it and/or modify
5// it under the terms of the GNU General Public License as published by
6// the Free Software Foundation, either version 3 of the License, or
7// (at your option) any later version.
8//
9// Moodle is distributed in the hope that it will be useful,
10// but WITHOUT ANY WARRANTY; without even the implied warranty of
11// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12// GNU General Public License for more details.
13//
14// You should have received a copy of the GNU General Public License
15// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
16
a0a07014 17
9a0df45a 18/**
19 * Core external functions and service definitions.
20 *
39b90b51
EL
21 * The functions and services defined on this file are
22 * processed and registered into the Moodle DB after any
23 * install or upgrade operation. All plugins support this.
24 *
25 * For more information, take a look to the documentation available:
26 * - Webservices API: {@link http://docs.moodle.org/dev/Web_services_API}
27 * - External API: {@link http://docs.moodle.org/dev/External_functions_API}
28 * - Upgrade API: {@link http://docs.moodle.org/dev/Upgrade_API}
29 *
a0a07014
JM
30 * @package core_webservice
31 * @category webservice
32 * @copyright 2009 Petr Skodak
9a0df45a 33 * @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
34 */
35
36$functions = array(
ef22c1b6 37
088645e2
AB
38 // Cohort related functions.
39
40 'core_cohort_create_cohorts' => array(
41 'classname' => 'core_cohort_external',
42 'methodname' => 'create_cohorts',
43 'classpath' => 'cohort/externallib.php',
44 'description' => 'Creates new cohorts.',
45 'type' => 'write',
46 'capabilities'=> 'moodle/cohort:manage',
47 ),
48
49 'core_cohort_delete_cohorts' => array(
50 'classname' => 'core_cohort_external',
51 'methodname' => 'delete_cohorts',
52 'classpath' => 'cohort/externallib.php',
53 'description' => 'Deletes all specified cohorts.',
54 'type' => 'delete',
55 'capabilities'=> 'moodle/cohort:manage',
56 ),
57
58 'core_cohort_get_cohorts' => array(
59 'classname' => 'core_cohort_external',
60 'methodname' => 'get_cohorts',
61 'classpath' => 'cohort/externallib.php',
62 'description' => 'Returns cohort details.',
63 'type' => 'read',
64 'capabilities'=> 'moodle/cohort:view',
65 ),
66
67 'core_cohort_update_cohorts' => array(
68 'classname' => 'core_cohort_external',
69 'methodname' => 'update_cohorts',
70 'classpath' => 'cohort/externallib.php',
71 'description' => 'Updates existing cohorts.',
72 'type' => 'write',
73 'capabilities'=> 'moodle/cohort:manage',
74 ),
75
76 'core_cohort_add_cohort_members' => array(
77 'classname' => 'core_cohort_external',
78 'methodname' => 'add_cohort_members',
79 'classpath' => 'cohort/externallib.php',
80 'description' => 'Adds cohort members.',
81 'type' => 'write',
82 'capabilities'=> 'moodle/cohort:assign',
83 ),
84
85 'core_cohort_delete_cohort_members' => array(
86 'classname' => 'core_cohort_external',
87 'methodname' => 'delete_cohort_members',
88 'classpath' => 'cohort/externallib.php',
89 'description' => 'Deletes cohort members.',
90 'type' => 'delete',
91 'capabilities'=> 'moodle/cohort:assign',
92 ),
93
94 'core_cohort_get_cohort_members' => array(
95 'classname' => 'core_cohort_external',
96 'methodname' => 'get_cohort_members',
97 'classpath' => 'cohort/externallib.php',
98 'description' => 'Returns cohort members.',
99 'type' => 'read',
100 'capabilities'=> 'moodle/cohort:view',
101 ),
604afeff 102
be985416
CC
103 // Comments related functions.
104
105 'core_comment_get_comments' => array(
e77a0f36
JL
106 'classname' => 'core_comment_external',
107 'methodname' => 'get_comments',
108 'description' => 'Returns comments.',
109 'type' => 'read',
110 'capabilities' => 'moodle/comment:view',
111 ),
112
198e802f 113 // Grade related functions.
d3549931 114
198e802f
JL
115 'core_grades_get_grades' => array(
116 'classname' => 'core_grades_external',
117 'methodname' => 'get_grades',
a0095e5a
JL
118 'description' => 'Returns student course total grade and grades for activities.
119 This function does not return category or manual items.
120 This function is suitable for managers or teachers not students.',
198e802f 121 'type' => 'read',
a0095e5a 122 'capabilities' => 'moodle/grade:view, moodle/grade:viewall, moodle/grade:viewhidden',
d3549931
AD
123 ),
124
198e802f
JL
125 'core_grades_update_grades' => array(
126 'classname' => 'core_grades_external',
127 'methodname' => 'update_grades',
198e802f
JL
128 'description' => 'Update a grade item and associated student grades.',
129 'type' => 'write',
130 'capabilities' => '',
d3549931 131 ),
088645e2 132
ef22c1b6 133 // === group related functions ===
f5072177 134
9a0df45a 135 'moodle_group_create_groups' => array(
3c1aa6fd 136 'classname' => 'moodle_group_external',
5d1017e1
JM
137 'methodname' => 'create_groups',
138 'classpath' => 'group/externallib.php',
3c1aa6fd 139 'description' => 'DEPRECATED: this deprecated function will be removed in a future version. This function has been renamed as core_group_create_groups(). ',
5d1017e1
JM
140 'type' => 'write',
141 'capabilities'=> 'moodle/course:managegroups',
142 ),
143
144 'core_group_create_groups' => array(
145 'classname' => 'core_group_external',
9a0df45a 146 'methodname' => 'create_groups',
147 'classpath' => 'group/externallib.php',
f5072177 148 'description' => 'Creates new groups.',
149 'type' => 'write',
72f68b51 150 'capabilities'=> 'moodle/course:managegroups',
9a0df45a 151 ),
f5072177 152
9a0df45a 153 'moodle_group_get_groups' => array(
3c1aa6fd 154 'classname' => 'moodle_group_external',
5d1017e1
JM
155 'methodname' => 'get_groups',
156 'classpath' => 'group/externallib.php',
3c1aa6fd 157 'description' => 'DEPRECATED: this deprecated function will be removed in a future version. This function has been renamed as core_group_get_groups()',
5d1017e1
JM
158 'type' => 'read',
159 'capabilities'=> 'moodle/course:managegroups',
160 ),
161
162 'core_group_get_groups' => array(
163 'classname' => 'core_group_external',
9a0df45a 164 'methodname' => 'get_groups',
165 'classpath' => 'group/externallib.php',
cfb99b75 166 'description' => 'Returns group details.',
f5072177 167 'type' => 'read',
72f68b51 168 'capabilities'=> 'moodle/course:managegroups',
9a0df45a 169 ),
246f6da2 170
171 'moodle_group_get_course_groups' => array(
3c1aa6fd 172 'classname' => 'moodle_group_external',
5d1017e1
JM
173 'methodname' => 'get_course_groups',
174 'classpath' => 'group/externallib.php',
3c1aa6fd 175 'description' => 'DEPRECATED: this deprecated function will be removed in a future version. This function has been renamed as core_group_get_course_groups()',
5d1017e1
JM
176 'type' => 'read',
177 'capabilities'=> 'moodle/course:managegroups',
178 ),
179
180 'core_group_get_course_groups' => array(
181 'classname' => 'core_group_external',
246f6da2 182 'methodname' => 'get_course_groups',
183 'classpath' => 'group/externallib.php',
184 'description' => 'Returns all groups in specified course.',
185 'type' => 'read',
72f68b51 186 'capabilities'=> 'moodle/course:managegroups',
246f6da2 187 ),
2cb1ee78 188
9a0df45a 189 'moodle_group_delete_groups' => array(
3c1aa6fd 190 'classname' => 'moodle_group_external',
5d1017e1
JM
191 'methodname' => 'delete_groups',
192 'classpath' => 'group/externallib.php',
3c1aa6fd 193 'description' => 'DEPRECATED: this deprecated function will be removed in a future version. This function has been renamed as core_group_delete_groups()',
5d1017e1
JM
194 'type' => 'delete',
195 'capabilities'=> 'moodle/course:managegroups',
196 ),
197
198 'core_group_delete_groups' => array(
199 'classname' => 'core_group_external',
9a0df45a 200 'methodname' => 'delete_groups',
201 'classpath' => 'group/externallib.php',
0f4e72de
PS
202 'description' => 'Deletes all specified groups.',
203 'type' => 'delete',
72f68b51 204 'capabilities'=> 'moodle/course:managegroups',
9a0df45a 205 ),
c863dc38 206
9a0df45a 207 'moodle_group_get_groupmembers' => array(
3c1aa6fd
DM
208 'classname' => 'moodle_group_external',
209 'methodname' => 'get_groupmembers',
5d1017e1 210 'classpath' => 'group/externallib.php',
3c1aa6fd 211 'description' => 'DEPRECATED: this deprecated function will be removed in a future version. This function has been renamed as core_group_get_group_members()',
5d1017e1
JM
212 'type' => 'read',
213 'capabilities'=> 'moodle/course:managegroups',
214 ),
215
216 'core_group_get_group_members' => array(
217 'classname' => 'core_group_external',
218 'methodname' => 'get_group_members',
9a0df45a 219 'classpath' => 'group/externallib.php',
0f4e72de
PS
220 'description' => 'Returns group members.',
221 'type' => 'read',
72f68b51 222 'capabilities'=> 'moodle/course:managegroups',
9a0df45a 223 ),
4efa2483 224
9a0df45a 225 'moodle_group_add_groupmembers' => array(
3c1aa6fd
DM
226 'classname' => 'moodle_group_external',
227 'methodname' => 'add_groupmembers',
5d1017e1 228 'classpath' => 'group/externallib.php',
3c1aa6fd 229 'description' => 'DEPRECATED: this deprecated function will be removed in a future version. This function has been renamed as core_group_add_group_members()',
5d1017e1
JM
230 'type' => 'write',
231 'capabilities'=> 'moodle/course:managegroups',
232 ),
233
234 'core_group_add_group_members' => array(
235 'classname' => 'core_group_external',
236 'methodname' => 'add_group_members',
9a0df45a 237 'classpath' => 'group/externallib.php',
0f4e72de
PS
238 'description' => 'Adds group members.',
239 'type' => 'write',
72f68b51 240 'capabilities'=> 'moodle/course:managegroups',
9a0df45a 241 ),
242
243 'moodle_group_delete_groupmembers' => array(
3c1aa6fd
DM
244 'classname' => 'moodle_group_external',
245 'methodname' => 'delete_groupmembers',
9a0df45a 246 'classpath' => 'group/externallib.php',
3c1aa6fd 247 'description' => 'DEPRECATED: this deprecated function will be removed in a future version. This function has been renamed as core_group_delete_group_members()',
0f4e72de 248 'type' => 'delete',
72f68b51 249 'capabilities'=> 'moodle/course:managegroups',
9a0df45a 250 ),
72f68b51 251
5d1017e1
JM
252 'core_group_delete_group_members' => array(
253 'classname' => 'core_group_external',
254 'methodname' => 'delete_group_members',
255 'classpath' => 'group/externallib.php',
256 'description' => 'Deletes group members.',
257 'type' => 'delete',
258 'capabilities'=> 'moodle/course:managegroups',
259 ),
72f68b51 260
7ce23590
JL
261 'core_group_create_groupings' => array(
262 'classname' => 'core_group_external',
263 'methodname' => 'create_groupings',
264 'classpath' => 'group/externallib.php',
265 'description' => 'Creates new groupings',
266 'type' => 'write',
267 ),
268
269 'core_group_update_groupings' => array(
270 'classname' => 'core_group_external',
271 'methodname' => 'update_groupings',
272 'classpath' => 'group/externallib.php',
273 'description' => 'Updates existing groupings',
274 'type' => 'write',
275 ),
276
277 'core_group_get_groupings' => array(
278 'classname' => 'core_group_external',
279 'methodname' => 'get_groupings',
280 'classpath' => 'group/externallib.php',
281 'description' => 'Returns groupings details.',
282 'type' => 'read',
283 ),
284
285 'core_group_get_course_groupings' => array(
67aa60f9
JL
286 'classname' => 'core_group_external',
287 'methodname' => 'get_course_groupings',
288 'classpath' => 'group/externallib.php',
289 'description' => 'Returns all groupings in specified course.',
290 'type' => 'read',
7ce23590
JL
291 ),
292
293 'core_group_delete_groupings' => array(
67aa60f9
JL
294 'classname' => 'core_group_external',
295 'methodname' => 'delete_groupings',
296 'classpath' => 'group/externallib.php',
297 'description' => 'Deletes all specified groupings.',
298 'type' => 'write',
7ce23590
JL
299 ),
300
301 'core_group_assign_grouping' => array(
67aa60f9
JL
302 'classname' => 'core_group_external',
303 'methodname' => 'assign_grouping',
304 'classpath' => 'group/externallib.php',
305 'description' => 'Assing groups from groupings',
306 'type' => 'write',
7ce23590
JL
307 ),
308
309 'core_group_unassign_grouping' => array(
67aa60f9
JL
310 'classname' => 'core_group_external',
311 'methodname' => 'unassign_grouping',
312 'classpath' => 'group/externallib.php',
313 'description' => 'Unassing groups from groupings',
314 'type' => 'write',
7ce23590
JL
315 ),
316
5d62e813
JL
317 'core_group_get_course_user_groups' => array(
318 'classname' => 'core_group_external',
319 'methodname' => 'get_course_user_groups',
320 'classpath' => 'group/externallib.php',
321 'description' => 'Returns all groups in specified course for the specified user.',
322 'type' => 'read',
323 'capabilities' => 'moodle/course:managegroups',
324 ),
325
9857381d
CC
326 'core_notes_get_course_notes' => array(
327 'classname' => 'core_notes_external',
328 'methodname' => 'get_course_notes',
7ceee324 329 'classpath' => 'notes/externallib.php',
9857381d
CC
330 'description' => 'Returns all notes in specified course (or site) for the specified user.',
331 'type' => 'read',
332 'capabilities' => 'moodle/notes:view',
333 ),
334
72f68b51 335 // === file related functions ===
336
249c4f60 337 'moodle_file_get_files' => array(
3c1aa6fd 338 'classname' => 'moodle_file_external',
5d1017e1 339 'methodname' => 'get_files',
3c1aa6fd 340 'description' => 'DEPRECATED: this deprecated function will be removed in a future version. This function has been renamed as core_files_get_files()',
5d1017e1
JM
341 'type' => 'read',
342 'classpath' => 'files/externallib.php',
343 ),
344
345 'core_files_get_files' => array(
346 'classname' => 'core_files_external',
249c4f60
DC
347 'methodname' => 'get_files',
348 'description' => 'browse moodle files',
349 'type' => 'read',
350 'classpath' => 'files/externallib.php',
351 ),
5d1017e1 352
249c4f60 353 'moodle_file_upload' => array(
3c1aa6fd 354 'classname' => 'moodle_file_external',
5d1017e1 355 'methodname' => 'upload',
3c1aa6fd 356 'description' => 'DEPRECATED: this deprecated function will be removed in a future version. This function has been renamed as core_files_upload()',
5d1017e1
JM
357 'type' => 'write',
358 'classpath' => 'files/externallib.php',
359 ),
360
361 'core_files_upload' => array(
362 'classname' => 'core_files_external',
249c4f60
DC
363 'methodname' => 'upload',
364 'description' => 'upload a file to moodle',
365 'type' => 'write',
366 'classpath' => 'files/externallib.php',
367 ),
4efa2483 368
ef22c1b6 369 // === user related functions ===
72f68b51 370
ef22c1b6 371 'moodle_user_create_users' => array(
3c1aa6fd 372 'classname' => 'moodle_user_external',
5d1017e1
JM
373 'methodname' => 'create_users',
374 'classpath' => 'user/externallib.php',
3c1aa6fd 375 'description' => 'DEPRECATED: this deprecated function will be removed in a future version. This function has been renamed as core_user_create_users()',
5d1017e1
JM
376 'type' => 'write',
377 'capabilities'=> 'moodle/user:create',
378 ),
379
380 'core_user_create_users' => array(
381 'classname' => 'core_user_external',
ef22c1b6 382 'methodname' => 'create_users',
383 'classpath' => 'user/externallib.php',
fb79269b 384 'description' => 'Create users.',
385 'type' => 'write',
72f68b51 386 'capabilities'=> 'moodle/user:create',
ef22c1b6 387 ),
388
b0365ea5
JM
389 'core_user_get_users' => array(
390 'classname' => 'core_user_external',
391 'methodname' => 'get_users',
392 'classpath' => 'user/externallib.php',
393 'description' => 'search for users matching the parameters',
394 'type' => 'read',
395 'capabilities'=> 'moodle/user:viewdetails, moodle/user:viewhiddendetails, moodle/course:useremail, moodle/user:update',
396 ),
397
fb79269b 398 'moodle_user_get_users_by_id' => array(
3c1aa6fd 399 'classname' => 'moodle_user_external',
5d1017e1
JM
400 'methodname' => 'get_users_by_id',
401 'classpath' => 'user/externallib.php',
3c1aa6fd 402 'description' => 'DEPRECATED: this deprecated function will be removed in a future version. Use core_user_get_users_by_field service instead',
5d1017e1
JM
403 'type' => 'read',
404 'capabilities'=> 'moodle/user:viewdetails, moodle/user:viewhiddendetails, moodle/course:useremail, moodle/user:update',
405 ),
406
c70b9853 407 'core_user_get_users_by_field' => array(
86477112 408 'classname' => 'core_user_external',
c70b9853 409 'methodname' => 'get_users_by_field',
86477112 410 'classpath' => 'user/externallib.php',
c70b9853 411 'description' => 'Retrieve users information for a specified unique field - If you want to do a user search, use core_user_get_users()',
86477112
FS
412 'type' => 'read',
413 'capabilities'=> 'moodle/user:viewdetails, moodle/user:viewhiddendetails, moodle/course:useremail, moodle/user:update',
414 ),
415
5d1017e1
JM
416 'core_user_get_users_by_id' => array(
417 'classname' => 'core_user_external',
fb79269b 418 'methodname' => 'get_users_by_id',
ef22c1b6 419 'classpath' => 'user/externallib.php',
41f5285f 420 'description' => 'DEPRECATED: this deprecated function will be removed in a future version. This function has been replaced by core_user_get_users_by_field()',
fb79269b 421 'type' => 'read',
b4c74367 422 'capabilities'=> 'moodle/user:viewdetails, moodle/user:viewhiddendetails, moodle/course:useremail, moodle/user:update',
ef22c1b6 423 ),
424
01479290 425 'moodle_user_get_users_by_courseid' => array(
3c1aa6fd
DM
426 'classname' => 'moodle_user_external',
427 'methodname' => 'get_users_by_courseid',
428 'classpath' => 'user/externallib.php',
429 'description' => 'DEPRECATED: this deprecated function will be removed in a future version. This function has been renamed as core_enrol_get_enrolled_users()',
01479290
DC
430 'type' => 'read',
431 'capabilities'=> 'moodle/user:viewdetails, moodle/user:viewhiddendetails, moodle/course:useremail, moodle/user:update, moodle/site:accessallgroups',
432 ),
433
ea4e96c2 434 'moodle_user_get_course_participants_by_id' => array(
3c1aa6fd
DM
435 'classname' => 'moodle_user_external',
436 'methodname' => 'get_course_participants_by_id',
ea4e96c2 437 'classpath' => 'user/externallib.php',
3c1aa6fd 438 'description' => 'DEPRECATED: this deprecated function will be removed in a future version. This function has been renamed as core_user_get_course_user_profiles()',
5d1017e1
JM
439 'type' => 'read',
440 'capabilities'=> 'moodle/user:viewdetails, moodle/user:viewhiddendetails, moodle/course:useremail, moodle/user:update, moodle/site:accessallgroups',
441 ),
442
443 'core_user_get_course_user_profiles' => array(
444 'classname' => 'core_user_external',
445 'methodname' => 'get_course_user_profiles',
446 'classpath' => 'user/externallib.php',
447 'description' => 'Get course user profiles (each of the profils matching a course id and a user id).',
ea4e96c2
DC
448 'type' => 'read',
449 'capabilities'=> 'moodle/user:viewdetails, moodle/user:viewhiddendetails, moodle/course:useremail, moodle/user:update, moodle/site:accessallgroups',
450 ),
451
ef22c1b6 452 'moodle_user_delete_users' => array(
3c1aa6fd 453 'classname' => 'moodle_user_external',
5d1017e1
JM
454 'methodname' => 'delete_users',
455 'classpath' => 'user/externallib.php',
3c1aa6fd 456 'description' => 'DEPRECATED: this deprecated function will be removed in a future version. This function has been renamed as core_user_delete_users()',
5d1017e1
JM
457 'type' => 'write',
458 'capabilities'=> 'moodle/user:delete',
459 ),
460
461 'core_user_delete_users' => array(
462 'classname' => 'core_user_external',
ef22c1b6 463 'methodname' => 'delete_users',
464 'classpath' => 'user/externallib.php',
fb79269b 465 'description' => 'Delete users.',
466 'type' => 'write',
72f68b51 467 'capabilities'=> 'moodle/user:delete',
ef22c1b6 468 ),
469
470 'moodle_user_update_users' => array(
3c1aa6fd 471 'classname' => 'moodle_user_external',
5d1017e1
JM
472 'methodname' => 'update_users',
473 'classpath' => 'user/externallib.php',
3c1aa6fd 474 'description' => 'DEPRECATED: this deprecated function will be removed in a future version. This function has been renamed as core_user_update_users()',
5d1017e1
JM
475 'type' => 'write',
476 'capabilities'=> 'moodle/user:update',
477 ),
478
479 'core_user_update_users' => array(
480 'classname' => 'core_user_external',
ef22c1b6 481 'methodname' => 'update_users',
482 'classpath' => 'user/externallib.php',
fb79269b 483 'description' => 'Update users.',
484 'type' => 'write',
72f68b51 485 'capabilities'=> 'moodle/user:update',
ef22c1b6 486 ),
e9b66095 487
6a403810
JL
488 'core_user_add_user_device' => array(
489 'classname' => 'core_user_external',
490 'methodname' => 'add_user_device',
491 'classpath' => 'user/externallib.php',
492 'description' => 'Store mobile user devices information for PUSH Notifications.',
493 'type' => 'write',
494 'capabilities'=> '',
495 ),
496
3221718e
JL
497 'core_user_remove_user_device' => array(
498 'classname' => 'core_user_external',
499 'methodname' => 'remove_user_device',
500 'classpath' => 'user/externallib.php',
501 'description' => 'Remove a user device from the Moodle database.',
502 'type' => 'write',
503 'capabilities' => '',
504 ),
505
7a334a9b
JL
506 'core_user_view_user_list' => array(
507 'classname' => 'core_user_external',
508 'methodname' => 'view_user_list',
509 'classpath' => 'user/externallib.php',
510 'description' => 'Simulates the web-interface view of user/index.php (triggering events).',
511 'type' => 'write',
512 'capabilities' => 'moodle/course:viewparticipants',
513 ),
514
5770f10e
JL
515 'core_user_view_user_profile' => array(
516 'classname' => 'core_user_external',
517 'methodname' => 'view_user_profile',
518 'classpath' => 'user/externallib.php',
519 'description' => 'Simulates the web-interface view of user/view.php and user/profile.php (triggering events).',
520 'type' => 'write',
521 'capabilities' => 'moodle/user:viewdetails',
522 ),
523
72f68b51 524 // === enrol related functions ===
d0068cd0 525
b6b6c7ac
PC
526 'core_enrol_get_enrolled_users_with_capability' => array(
527 'classname' => 'core_enrol_external',
528 'methodname' => 'get_enrolled_users_with_capability',
529 'classpath' => 'enrol/externallib.php',
530 'description' => 'For each course and capability specified, return a list of the users that are enrolled in the course
531 and have that capability',
532 'type' => 'read',
533 ),
72f68b51 534
df997f84
PS
535 'moodle_enrol_get_enrolled_users' => array(
536 'classname' => 'moodle_enrol_external',
537 'methodname' => 'get_enrolled_users',
538 'classpath' => 'enrol/externallib.php',
5d1017e1 539 'description' => 'DEPRECATED: this deprecated function will be removed in a future version. Please use core_enrol_get_enrolled_users() (previously known as moodle_user_get_users_by_courseid).',
df997f84 540 'type' => 'read',
72f68b51 541 'capabilities'=> 'moodle/site:viewparticipants, moodle/course:viewparticipants,
542 moodle/role:review, moodle/site:accessallgroups, moodle/course:enrolreview',
df997f84 543 ),
e6acc551 544
5d1017e1
JM
545 'core_enrol_get_enrolled_users' => array(
546 'classname' => 'core_enrol_external',
547 'methodname' => 'get_enrolled_users',
548 'classpath' => 'enrol/externallib.php',
549 'description' => 'Get enrolled users by course id.',
550 'type' => 'read',
551 'capabilities'=> 'moodle/user:viewdetails, moodle/user:viewhiddendetails, moodle/course:useremail, moodle/user:update, moodle/site:accessallgroups',
552 ),
df997f84 553
3364dbb5 554 'moodle_enrol_get_users_courses' => array(
3c1aa6fd 555 'classname' => 'moodle_enrol_external',
3364dbb5
PS
556 'methodname' => 'get_users_courses',
557 'classpath' => 'enrol/externallib.php',
3c1aa6fd 558 'description' => 'DEPRECATED: this deprecated function will be removed in a future version. This function has been renamed as core_enrol_get_users_courses()',
3364dbb5
PS
559 'type' => 'read',
560 'capabilities'=> 'moodle/course:viewparticipants',
561 ),
562
5d1017e1
JM
563 'core_enrol_get_users_courses' => array(
564 'classname' => 'core_enrol_external',
565 'methodname' => 'get_users_courses',
566 'classpath' => 'enrol/externallib.php',
567 'description' => 'Get the list of courses where a user is enrolled in',
568 'type' => 'read',
569 'capabilities'=> 'moodle/course:viewparticipants',
570 ),
571
be9bf94e
RT
572 'core_enrol_get_course_enrolment_methods' => array(
573 'classname' => 'core_enrol_external',
574 'methodname' => 'get_course_enrolment_methods',
575 'classpath' => 'enrol/externallib.php',
576 'description' => 'Get the list of course enrolment methods',
577 'type' => 'read',
578 ),
579
5d1017e1
JM
580 // === Role related functions ===
581
df997f84 582 'moodle_role_assign' => array(
3c1aa6fd
DM
583 'classname' => 'moodle_enrol_external',
584 'methodname' => 'role_assign',
5d1017e1 585 'classpath' => 'enrol/externallib.php',
3c1aa6fd 586 'description' => 'DEPRECATED: this deprecated function will be removed in a future version. This function has been renamed as core_role_assign_role()',
5d1017e1
JM
587 'type' => 'write',
588 'capabilities'=> 'moodle/role:assign',
589 ),
590
591 'core_role_assign_roles' => array(
592 'classname' => 'core_role_external',
593 'methodname' => 'assign_roles',
e9b66095 594 'classpath' => 'enrol/externallib.php',
df997f84 595 'description' => 'Manual role assignments.',
e9b66095 596 'type' => 'write',
72f68b51 597 'capabilities'=> 'moodle/role:assign',
e9b66095 598 ),
599
df997f84 600 'moodle_role_unassign' => array(
3c1aa6fd
DM
601 'classname' => 'moodle_enrol_external',
602 'methodname' => 'role_unassign',
5d1017e1 603 'classpath' => 'enrol/externallib.php',
3c1aa6fd 604 'description' => 'DEPRECATED: this deprecated function will be removed in a future version. This function has been renamed as core_role_unassign_role()',
5d1017e1
JM
605 'type' => 'write',
606 'capabilities'=> 'moodle/role:assign',
607 ),
608
609 'core_role_unassign_roles' => array(
610 'classname' => 'core_role_external',
611 'methodname' => 'unassign_roles',
e9b66095 612 'classpath' => 'enrol/externallib.php',
df997f84 613 'description' => 'Manual role unassignments.',
e9b66095 614 'type' => 'write',
72f68b51 615 'capabilities'=> 'moodle/role:assign',
e9b66095 616 ),
5b4a78e2 617
6bb31e40 618 // === course related functions ===
619
3ec163dd 620 'core_course_get_contents' => array(
d4a246bc 621 'classname' => 'core_course_external',
3ec163dd 622 'methodname' => 'get_course_contents',
d4a246bc 623 'classpath' => 'course/externallib.php',
3ec163dd 624 'description' => 'Get course contents',
d4a246bc 625 'type' => 'read',
3ec163dd 626 'capabilities'=> 'moodle/course:update,moodle/course:viewhiddencourses',
f2229c68 627 ),
d6ebe011 628
6bb31e40 629 'moodle_course_get_courses' => array(
3c1aa6fd 630 'classname' => 'moodle_course_external',
5d1017e1
JM
631 'methodname' => 'get_courses',
632 'classpath' => 'course/externallib.php',
3c1aa6fd 633 'description' => 'DEPRECATED: this deprecated function will be removed in a future version. This function has been renamed as core_course_get_courses()',
5d1017e1
JM
634 'type' => 'read',
635 'capabilities'=> 'moodle/course:view,moodle/course:update,moodle/course:viewhiddencourses',
636 ),
637
638 'core_course_get_courses' => array(
639 'classname' => 'core_course_external',
6bb31e40 640 'methodname' => 'get_courses',
641 'classpath' => 'course/externallib.php',
642 'description' => 'Return course details',
643 'type' => 'read',
644 'capabilities'=> 'moodle/course:view,moodle/course:update,moodle/course:viewhiddencourses',
645 ),
646
647 'moodle_course_create_courses' => array(
3c1aa6fd 648 'classname' => 'moodle_course_external',
5d1017e1
JM
649 'methodname' => 'create_courses',
650 'classpath' => 'course/externallib.php',
3c1aa6fd 651 'description' => 'DEPRECATED: this deprecated function will be removed in a future version. This function has been renamed as core_course_create_courses()',
5d1017e1
JM
652 'type' => 'write',
653 'capabilities'=> 'moodle/course:create,moodle/course:visibility',
654 ),
655
656 'core_course_create_courses' => array(
657 'classname' => 'core_course_external',
6bb31e40 658 'methodname' => 'create_courses',
659 'classpath' => 'course/externallib.php',
660 'description' => 'Create new courses',
661 'type' => 'write',
662 'capabilities'=> 'moodle/course:create,moodle/course:visibility',
663 ),
664
63a85dc7
JL
665 'core_course_delete_courses' => array(
666 'classname' => 'core_course_external',
667 'methodname' => 'delete_courses',
668 'classpath' => 'course/externallib.php',
669 'description' => 'Deletes all specified courses',
670 'type' => 'write',
671 'capabilities'=> 'moodle/course:delete',
672 ),
673
79949c1b
MN
674 'core_course_delete_modules' => array(
675 'classname' => 'core_course_external',
676 'methodname' => 'delete_modules',
677 'classpath' => 'course/externallib.php',
678 'description' => 'Deletes all specified module instances',
679 'type' => 'write',
680 'capabilities' => 'moodle/course:manageactivities'
681 ),
682
3dc1d76e
JL
683 'core_course_duplicate_course' => array(
684 'classname' => 'core_course_external',
685 'methodname' => 'duplicate_course',
686 'classpath' => 'course/externallib.php',
687 'description' => 'Duplicate an existing course (creating a new one) without user data',
688 'type' => 'write',
689 'capabilities'=> 'moodle/backup:backupcourse,moodle/restore:restorecourse,moodle/course:create',
690 ),
691
791723c3
RT
692 'core_course_update_courses' => array(
693 'classname' => 'core_course_external',
694 'methodname' => 'update_courses',
695 'classpath' => 'course/externallib.php',
696 'description' => 'Update courses',
697 'type' => 'write',
698 'capabilities'=> 'moodle/course:update,moodle/course:changecategory,moodle/course:changefullname,moodle/course:changeshortname,moodle/course:changeidnumber,moodle/course:changesummary,moodle/course:visibility',
699 ),
700
c4f7bf29
JL
701 'core_course_view_course' => array(
702 'classname' => 'core_course_external',
703 'methodname' => 'view_course',
704 'classpath' => 'course/externallib.php',
705 'description' => 'Log that the course was viewed',
706 'type' => 'write'
707 ),
708
709
3ec163dd
EL
710 // === course category related functions ===
711
712 'core_course_get_categories' => array(
713 'classname' => 'core_course_external',
714 'methodname' => 'get_categories',
715 'classpath' => 'course/externallib.php',
716 'description' => 'Return category details',
717 'type' => 'read',
718 'capabilities'=> 'moodle/category:viewhiddencategories',
719 ),
720
479a5db1
FS
721 'core_course_create_categories' => array(
722 'classname' => 'core_course_external',
723 'methodname' => 'create_categories',
724 'classpath' => 'course/externallib.php',
725 'description' => 'Create course categories',
726 'type' => 'write',
727 'capabilities'=> 'moodle/category:manage',
728 ),
d6ebe011 729
3ec163dd
EL
730 'core_course_update_categories' => array(
731 'classname' => 'core_course_external',
732 'methodname' => 'update_categories',
733 'classpath' => 'course/externallib.php',
734 'description' => 'Update categories',
735 'type' => 'write',
afe27edc 736 'capabilities'=> 'moodle/category:manage',
3ec163dd
EL
737 ),
738
2f951d86
FS
739 'core_course_delete_categories' => array(
740 'classname' => 'core_course_external',
741 'methodname' => 'delete_categories',
742 'classpath' => 'course/externallib.php',
743 'description' => 'Delete course categories',
744 'type' => 'write',
745 'capabilities'=> 'moodle/category:manage',
746 ),
479a5db1 747
8430d87b
JL
748 'core_course_import_course' => array(
749 'classname' => 'core_course_external',
750 'methodname' => 'import_course',
751 'classpath' => 'course/externallib.php',
752 'description' => 'Import course data from a course into another course. Does not include any user data.',
753 'type' => 'write',
754 'capabilities'=> 'moodle/backup:backuptargetimport, moodle/restore:restoretargetimport',
755 ),
756
a623b6b8
JM
757 // === message related functions ===
758
4de00da7 759 'moodle_message_send_instantmessages' => array(
3c1aa6fd
DM
760 'classname' => 'moodle_message_external',
761 'methodname' => 'send_instantmessages',
5d1017e1 762 'classpath' => 'message/externallib.php',
3c1aa6fd 763 'description' => 'DEPRECATED: this deprecated function will be removed in a future version. This function has been renamed as core_message_send_instant_messages()',
5d1017e1
JM
764 'type' => 'write',
765 'capabilities'=> 'moodle/site:sendmessage',
766 ),
767
768 'core_message_send_instant_messages' => array(
769 'classname' => 'core_message_external',
770 'methodname' => 'send_instant_messages',
a623b6b8 771 'classpath' => 'message/externallib.php',
4de00da7 772 'description' => 'Send instant messages',
a623b6b8
JM
773 'type' => 'write',
774 'capabilities'=> 'moodle/site:sendmessage',
775 ),
776
d6731600
FM
777 'core_message_create_contacts' => array(
778 'classname' => 'core_message_external',
779 'methodname' => 'create_contacts',
780 'classpath' => 'message/externallib.php',
781 'description' => 'Add contacts to the contact list',
782 'type' => 'write',
783 'capabilities'=> '',
784 ),
785
786 'core_message_delete_contacts' => array(
787 'classname' => 'core_message_external',
788 'methodname' => 'delete_contacts',
789 'classpath' => 'message/externallib.php',
790 'description' => 'Remove contacts from the contact list',
791 'type' => 'write',
792 'capabilities'=> '',
793 ),
794
795 'core_message_block_contacts' => array(
796 'classname' => 'core_message_external',
797 'methodname' => 'block_contacts',
798 'classpath' => 'message/externallib.php',
799 'description' => 'Block contacts',
800 'type' => 'write',
801 'capabilities'=> '',
802 ),
803
804 'core_message_unblock_contacts' => array(
805 'classname' => 'core_message_external',
806 'methodname' => 'unblock_contacts',
807 'classpath' => 'message/externallib.php',
808 'description' => 'Unblock contacts',
809 'type' => 'write',
810 'capabilities'=> '',
811 ),
812
813 'core_message_get_contacts' => array(
814 'classname' => 'core_message_external',
815 'methodname' => 'get_contacts',
816 'classpath' => 'message/externallib.php',
817 'description' => 'Retrieve the contact list',
818 'type' => 'read',
819 'capabilities'=> '',
820 ),
821
822 'core_message_search_contacts' => array(
823 'classname' => 'core_message_external',
824 'methodname' => 'search_contacts',
825 'classpath' => 'message/externallib.php',
826 'description' => 'Search for contacts',
827 'type' => 'read',
828 'capabilities'=> '',
829 ),
830
aff9da17 831 'core_message_get_messages' => array(
6ff4464b
JL
832 'classname' => 'core_message_external',
833 'methodname' => 'get_messages',
834 'classpath' => 'message/externallib.php',
127ef540 835 'description' => 'Retrieve a list of messages sent and received by a user (conversations, notifications or both)',
6ff4464b
JL
836 'type' => 'read',
837 'capabilities' => '',
aff9da17
JL
838 ),
839
60ab2e1b
JL
840 'core_message_get_blocked_users' => array(
841 'classname' => 'core_message_external',
842 'methodname' => 'get_blocked_users',
843 'classpath' => 'message/externallib.php',
844 'description' => 'Retrieve a list of users blocked',
845 'type' => 'read',
846 'capabilities' => '',
847 ),
848
a84f89ca
JL
849 'core_message_mark_message_read' => array(
850 'classname' => 'core_message_external',
851 'methodname' => 'mark_message_read',
852 'classpath' => 'message/externallib.php',
853 'description' => 'Mark a single message as read, trigger message_viewed event.',
854 'type' => 'write',
855 'capabilities' => '',
856 ),
857
8d46dabb
JM
858 // === notes related functions ===
859
860 'moodle_notes_create_notes' => array(
3c1aa6fd 861 'classname' => 'moodle_notes_external',
5d1017e1
JM
862 'methodname' => 'create_notes',
863 'classpath' => 'notes/externallib.php',
3c1aa6fd 864 'description' => 'DEPRECATED: this deprecated function will be removed in a future version. This function has been renamed as core_notes_create_notes()',
5d1017e1
JM
865 'type' => 'write',
866 'capabilities'=> 'moodle/notes:manage',
867 ),
868
869 'core_notes_create_notes' => array(
870 'classname' => 'core_notes_external',
8d46dabb
JM
871 'methodname' => 'create_notes',
872 'classpath' => 'notes/externallib.php',
873 'description' => 'Create notes',
874 'type' => 'write',
875 'capabilities'=> 'moodle/notes:manage',
876 ),
877
34348b2b
JF
878 'core_notes_delete_notes' => array(
879 'classname' => 'core_notes_external',
880 'methodname' => 'delete_notes',
881 'classpath' => 'notes/externallib.php',
882 'description' => 'Delete notes',
883 'type' => 'write',
884 'capabilities'=> 'moodle/notes:manage',
885 ),
886
887 'core_notes_get_notes' => array(
888 'classname' => 'core_notes_external',
889 'methodname' => 'get_notes',
890 'classpath' => 'notes/externallib.php',
891 'description' => 'Get notes',
892 'type' => 'read',
893 'capabilities'=> 'moodle/notes:view',
894 ),
895
896 'core_notes_update_notes' => array(
897 'classname' => 'core_notes_external',
898 'methodname' => 'update_notes',
899 'classpath' => 'notes/externallib.php',
900 'description' => 'Update notes',
901 'type' => 'write',
902 'capabilities'=> 'moodle/notes:manage',
903 ),
904
a80b5518
JL
905 'core_notes_view_notes' => array(
906 'classname' => 'core_notes_external',
907 'methodname' => 'view_notes',
908 'classpath' => 'notes/externallib.php',
909 'description' => 'Simulates the web interface view of notes/index.php: trigger events.',
910 'type' => 'write',
911 'capabilities' => 'moodle/notes:view',
912 ),
913
9028d9b5
PC
914 // === grading related functions ===
915
916 'core_grading_get_definitions' => array(
917 'classname' => 'core_grading_external',
918 'methodname' => 'get_definitions',
9028d9b5
PC
919 'description' => 'Get grading definitions',
920 'type' => 'read'
921 ),
3f0ea6d8
PC
922
923 'core_grade_get_definitions' => array(
924 'classname' => 'core_grade_external',
925 'methodname' => 'get_definitions',
926 'classpath' => 'grade/externallib.php',
9028d9b5
PC
927 'description' => 'DEPRECATED: this deprecated function will be removed in a future version. This function has been renamed as core_grading_get_definitions()',
928 'type' => 'read'
929 ),
930
0ff4ebb4
PC
931 'core_grading_save_definitions' => array(
932 'classname' => 'core_grading_external',
933 'methodname' => 'save_definitions',
934 'description' => 'Save grading definitions',
935 'type' => 'write'
936 ),
937
9028d9b5
PC
938 'core_grading_get_gradingform_instances' => array(
939 'classname' => 'core_grading_external',
940 'methodname' => 'get_gradingform_instances',
9028d9b5 941 'description' => 'Get grading form instances',
3f0ea6d8
PC
942 'type' => 'read'
943 ),
944
0bf486a6
JM
945 // === webservice related functions ===
946
947 'moodle_webservice_get_siteinfo' => array(
3c1aa6fd
DM
948 'classname' => 'moodle_webservice_external',
949 'methodname' => 'get_siteinfo',
5d1017e1 950 'classpath' => 'webservice/externallib.php',
3c1aa6fd 951 'description' => 'DEPRECATED: this deprecated function will be removed in a future version. This function has been renamed as core_webservice_get_site_info()',
5d1017e1
JM
952 'type' => 'read',
953 ),
954
955 'core_webservice_get_site_info' => array(
956 'classname' => 'core_webservice_external',
957 'methodname' => 'get_site_info',
0bf486a6
JM
958 'classpath' => 'webservice/externallib.php',
959 'description' => 'Return some site info / user info / list web service functions',
960 'type' => 'read',
961 ),
962
11e76602
JM
963 'core_get_string' => array(
964 'classname' => 'core_external',
965 'methodname' => 'get_string',
966 'classpath' => 'lib/external/externallib.php',
967 'description' => 'Return a translated string - similar to core get_string() call',
968 'type' => 'read',
969 ),
970
971 'core_get_strings' => array(
972 'classname' => 'core_external',
973 'methodname' => 'get_strings',
974 'classpath' => 'lib/external/externallib.php',
975 'description' => 'Return some translated strings - like several core get_string() calls',
976 'type' => 'read',
977 ),
978
979 'core_get_component_strings' => array(
980 'classname' => 'core_external',
981 'methodname' => 'get_component_strings',
982 'classpath' => 'lib/external/externallib.php',
983 'description' => 'Return all raw strings (with {$a->xxx}) for a specific component
984 - similar to core get_component_strings() call',
985 'type' => 'read',
986 ),
5e1350ab
AA
987
988
989 // === Calendar related functions ===
990
991 'core_calendar_delete_calendar_events' => array(
992 'classname' => 'core_calendar_external',
993 'methodname' => 'delete_calendar_events',
994 'description' => 'Delete calendar events',
995 'classpath' => 'calendar/externallib.php',
996 'type' => 'write',
997 'capabilities'=> 'moodle/calendar:manageentries', 'moodle/calendar:manageownentries', 'moodle/calendar:managegroupentries'
998 ),
999
793d3855
AA
1000
1001 'core_calendar_get_calendar_events' => array(
1002 'classname' => 'core_calendar_external',
1003 'methodname' => 'get_calendar_events',
1004 'description' => 'Get calendar events',
1005 'classpath' => 'calendar/externallib.php',
1006 'type' => 'read',
1007 'capabilities'=> 'moodle/calendar:manageentries', 'moodle/calendar:manageownentries', 'moodle/calendar:managegroupentries'
1008 ),
1009
c66dc3df
AA
1010 'core_calendar_create_calendar_events' => array(
1011 'classname' => 'core_calendar_external',
1012 'methodname' => 'create_calendar_events',
1013 'description' => 'Create calendar events',
1014 'classpath' => 'calendar/externallib.php',
1015 'type' => 'write',
1016 'capabilities'=> 'moodle/calendar:manageentries', 'moodle/calendar:manageownentries', 'moodle/calendar:managegroupentries'
1017 ),
9bdcf579
DW
1018
1019 'core_output_load_template' => array(
1020 'classname' => 'core\output\external',
1021 'methodname' => 'load_template',
1022 'description' => 'Load a template for a renderable',
1023 'type' => 'read'
1024 ),
25c49a85
JL
1025
1026 // Completion related functions.
1027 'core_completion_update_activity_completion_status_manually' => array(
1028 'classname' => 'core_completion_external',
1029 'methodname' => 'update_activity_completion_status_manually',
1030 'description' => 'Update completion status for the current user in an activity, only for activities with manual tracking.',
1031 'type' => 'write',
1032 ),
6c785afa
JL
1033
1034 'core_completion_get_activities_completion_status' => array(
1035 'classname' => 'core_completion_external',
1036 'methodname' => 'get_activities_completion_status',
1037 'description' => 'Return the activities completion status for a user in a course.',
1038 'type' => 'read',
1039 'capabilities' => '',
1040 ),
1041
1042 'core_completion_get_course_completion_status' => array(
1043 'classname' => 'core_completion_external',
1044 'methodname' => 'get_course_completion_status',
1045 'description' => 'Returns course completion status.',
1046 'type' => 'read',
1047 'capabilities' => 'report/completion:view',
1048 ),
89c3afc2 1049
db5b6971
CC
1050 // Rating functions.
1051 'core_rating_get_item_ratings' => array(
46e41e63
JL
1052 'classname' => 'core_rating_external',
1053 'methodname' => 'get_item_ratings',
1054 'description' => 'Retrieve all the ratings for an item.',
1055 'type' => 'read',
1056 'capabilities' => 'moodle/rating:view'
db5b6971 1057 ),
9a0df45a 1058);
c1b65883
JM
1059
1060$services = array(
96e0194c
SH
1061 'Moodle mobile web service' => array(
1062 'functions' => array (
1063 'moodle_enrol_get_users_courses',
1064 'moodle_enrol_get_enrolled_users',
f2806b9a
JM
1065 'moodle_user_get_users_by_id',
1066 'moodle_webservice_get_siteinfo',
1067 'moodle_notes_create_notes',
ea4e96c2 1068 'moodle_user_get_course_participants_by_id',
01479290 1069 'moodle_user_get_users_by_courseid',
ec0d6ea2 1070 'moodle_message_send_instantmessages',
11e76602 1071 'core_course_get_contents',
6a403810 1072 'core_get_component_strings',
925f4d6b 1073 'core_user_add_user_device',
cb9d8257
JL
1074 'core_calendar_get_calendar_events',
1075 'core_enrol_get_users_courses',
1076 'core_enrol_get_enrolled_users',
1077 'core_user_get_users_by_id',
1078 'core_webservice_get_site_info',
1079 'core_notes_create_notes',
1080 'core_user_get_course_user_profiles',
ba1dc597
JL
1081 'core_message_send_instant_messages',
1082 'mod_assign_get_grades',
1083 'mod_assign_get_assignments',
1084 'mod_assign_get_submissions',
1085 'mod_assign_get_user_flags',
1086 'mod_assign_set_user_flags',
1087 'mod_assign_get_user_mappings',
1088 'mod_assign_revert_submissions_to_draft',
1089 'mod_assign_lock_submissions',
1090 'mod_assign_unlock_submissions',
1091 'mod_assign_save_submission',
1092 'mod_assign_submit_for_grading',
1093 'mod_assign_save_grade',
1094 'mod_assign_save_user_extensions',
6acfacfa
JL
1095 'mod_assign_reveal_identities',
1096 'message_airnotifier_is_system_configured',
2e04d250 1097 'message_airnotifier_are_notification_preferences_configured',
e2ede426
JL
1098 'core_grades_update_grades',
1099 'mod_forum_get_forums_by_courses',
2ce8934b 1100 'mod_forum_get_forum_discussions_paginated',
feae0f9f 1101 'mod_forum_get_forum_discussion_posts',
aff9da17 1102 'core_files_get_files',
93872873
JL
1103 'core_message_get_messages',
1104 'core_message_create_contacts',
1105 'core_message_delete_contacts',
1106 'core_message_block_contacts',
1107 'core_message_unblock_contacts',
1108 'core_message_get_contacts',
60ab2e1b 1109 'core_message_search_contacts',
3a2ba746 1110 'core_message_get_blocked_users',
5d62e813 1111 'gradereport_user_get_grades_table',
db23cd08
AN
1112 'core_group_get_course_user_groups',
1113 'core_user_remove_user_device',
25c49a85
JL
1114 'core_course_get_courses',
1115 'core_completion_update_activity_completion_status_manually',
e77a0f36
JL
1116 'mod_data_get_databases_by_courses',
1117 'core_comment_get_comments',
449a6304 1118 'mod_forum_view_forum',
c4f7bf29 1119 'core_course_view_course',
604afeff 1120 'core_completion_get_activities_completion_status',
9857381d 1121 'core_notes_get_course_notes',
6c785afa 1122 'core_completion_get_course_completion_status',
7a334a9b 1123 'core_user_view_user_list',
a84f89ca 1124 'core_message_mark_message_read',
a80b5518 1125 'core_notes_view_notes',
d508dfe7 1126 'mod_forum_view_forum_discussion',
5770f10e 1127 'core_user_view_user_profile',
1bc85767 1128 'gradereport_user_view_grade_report',
db5b6971 1129 'core_rating_get_item_ratings',
60ab2e1b 1130 ),
96e0194c
SH
1131 'enabled' => 0,
1132 'restrictedusers' => 0,
af03513f 1133 'shortname' => MOODLE_OFFICIAL_MOBILE_SERVICE,
106c55fb
DW
1134 'downloadfiles' => 1,
1135 'uploadfiles' => 1
96e0194c
SH
1136 ),
1137);