MDL-66700 gradingform_guide: Support new grading panel
[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(
83e4dc17
JL
37 'core_auth_confirm_user' => array(
38 'classname' => 'core_auth_external',
39 'methodname' => 'confirm_user',
40 'description' => 'Confirm a user account.',
41 'type' => 'write',
42 'ajax' => true,
43 'loginrequired' => false,
44 ),
b6f70a37
JL
45 'core_auth_request_password_reset' => array(
46 'classname' => 'core_auth_external',
47 'methodname' => 'request_password_reset',
48 'description' => 'Requests a password reset.',
49 'type' => 'write',
50 'ajax' => true,
51 'loginrequired' => false,
52 ),
25dbbdf9
MG
53 'core_auth_is_minor' => array(
54 'classname' => 'core_auth_external',
55 'methodname' => 'is_minor',
56 'description' => 'Requests a check if a user is a digital minor.',
57 'type' => 'read',
1f7565c1
JL
58 'ajax' => true,
59 'loginrequired' => false,
60 ),
61 'core_auth_is_age_digital_consent_verification_enabled' => array(
62 'classname' => 'core_auth_external',
63 'methodname' => 'is_age_digital_consent_verification_enabled',
64 'description' => 'Checks if age digital consent verification is enabled.',
65 'type' => 'read',
66 'ajax' => true,
25dbbdf9
MG
67 'loginrequired' => false,
68 ),
6f793705
JL
69 'core_auth_resend_confirmation_email' => array(
70 'classname' => 'core_auth_external',
71 'methodname' => 'resend_confirmation_email',
72 'description' => 'Resend confirmation email.',
73 'type' => 'write',
74 'ajax' => true,
75 'loginrequired' => false,
76 ),
2cd901a4
MP
77 'core_backup_get_async_backup_progress' => array(
78 'classname' => 'core_backup_external',
79 'classpath' => 'backup/externallib.php',
80 'methodname' => 'get_async_backup_progress',
81 'description' => 'Get the progress of an Asyncronhous backup.',
82 'type' => 'read',
83 'ajax' => true,
84 'loginrequired' => true,
85 ),
86 'core_backup_get_async_backup_links_backup' => array(
87 'classname' => 'core_backup_external',
88 'classpath' => 'backup/externallib.php',
89 'methodname' => 'get_async_backup_links_backup',
90 'description' => 'Gets the data to use when updating the status table row in the UI for when an async backup completes.',
91 'type' => 'read',
92 'ajax' => true,
93 'loginrequired' => true,
94 ),
95 'core_backup_get_async_backup_links_restore' => array(
96 'classname' => 'core_backup_external',
97 'classpath' => 'backup/externallib.php',
98 'methodname' => 'get_async_backup_links_restore',
99 'description' => 'Gets the data to use when updating the status table row in the UI for when an async restore completes.',
100 'type' => 'read',
101 'ajax' => true,
102 'loginrequired' => true,
103 ),
f23e9b6b
CB
104 'core_badges_get_user_badges' => array(
105 'classname' => 'core_badges_external',
106 'methodname' => 'get_user_badges',
107 'description' => 'Returns the list of badges awarded to a user.',
108 'type' => 'read',
ee7295ee
JL
109 'capabilities' => 'moodle/badges:viewotherbadges',
110 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
088645e2 111 ),
bb96ff71
JL
112 'core_blog_get_entries' => array(
113 'classname' => 'core_blog\external',
114 'methodname' => 'get_entries',
115 'description' => 'Returns blog entries.',
116 'type' => 'read',
117 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
118 'ajax' => true,
119 'loginrequired' => false,
120 ),
ca48cc91
JL
121 'core_blog_view_entries' => array(
122 'classname' => 'core_blog\external',
123 'methodname' => 'view_entries',
124 'description' => 'Trigger the blog_entries_viewed event.',
125 'type' => 'read',
126 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
127 'ajax' => true,
128 'loginrequired' => false,
129 ),
695c5726
AN
130 'core_calendar_get_calendar_monthly_view' => array(
131 'classname' => 'core_calendar_external',
132 'methodname' => 'get_calendar_monthly_view',
133 'description' => 'Fetch the monthly view data for a calendar',
134 'classpath' => 'calendar/externallib.php',
3ea4f446
AN
135 'type' => 'read',
136 'capabilities' => '',
137 'ajax' => true,
138 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
139 ),
140 'core_calendar_get_calendar_day_view' => array(
141 'classname' => 'core_calendar_external',
142 'methodname' => 'get_calendar_day_view',
143 'description' => 'Fetch the day view data for a calendar',
144 'classpath' => 'calendar/externallib.php',
695c5726
AN
145 'type' => 'read',
146 'capabilities' => '',
147 'ajax' => true,
148 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
149 ),
e8306438
SL
150 'core_calendar_get_calendar_upcoming_view' => array(
151 'classname' => 'core_calendar_external',
152 'methodname' => 'get_calendar_upcoming_view',
153 'description' => 'Fetch the upcoming view data for a calendar',
154 'classpath' => 'calendar/externallib.php',
155 'type' => 'read',
156 'capabilities' => '',
157 'ajax' => true,
158 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
159 ),
c6fb9310
RW
160 'core_calendar_update_event_start_day' => array(
161 'classname' => 'core_calendar_external',
162 'methodname' => 'update_event_start_day',
163 'description' => 'Update the start day (but not time) for an event.',
164 'classpath' => 'calendar/externallib.php',
165 'type' => 'write',
166 'capabilities' => 'moodle/calendar:manageentries, moodle/calendar:manageownentries, moodle/calendar:managegroupentries',
167 'ajax' => true,
ef38c5a5 168 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
c6fb9310 169 ),
f23e9b6b
CB
170 'core_calendar_create_calendar_events' => array(
171 'classname' => 'core_calendar_external',
172 'methodname' => 'create_calendar_events',
173 'description' => 'Create calendar events',
174 'classpath' => 'calendar/externallib.php',
175 'type' => 'write',
e453ed68
JL
176 'capabilities' => 'moodle/calendar:manageentries, moodle/calendar:manageownentries, moodle/calendar:managegroupentries',
177 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
088645e2 178 ),
f23e9b6b
CB
179 'core_calendar_delete_calendar_events' => array(
180 'classname' => 'core_calendar_external',
181 'methodname' => 'delete_calendar_events',
182 'description' => 'Delete calendar events',
183 'classpath' => 'calendar/externallib.php',
184 'type' => 'write',
e453ed68 185 'capabilities' => 'moodle/calendar:manageentries, moodle/calendar:manageownentries, moodle/calendar:managegroupentries',
542f5afa 186 'ajax' => true,
e453ed68 187 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
088645e2 188 ),
f23e9b6b
CB
189 'core_calendar_get_calendar_events' => array(
190 'classname' => 'core_calendar_external',
191 'methodname' => 'get_calendar_events',
192 'description' => 'Get calendar events',
193 'classpath' => 'calendar/externallib.php',
194 'type' => 'read',
ee7295ee
JL
195 'capabilities' => 'moodle/calendar:manageentries, moodle/calendar:manageownentries, moodle/calendar:managegroupentries',
196 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
088645e2 197 ),
c0f877fa
MN
198 'core_calendar_get_action_events_by_timesort' => array(
199 'classname' => 'core_calendar_external',
200 'methodname' => 'get_calendar_action_events_by_timesort',
201 'description' => 'Get calendar action events by tiemsort',
202 'classpath' => 'calendar/externallib.php',
203 'type' => 'read',
204 'capabilities' => 'moodle/calendar:manageentries, moodle/calendar:manageownentries, moodle/calendar:managegroupentries',
60774b28 205 'ajax' => true,
569d091b 206 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
60774b28
RW
207 ),
208 'core_calendar_get_action_events_by_course' => array(
209 'classname' => 'core_calendar_external',
210 'methodname' => 'get_calendar_action_events_by_course',
211 'description' => 'Get calendar action events by course',
212 'classpath' => 'calendar/externallib.php',
213 'type' => 'read',
214 'capabilities' => 'moodle/calendar:manageentries, moodle/calendar:manageownentries, moodle/calendar:managegroupentries',
9b8e5057 215 'ajax' => true,
569d091b 216 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
9b8e5057
RW
217 ),
218 'core_calendar_get_action_events_by_courses' => array(
219 'classname' => 'core_calendar_external',
220 'methodname' => 'get_calendar_action_events_by_courses',
221 'description' => 'Get calendar action events by courses',
222 'classpath' => 'calendar/externallib.php',
223 'type' => 'read',
224 'capabilities' => 'moodle/calendar:manageentries, moodle/calendar:manageownentries, moodle/calendar:managegroupentries',
c0f877fa 225 'ajax' => true,
569d091b 226 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
c0f877fa 227 ),
5813d1b9
SL
228 'core_calendar_get_calendar_event_by_id' => array(
229 'classname' => 'core_calendar_external',
230 'methodname' => 'get_calendar_event_by_id',
231 'description' => 'Get calendar event by id',
232 'classpath' => 'calendar/externallib.php',
233 'type' => 'read',
234 'capabilities' => 'moodle/calendar:manageentries, moodle/calendar:manageownentries, moodle/calendar:managegroupentries',
235 'ajax' => true,
236 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
237 ),
aa091225
RW
238 'core_calendar_submit_create_update_form' => array(
239 'classname' => 'core_calendar_external',
240 'methodname' => 'submit_create_update_form',
241 'description' => 'Submit form data for event form',
242 'classpath' => 'calendar/externallib.php',
243 'type' => 'write',
244 'capabilities' => 'moodle/calendar:manageentries, moodle/calendar:manageownentries, moodle/calendar:managegroupentries',
245 'ajax' => true,
ef38c5a5 246 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
a46980fa
JL
247 ),
248 'core_calendar_get_calendar_access_information' => array(
249 'classname' => 'core_calendar_external',
250 'methodname' => 'get_calendar_access_information',
251 'description' => 'Convenience function to retrieve some permissions/access information for the given course calendar.',
252 'classpath' => 'calendar/externallib.php',
253 'type' => 'read',
254 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
2aad6b82
JL
255 ),
256 'core_calendar_get_allowed_event_types' => array(
257 'classname' => 'core_calendar_external',
258 'methodname' => 'get_allowed_event_types',
259 'description' => 'Get the type of events a user can create in the given course.',
260 'classpath' => 'calendar/externallib.php',
261 'type' => 'read',
262 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
aa091225 263 ),
088645e2 264 'core_cohort_add_cohort_members' => array(
f23e9b6b
CB
265 'classname' => 'core_cohort_external',
266 'methodname' => 'add_cohort_members',
267 'classpath' => 'cohort/externallib.php',
088645e2 268 'description' => 'Adds cohort members.',
f23e9b6b
CB
269 'type' => 'write',
270 'capabilities' => 'moodle/cohort:assign'
271 ),
272 'core_cohort_create_cohorts' => array(
273 'classname' => 'core_cohort_external',
274 'methodname' => 'create_cohorts',
275 'classpath' => 'cohort/externallib.php',
276 'description' => 'Creates new cohorts.',
277 'type' => 'write',
278 'capabilities' => 'moodle/cohort:manage'
088645e2 279 ),
088645e2 280 'core_cohort_delete_cohort_members' => array(
f23e9b6b
CB
281 'classname' => 'core_cohort_external',
282 'methodname' => 'delete_cohort_members',
283 'classpath' => 'cohort/externallib.php',
088645e2 284 'description' => 'Deletes cohort members.',
0a4f3eb2 285 'type' => 'write',
f23e9b6b
CB
286 'capabilities' => 'moodle/cohort:assign'
287 ),
288 'core_cohort_delete_cohorts' => array(
289 'classname' => 'core_cohort_external',
290 'methodname' => 'delete_cohorts',
291 'classpath' => 'cohort/externallib.php',
292 'description' => 'Deletes all specified cohorts.',
0a4f3eb2 293 'type' => 'write',
f23e9b6b 294 'capabilities' => 'moodle/cohort:manage'
088645e2 295 ),
088645e2 296 'core_cohort_get_cohort_members' => array(
f23e9b6b
CB
297 'classname' => 'core_cohort_external',
298 'methodname' => 'get_cohort_members',
299 'classpath' => 'cohort/externallib.php',
088645e2 300 'description' => 'Returns cohort members.',
f23e9b6b
CB
301 'type' => 'read',
302 'capabilities' => 'moodle/cohort:view'
e77a0f36 303 ),
a60e8ba5
DW
304 'core_cohort_search_cohorts' => array(
305 'classname' => 'core_cohort_external',
306 'methodname' => 'search_cohorts',
307 'classpath' => 'cohort/externallib.php',
308 'description' => 'Search for cohorts.',
309 'type' => 'read',
310 'ajax' => true,
311 'capabilities' => 'moodle/cohort:view'
312 ),
f23e9b6b
CB
313 'core_cohort_get_cohorts' => array(
314 'classname' => 'core_cohort_external',
315 'methodname' => 'get_cohorts',
316 'classpath' => 'cohort/externallib.php',
317 'description' => 'Returns cohort details.',
318 'type' => 'read',
319 'capabilities' => 'moodle/cohort:view'
d3549931 320 ),
f23e9b6b
CB
321 'core_cohort_update_cohorts' => array(
322 'classname' => 'core_cohort_external',
323 'methodname' => 'update_cohorts',
324 'classpath' => 'cohort/externallib.php',
325 'description' => 'Updates existing cohorts.',
326 'type' => 'write',
327 'capabilities' => 'moodle/cohort:manage'
d3549931 328 ),
f23e9b6b
CB
329 'core_comment_get_comments' => array(
330 'classname' => 'core_comment_external',
331 'methodname' => 'get_comments',
332 'description' => 'Returns comments.',
333 'type' => 'read',
ee7295ee
JL
334 'capabilities' => 'moodle/comment:view',
335 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
8e4a9ed8
JL
336 ),
337 'core_comment_add_comments' => array(
338 'classname' => 'core_comment_external',
339 'methodname' => 'add_comments',
340 'description' => 'Adds a comment or comments.',
341 'type' => 'write',
342 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
09899abc
JL
343 ),
344 'core_comment_delete_comments' => array(
345 'classname' => 'core_comment_external',
346 'methodname' => 'delete_comments',
347 'description' => 'Deletes a comment or comments.',
348 'type' => 'write',
349 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
5d1017e1 350 ),
f23e9b6b
CB
351 'core_completion_get_activities_completion_status' => array(
352 'classname' => 'core_completion_external',
353 'methodname' => 'get_activities_completion_status',
354 'description' => 'Return the activities completion status for a user in a course.',
355 'type' => 'read',
ee7295ee 356 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
9a0df45a 357 ),
f23e9b6b
CB
358 'core_completion_get_course_completion_status' => array(
359 'classname' => 'core_completion_external',
360 'methodname' => 'get_course_completion_status',
361 'description' => 'Returns course completion status.',
362 'type' => 'read',
ee7295ee
JL
363 'capabilities' => 'report/completion:view',
364 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
5d1017e1 365 ),
f23e9b6b
CB
366 'core_completion_mark_course_self_completed' => array(
367 'classname' => 'core_completion_external',
368 'methodname' => 'mark_course_self_completed',
369 'description' => 'Update the course completion status for the current user (if course self-completion is enabled).',
370 'type' => 'write',
ee7295ee 371 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
9a0df45a 372 ),
f23e9b6b
CB
373 'core_completion_update_activity_completion_status_manually' => array(
374 'classname' => 'core_completion_external',
375 'methodname' => 'update_activity_completion_status_manually',
376 'description' => 'Update completion status for the current user in an activity, only for activities with manual tracking.',
377 'type' => 'write',
ee7295ee 378 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
5d1017e1 379 ),
a39918da
EEAK
380 'core_completion_override_activity_completion_status' => array(
381 'classname' => 'core_completion_external',
382 'methodname' => 'override_activity_completion_status',
383 'description' => 'Update completion status for a user in an activity by overriding it.',
384 'type' => 'write',
385 'capabilities' => 'moodle/course:overridecompletion',
386 'ajax' => true,
387 ),
f23e9b6b
CB
388 'core_course_create_categories' => array(
389 'classname' => 'core_course_external',
390 'methodname' => 'create_categories',
391 'classpath' => 'course/externallib.php',
392 'description' => 'Create course categories',
393 'type' => 'write',
394 'capabilities' => 'moodle/category:manage'
246f6da2 395 ),
f23e9b6b
CB
396 'core_course_create_courses' => array(
397 'classname' => 'core_course_external',
398 'methodname' => 'create_courses',
399 'classpath' => 'course/externallib.php',
400 'description' => 'Create new courses',
401 'type' => 'write',
402 'capabilities' => 'moodle/course:create, moodle/course:visibility'
5d1017e1 403 ),
f23e9b6b
CB
404 'core_course_delete_categories' => array(
405 'classname' => 'core_course_external',
406 'methodname' => 'delete_categories',
407 'classpath' => 'course/externallib.php',
408 'description' => 'Delete course categories',
409 'type' => 'write',
410 'capabilities' => 'moodle/category:manage'
9a0df45a 411 ),
f23e9b6b
CB
412 'core_course_delete_courses' => array(
413 'classname' => 'core_course_external',
414 'methodname' => 'delete_courses',
415 'classpath' => 'course/externallib.php',
416 'description' => 'Deletes all specified courses',
417 'type' => 'write',
418 'capabilities' => 'moodle/course:delete'
5d1017e1 419 ),
f23e9b6b
CB
420 'core_course_delete_modules' => array(
421 'classname' => 'core_course_external',
422 'methodname' => 'delete_modules',
423 'classpath' => 'course/externallib.php',
424 'description' => 'Deletes all specified module instances',
425 'type' => 'write',
426 'capabilities' => 'moodle/course:manageactivities'
9a0df45a 427 ),
f23e9b6b
CB
428 'core_course_duplicate_course' => array(
429 'classname' => 'core_course_external',
430 'methodname' => 'duplicate_course',
431 'classpath' => 'course/externallib.php',
67adb4d8 432 'description' => 'Duplicate an existing course (creating a new one).',
f23e9b6b
CB
433 'type' => 'write',
434 'capabilities' => 'moodle/backup:backupcourse, moodle/restore:restorecourse, moodle/course:create'
5d1017e1 435 ),
f23e9b6b
CB
436 'core_course_get_categories' => array(
437 'classname' => 'core_course_external',
438 'methodname' => 'get_categories',
439 'classpath' => 'course/externallib.php',
440 'description' => 'Return category details',
441 'type' => 'read',
331e038b
JL
442 'capabilities' => 'moodle/category:viewhiddencategories',
443 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
9a0df45a 444 ),
f23e9b6b
CB
445 'core_course_get_contents' => array(
446 'classname' => 'core_course_external',
447 'methodname' => 'get_course_contents',
448 'classpath' => 'course/externallib.php',
449 'description' => 'Get course contents',
450 'type' => 'read',
ee7295ee
JL
451 'capabilities' => 'moodle/course:update, moodle/course:viewhiddencourses',
452 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
9a0df45a 453 ),
f23e9b6b
CB
454 'core_course_get_course_module' => array(
455 'classname' => 'core_course_external',
456 'methodname' => 'get_course_module',
457 'classpath' => 'course/externallib.php',
458 'description' => 'Return information about a course module',
459 'type' => 'read',
ee7295ee 460 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
5d1017e1 461 ),
f23e9b6b
CB
462 'core_course_get_course_module_by_instance' => array(
463 'classname' => 'core_course_external',
464 'methodname' => 'get_course_module_by_instance',
465 'classpath' => 'course/externallib.php',
466 'description' => 'Return information about a given module name and instance id',
467 'type' => 'read',
ee7295ee 468 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
7ce23590 469 ),
4529327a
MG
470 'core_course_get_module' => array(
471 'classname' => 'core_course_external',
472 'methodname' => 'get_module',
473 'classpath' => 'course/externallib.php',
474 'description' => 'Returns html with one activity module on course page',
475 'type' => 'read',
476 'ajax' => true,
477 ),
478 'core_course_edit_module' => array(
479 'classname' => 'core_course_external',
480 'methodname' => 'edit_module',
481 'classpath' => 'course/externallib.php',
482 'description' => 'Performs an action on course module (change visibility, duplicate, delete, etc.)',
483 'type' => 'write',
484 'ajax' => true,
485 ),
486 'core_course_edit_section' => array(
487 'classname' => 'core_course_external',
488 'methodname' => 'edit_section',
489 'classpath' => 'course/externallib.php',
490 'description' => 'Performs an action on course section (change visibility, set marker, delete)',
491 'type' => 'write',
492 'ajax' => true,
493 ),
f23e9b6b
CB
494 'core_course_get_courses' => array(
495 'classname' => 'core_course_external',
496 'methodname' => 'get_courses',
497 'classpath' => 'course/externallib.php',
498 'description' => 'Return course details',
499 'type' => 'read',
500 'capabilities' => 'moodle/course:view, moodle/course:update, moodle/course:viewhiddencourses',
5041600d 501 'ajax' => true,
ee7295ee 502 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
7ce23590 503 ),
f23e9b6b
CB
504 'core_course_import_course' => array(
505 'classname' => 'core_course_external',
506 'methodname' => 'import_course',
507 'classpath' => 'course/externallib.php',
508 'description' => 'Import course data from a course into another course. Does not include any user data.',
509 'type' => 'write',
510 'capabilities' => 'moodle/backup:backuptargetimport, moodle/restore:restoretargetimport'
7ce23590 511 ),
f23e9b6b
CB
512 'core_course_search_courses' => array(
513 'classname' => 'core_course_external',
514 'methodname' => 'search_courses',
515 'classpath' => 'course/externallib.php',
516 'description' => 'Search courses by (name, module, block, tag)',
517 'type' => 'read',
5041600d 518 'ajax' => true,
ee7295ee 519 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
7ce23590 520 ),
f23e9b6b
CB
521 'core_course_update_categories' => array(
522 'classname' => 'core_course_external',
523 'methodname' => 'update_categories',
524 'classpath' => 'course/externallib.php',
525 'description' => 'Update categories',
526 'type' => 'write',
527 'capabilities' => 'moodle/category:manage',
7ce23590 528 ),
f23e9b6b
CB
529 'core_course_update_courses' => array(
530 'classname' => 'core_course_external',
531 'methodname' => 'update_courses',
532 'classpath' => 'course/externallib.php',
533 'description' => 'Update courses',
534 'type' => 'write',
535 'capabilities' => 'moodle/course:update, moodle/course:changecategory, moodle/course:changefullname, '
536 . 'moodle/course:changeshortname, moodle/course:changeidnumber, moodle/course:changesummary, moodle/course:visibility'
7ce23590 537 ),
f23e9b6b
CB
538 'core_course_view_course' => array(
539 'classname' => 'core_course_external',
540 'methodname' => 'view_course',
541 'classpath' => 'course/externallib.php',
542 'description' => 'Log that the course was viewed',
543 'type' => 'write',
ee7295ee 544 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
7ce23590 545 ),
c115ff6a
JL
546 'core_course_get_user_navigation_options' => array(
547 'classname' => 'core_course_external',
548 'methodname' => 'get_user_navigation_options',
549 'classpath' => 'course/externallib.php',
550 'description' => 'Return a list of navigation options in a set of courses that are avaialable or not for the current user.',
551 'type' => 'read',
552 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
553 ),
b9050b10
JL
554 'core_course_get_user_administration_options' => array(
555 'classname' => 'core_course_external',
556 'methodname' => 'get_user_administration_options',
557 'classpath' => 'course/externallib.php',
558 'description' => 'Return a list of administration options in a set of courses that are avaialable or not for the current
559 user.',
560 'type' => 'read',
561 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
562 ),
80adabef
JL
563 'core_course_get_courses_by_field' => array(
564 'classname' => 'core_course_external',
565 'methodname' => 'get_courses_by_field',
566 'classpath' => 'course/externallib.php',
567 'description' => 'Get courses matching a specific field (id/s, shortname, idnumber, category)',
568 'type' => 'read',
569 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
570 ),
26659f62
JL
571 'core_course_check_updates' => array(
572 'classname' => 'core_course_external',
573 'methodname' => 'check_updates',
574 'classpath' => 'course/externallib.php',
575 'description' => 'Check if there is updates affecting the user for the given course and contexts.',
576 'type' => 'read',
577 'ajax' => true,
578 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
579 ),
879a8f56
JL
580 'core_course_get_updates_since' => array(
581 'classname' => 'core_course_external',
582 'methodname' => 'get_updates_since',
583 'classpath' => 'course/externallib.php',
584 'description' => 'Check if there are updates affecting the user for the given course since the given time stamp.',
585 'type' => 'read',
586 'ajax' => true,
587 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
588 ),
2c1d19fd
RW
589 'core_course_get_enrolled_courses_by_timeline_classification' => array(
590 'classname' => 'core_course_external',
591 'methodname' => 'get_enrolled_courses_by_timeline_classification',
592 'classpath' => 'course/externallib.php',
593 'description' => 'List of enrolled courses for the given timeline classification (past, inprogress, or future).',
594 'type' => 'read',
b9508423
JL
595 'ajax' => true,
596 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
2c1d19fd 597 ),
98a52c80
VD
598 'core_course_get_recent_courses' => array(
599 'classname' => 'core_course_external',
600 'methodname' => 'get_recent_courses',
601 'classpath' => 'course/externallib.php',
602 'description' => 'List of courses a user has accessed most recently.',
603 'type' => 'read',
b9508423
JL
604 'ajax' => true,
605 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
606 ),
607 'core_course_set_favourite_courses' => array(
608 'classname' => 'core_course_external',
609 'methodname' => 'set_favourite_courses',
610 'classpath' => 'course/externallib.php',
611 'description' => 'Add a list of courses to the list of favourite courses.',
612 'type' => 'read',
613 'ajax' => true,
614 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
98a52c80 615 ),
06e50afd
MM
616 'core_course_get_enrolled_users_by_cmid' => array(
617 'classname' => 'core_course_external',
618 'methodname' => 'get_enrolled_users_by_cmid',
619 'classpath' => 'course/externallib.php',
620 'description' => 'List users bycourse module id.',
621 'type' => 'read',
622 'ajax' => true,
623 ),
f23e9b6b
CB
624 'core_enrol_get_course_enrolment_methods' => array(
625 'classname' => 'core_enrol_external',
626 'methodname' => 'get_course_enrolment_methods',
627 'classpath' => 'enrol/externallib.php',
628 'description' => 'Get the list of course enrolment methods',
629 'type' => 'read',
ee7295ee 630 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
5d62e813 631 ),
f23e9b6b
CB
632 'core_enrol_get_enrolled_users' => array(
633 'classname' => 'core_enrol_external',
634 'methodname' => 'get_enrolled_users',
635 'classpath' => 'enrol/externallib.php',
636 'description' => 'Get enrolled users by course id.',
637 'type' => 'read',
638 'capabilities' => 'moodle/user:viewdetails, moodle/user:viewhiddendetails, moodle/course:useremail, moodle/user:update, '
ee7295ee
JL
639 . 'moodle/site:accessallgroups',
640 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
7107c2f0 641 ),
f23e9b6b
CB
642 'core_enrol_get_enrolled_users_with_capability' => array(
643 'classname' => 'core_enrol_external',
644 'methodname' => 'get_enrolled_users_with_capability',
645 'classpath' => 'enrol/externallib.php',
646 'description' => 'For each course and capability specified, return a list of the users that are enrolled in the course
647 and have that capability',
648 'type' => 'read',
c0ef63eb 649 ),
a60e8ba5
DW
650 'core_enrol_get_potential_users' => array(
651 'classname' => 'core_enrol_external',
652 'methodname' => 'get_potential_users',
653 'classpath' => 'enrol/externallib.php',
654 'description' => 'Get the list of potential users to enrol',
0fa35b1a 655 'ajax' => true,
a60e8ba5
DW
656 'type' => 'read',
657 'capabilities' => 'moodle/course:enrolreview'
658 ),
0f308fcd
SR
659 'core_enrol_search_users' => [
660 'classname' => 'core_enrol_external',
661 'methodname' => 'search_users',
662 'classpath' => 'enrol/externallib.php',
663 'description' => 'Search within the list of course participants',
664 'ajax' => true,
665 'type' => 'read',
666 'capabilities' => 'moodle/course:viewparticipants',
187b11f4 667 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
0f308fcd 668 ],
f23e9b6b
CB
669 'core_enrol_get_users_courses' => array(
670 'classname' => 'core_enrol_external',
671 'methodname' => 'get_users_courses',
672 'classpath' => 'enrol/externallib.php',
673 'description' => 'Get the list of courses where a user is enrolled in',
674 'type' => 'read',
ee7295ee
JL
675 'capabilities' => 'moodle/course:viewparticipants',
676 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
9857381d 677 ),
58c20c81
JP
678 'core_enrol_edit_user_enrolment' => array(
679 'classname' => 'core_enrol_external',
680 'methodname' => 'edit_user_enrolment',
681 'classpath' => 'enrol/externallib.php',
2d4ce64d
SR
682 'description' => '** DEPRECATED ** Please do not call this function any more.
683 External function that updates a given user enrolment',
684 'type' => 'write',
685 'ajax' => true,
686 ),
687 'core_enrol_submit_user_enrolment_form' => array(
688 'classname' => 'core_enrol_external',
689 'methodname' => 'submit_user_enrolment_form',
690 'classpath' => 'enrol/externallib.php',
691 'description' => 'Submit form data for enrolment form',
58c20c81
JP
692 'type' => 'write',
693 'ajax' => true,
694 ),
c8351261
MG
695 'core_enrol_unenrol_user_enrolment' => array(
696 'classname' => 'core_enrol_external',
697 'methodname' => 'unenrol_user_enrolment',
698 'classpath' => 'enrol/externallib.php',
699 'description' => 'External function that unenrols a given user enrolment',
700 'type' => 'write',
701 'ajax' => true,
702 ),
f23e9b6b
CB
703 'core_fetch_notifications' => array(
704 'classname' => 'core_external',
705 'methodname' => 'fetch_notifications',
706 'classpath' => 'lib/external/externallib.php',
707 'description' => 'Return a list of notifications for the current session',
708 'type' => 'read',
5041600d
RT
709 'loginrequired' => false,
710 'ajax' => true,
5d1017e1 711 ),
7aeeb444
DW
712 'core_session_touch' => array(
713 'classname' => 'core\session\external',
714 'methodname' => 'touch_session',
715 'description' => 'Keep the users session alive',
716 'type' => 'read',
717 'loginrequired' => true,
718 'ajax' => true,
719 ),
720 'core_session_time_remaining' => array(
721 'classname' => 'core\session\external',
722 'methodname' => 'time_remaining',
723 'description' => 'Count the seconds remaining in this session',
724 'type' => 'read',
725 'loginrequired' => true,
726 'ajax' => true,
727 ),
5d1017e1 728 'core_files_get_files' => array(
f23e9b6b
CB
729 'classname' => 'core_files_external',
730 'methodname' => 'get_files',
249c4f60 731 'description' => 'browse moodle files',
f23e9b6b
CB
732 'type' => 'read',
733 'classpath' => 'files/externallib.php',
ee7295ee 734 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
5d1017e1 735 ),
5d1017e1 736 'core_files_upload' => array(
f23e9b6b
CB
737 'classname' => 'core_files_external',
738 'methodname' => 'upload',
249c4f60
DC
739 'description' => 'upload a file to moodle',
740 'type' => 'write',
741 'classpath' => 'files/externallib.php',
742 ),
8b493eb0
DM
743 'core_form_get_filetypes_browser_data' => array(
744 'classname' => 'core_form\external',
745 'methodname' => 'get_filetypes_browser_data',
746 'classpath' => '',
747 'description' => 'Provides data for the filetypes element browser.',
748 'type' => 'read',
749 'loginrequired' => false,
750 'ajax' => true,
751 ),
f23e9b6b
CB
752 'core_get_component_strings' => array(
753 'classname' => 'core_external',
754 'methodname' => 'get_component_strings',
755 'classpath' => 'lib/external/externallib.php',
faeca20d
DM
756 'description' => 'Return all raw strings (with {$a->xxx}), for a specific component ' .
757 '- similar to core get_component_strings(), call',
f23e9b6b 758 'type' => 'read',
5041600d
RT
759 'loginrequired' => false,
760 'ajax' => true,
ee7295ee 761 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
3364dbb5 762 ),
f23e9b6b
CB
763 'core_get_fragment' => array(
764 'classname' => 'core_external',
765 'methodname' => 'get_fragment',
766 'classpath' => 'lib/external/externallib.php',
767 'description' => 'Return a fragment for inclusion, such as a JavaScript page.',
768 'type' => 'read',
5041600d 769 'ajax' => true,
5d1017e1 770 ),
f23e9b6b
CB
771 'core_get_string' => array(
772 'classname' => 'core_external',
773 'methodname' => 'get_string',
774 'classpath' => 'lib/external/externallib.php',
775 'description' => 'Return a translated string - similar to core get_string(), call',
776 'type' => 'read',
5041600d
RT
777 'loginrequired' => false,
778 'ajax' => true,
be9bf94e 779 ),
f23e9b6b
CB
780 'core_get_strings' => array(
781 'classname' => 'core_external',
782 'methodname' => 'get_strings',
783 'classpath' => 'lib/external/externallib.php',
784 'description' => 'Return some translated strings - like several core get_string(), calls',
785 'type' => 'read',
5041600d
RT
786 'loginrequired' => false,
787 'ajax' => true,
5d1017e1 788 ),
88c2941b
RW
789 'core_get_user_dates' => array(
790 'classname' => 'core_external',
791 'methodname' => 'get_user_dates',
792 'classpath' => 'lib/external/externallib.php',
793 'description' => 'Return formatted timestamps',
794 'type' => 'read',
795 'ajax' => true,
796 ),
f23e9b6b
CB
797 'core_grades_get_grades' => array(
798 'classname' => 'core_grades_external',
799 'methodname' => 'get_grades',
aa7e371a
JL
800 'description' => '** DEPRECATED ** Please do not call this function any more.
801 Returns student course total grade and grades for activities.
f23e9b6b
CB
802 This function does not return category or manual items.
803 This function is suitable for managers or teachers not students.',
804 'type' => 'read',
805 'capabilities' => 'moodle/grade:view, moodle/grade:viewall, moodle/grade:viewhidden'
e9b66095 806 ),
f23e9b6b
CB
807 'core_grades_update_grades' => array(
808 'classname' => 'core_grades_external',
809 'methodname' => 'update_grades',
810 'description' => 'Update a grade item and associated student grades.',
811 'type' => 'write',
5d1017e1 812 ),
9adedccd
AN
813 'core_grades_grader_gradingpanel_point_fetch' => [
814 'classname' => 'core_grades\\grades\\grader\\gradingpanel\\point\\external\\fetch',
815 'methodname' => 'execute',
816 'description' => 'Fetch the data required to display the grader grading panel for simple grading, ' .
817 'creating the grade item if required',
818 'type' => 'write',
819 'ajax' => true,
820 'services' => [MOODLE_OFFICIAL_MOBILE_SERVICE],
821 ],
822 'core_grades_grader_gradingpanel_point_store' => [
823 'classname' => 'core_grades\\grades\\grader\\gradingpanel\\point\\external\\store',
824 'methodname' => 'execute',
825 'description' => 'Store the data required to display the grader grading panel for simple grading',
826 'type' => 'write',
827 'ajax' => true,
828 'services' => [MOODLE_OFFICIAL_MOBILE_SERVICE],
829 ],
f23e9b6b
CB
830 'core_grading_get_definitions' => array(
831 'classname' => 'core_grading_external',
832 'methodname' => 'get_definitions',
833 'description' => 'Get grading definitions',
834 'type' => 'read',
e9b66095 835 ),
f23e9b6b
CB
836 'core_grading_get_gradingform_instances' => array(
837 'classname' => 'core_grading_external',
838 'methodname' => 'get_gradingform_instances',
839 'description' => 'Get grading form instances',
840 'type' => 'read',
f2229c68 841 ),
f23e9b6b
CB
842 'core_grading_save_definitions' => array(
843 'classname' => 'core_grading_external',
844 'methodname' => 'save_definitions',
845 'description' => 'Save grading definitions',
846 'type' => 'write',
5d1017e1 847 ),
f23e9b6b
CB
848 'core_group_add_group_members' => array(
849 'classname' => 'core_group_external',
850 'methodname' => 'add_group_members',
851 'classpath' => 'group/externallib.php',
852 'description' => 'Adds group members.',
853 'type' => 'write',
854 'capabilities' => 'moodle/course:managegroups',
6bb31e40 855 ),
f23e9b6b
CB
856 'core_group_assign_grouping' => array(
857 'classname' => 'core_group_external',
858 'methodname' => 'assign_grouping',
859 'classpath' => 'group/externallib.php',
860 'description' => 'Assing groups from groupings',
861 'type' => 'write',
740c354f 862 ),
f23e9b6b
CB
863 'core_group_create_groupings' => array(
864 'classname' => 'core_group_external',
865 'methodname' => 'create_groupings',
866 'classpath' => 'group/externallib.php',
867 'description' => 'Creates new groupings',
868 'type' => 'write',
5d1017e1 869 ),
f23e9b6b
CB
870 'core_group_create_groups' => array(
871 'classname' => 'core_group_external',
872 'methodname' => 'create_groups',
873 'classpath' => 'group/externallib.php',
874 'description' => 'Creates new groups.',
875 'type' => 'write',
876 'capabilities' => 'moodle/course:managegroups'
6bb31e40 877 ),
f23e9b6b
CB
878 'core_group_delete_group_members' => array(
879 'classname' => 'core_group_external',
880 'methodname' => 'delete_group_members',
881 'classpath' => 'group/externallib.php',
882 'description' => 'Deletes group members.',
0a4f3eb2 883 'type' => 'write',
f23e9b6b 884 'capabilities' => 'moodle/course:managegroups'
63a85dc7 885 ),
f23e9b6b
CB
886 'core_group_delete_groupings' => array(
887 'classname' => 'core_group_external',
888 'methodname' => 'delete_groupings',
889 'classpath' => 'group/externallib.php',
890 'description' => 'Deletes all specified groupings.',
79949c1b 891 'type' => 'write',
79949c1b 892 ),
f23e9b6b
CB
893 'core_group_delete_groups' => array(
894 'classname' => 'core_group_external',
895 'methodname' => 'delete_groups',
896 'classpath' => 'group/externallib.php',
897 'description' => 'Deletes all specified groups.',
0a4f3eb2 898 'type' => 'write',
f23e9b6b 899 'capabilities' => 'moodle/course:managegroups'
3dc1d76e 900 ),
f23e9b6b
CB
901 'core_group_get_activity_allowed_groups' => array(
902 'classname' => 'core_group_external',
903 'methodname' => 'get_activity_allowed_groups',
904 'classpath' => 'group/externallib.php',
905 'description' => 'Gets a list of groups that the user is allowed to access within the specified activity.',
906 'type' => 'read',
ee7295ee 907 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
791723c3 908 ),
f23e9b6b
CB
909 'core_group_get_activity_groupmode' => array(
910 'classname' => 'core_group_external',
911 'methodname' => 'get_activity_groupmode',
912 'classpath' => 'group/externallib.php',
913 'description' => 'Returns effective groupmode used in a given activity.',
914 'type' => 'read',
ee7295ee 915 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
c4f7bf29 916 ),
f23e9b6b
CB
917 'core_group_get_course_groupings' => array(
918 'classname' => 'core_group_external',
919 'methodname' => 'get_course_groupings',
920 'classpath' => 'group/externallib.php',
921 'description' => 'Returns all groupings in specified course.',
922 'type' => 'read',
57858670 923 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
c5158499 924 ),
f23e9b6b
CB
925 'core_group_get_course_groups' => array(
926 'classname' => 'core_group_external',
927 'methodname' => 'get_course_groups',
928 'classpath' => 'group/externallib.php',
929 'description' => 'Returns all groups in specified course.',
930 'type' => 'read',
dfc609e5 931 'ajax' => true,
57858670
JL
932 'capabilities' => 'moodle/course:managegroups',
933 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
13bb6819 934 ),
f23e9b6b
CB
935 'core_group_get_course_user_groups' => array(
936 'classname' => 'core_group_external',
937 'methodname' => 'get_course_user_groups',
938 'classpath' => 'group/externallib.php',
939 'description' => 'Returns all groups in specified course for the specified user.',
940 'type' => 'read',
ee7295ee
JL
941 'capabilities' => 'moodle/course:managegroups',
942 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
3ec163dd 943 ),
f23e9b6b
CB
944 'core_group_get_group_members' => array(
945 'classname' => 'core_group_external',
946 'methodname' => 'get_group_members',
947 'classpath' => 'group/externallib.php',
948 'description' => 'Returns group members.',
949 'type' => 'read',
950 'capabilities' => 'moodle/course:managegroups'
479a5db1 951 ),
f23e9b6b
CB
952 'core_group_get_groupings' => array(
953 'classname' => 'core_group_external',
954 'methodname' => 'get_groupings',
955 'classpath' => 'group/externallib.php',
956 'description' => 'Returns groupings details.',
957 'type' => 'read',
3ec163dd 958 ),
f23e9b6b
CB
959 'core_group_get_groups' => array(
960 'classname' => 'core_group_external',
961 'methodname' => 'get_groups',
962 'classpath' => 'group/externallib.php',
963 'description' => 'Returns group details.',
964 'type' => 'read',
965 'capabilities' => 'moodle/course:managegroups'
2f951d86 966 ),
f23e9b6b
CB
967 'core_group_unassign_grouping' => array(
968 'classname' => 'core_group_external',
969 'methodname' => 'unassign_grouping',
970 'classpath' => 'group/externallib.php',
971 'description' => 'Unassing groups from groupings',
972 'type' => 'write',
8430d87b 973 ),
f23e9b6b
CB
974 'core_group_update_groupings' => array(
975 'classname' => 'core_group_external',
976 'methodname' => 'update_groupings',
977 'classpath' => 'group/externallib.php',
978 'description' => 'Updates existing groupings',
979 'type' => 'write',
5d1017e1 980 ),
474dd887
R
981 'core_group_update_groups' => array(
982 'classname' => 'core_group_external',
983 'methodname' => 'update_groups',
984 'classpath' => 'group/externallib.php',
985 'description' => 'Updates existing groups.',
986 'type' => 'write',
987 'capabilities' => 'moodle/course:managegroups'
988 ),
086409f6
MN
989 'core_message_mute_conversations' => array(
990 'classname' => 'core_message_external',
991 'methodname' => 'mute_conversations',
992 'classpath' => 'message/externallib.php',
993 'description' => 'Mutes a list of conversations',
994 'type' => 'write',
995 'ajax' => true,
996 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
997 ),
998 'core_message_unmute_conversations' => array(
999 'classname' => 'core_message_external',
1000 'methodname' => 'unmute_conversations',
1001 'classpath' => 'message/externallib.php',
1002 'description' => 'Unmutes a list of conversations',
1003 'type' => 'write',
1004 'ajax' => true,
1005 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1006 ),
52284186
MN
1007 'core_message_block_user' => array(
1008 'classname' => 'core_message_external',
1009 'methodname' => 'block_user',
1010 'classpath' => 'message/externallib.php',
1011 'description' => 'Blocks a user',
1012 'type' => 'write',
1013 'ajax' => true,
1014 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1015 ),
f23e9b6b
CB
1016 'core_message_block_contacts' => array(
1017 'classname' => 'core_message_external',
1018 'methodname' => 'block_contacts',
1019 'classpath' => 'message/externallib.php',
0b3eadcd
MN
1020 'description' => '** DEPRECATED ** Please do not call this function any more.
1021 Block contacts',
f23e9b6b 1022 'type' => 'write',
c6e97f54 1023 'ajax' => true,
ee7295ee 1024 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
a623b6b8 1025 ),
d6731600 1026 'core_message_create_contacts' => array(
f23e9b6b
CB
1027 'classname' => 'core_message_external',
1028 'methodname' => 'create_contacts',
1029 'classpath' => 'message/externallib.php',
0b3eadcd
MN
1030 'description' => '** DEPRECATED ** Please do not call this function any more.
1031 Add contacts to the contact list',
f23e9b6b 1032 'type' => 'write',
c6e97f54 1033 'ajax' => true,
ee7295ee 1034 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
d6731600 1035 ),
52284186
MN
1036 'core_message_get_contact_requests' => array(
1037 'classname' => 'core_message_external',
1038 'methodname' => 'get_contact_requests',
1039 'classpath' => 'message/externallib.php',
1040 'description' => 'Returns contact requests for a user',
1041 'type' => 'read',
1042 'ajax' => true,
1043 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1044 ),
1045 'core_message_create_contact_request' => array(
1046 'classname' => 'core_message_external',
1047 'methodname' => 'create_contact_request',
1048 'classpath' => 'message/externallib.php',
1049 'description' => 'Creates a contact request',
1050 'type' => 'write',
1051 'ajax' => true,
1052 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1053 ),
1054 'core_message_confirm_contact_request' => array(
1055 'classname' => 'core_message_external',
1056 'methodname' => 'confirm_contact_request',
1057 'classpath' => 'message/externallib.php',
1058 'description' => 'Confirms a contact request',
1059 'type' => 'write',
1060 'ajax' => true,
1061 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1062 ),
1063 'core_message_decline_contact_request' => array(
1064 'classname' => 'core_message_external',
1065 'methodname' => 'decline_contact_request',
1066 'classpath' => 'message/externallib.php',
1067 'description' => 'Declines a contact request',
1068 'type' => 'write',
1069 'ajax' => true,
1070 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1071 ),
7d678923
MN
1072 'core_message_get_received_contact_requests_count' => array(
1073 'classname' => 'core_message_external',
1074 'methodname' => 'get_received_contact_requests_count',
1075 'classpath' => 'message/externallib.php',
1076 'description' => 'Gets the number of received contact requests',
1077 'type' => 'read',
1078 'ajax' => true,
1079 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1080 ),
d6731600 1081 'core_message_delete_contacts' => array(
f23e9b6b
CB
1082 'classname' => 'core_message_external',
1083 'methodname' => 'delete_contacts',
1084 'classpath' => 'message/externallib.php',
d6731600 1085 'description' => 'Remove contacts from the contact list',
f23e9b6b 1086 'type' => 'write',
c6e97f54 1087 'ajax' => true,
ee7295ee 1088 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
d6731600 1089 ),
dec0cd99
MN
1090 'core_message_delete_conversation' => array(
1091 'classname' => 'core_message_external',
1092 'methodname' => 'delete_conversation',
1093 'classpath' => 'message/externallib.php',
fa024820
MN
1094 'description' => '** DEPRECATED ** Please do not call this function any more.
1095 Deletes a conversation.',
dec0cd99
MN
1096 'type' => 'write',
1097 'capabilities' => 'moodle/site:deleteownmessage',
1098 'ajax' => true,
53522c6e 1099 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
dec0cd99 1100 ),
60b67bbc 1101 'core_message_delete_conversations_by_id' => array(
26f39c88 1102 'classname' => 'core_message_external',
60b67bbc 1103 'methodname' => 'delete_conversations_by_id',
26f39c88 1104 'classpath' => 'message/externallib.php',
60b67bbc 1105 'description' => 'Deletes a list of conversations.',
26f39c88
MN
1106 'type' => 'write',
1107 'capabilities' => 'moodle/site:deleteownmessage',
1108 'ajax' => true,
1109 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1110 ),
f23e9b6b
CB
1111 'core_message_delete_message' => array(
1112 'classname' => 'core_message_external',
1113 'methodname' => 'delete_message',
1114 'classpath' => 'message/externallib.php',
1115 'description' => 'Deletes a message.',
1116 'type' => 'write',
ee7295ee 1117 'capabilities' => 'moodle/site:deleteownmessage',
3090f52f 1118 'ajax' => true,
ee7295ee 1119 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
d6731600 1120 ),
f23e9b6b
CB
1121 'core_message_get_blocked_users' => array(
1122 'classname' => 'core_message_external',
1123 'methodname' => 'get_blocked_users',
1124 'classpath' => 'message/externallib.php',
1125 'description' => 'Retrieve a list of users blocked',
1126 'type' => 'read',
ee7295ee 1127 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
d6731600 1128 ),
cd03b8d7
MN
1129 'core_message_data_for_messagearea_search_messages' => array(
1130 'classname' => 'core_message_external',
1131 'methodname' => 'data_for_messagearea_search_messages',
1132 'classpath' => 'message/externallib.php',
1133 'description' => 'Retrieve the template data for searching for messages',
1134 'type' => 'read',
1135 'ajax' => true,
53522c6e 1136 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
cd03b8d7 1137 ),
48e8bdba 1138 'core_message_data_for_messagearea_search_users' => array(
cd03b8d7 1139 'classname' => 'core_message_external',
48e8bdba 1140 'methodname' => 'data_for_messagearea_search_users',
cd03b8d7 1141 'classpath' => 'message/externallib.php',
548cac7d
AA
1142 'description' => '** DEPRECATED ** Please do not call this function any more.
1143 Retrieve the template data for searching for people',
cd03b8d7
MN
1144 'type' => 'read',
1145 'ajax' => true,
1146 ),
48e8bdba 1147 'core_message_data_for_messagearea_search_users_in_course' => array(
cd03b8d7 1148 'classname' => 'core_message_external',
48e8bdba 1149 'methodname' => 'data_for_messagearea_search_users_in_course',
cd03b8d7 1150 'classpath' => 'message/externallib.php',
548cac7d
AA
1151 'description' => '** DEPRECATED ** Please do not call this function any more.
1152 Retrieve the template data for searching for people in a course',
1153 'type' => 'read',
1154 'ajax' => true,
1155 ),
1156 'core_message_message_search_users' => array(
1157 'classname' => 'core_message_external',
1158 'methodname' => 'message_search_users',
1159 'classpath' => 'message/externallib.php',
1160 'description' => 'Retrieve the data for searching for people',
cd03b8d7
MN
1161 'type' => 'read',
1162 'ajax' => true,
548cac7d 1163 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
cd03b8d7 1164 ),
9aa012b5
MN
1165 'core_message_data_for_messagearea_conversations' => array(
1166 'classname' => 'core_message_external',
1167 'methodname' => 'data_for_messagearea_conversations',
1168 'classpath' => 'message/externallib.php',
eb35e0b1
JD
1169 'description' => '** DEPRECATED ** Please do not call this function any more.
1170 Retrieve the template data for the conversation list',
9aa012b5
MN
1171 'type' => 'read',
1172 'ajax' => true,
21d9f020 1173 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
9aa012b5
MN
1174 ),
1175 'core_message_data_for_messagearea_contacts' => array(
1176 'classname' => 'core_message_external',
1177 'methodname' => 'data_for_messagearea_contacts',
1178 'classpath' => 'message/externallib.php',
a6049a79
MN
1179 'description' => '** DEPRECATED ** Please do not call this function any more.
1180 Retrieve the template data for the contact list',
9aa012b5
MN
1181 'type' => 'read',
1182 'ajax' => true,
21d9f020 1183 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
9aa012b5 1184 ),
3cd13828
MN
1185 'core_message_data_for_messagearea_messages' => array(
1186 'classname' => 'core_message_external',
1187 'methodname' => 'data_for_messagearea_messages',
1188 'classpath' => 'message/externallib.php',
a6049a79
MN
1189 'description' => '** DEPRECATED ** Please do not call this function any more.
1190 Retrieve the template data for the messages',
3cd13828
MN
1191 'type' => 'read',
1192 'ajax' => true,
21d9f020 1193 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
3cd13828 1194 ),
c060cd49
MN
1195 'core_message_data_for_messagearea_get_most_recent_message' => array(
1196 'classname' => 'core_message_external',
1197 'methodname' => 'data_for_messagearea_get_most_recent_message',
1198 'classpath' => 'message/externallib.php',
a6049a79
MN
1199 'description' => '** DEPRECATED ** Please do not call this function any more.
1200 Retrieve the template data for the most recent message',
c060cd49
MN
1201 'type' => 'read',
1202 'ajax' => true,
1203 ),
c6e97f54
MN
1204 'core_message_data_for_messagearea_get_profile' => array(
1205 'classname' => 'core_message_external',
1206 'methodname' => 'data_for_messagearea_get_profile',
1207 'classpath' => 'message/externallib.php',
a6049a79
MN
1208 'description' => '** DEPRECATED ** Please do not call this function any more.
1209 Retrieve the template data for the users\'s profile',
c6e97f54
MN
1210 'type' => 'read',
1211 'ajax' => true,
1212 ),
d6731600 1213 'core_message_get_contacts' => array(
f23e9b6b
CB
1214 'classname' => 'core_message_external',
1215 'methodname' => 'get_contacts',
1216 'classpath' => 'message/externallib.php',
f8905537
MN
1217 'description' => '** DEPRECATED ** Please do not call this function any more.
1218 Retrieve the contact list',
f23e9b6b 1219 'type' => 'read',
6f31927a
JD
1220 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1221 ),
c9b0f33f
MN
1222 'core_message_get_user_contacts' => array(
1223 'classname' => 'core_message_external',
1224 'methodname' => 'get_user_contacts',
1225 'classpath' => 'message/externallib.php',
d6731600 1226 'description' => 'Retrieve the contact list',
f23e9b6b 1227 'type' => 'read',
c9b0f33f 1228 'ajax' => true,
6f31927a
JD
1229 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1230 ),
1231 'core_message_get_conversations' => array(
1232 'classname' => 'core_message_external',
1233 'methodname' => 'get_conversations',
1234 'classpath' => 'message/externallib.php',
1235 'description' => 'Retrieve a list of conversations for a user',
1236 'type' => 'read',
ee7295ee 1237 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
b3bbd4a0 1238 'ajax' => true
d6731600 1239 ),
4e313026
RW
1240 'core_message_get_conversation' => array(
1241 'classname' => 'core_message_external',
1242 'methodname' => 'get_conversation',
1243 'classpath' => 'message/externallib.php',
1244 'description' => 'Retrieve a conversation for a user',
1245 'type' => 'read',
569c0bae
RW
1246 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1247 'ajax' => true
1248 ),
1249 'core_message_get_conversation_between_users' => array(
1250 'classname' => 'core_message_external',
1251 'methodname' => 'get_conversation_between_users',
1252 'classpath' => 'message/externallib.php',
1253 'description' => 'Retrieve a conversation for a user between another user',
1254 'type' => 'read',
4e313026
RW
1255 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1256 'ajax' => true
1257 ),
734b198f
SA
1258 'core_message_get_self_conversation' => array(
1259 'classname' => 'core_message_external',
1260 'methodname' => 'get_self_conversation',
1261 'classpath' => 'message/externallib.php',
1262 'description' => 'Retrieve a self-conversation for a user',
1263 'type' => 'read',
1264 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1265 'ajax' => true
1266 ),
aff9da17 1267 'core_message_get_messages' => array(
f23e9b6b
CB
1268 'classname' => 'core_message_external',
1269 'methodname' => 'get_messages',
1270 'classpath' => 'message/externallib.php',
1271 'description' => 'Retrieve a list of messages sent and received by a user (conversations, notifications or both)',
1272 'type' => 'read',
ee7295ee 1273 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
3274d5ca
RW
1274 'ajax' => true,
1275 ),
28ff6ad1
JD
1276 'core_message_get_conversation_counts' => array(
1277 'classname' => 'core_message_external',
1278 'methodname' => 'get_conversation_counts',
1279 'classpath' => 'message/externallib.php',
1280 'description' => 'Retrieve a list of conversation counts, indexed by type.',
1281 'type' => 'read',
1282 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1283 'ajax' => true,
1284 ),
b402a163
JD
1285 'core_message_get_unread_conversation_counts' => array(
1286 'classname' => 'core_message_external',
1287 'methodname' => 'get_unread_conversation_counts',
1288 'classpath' => 'message/externallib.php',
1289 'description' => 'Retrieve a list of unread conversation counts, indexed by type.',
1290 'type' => 'read',
1291 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1292 'ajax' => true,
1293 ),
5584c48a
MN
1294 'core_message_get_conversation_members' => array(
1295 'classname' => 'core_message_external',
1296 'methodname' => 'get_conversation_members',
1297 'classpath' => 'message/externallib.php',
1298 'description' => 'Retrieve a list of members in a conversation',
1299 'type' => 'read',
1300 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1301 'ajax' => true,
1302 ),
8350978a
RW
1303 'core_message_get_member_info' => array(
1304 'classname' => 'core_message_external',
1305 'methodname' => 'get_member_info',
1306 'classpath' => 'message/externallib.php',
1307 'description' => 'Retrieve a user message profiles',
1308 'type' => 'read',
1309 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1310 'ajax' => true,
1311 ),
8c55bd6c
RW
1312 'core_message_get_unread_conversations_count' => array(
1313 'classname' => 'core_message_external',
1314 'methodname' => 'get_unread_conversations_count',
1315 'classpath' => 'message/externallib.php',
1316 'description' => 'Retrieve the count of unread conversations for a given user',
1317 'type' => 'read',
1318 'ajax' => true,
53522c6e 1319 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
8c55bd6c 1320 ),
3274d5ca
RW
1321 'core_message_mark_all_notifications_as_read' => array(
1322 'classname' => 'core_message_external',
1323 'methodname' => 'mark_all_notifications_as_read',
1324 'classpath' => 'message/externallib.php',
8c55bd6c
RW
1325 'description' => 'Mark all notifications as read for a given user',
1326 'type' => 'write',
1327 'ajax' => true,
53522c6e 1328 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
8c55bd6c
RW
1329 ),
1330 'core_message_mark_all_messages_as_read' => array(
1331 'classname' => 'core_message_external',
1332 'methodname' => 'mark_all_messages_as_read',
1333 'classpath' => 'message/externallib.php',
e4c30994
MN
1334 'description' => '** DEPRECATED ** Please do not call this function any more.
1335 Mark all messages as read for a given user',
3274d5ca
RW
1336 'type' => 'write',
1337 'ajax' => true,
53522c6e 1338 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
60ab2e1b 1339 ),
09ec5017
MN
1340 'core_message_mark_all_conversation_messages_as_read' => array(
1341 'classname' => 'core_message_external',
1342 'methodname' => 'mark_all_conversation_messages_as_read',
1343 'classpath' => 'message/externallib.php',
1344 'description' => 'Mark all conversation messages as read for a given user',
3274d5ca
RW
1345 'type' => 'write',
1346 'ajax' => true,
53522c6e 1347 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
60ab2e1b 1348 ),
a84f89ca 1349 'core_message_mark_message_read' => array(
f23e9b6b
CB
1350 'classname' => 'core_message_external',
1351 'methodname' => 'mark_message_read',
1352 'classpath' => 'message/externallib.php',
1353 'description' => 'Mark a single message as read, trigger message_viewed event.',
1354 'type' => 'write',
ee7295ee 1355 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
0b19d048 1356 'ajax' => true,
a84f89ca 1357 ),
2b595d96
MN
1358 'core_message_mark_notification_read' => array(
1359 'classname' => 'core_message_external',
1360 'methodname' => 'mark_notification_read',
1361 'classpath' => 'message/externallib.php',
1362 'description' => 'Mark a single notification as read, trigger notification_viewed event.',
1363 'type' => 'write',
1364 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1365 'ajax' => true,
1366 ),
a0eabdd3
RW
1367 'core_message_message_processor_config_form' => array(
1368 'classname' => 'core_message_external',
1369 'methodname' => 'message_processor_config_form',
1370 'classpath' => 'message/externallib.php',
1371 'description' => 'Process the message processor config form',
1372 'type' => 'write',
1373 'ajax' => true,
53522c6e 1374 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
a0eabdd3 1375 ),
8c125526
RW
1376 'core_message_get_message_processor' => array(
1377 'classname' => 'core_message_external',
1378 'methodname' => 'get_message_processor',
1379 'classpath' => 'message/externallib.php',
1380 'description' => 'Get a message processor',
1381 'type' => 'read',
1382 'ajax' => true,
1383 ),
f23e9b6b
CB
1384 'core_message_search_contacts' => array(
1385 'classname' => 'core_message_external',
1386 'methodname' => 'search_contacts',
1387 'classpath' => 'message/externallib.php',
1388 'description' => 'Search for contacts',
1389 'type' => 'read',
ee7295ee 1390 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
419b1128 1391 ),
f23e9b6b
CB
1392 'core_message_send_instant_messages' => array(
1393 'classname' => 'core_message_external',
1394 'methodname' => 'send_instant_messages',
1395 'classpath' => 'message/externallib.php',
1396 'description' => 'Send instant messages',
1397 'type' => 'write',
ee7295ee 1398 'capabilities' => 'moodle/site:sendmessage',
c060cd49 1399 'ajax' => true,
ee7295ee 1400 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
f23e9b6b 1401 ),
2553e9db
JD
1402 'core_message_send_messages_to_conversation' => array(
1403 'classname' => 'core_message_external',
1404 'methodname' => 'send_messages_to_conversation',
1405 'classpath' => 'message/externallib.php',
1406 'description' => 'Send messages to an existing conversation between users',
1407 'type' => 'write',
1408 'capabilities' => 'moodle/site:sendmessage',
1409 'ajax' => true,
1410 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1411 ),
fb04293b
SA
1412 'core_message_get_conversation_messages' => array(
1413 'classname' => 'core_message_external',
1414 'methodname' => 'get_conversation_messages',
1415 'classpath' => 'message/externallib.php',
1416 'description' => 'Retrieve the conversation messages and relevant member information',
1417 'type' => 'read',
1418 'ajax' => true,
1419 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1420 ),
52284186
MN
1421 'core_message_unblock_user' => array(
1422 'classname' => 'core_message_external',
1423 'methodname' => 'unblock_user',
1424 'classpath' => 'message/externallib.php',
1425 'description' => 'Unblocks a user',
1426 'type' => 'write',
1427 'ajax' => true,
1428 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1429 ),
f23e9b6b
CB
1430 'core_message_unblock_contacts' => array(
1431 'classname' => 'core_message_external',
1432 'methodname' => 'unblock_contacts',
1433 'classpath' => 'message/externallib.php',
0b3eadcd
MN
1434 'description' => '** DEPRECATED ** Please do not call this function any more.
1435 Unblock contacts',
f23e9b6b 1436 'type' => 'write',
c6e97f54 1437 'ajax' => true,
ee7295ee 1438 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
5d1017e1 1439 ),
e86f0cb4
JL
1440 'core_message_get_user_notification_preferences' => array(
1441 'classname' => 'core_message_external',
1442 'methodname' => 'get_user_notification_preferences',
1443 'classpath' => 'message/externallib.php',
1444 'description' => 'Get the notification preferences for a given user.',
1445 'type' => 'read',
1446 'capabilities' => 'moodle/user:editownmessageprofile',
1447 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1448 ),
2521afd2
JL
1449 'core_message_get_user_message_preferences' => array(
1450 'classname' => 'core_message_external',
1451 'methodname' => 'get_user_message_preferences',
1452 'classpath' => 'message/externallib.php',
1453 'description' => 'Get the message preferences for a given user.',
1454 'type' => 'read',
1455 'capabilities' => 'moodle/user:editownmessageprofile',
1456 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
08ae9a73 1457 'ajax' => true
2521afd2 1458 ),
5b367bae
JD
1459 'core_message_set_favourite_conversations' => array(
1460 'classname' => 'core_message_external',
1461 'methodname' => 'set_favourite_conversations',
1462 'classpath' => 'message/externallib.php',
1463 'description' => 'Mark a conversation or group of conversations as favourites/starred conversations.',
1464 'type' => 'write',
9e189a91 1465 'ajax' => true,
5b367bae
JD
1466 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1467 ),
1468 'core_message_unset_favourite_conversations' => array(
1469 'classname' => 'core_message_external',
1470 'methodname' => 'unset_favourite_conversations',
1471 'classpath' => 'message/externallib.php',
1472 'description' => 'Unset a conversation or group of conversations as favourites/starred conversations.',
1473 'type' => 'write',
9e189a91 1474 'ajax' => true,
5b367bae
JD
1475 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1476 ),
e3e19387 1477 'core_message_delete_message_for_all_users' => array(
1478 'classname' => 'core_message_external',
1479 'methodname' => 'delete_message_for_all_users',
1480 'classpath' => 'message/externallib.php',
1481 'description' => 'Deletes a message for all users.',
1482 'type' => 'write',
1483 'capabilities' => 'moodle/site:deleteanymessage',
1484 'ajax' => true,
1485 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1486 ),
5d1017e1 1487 'core_notes_create_notes' => array(
f23e9b6b
CB
1488 'classname' => 'core_notes_external',
1489 'methodname' => 'create_notes',
1490 'classpath' => 'notes/externallib.php',
8d46dabb 1491 'description' => 'Create notes',
f23e9b6b 1492 'type' => 'write',
b5b81de3 1493 'ajax' => true,
ee7295ee
JL
1494 'capabilities' => 'moodle/notes:manage',
1495 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
8d46dabb 1496 ),
34348b2b 1497 'core_notes_delete_notes' => array(
f23e9b6b
CB
1498 'classname' => 'core_notes_external',
1499 'methodname' => 'delete_notes',
1500 'classpath' => 'notes/externallib.php',
34348b2b 1501 'description' => 'Delete notes',
f23e9b6b 1502 'type' => 'write',
ee7295ee
JL
1503 'capabilities' => 'moodle/notes:manage',
1504 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
f23e9b6b
CB
1505 ),
1506 'core_notes_get_course_notes' => array(
1507 'classname' => 'core_notes_external',
1508 'methodname' => 'get_course_notes',
1509 'classpath' => 'notes/externallib.php',
1510 'description' => 'Returns all notes in specified course (or site), for the specified user.',
1511 'type' => 'read',
ee7295ee
JL
1512 'capabilities' => 'moodle/notes:view',
1513 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
34348b2b 1514 ),
34348b2b 1515 'core_notes_get_notes' => array(
f23e9b6b
CB
1516 'classname' => 'core_notes_external',
1517 'methodname' => 'get_notes',
1518 'classpath' => 'notes/externallib.php',
34348b2b 1519 'description' => 'Get notes',
f23e9b6b
CB
1520 'type' => 'read',
1521 'capabilities' => 'moodle/notes:view'
34348b2b 1522 ),
34348b2b 1523 'core_notes_update_notes' => array(
f23e9b6b
CB
1524 'classname' => 'core_notes_external',
1525 'methodname' => 'update_notes',
1526 'classpath' => 'notes/externallib.php',
34348b2b 1527 'description' => 'Update notes',
f23e9b6b
CB
1528 'type' => 'write',
1529 'capabilities' => 'moodle/notes:manage'
34348b2b 1530 ),
a80b5518 1531 'core_notes_view_notes' => array(
f23e9b6b
CB
1532 'classname' => 'core_notes_external',
1533 'methodname' => 'view_notes',
1534 'classpath' => 'notes/externallib.php',
1535 'description' => 'Simulates the web interface view of notes/index.php: trigger events.',
1536 'type' => 'write',
ee7295ee
JL
1537 'capabilities' => 'moodle/notes:view',
1538 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
9028d9b5 1539 ),
f23e9b6b
CB
1540 'core_output_load_template' => array(
1541 'classname' => 'core\output\external',
1542 'methodname' => 'load_template',
1543 'description' => 'Load a template for a renderable',
1544 'type' => 'read',
5041600d
RT
1545 'loginrequired' => false,
1546 'ajax' => true,
0ff4ebb4 1547 ),
e0034b5d
RW
1548 'core_output_load_template_with_dependencies' => array(
1549 'classname' => 'core\output\external',
1550 'methodname' => 'load_template_with_dependencies',
1551 'description' => 'Load a template and its dependencies for a renderable',
1552 'type' => 'read',
1553 'loginrequired' => false,
1554 'ajax' => true,
1555 ),
e330b1c2 1556 'core_output_load_fontawesome_icon_map' => array(
a26ce248 1557 'classname' => 'core\output\external',
e330b1c2 1558 'methodname' => 'load_fontawesome_icon_map',
a26ce248
DW
1559 'description' => 'Load the mapping of names to icons',
1560 'type' => 'read',
1561 'loginrequired' => false,
1562 'ajax' => true,
1563 ),
f23e9b6b
CB
1564 // Question related functions.
1565 'core_question_update_flag' => array(
1566 'classname' => 'core_question_external',
1567 'methodname' => 'update_flag',
1568 'description' => 'Update the flag state of a question attempt.',
1569 'type' => 'write',
1570 'capabilities' => 'moodle/question:flag',
ee7295ee 1571 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
3f0ea6d8 1572 ),
680d5c5b
SL
1573 'core_question_submit_tags_form' => array(
1574 'classname' => 'core_question_external',
1575 'methodname' => 'submit_tags_form',
1576 'description' => 'Update the question tags.',
1577 'type' => 'write',
1578 'ajax' => true,
1579 ),
6768729e
RW
1580 'core_question_get_random_question_summaries' => array(
1581 'classname' => 'core_question_external',
1582 'methodname' => 'get_random_question_summaries',
1583 'description' => 'Get the random question set for a criteria',
1584 'type' => 'read',
1585 'ajax' => true,
1586 ),
f23e9b6b
CB
1587 'core_rating_get_item_ratings' => array(
1588 'classname' => 'core_rating_external',
1589 'methodname' => 'get_item_ratings',
1590 'description' => 'Retrieve all the ratings for an item.',
1591 'type' => 'read',
ee7295ee
JL
1592 'capabilities' => 'moodle/rating:view',
1593 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
5d1017e1 1594 ),
afb7799a
JL
1595 'core_rating_add_rating' => array(
1596 'classname' => 'core_rating_external',
1597 'methodname' => 'add_rating',
1598 'description' => 'Rates an item.',
1599 'type' => 'write',
1600 'capabilities' => 'moodle/rating:rate',
1601 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1602 ),
f23e9b6b
CB
1603 'core_role_assign_roles' => array(
1604 'classname' => 'core_role_external',
1605 'methodname' => 'assign_roles',
1606 'classpath' => 'enrol/externallib.php',
1607 'description' => 'Manual role assignments.',
1608 'type' => 'write',
1609 'capabilities' => 'moodle/role:assign'
0bf486a6 1610 ),
f23e9b6b
CB
1611 'core_role_unassign_roles' => array(
1612 'classname' => 'core_role_external',
1613 'methodname' => 'unassign_roles',
1614 'classpath' => 'enrol/externallib.php',
1615 'description' => 'Manual role unassignments.',
1616 'type' => 'write',
1617 'capabilities' => 'moodle/role:assign'
11e76602 1618 ),
a6cacdd2 1619 'core_search_get_relevant_users' => array(
1620 'classname' => '\core_search\external',
1621 'methodname' => 'get_relevant_users',
1622 'description' => 'Gets relevant users for a search request.',
1623 'type' => 'read',
1624 'ajax' => true
1625 ),
f23e9b6b
CB
1626 'core_tag_get_tagindex' => array(
1627 'classname' => 'core_tag_external',
1628 'methodname' => 'get_tagindex',
1629 'description' => 'Gets tag index page for one tag and one tag area',
1630 'type' => 'read',
5041600d 1631 'ajax' => true,
52fcc0b8 1632 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
11e76602 1633 ),
f23e9b6b
CB
1634 'core_tag_get_tags' => array(
1635 'classname' => 'core_tag_external',
1636 'methodname' => 'get_tags',
1637 'description' => 'Gets tags by their ids',
1638 'type' => 'read',
5041600d 1639 'ajax' => true,
11e76602 1640 ),
f23e9b6b
CB
1641 'core_tag_update_tags' => array(
1642 'classname' => 'core_tag_external',
1643 'methodname' => 'update_tags',
1644 'description' => 'Updates tags',
1645 'type' => 'write',
5041600d 1646 'ajax' => true,
cc73ea07 1647 ),
f1218899
JL
1648 'core_tag_get_tagindex_per_area' => array(
1649 'classname' => 'core_tag_external',
1650 'methodname' => 'get_tagindex_per_area',
1651 'description' => 'Gets tag index page per different areas.',
1652 'type' => 'read',
1653 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1654 ),
07a48837
JL
1655 'core_tag_get_tag_areas' => array(
1656 'classname' => 'core_tag_external',
1657 'methodname' => 'get_tag_areas',
1658 'description' => 'Retrieves existing tag areas.',
1659 'type' => 'read',
1660 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1661 ),
87bdad57
JL
1662 'core_tag_get_tag_collections' => array(
1663 'classname' => 'core_tag_external',
1664 'methodname' => 'get_tag_collections',
1665 'description' => 'Retrieves existing tag collections.',
1666 'type' => 'read',
1667 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1668 ),
86fd9277
JL
1669 'core_tag_get_tag_cloud' => array(
1670 'classname' => 'core_tag_external',
1671 'methodname' => 'get_tag_cloud',
1672 'description' => 'Retrieves a tag cloud for the given collection and/or query search.',
1673 'type' => 'read',
1674 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1675 ),
cdc5f978 1676 'core_update_inplace_editable' => array(
f23e9b6b
CB
1677 'classname' => 'core_external',
1678 'methodname' => 'update_inplace_editable',
1679 'classpath' => 'lib/external/externallib.php',
cdc5f978 1680 'description' => 'Generic service to update title',
f23e9b6b 1681 'type' => 'write',
5041600d
RT
1682 'loginrequired' => true,
1683 'ajax' => true,
c66dc3df 1684 ),
f23e9b6b
CB
1685 'core_user_add_user_device' => array(
1686 'classname' => 'core_user_external',
1687 'methodname' => 'add_user_device',
1688 'classpath' => 'user/externallib.php',
1689 'description' => 'Store mobile user devices information for PUSH Notifications.',
1690 'type' => 'write',
ee7295ee 1691 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
9bdcf579 1692 ),
f23e9b6b
CB
1693 'core_user_add_user_private_files' => array(
1694 'classname' => 'core_user_external',
1695 'methodname' => 'add_user_private_files',
1696 'classpath' => 'user/externallib.php',
1697 'description' => 'Copy files from a draft area to users private files area.',
1698 'type' => 'write',
ee7295ee
JL
1699 'capabilities' => 'moodle/user:manageownfiles',
1700 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
25c49a85 1701 ),
f23e9b6b
CB
1702 'core_user_create_users' => array(
1703 'classname' => 'core_user_external',
1704 'methodname' => 'create_users',
1705 'classpath' => 'user/externallib.php',
1706 'description' => 'Create users.',
1707 'type' => 'write',
1708 'capabilities' => 'moodle/user:create'
23b398fc 1709 ),
f23e9b6b
CB
1710 'core_user_delete_users' => array(
1711 'classname' => 'core_user_external',
1712 'methodname' => 'delete_users',
1713 'classpath' => 'user/externallib.php',
1714 'description' => 'Delete users.',
1715 'type' => 'write',
1716 'capabilities' => 'moodle/user:delete'
6c785afa 1717 ),
f23e9b6b
CB
1718 'core_user_get_course_user_profiles' => array(
1719 'classname' => 'core_user_external',
1720 'methodname' => 'get_course_user_profiles',
1721 'classpath' => 'user/externallib.php',
1722 'description' => 'Get course user profiles (each of the profils matching a course id and a user id),.',
1723 'type' => 'read',
1724 'capabilities' => 'moodle/user:viewdetails, moodle/user:viewhiddendetails, moodle/course:useremail, moodle/user:update, '
ee7295ee
JL
1725 . 'moodle/site:accessallgroups',
1726 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
6c785afa 1727 ),
f23e9b6b
CB
1728 'core_user_get_users' => array(
1729 'classname' => 'core_user_external',
1730 'methodname' => 'get_users',
1731 'classpath' => 'user/externallib.php',
1732 'description' => 'search for users matching the parameters',
1733 'type' => 'read',
1734 'capabilities' => 'moodle/user:viewdetails, moodle/user:viewhiddendetails, moodle/course:useremail, moodle/user:update'
db5b6971 1735 ),
f23e9b6b
CB
1736 'core_user_get_users_by_field' => array(
1737 'classname' => 'core_user_external',
1738 'methodname' => 'get_users_by_field',
1739 'classpath' => 'user/externallib.php',
1740 'description' => 'Retrieve users\' information for a specified unique field - If you want to do a user search, use '
1741 . 'core_user_get_users()',
1742 'type' => 'read',
ee7295ee 1743 'capabilities' => 'moodle/user:viewdetails, moodle/user:viewhiddendetails, moodle/course:useremail, moodle/user:update',
5041600d 1744 'ajax' => true,
ee7295ee 1745 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
8e355853 1746 ),
f23e9b6b
CB
1747 'core_user_remove_user_device' => array(
1748 'classname' => 'core_user_external',
1749 'methodname' => 'remove_user_device',
1750 'classpath' => 'user/externallib.php',
1751 'description' => 'Remove a user device from the Moodle database.',
1752 'type' => 'write',
ee7295ee 1753 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
ef4c23cc 1754 ),
c598f278 1755 'core_user_update_users' => array(
a0eabdd3 1756 'classname' => 'core_user_external',
c598f278 1757 'methodname' => 'update_users',
a0eabdd3 1758 'classpath' => 'user/externallib.php',
c598f278 1759 'description' => 'Update users.',
a0eabdd3
RW
1760 'type' => 'write',
1761 'capabilities' => 'moodle/user:update',
1762 'ajax' => true,
1763 ),
c598f278 1764 'core_user_update_user_preferences' => array(
f23e9b6b 1765 'classname' => 'core_user_external',
c598f278 1766 'methodname' => 'update_user_preferences',
f23e9b6b 1767 'classpath' => 'user/externallib.php',
c598f278 1768 'description' => 'Update a user\'s preferences',
f23e9b6b 1769 'type' => 'write',
c598f278 1770 'capabilities' => 'moodle/user:editownmessageprofile, moodle/user:editmessageprofile',
a0eabdd3 1771 'ajax' => true,
6d2f938c 1772 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
c026a28d 1773 ),
f23e9b6b
CB
1774 'core_user_view_user_list' => array(
1775 'classname' => 'core_user_external',
1776 'methodname' => 'view_user_list',
1777 'classpath' => 'user/externallib.php',
1778 'description' => 'Simulates the web-interface view of user/index.php (triggering events),.',
1779 'type' => 'write',
1780 'capabilities' => 'moodle/course:viewparticipants',
ee7295ee 1781 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
7361b968 1782 ),
f23e9b6b
CB
1783 'core_user_view_user_profile' => array(
1784 'classname' => 'core_user_external',
1785 'methodname' => 'view_user_profile',
1786 'classpath' => 'user/externallib.php',
1787 'description' => 'Simulates the web-interface view of user/view.php and user/profile.php (triggering events),.',
1788 'type' => 'write',
1789 'capabilities' => 'moodle/user:viewdetails',
ee7295ee 1790 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
f4fb827e 1791 ),
45fec983
JL
1792 'core_user_get_user_preferences' => array(
1793 'classname' => 'core_user_external',
1794 'methodname' => 'get_user_preferences',
1795 'classpath' => 'user/externallib.php',
1796 'description' => 'Return user preferences.',
1797 'type' => 'read',
5005d8cf 1798 'ajax' => true,
45fec983
JL
1799 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1800 ),
d44e2e42
JL
1801 'core_user_update_picture' => array(
1802 'classname' => 'core_user_external',
1803 'methodname' => 'update_picture',
1804 'classpath' => 'user/externallib.php',
1805 'description' => 'Update or delete the user picture in the site',
1806 'type' => 'write',
1807 'capabilities' => 'moodle/user:editownprofile, moodle/user:editprofile',
1808 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1809 ),
649777fb
JL
1810 'core_user_set_user_preferences' => array(
1811 'classname' => 'core_user_external',
1812 'methodname' => 'set_user_preferences',
1813 'classpath' => 'user/externallib.php',
1814 'description' => 'Set user preferences.',
1815 'type' => 'write',
1816 'capabilities' => 'moodle/site:config',
2979ca11
JL
1817 'ajax' => true,
1818 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
649777fb 1819 ),
3e8145a3
JL
1820 'core_user_agree_site_policy' => array(
1821 'classname' => 'core_user_external',
1822 'methodname' => 'agree_site_policy',
1823 'classpath' => 'user/externallib.php',
1824 'description' => 'Agree the site policy for the current user.',
1825 'type' => 'write',
1826 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1827 ),
f74ac6e7
JL
1828 'core_user_get_private_files_info' => array(
1829 'classname' => 'core_user_external',
1830 'methodname' => 'get_private_files_info',
1831 'classpath' => 'user/externallib.php',
1832 'description' => 'Returns general information about files in the user private files area.',
1833 'type' => 'read',
1834 'capabilities' => 'moodle/user:manageownfiles',
1835 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1836 ),
649777fb 1837
81de839f
FM
1838 // Competencies functions.
1839 'core_competency_create_competency_framework' => array(
1840 'classname' => 'core_competency\external',
1841 'methodname' => 'create_competency_framework',
1842 'classpath' => '',
1843 'description' => 'Creates new competency frameworks.',
1844 'type' => 'write',
1845 'capabilities' => 'moodle/competency:competencymanage',
1846 'ajax' => true,
1847 ),
1848 'core_competency_read_competency_framework' => array(
1849 'classname' => 'core_competency\external',
1850 'methodname' => 'read_competency_framework',
1851 'classpath' => '',
1852 'description' => 'Load a summary of a competency framework.',
1853 'type' => 'read',
1854 'capabilities' => 'moodle/competency:competencyview',
1855 'ajax' => true,
1856 ),
1857 'core_competency_duplicate_competency_framework' => array(
1858 'classname' => 'core_competency\external',
1859 'methodname' => 'duplicate_competency_framework',
1860 'classpath' => '',
1861 'description' => 'Duplicate a competency framework.',
1862 'type' => 'write',
1863 'capabilities' => 'moodle/competency:competencymanage',
1864 'ajax' => true,
1865 ),
1866 'core_competency_delete_competency_framework' => array(
1867 'classname' => 'core_competency\external',
1868 'methodname' => 'delete_competency_framework',
1869 'classpath' => '',
1870 'description' => 'Delete a competency framework.',
1871 'type' => 'write',
1872 'capabilities' => 'moodle/competency:competencymanage',
1873 'ajax' => true,
1874 ),
1875 'core_competency_update_competency_framework' => array(
1876 'classname' => 'core_competency\external',
1877 'methodname' => 'update_competency_framework',
1878 'classpath' => '',
1879 'description' => 'Update a competency framework.',
1880 'type' => 'write',
1881 'capabilities' => 'moodle/competency:competencymanage',
1882 'ajax' => true,
1883 ),
1884 'core_competency_list_competency_frameworks' => array(
1885 'classname' => 'core_competency\external',
1886 'methodname' => 'list_competency_frameworks',
1887 'classpath' => '',
1888 'description' => 'Load a list of a competency frameworks.',
1889 'type' => 'read',
1890 'capabilities' => 'moodle/competency:competencyview',
1891 'ajax' => true,
1892 ),
1893 'core_competency_count_competency_frameworks' => array(
1894 'classname' => 'core_competency\external',
1895 'methodname' => 'count_competency_frameworks',
1896 'classpath' => '',
1897 'description' => 'Count a list of a competency frameworks.',
1898 'type' => 'read',
1899 'capabilities' => 'moodle/competency:competencyview',
1900 'ajax' => true,
1901 ),
1902 'core_competency_competency_framework_viewed' => array(
1903 'classname' => 'core_competency\external',
1904 'methodname' => 'competency_framework_viewed',
1905 'classpath' => '',
1906 'description' => 'Log event competency framework viewed',
1907 'type' => 'read',
1908 'capabilities' => 'moodle/competency:competencyview',
1909 'ajax' => true,
1910 ),
1911 'core_competency_create_competency' => array(
1912 'classname' => 'core_competency\external',
1913 'methodname' => 'create_competency',
1914 'classpath' => '',
1915 'description' => 'Creates new competencies.',
1916 'type' => 'write',
1917 'capabilities' => 'moodle/competency:competencymanage',
1918 'ajax' => true,
1919 ),
1920 'core_competency_read_competency' => array(
1921 'classname' => 'core_competency\external',
1922 'methodname' => 'read_competency',
1923 'classpath' => '',
1924 'description' => 'Load a summary of a competency.',
1925 'type' => 'read',
1926 'capabilities' => 'moodle/competency:competencyview',
1927 'ajax' => true,
1928 ),
1929 'core_competency_competency_viewed' => array(
1930 'classname' => 'core_competency\external',
1931 'methodname' => 'competency_viewed',
1932 'classpath' => '',
1933 'description' => 'Log event competency viewed',
1934 'type' => 'read',
1935 'capabilities' => 'moodle/competency:competencyview',
1936 'ajax' => true,
3123c2cf 1937 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
81de839f
FM
1938 ),
1939 'core_competency_delete_competency' => array(
1940 'classname' => 'core_competency\external',
1941 'methodname' => 'delete_competency',
1942 'classpath' => '',
1943 'description' => 'Delete a competency.',
1944 'type' => 'write',
1945 'capabilities' => 'moodle/competency:competencymanage',
1946 'ajax' => true,
1947 ),
1948 'core_competency_update_competency' => array(
1949 'classname' => 'core_competency\external',
1950 'methodname' => 'update_competency',
1951 'classpath' => '',
1952 'description' => 'Update a competency.',
1953 'type' => 'write',
1954 'capabilities' => 'moodle/competency:competencymanage',
1955 'ajax' => true,
1956 ),
1957 'core_competency_list_competencies' => array(
1958 'classname' => 'core_competency\external',
1959 'methodname' => 'list_competencies',
1960 'classpath' => '',
1961 'description' => 'Load a list of a competencies.',
1962 'type' => 'read',
1963 'capabilities' => 'moodle/competency:competencyview',
1964 'ajax' => true,
1965 ),
1966 'core_competency_list_competencies_in_template' => array(
1967 'classname' => 'core_competency\external',
1968 'methodname' => 'list_competencies_in_template',
1969 'classpath' => '',
1970 'description' => 'Load a list of a competencies for a given template.',
1971 'type' => 'read',
1972 'capabilities' => 'moodle/competency:competencyview',
1973 'ajax' => true,
1974 ),
1975 'core_competency_count_competencies' => array(
1976 'classname' => 'core_competency\external',
1977 'methodname' => 'count_competencies',
1978 'classpath' => '',
1979 'description' => 'Count a list of a competencies.',
1980 'type' => 'read',
1981 'capabilities' => 'moodle/competency:competencyview',
1982 'ajax' => true,
1983 ),
1984 'core_competency_count_competencies_in_template' => array(
1985 'classname' => 'core_competency\external',
1986 'methodname' => 'count_competencies_in_template',
1987 'classpath' => '',
1988 'description' => 'Count a list of a competencies for a given template.',
1989 'type' => 'read',
1990 'capabilities' => 'moodle/competency:competencyview',
1991 'ajax' => true,
1992 ),
1993 'core_competency_search_competencies' => array(
1994 'classname' => 'core_competency\external',
1995 'methodname' => 'search_competencies',
1996 'classpath' => '',
1997 'description' => 'Search a list of a competencies.',
1998 'type' => 'read',
1999 'capabilities' => 'moodle/competency:competencyview',
2000 'ajax' => true,
2001 ),
2002 'core_competency_set_parent_competency' => array(
2003 'classname' => 'core_competency\external',
2004 'methodname' => 'set_parent_competency',
2005 'classpath' => '',
2006 'description' => 'Set a new parent for a competency.',
2007 'type' => 'write',
2008 'capabilities' => 'moodle/competency:competencymanage',
2009 'ajax' => true,
2010 ),
2011 'core_competency_move_up_competency' => array(
2012 'classname' => 'core_competency\external',
2013 'methodname' => 'move_up_competency',
2014 'classpath' => '',
2015 'description' => 'Re-order a competency.',
2016 'type' => 'write',
2017 'capabilities' => 'moodle/competency:competencymanage',
2018 'ajax' => true,
2019 ),
2020 'core_competency_move_down_competency' => array(
2021 'classname' => 'core_competency\external',
2022 'methodname' => 'move_down_competency',
2023 'classpath' => '',
2024 'description' => 'Re-order a competency.',
2025 'type' => 'write',
2026 'capabilities' => 'moodle/competency:competencymanage',
2027 'ajax' => true,
2028 ),
bde97497
DW
2029 'core_competency_list_course_module_competencies' => array(
2030 'classname' => 'core_competency\external',
2031 'methodname' => 'list_course_module_competencies',
2032 'classpath' => '',
2033 'description' => 'List the competencies in a course module',
2034 'type' => 'read',
2035 'capabilities' => 'moodle/competency:coursecompetencyview',
2036 'ajax' => true,
2037 ),
2038 'core_competency_count_course_module_competencies' => array(
2039 'classname' => 'core_competency\external',
2040 'methodname' => 'count_course_module_competencies',
2041 'classpath' => '',
2042 'description' => 'Count the competencies in a course module',
2043 'type' => 'read',
2044 'capabilities' => 'moodle/competency:coursecompetencyview',
2045 'ajax' => true,
2046 ),
81de839f
FM
2047 'core_competency_list_course_competencies' => array(
2048 'classname' => 'core_competency\external',
2049 'methodname' => 'list_course_competencies',
2050 'classpath' => '',
2051 'description' => 'List the competencies in a course',
2052 'type' => 'read',
2053 'capabilities' => 'moodle/competency:coursecompetencyview',
2054 'ajax' => true,
3123c2cf 2055 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
81de839f
FM
2056 ),
2057 'core_competency_count_competencies_in_course' => array(
2058 'classname' => 'core_competency\external',
2059 'methodname' => 'count_competencies_in_course',
2060 'classpath' => '',
2061 'description' => 'List the competencies in a course',
2062 'type' => 'read',
2063 'capabilities' => 'moodle/competency:coursecompetencyview',
2064 'ajax' => true,
2065 ),
2066 'core_competency_count_courses_using_competency' => array(
2067 'classname' => 'core_competency\external',
2068 'methodname' => 'count_courses_using_competency',
2069 'classpath' => '',
2070 'description' => 'List the courses using a competency',
2071 'type' => 'read',
2072 'capabilities' => 'moodle/competency:coursecompetencyview',
2073 'ajax' => true,
2074 ),
2075 'core_competency_add_competency_to_course' => array(
2076 'classname' => 'core_competency\external',
2077 'methodname' => 'add_competency_to_course',
2078 'classpath' => '',
2079 'description' => 'Add the competency to a course',
2080 'type' => 'write',
2081 'capabilities' => 'moodle/competency:coursecompetencymanage',
2082 'ajax' => true,
2083 ),
2084 'core_competency_add_competency_to_template' => array(
2085 'classname' => 'core_competency\external',
2086 'methodname' => 'add_competency_to_template',
2087 'classpath' => '',
2088 'description' => 'Add the competency to a template',
2089 'type' => 'write',
2090 'capabilities' => 'moodle/competency:templatemanage',
2091 'ajax' => true,
2092 ),
2093 'core_competency_remove_competency_from_course' => array(
2094 'classname' => 'core_competency\external',
2095 'methodname' => 'remove_competency_from_course',
2096 'classpath' => '',
2097 'description' => 'Remove a competency from a course',
2098 'type' => 'write',
2099 'capabilities' => 'moodle/competency:coursecompetencymanage',
2100 'ajax' => true,
2101 ),
2102 'core_competency_set_course_competency_ruleoutcome' => array(
2103 'classname' => 'core_competency\external',
2104 'methodname' => 'set_course_competency_ruleoutcome',
2105 'classpath' => '',
2106 'description' => 'Modify the ruleoutcome value for course competency',
2107 'type' => 'write',
2108 'capabilities' => 'moodle/competency:coursecompetencymanage',
2109 'ajax' => true,
2110 ),
2111 'core_competency_remove_competency_from_template' => array(
2112 'classname' => 'core_competency\external',
2113 'methodname' => 'remove_competency_from_template',
2114 'classpath' => '',
2115 'description' => 'Remove a competency from a template',
2116 'type' => 'write',
2117 'capabilities' => 'moodle/competency:templatemanage',
2118 'ajax' => true,
2119 ),
2120 'core_competency_reorder_course_competency' => array(
2121 'classname' => 'core_competency\external',
2122 'methodname' => 'reorder_course_competency',
2123 'classpath' => '',
2124 'description' => 'Move a course competency to a new relative sort order.',
2125 'type' => 'write',
2126 'capabilities' => 'moodle/competency:coursecompetencymanage',
2127 'ajax' => true,
2128 ),
2129 'core_competency_reorder_template_competency' => array(
2130 'classname' => 'core_competency\external',
2131 'methodname' => 'reorder_template_competency',
2132 'classpath' => '',
2133 'description' => 'Move a template competency to a new relative sort order.',
2134 'type' => 'write',
2135 'capabilities' => 'moodle/competency:templatemanage',
2136 'ajax' => true,
2137 ),
2138 'core_competency_create_template' => array(
2139 'classname' => 'core_competency\external',
2140 'methodname' => 'create_template',
2141 'classpath' => '',
2142 'description' => 'Creates new learning plan templates.',
2143 'type' => 'write',
2144 'capabilities' => 'moodle/competency:templatemanage',
2145 'ajax' => true,
2146 ),
2147 'core_competency_duplicate_template' => array(
2148 'classname' => 'core_competency\external',
2149 'methodname' => 'duplicate_template',
2150 'classpath' => '',
2151 'description' => 'Duplicate learning plan template.',
2152 'type' => 'write',
2153 'capabilities' => 'moodle/competency:templatemanage',
2154 'ajax' => true,
2155 ),
2156 'core_competency_read_template' => array(
2157 'classname' => 'core_competency\external',
2158 'methodname' => 'read_template',
2159 'classpath' => '',
2160 'description' => 'Load a summary of a learning plan template.',
2161 'type' => 'read',
2162 'capabilities' => 'moodle/competency:templateview',
2163 'ajax' => true,
2164 ),
2165 'core_competency_delete_template' => array(
2166 'classname' => 'core_competency\external',
2167 'methodname' => 'delete_template',
2168 'classpath' => '',
2169 'description' => 'Delete a learning plan template.',
2170 'type' => 'write',
2171 'capabilities' => 'moodle/competency:templatemanage',
2172 'ajax' => true,
2173 ),
2174 'core_competency_update_template' => array(
2175 'classname' => 'core_competency\external',
2176 'methodname' => 'update_template',
2177 'classpath' => '',
2178 'description' => 'Update a learning plan template.',
2179 'type' => 'write',
2180 'capabilities' => 'moodle/competency:templatemanage',
2181 'ajax' => true,
2182 ),
2183 'core_competency_list_templates' => array(
2184 'classname' => 'core_competency\external',
2185 'methodname' => 'list_templates',
2186 'classpath' => '',
2187 'description' => 'Load a list of a learning plan templates.',
2188 'type' => 'read',
2189 'capabilities' => 'moodle/competency:templateview',
2190 'ajax' => true,
2191 ),
2192 'core_competency_list_templates_using_competency' => array(
2193 'classname' => 'core_competency\external',
2194 'methodname' => 'list_templates_using_competency',
2195 'classpath' => '',
2196 'description' => 'Load a list of a learning plan templates for a given competency.',
2197 'type' => 'read',
2198 'capabilities' => 'moodle/competency:templateview',
2199 'ajax' => true,
2200 ),
2201 'core_competency_count_templates' => array(
2202 'classname' => 'core_competency\external',
2203 'methodname' => 'count_templates',
2204 'classpath' => '',
2205 'description' => 'Count a list of a learning plan templates.',
2206 'type' => 'read',
2207 'capabilities' => 'moodle/competency:templateview',
2208 'ajax' => true,
2209 ),
2210 'core_competency_count_templates_using_competency' => array(
2211 'classname' => 'core_competency\external',
2212 'methodname' => 'count_templates_using_competency',
2213 'classpath' => '',
2214 'description' => 'Count a list of a learning plan templates for a given competency.',
2215 'type' => 'read',
2216 'capabilities' => 'moodle/competency:templateview',
2217 'ajax' => true,
2218 ),
2219 'core_competency_create_plan' => array(
2220 'classname' => 'core_competency\external',
2221 'methodname' => 'create_plan',
2222 'classpath' => '',
2223 'description' => 'Creates a learning plan.',
2224 'type' => 'write',
2225 'capabilities' => 'moodle/competency:planmanage',
2226 'ajax' => true,
2227 ),
2228 'core_competency_update_plan' => array(
2229 'classname' => 'core_competency\external',
2230 'methodname' => 'update_plan',
2231 'classpath' => '',
2232 'description' => 'Updates a learning plan.',
2233 'type' => 'write',
2234 'capabilities' => 'moodle/competency:planmanage',
2235 'ajax' => true,
2236 ),
2237 'core_competency_complete_plan' => array(
2238 'classname' => 'core_competency\external',
2239 'methodname' => 'complete_plan',
2240 'classpath' => '',
2241 'description' => 'Complete learning plan.',
2242 'type' => 'write',
2243 'capabilities' => 'moodle/competency:planmanage',
2244 'ajax' => true,
2245 ),
2246 'core_competency_reopen_plan' => array(
2247 'classname' => 'core_competency\external',
2248 'methodname' => 'reopen_plan',
2249 'classpath' => '',
2250 'description' => 'Reopen learning plan.',
2251 'type' => 'write',
2252 'capabilities' => 'moodle/competency:planmanage',
2253 'ajax' => true,
2254 ),
2255 'core_competency_read_plan' => array(
2256 'classname' => 'core_competency\external',
2257 'methodname' => 'read_plan',
2258 'classpath' => '',
2259 'description' => 'Load a learning plan.',
2260 'type' => 'read',
2261 'capabilities' => 'moodle/competency:planviewown',
2262 'ajax' => true,
2263 ),
2264 'core_competency_delete_plan' => array(
2265 'classname' => 'core_competency\external',
2266 'methodname' => 'delete_plan',
2267 'classpath' => '',
2268 'description' => 'Delete a learning plan.',
2269 'type' => 'write',
2270 'capabilities' => 'moodle/competency:planmanage',
2271 'ajax' => true,
2272 ),
2273 'core_competency_list_user_plans' => array(
2274 'classname' => 'core_competency\external',
2275 'methodname' => 'list_user_plans',
2276 'classpath' => '',
2277 'description' => 'List a user\'s learning plans.',
2278 'type' => 'read',
2279 'capabilities' => 'moodle/competency:planviewown',
2280 'ajax' => true,
2281 ),
2282 'core_competency_list_plan_competencies' => array(
2283 'classname' => 'core_competency\external',
2284 'methodname' => 'list_plan_competencies',
2285 'classpath' => '',
2286 'description' => 'List the competencies in a plan',
2287 'type' => 'read',
2288 'capabilities' => 'moodle/competency:planviewown',
2289 'ajax' => true,
2290 ),
2291 'core_competency_add_competency_to_plan' => array(
2292 'classname' => 'core_competency\external',
2293 'methodname' => 'add_competency_to_plan',
2294 'classpath' => '',
2295 'description' => 'Add the competency to a learning plan',
2296 'type' => 'write',
2297 'capabilities' => 'moodle/competency:planmanage',
2298 'ajax' => true,
2299 ),
2300 'core_competency_remove_competency_from_plan' => array(
2301 'classname' => 'core_competency\external',
2302 'methodname' => 'remove_competency_from_plan',
2303 'classpath' => '',
2304 'description' => 'Remove the competency from a learning plan',
2305 'type' => 'write',
2306 'capabilities' => 'moodle/competency:planmanage',
2307 'ajax' => true,
2308 ),
2309 'core_competency_reorder_plan_competency' => array(
2310 'classname' => 'core_competency\external',
2311 'methodname' => 'reorder_plan_competency',
2312 'classpath' => '',
2313 'description' => 'Move a plan competency to a new relative sort order.',
2314 'type' => 'write',
2315 'capabilities' => 'moodle/competency:planmanage',
2316 'ajax' => true,
2317 ),
2318 'core_competency_plan_request_review' => array(
2319 'classname' => 'core_competency\external',
2320 'methodname' => 'plan_request_review',
2321 'classpath' => '',
2322 'description' => 'Request for a plan to be reviewed.',
2323 'type' => 'write',
2324 'capabilities' => 'moodle/competency:planmanagedraft',
2325 'ajax' => true,
2326 ),
2327 'core_competency_plan_start_review' => array(
2328 'classname' => 'core_competency\external',
2329 'methodname' => 'plan_start_review',
2330 'classpath' => '',
2331 'description' => 'Start the review of a plan.',
2332 'type' => 'write',
2333 'capabilities' => 'moodle/competency:planmanage',
2334 'ajax' => true,
2335 ),
2336 'core_competency_plan_stop_review' => array(
2337 'classname' => 'core_competency\external',
2338 'methodname' => 'plan_stop_review',
2339 'classpath' => '',
2340 'description' => 'Stop the review of a plan.',
2341 'type' => 'write',
2342 'capabilities' => 'moodle/competency:planmanage',
2343 'ajax' => true,
2344 ),
2345 'core_competency_plan_cancel_review_request' => array(
2346 'classname' => 'core_competency\external',
2347 'methodname' => 'plan_cancel_review_request',
2348 'classpath' => '',
2349 'description' => 'Cancel the review of a plan.',
2350 'type' => 'write',
2351 'capabilities' => 'moodle/competency:planmanagedraft',
2352 'ajax' => true,
2353 ),
2354 'core_competency_approve_plan' => array(
2355 'classname' => 'core_competency\external',
2356 'methodname' => 'approve_plan',
2357 'classpath' => '',
2358 'description' => 'Approve a plan.',
2359 'type' => 'write',
2360 'capabilities' => 'moodle/competency:planmanage',
2361 'ajax' => true,
2362 ),
2363 'core_competency_unapprove_plan' => array(
2364 'classname' => 'core_competency\external',
2365 'methodname' => 'unapprove_plan',
2366 'classpath' => '',
2367 'description' => 'Unapprove a plan.',
2368 'type' => 'write',
2369 'capabilities' => 'moodle/competency:planmanage',
2370 'ajax' => true,
2371 ),
2372 'core_competency_template_has_related_data' => array(
2373 'classname' => 'core_competency\external',
2374 'methodname' => 'template_has_related_data',
2375 'classpath' => '',
2376 'description' => 'Check if a template has related data',
2377 'type' => 'read',
2378 'capabilities' => 'moodle/competency:templateview',
2379 'ajax' => true,
2380 ),
2381 'core_competency_get_scale_values' => array(
2382 'classname' => 'core_competency\external',
2383 'methodname' => 'get_scale_values',
2384 'classpath' => '',
2385 'description' => 'Fetch the values for a specific scale',
2386 'type' => 'read',
2387 'capabilities' => 'moodle/competency:competencymanage',
2388 'ajax' => true,
3123c2cf 2389 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
81de839f
FM
2390 ),
2391 'core_competency_add_related_competency' => array(
2392 'classname' => 'core_competency\external',
2393 'methodname' => 'add_related_competency',
2394 'classpath' => '',
2395 'description' => 'Adds a related competency',
2396 'type' => 'write',
2397 'capabilities' => 'moodle/competency:competencymanage',
2398 'ajax' => true,
2399 ),
2400 'core_competency_remove_related_competency' => array(
2401 'classname' => 'core_competency\external',
2402 'methodname' => 'remove_related_competency',
2403 'classpath' => '',
2404 'description' => 'Remove a related competency',
2405 'type' => 'write',
2406 'capabilities' => 'moodle/competency:competencymanage',
2407 'ajax' => true,
2408 ),
2409 'core_competency_read_user_evidence' => array(
2410 'classname' => 'core_competency\external',
2411 'methodname' => 'read_user_evidence',
2412 'classpath' => '',
2413 'description' => 'Read an evidence of prior learning.',
2414 'type' => 'read',
2415 'capabilities' => 'moodle/competency:userevidenceview',
2416 'ajax' => true,
2417 ),
2418 'core_competency_delete_user_evidence' => array(
2419 'classname' => 'core_competency\external',
2420 'methodname' => 'delete_user_evidence',
2421 'classpath' => '',
2422 'description' => 'Delete an evidence of prior learning.',
2423 'type' => 'write',
2424 'capabilities' => 'moodle/competency:userevidencemanageown',
2425 'ajax' => true,
2426 ),
2427 'core_competency_create_user_evidence_competency' => array(
2428 'classname' => 'core_competency\external',
2429 'methodname' => 'create_user_evidence_competency',
2430 'classpath' => '',
2431 'description' => 'Create an evidence of prior learning relationship with a competency.',
2432 'type' => 'read',
2433 'capabilities' => 'moodle/competency:userevidencemanageown, moodle/competency:competencyview',
2434 'ajax' => true,
2435 ),
2436 'core_competency_delete_user_evidence_competency' => array(
2437 'classname' => 'core_competency\external',
2438 'methodname' => 'delete_user_evidence_competency',
2439 'classpath' => '',
2440 'description' => 'Delete an evidence of prior learning relationship with a competency.',
2441 'type' => 'write',
2442 'capabilities' => 'moodle/competency:userevidencemanageown',
2443 'ajax' => true,
2444 ),
2445 'core_competency_user_competency_cancel_review_request' => array(
2446 'classname' => 'core_competency\external',
2447 'methodname' => 'user_competency_cancel_review_request',
2448 'classpath' => '',
2449 'description' => 'Cancel a review request.',
2450 'type' => 'write',
2451 'capabilities' => 'moodle/competency:userevidencemanageown',
2452 'ajax' => true,
2453 ),
2454 'core_competency_user_competency_request_review' => array(
2455 'classname' => 'core_competency\external',
2456 'methodname' => 'user_competency_request_review',
2457 'classpath' => '',
2458 'description' => 'Request a review.',
2459 'type' => 'write',
2460 'capabilities' => 'moodle/competency:userevidencemanageown',
2461 'ajax' => true,
2462 ),
2463 'core_competency_user_competency_start_review' => array(
2464 'classname' => 'core_competency\external',
2465 'methodname' => 'user_competency_start_review',
2466 'classpath' => '',
2467 'description' => 'Start a review.',
2468 'type' => 'write',
2469 'capabilities' => 'moodle/competency:competencygrade',
2470 'ajax' => true,
2471 ),
2472 'core_competency_user_competency_stop_review' => array(
2473 'classname' => 'core_competency\external',
2474 'methodname' => 'user_competency_stop_review',
2475 'classpath' => '',
2476 'description' => 'Stop a review.',
2477 'type' => 'write',
2478 'capabilities' => 'moodle/competency:competencygrade',
2479 'ajax' => true,
2480 ),
2481 'core_competency_user_competency_viewed' => array(
2482 'classname' => 'core_competency\external',
2483 'methodname' => 'user_competency_viewed',
2484 'classpath' => '',
2485 'description' => 'Log the user competency viewed event.',
2486 'type' => 'read',
2487 'capabilities' => 'moodle/competency:usercompetencyview',
2488 'ajax' => true,
3123c2cf 2489 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
81de839f
FM
2490 ),
2491 'core_competency_user_competency_viewed_in_plan' => array(
2492 'classname' => 'core_competency\external',
2493 'methodname' => 'user_competency_viewed_in_plan',
2494 'classpath' => '',
2495 'description' => 'Log the user competency viewed in plan event.',
2496 'type' => 'read',
2497 'capabilities' => 'moodle/competency:usercompetencyview',
2498 'ajax' => true,
3123c2cf 2499 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
81de839f
FM
2500 ),
2501 'core_competency_user_competency_viewed_in_course' => array(
2502 'classname' => 'core_competency\external',
2503 'methodname' => 'user_competency_viewed_in_course',
2504 'classpath' => '',
2505 'description' => 'Log the user competency viewed in course event',
2506 'type' => 'read',
2507 'capabilities' => 'moodle/competency:usercompetencyview',
2508 'ajax' => true,
3123c2cf 2509 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
81de839f
FM
2510 ),
2511 'core_competency_user_competency_plan_viewed' => array(
2512 'classname' => 'core_competency\external',
2513 'methodname' => 'user_competency_plan_viewed',
2514 'classpath' => '',
2515 'description' => 'Log the user competency plan viewed event.',
2516 'type' => 'read',
2517 'capabilities' => 'moodle/competency:usercompetencyview',
2518 'ajax' => true,
3123c2cf 2519 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
81de839f
FM
2520 ),
2521 'core_competency_grade_competency' => array(
2522 'classname' => 'core_competency\external',
2523 'methodname' => 'grade_competency',
2524 'classpath' => '',
2525 'description' => 'Grade a competency.',
2526 'type' => 'write',
2527 'capabilities' => 'moodle/competency:competencygrade',
2528 'ajax' => true,
2529 ),
2530 'core_competency_grade_competency_in_plan' => array(
2531 'classname' => 'core_competency\external',
2532 'methodname' => 'grade_competency_in_plan',
2533 'classpath' => '',
2534 'description' => 'Grade a competency from the user plan page.',
2535 'type' => 'write',
2536 'capabilities' => 'moodle/competency:competencygrade',
2537 'ajax' => true,
2538 ),
2539 'core_competency_grade_competency_in_course' => array(
2540 'classname' => 'core_competency\external',
2541 'methodname' => 'grade_competency_in_course',
2542 'classpath' => '',
2543 'description' => 'Grade a competency from the course page.',
2544 'type' => 'write',
2545 'capabilities' => 'moodle/competency:competencygrade',
2546 'ajax' => true,
3123c2cf 2547 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
81de839f
FM
2548 ),
2549 'core_competency_unlink_plan_from_template' => array(
2550 'classname' => 'core_competency\external',
2551 'methodname' => 'unlink_plan_from_template',
2552 'classpath' => '',
2553 'description' => 'Unlink a plan form it template.',
2554 'type' => 'write',
2555 'capabilities' => 'moodle/competency:planmanage',
2556 'ajax' => true,
2557 ),
2558 'core_competency_template_viewed' => array(
2559 'classname' => 'core_competency\external',
2560 'methodname' => 'template_viewed',
2561 'classpath' => '',
2562 'description' => 'Log event template viewed',
2563 'type' => 'read',
2564 'capabilities' => 'moodle/competency:templateview',
2565 'ajax' => true,
2566 ),
2567 'core_competency_request_review_of_user_evidence_linked_competencies' => array(
2568 'classname' => 'core_competency\external',
2569 'methodname' => 'request_review_of_user_evidence_linked_competencies',
2570 'classpath' => '',
2571 'description' => 'Send user evidence competencies in review',
2572 'type' => 'write',
2573 'capabilities' => 'moodle/competency:userevidencemanageown',
2574 'ajax' => true,
2575 ),
2576 'core_competency_update_course_competency_settings' => array(
2577 'classname' => 'core_competency\external',
2578 'methodname' => 'update_course_competency_settings',
2579 'classpath' => '',
2580 'description' => 'Update the course competency settings',
2581 'type' => 'write',
2582 'capabilities' => 'moodle/competency:coursecompetencyconfigure',
2583 'ajax' => true,
2584 ),
1e99f31e
FM
2585 'core_competency_delete_evidence' => array(
2586 'classname' => 'core_competency\external',
2587 'methodname' => 'delete_evidence',
2588 'classpath' => '',
2589 'description' => 'Delete an evidence',
2590 'type' => 'write',
2591 'capabilities' => 'moodle/competency:evidencedelete',
2592 'ajax' => true,
3123c2cf 2593 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
1e99f31e 2594 ),
f23e9b6b
CB
2595
2596 'core_webservice_get_site_info' => array(
2597 'classname' => 'core_webservice_external',
2598 'methodname' => 'get_site_info',
2599 'classpath' => 'webservice/externallib.php',
2600 'description' => 'Return some site info / user info / list web service functions',
2601 'type' => 'read',
ee7295ee 2602 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
8446ba36
JL
2603 ),
2604
2605 // Blocks functions.
2606 'core_block_get_course_blocks' => array(
2607 'classname' => 'core_block_external',
2608 'methodname' => 'get_course_blocks',
2609 'description' => 'Returns blocks information for a course.',
2610 'type' => 'read',
2611 'capabilities' => '',
2612 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
2613 ),
66ef16d3 2614
0f8b2604
JL
2615 'core_block_get_dashboard_blocks' => array(
2616 'classname' => 'core_block_external',
2617 'methodname' => 'get_dashboard_blocks',
2618 'description' => 'Returns blocks information for the given user dashboard.',
2619 'type' => 'read',
2620 'capabilities' => '',
2621 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
2622 ),
2623
66ef16d3
JL
2624 // Filters functions.
2625 'core_filters_get_available_in_context' => array(
2626 'classname' => 'core_filters\external',
2627 'methodname' => 'get_available_in_context',
2628 'description' => 'Returns the filters available in the given contexts.',
2629 'type' => 'read',
2630 'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
3cfff885 2631 ),
1eeb465a
TBM
2632 'core_customfield_delete_field' => array(
2633 'classname' => 'core_customfield_external',
2634 'methodname' => 'delete_field',
2635 'classpath' => 'customfield/externallib.php',
2636 'description' => 'Deletes an entry',
2637 'type' => 'write',
2638 'ajax' => 'true'
2639 ),
2640 'core_customfield_reload_template' => array(
2641 'classname' => 'core_customfield_external',
2642 'methodname' => 'reload_template',
2643 'classpath' => 'customfield/externallib.php',
2644 'description' => 'Reloads template',
2645 'type' => 'read',
2646 'ajax' => 'true'
2647 ),
2648 'core_customfield_create_category' => array(
2649 'classname' => 'core_customfield_external',
2650 'methodname' => 'create_category',
2651 'classpath' => 'customfield/externallib.php',
2652 'description' => 'Creates a new category',
2653 'type' => 'write',
2654 'ajax' => 'true'
2655 ),
2656 'core_customfield_delete_category' => array(
2657 'classname' => 'core_customfield_external',
2658 'methodname' => 'delete_category',
2659 'classpath' => 'customfield/externallib.php',
2660 'description' => 'Deletes a category',
2661 'type' => 'write',
2662 'ajax' => 'true'
2663 ),
2664 'core_customfield_move_field' => array(
2665 'classname' => 'core_customfield_external',
2666 'methodname' => 'move_field',
2667 'classpath' => 'customfield/externallib.php',
2668 'description' => 'Drag and drop',
2669 'type' => 'write',
2670 'ajax' => 'true'
2671 ),
2672 'core_customfield_move_category' => array(
2673 'classname' => 'core_customfield_external',
2674 'methodname' => 'move_category',
2675 'classpath' => 'customfield/externallib.php',
2676 'description' => 'Drag and drop categories',
2677 'type' => 'write',
2678 'ajax' => 'true'
2679 )
9a0df45a 2680);
c1b65883
JM
2681
2682$services = array(
96e0194c 2683 'Moodle mobile web service' => array(
12c52b91 2684 'functions' => array(), // Unused as we add the service in each function definition, third party services would use this.
96e0194c
SH
2685 'enabled' => 0,
2686 'restrictedusers' => 0,
af03513f 2687 'shortname' => MOODLE_OFFICIAL_MOBILE_SERVICE,
106c55fb
DW
2688 'downloadfiles' => 1,
2689 'uploadfiles' => 1
96e0194c
SH
2690 ),
2691);