moodle_rb 2.1.0 → 2.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +13 -1
- data/lib/moodle_rb/courses.rb +25 -5
- data/lib/moodle_rb/version.rb +1 -1
- data/spec/lib/moodle_rb/courses_spec.rb +61 -4
- metadata +10 -120
- data/.github/workflows/build.yml +0 -36
- data/.github/workflows/publish.yml +0 -27
- data/.gitignore +0 -35
- data/.travis.yml +0 -9
- data/Dockerfile +0 -10
- data/Gemfile +0 -2
- data/docker-compose.yml +0 -6
- data/moodle_rb.gemspec +0 -26
- data/spec/cassettes/MoodleRb_Categories/_create/.yml +0 -39
- data/spec/cassettes/MoodleRb_Categories/_create/when_validation_fails/.yml +0 -39
- data/spec/cassettes/MoodleRb_Categories/_destroy/when_using_invalid_token/.yml +0 -39
- data/spec/cassettes/MoodleRb_Categories/_destroy/when_using_valid_token/.yml +0 -76
- data/spec/cassettes/MoodleRb_Categories/_index/.yml +0 -39
- data/spec/cassettes/MoodleRb_Categories/_index/when_using_invalid_token/.yml +0 -39
- data/spec/cassettes/MoodleRb_Categories/_show/.yml +0 -39
- data/spec/cassettes/MoodleRb_Categories/_show/when_using_invalid_token/.yml +0 -39
- data/spec/cassettes/MoodleRb_Client/_site_info/when_invalid_token/.yml +0 -39
- data/spec/cassettes/MoodleRb_Client/_site_info/when_valid_token/.yml +0 -39
- data/spec/cassettes/MoodleRb_Courses/_contents/when_using_invalid_token/.yml +0 -52
- data/spec/cassettes/MoodleRb_Courses/_contents/when_using_valid_token/.yml +0 -52
- data/spec/cassettes/MoodleRb_Courses/_create/.yml +0 -39
- data/spec/cassettes/MoodleRb_Courses/_create/when_validation_fails/.yml +0 -75
- data/spec/cassettes/MoodleRb_Courses/_destroy/when_using_invalid_token/.yml +0 -39
- data/spec/cassettes/MoodleRb_Courses/_destroy/when_using_valid_token/.yml +0 -75
- data/spec/cassettes/MoodleRb_Courses/_destroy/when_using_valid_token/when_using_invalid_course_id/.yml +0 -39
- data/spec/cassettes/MoodleRb_Courses/_enrolled_users/when_using_invalid_token/.yml +0 -39
- data/spec/cassettes/MoodleRb_Courses/_enrolled_users/when_using_valid_token/.yml +0 -75
- data/spec/cassettes/MoodleRb_Courses/_grade_items/when_using_invalid_token/.yml +0 -52
- data/spec/cassettes/MoodleRb_Courses/_grade_items/when_using_valid_token/.yml +0 -56
- data/spec/cassettes/MoodleRb_Courses/_index/.yml +0 -39
- data/spec/cassettes/MoodleRb_Courses/_index/when_using_invalid_token/.yml +0 -39
- data/spec/cassettes/MoodleRb_Courses/_module/when_using_invalid_token/.yml +0 -52
- data/spec/cassettes/MoodleRb_Courses/_module/when_using_valid_token/.yml +0 -51
- data/spec/cassettes/MoodleRb_Courses/_search/.yml +0 -102
- data/spec/cassettes/MoodleRb_Courses/_search/when_using_invalid_token/.yml +0 -55
- data/spec/cassettes/MoodleRb_Courses/_show/.yml +0 -39
- data/spec/cassettes/MoodleRb_Courses/_show/when_using_invalid_token/.yml +0 -39
- data/spec/cassettes/MoodleRb_Enrolments/_create/.yml +0 -39
- data/spec/cassettes/MoodleRb_Enrolments/_create/when_user_or_course_id_is_invalid/.yml +0 -39
- data/spec/cassettes/MoodleRb_Enrolments/_destroy/.yml +0 -51
- data/spec/cassettes/MoodleRb_Enrolments/_destroy/when_user_or_course_id_is_invalid/.yml +0 -52
- data/spec/cassettes/MoodleRb_Grades/_by_assignment/.yml +0 -39
- data/spec/cassettes/MoodleRb_Grades/_by_course/.yml +0 -39
- data/spec/cassettes/MoodleRb_Grades/_by_course/when_invalid_parameters/.yml +0 -39
- data/spec/cassettes/MoodleRb_Users/_create/.yml +0 -39
- data/spec/cassettes/MoodleRb_Users/_create/when_missing_required_parameters/.yml +0 -39
- data/spec/cassettes/MoodleRb_Users/_destroy/.yml +0 -39
- data/spec/cassettes/MoodleRb_Users/_destroy/when_id_does_not_exist/.yml +0 -39
- data/spec/cassettes/MoodleRb_Users/_destroy/when_using_invalid_token/.yml +0 -39
- data/spec/cassettes/MoodleRb_Users/_enrolled_courses/.yml +0 -39
- data/spec/cassettes/MoodleRb_Users/_enrolled_courses/when_using_invalid_token/.yml +0 -39
- data/spec/cassettes/MoodleRb_Users/_search/.yml +0 -39
- data/spec/cassettes/MoodleRb_Users/_search/when_using_invalid_token/.yml +0 -39
- data/spec/cassettes/MoodleRb_Users/_search_identity/.yml +0 -51
- data/spec/cassettes/MoodleRb_Users/_search_identity/when_using_invalid_token/.yml +0 -52
- data/spec/cassettes/MoodleRb_Users/_show/.yml +0 -39
- data/spec/cassettes/MoodleRb_Users/_show/when_using_invalid_token/.yml +0 -39
- data/spec/cassettes/MoodleRb_Users/_update/.yml +0 -39
- data/spec/cassettes/MoodleRb_Users/_update/when_using_invalid_token/.yml +0 -39
@@ -1,55 +0,0 @@
|
|
1
|
-
---
|
2
|
-
http_interactions:
|
3
|
-
- request:
|
4
|
-
method: get
|
5
|
-
uri: http://localhost:8888/moodle28/webservice/rest/server.php?criterianame=search&criteriavalue=My%20course&moodlewsrestformat=json&wsfunction=core_course_search_courses&wstoken=
|
6
|
-
body:
|
7
|
-
encoding: US-ASCII
|
8
|
-
string: ''
|
9
|
-
headers:
|
10
|
-
Accept-Encoding:
|
11
|
-
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
12
|
-
Accept:
|
13
|
-
- "*/*"
|
14
|
-
User-Agent:
|
15
|
-
- Ruby
|
16
|
-
response:
|
17
|
-
status:
|
18
|
-
code: 200
|
19
|
-
message: OK
|
20
|
-
headers:
|
21
|
-
Accept-Ranges:
|
22
|
-
- bytes
|
23
|
-
Access-Control-Allow-Origin:
|
24
|
-
- "*"
|
25
|
-
Age:
|
26
|
-
- '0'
|
27
|
-
Cache-Control:
|
28
|
-
- private, must-revalidate, pre-check=0, post-check=0, max-age=0
|
29
|
-
Content-Type:
|
30
|
-
- application/json
|
31
|
-
Date:
|
32
|
-
- Wed, 11 May 2022 03:43:20 GMT
|
33
|
-
Expires:
|
34
|
-
- Thu, 01 Jan 1970 00:00:00 GMT
|
35
|
-
Pragma:
|
36
|
-
- no-cache
|
37
|
-
Server:
|
38
|
-
- Moodle
|
39
|
-
X-Cache:
|
40
|
-
- MISS
|
41
|
-
X-Clacks-Overhead:
|
42
|
-
- GNU Terry Pratchett
|
43
|
-
X-Powered-By:
|
44
|
-
- Moodle Ninjas
|
45
|
-
Content-Length:
|
46
|
-
- '103'
|
47
|
-
Connection:
|
48
|
-
- keep-alive
|
49
|
-
body:
|
50
|
-
encoding: UTF-8
|
51
|
-
string: '{"exception":"moodle_exception","errorcode":"invalidtoken","message":"Invalid
|
52
|
-
token - token not found"}'
|
53
|
-
http_version:
|
54
|
-
recorded_at: Wed, 11 May 2022 03:42:46 GMT
|
55
|
-
recorded_with: VCR 2.9.3
|
@@ -1,39 +0,0 @@
|
|
1
|
-
---
|
2
|
-
http_interactions:
|
3
|
-
- request:
|
4
|
-
method: post
|
5
|
-
uri: http://localhost:8888/moodle28/webservice/rest/server.php?moodlewsrestformat=json&wsfunction=core_course_get_courses&wstoken=60fc9c9415259404795094957e4ab32f
|
6
|
-
body:
|
7
|
-
string: options[ids][0]=1
|
8
|
-
headers: {}
|
9
|
-
|
10
|
-
response:
|
11
|
-
status:
|
12
|
-
code: 200
|
13
|
-
message: OK
|
14
|
-
headers:
|
15
|
-
Access-Control-Allow-Origin:
|
16
|
-
- "*"
|
17
|
-
X-Powered-By:
|
18
|
-
- PHP/5.6.2
|
19
|
-
Expires:
|
20
|
-
- Thu, 01 Jan 1970 00:00:00 GMT
|
21
|
-
Server:
|
22
|
-
- Apache/2.2.29 (Unix) mod_fastcgi/2.4.6 mod_wsgi/3.4 Python/2.7.8 PHP/5.6.2 mod_ssl/2.2.29 OpenSSL/0.9.8zd DAV/2 mod_perl/2.0.8 Perl/v5.20.0
|
23
|
-
Pragma:
|
24
|
-
- no-cache
|
25
|
-
Accept-Ranges:
|
26
|
-
- none
|
27
|
-
Content-Type:
|
28
|
-
- application/json
|
29
|
-
Date:
|
30
|
-
- Sun, 12 Apr 2015 00:51:46 GMT
|
31
|
-
Content-Length:
|
32
|
-
- "707"
|
33
|
-
Cache-Control:
|
34
|
-
- private, must-revalidate, pre-check=0, post-check=0, max-age=0
|
35
|
-
body:
|
36
|
-
string: "[{\"id\":1,\"shortname\":\"Moodle 2.8\",\"categoryid\":0,\"categorysortorder\":1,\"fullname\":\"Moodle 2.8\",\"idnumber\":\"\",\"summary\":\"<h2 style=\\\"font-size: large;\\\">Moodle<span style=\\\"font-size: 1.8em; color: red;\\\">4<\\/span>Mac<\\/h2>\\r\\n<p>This package for OS X comes with Moodle 2.8.5+ and MAMP 3.0.7.3. We hope you will like it!<\\/p>\",\"summaryformat\":1,\"format\":\"site\",\"showgrades\":1,\"newsitems\":3,\"startdate\":0,\"numsections\":1,\"maxbytes\":0,\"showreports\":0,\"visible\":1,\"groupmode\":0,\"groupmodeforce\":0,\"defaultgroupingid\":0,\"timecreated\":1405375287,\"timemodified\":1426316351,\"enablecompletion\":0,\"completionnotify\":0,\"lang\":\"\",\"forcetheme\":\"\",\"courseformatoptions\":[{\"name\":\"numsections\",\"value\":1}]}]"
|
37
|
-
http_version:
|
38
|
-
recorded_at: Sun, 12 Apr 2015 00:51:46 GMT
|
39
|
-
recorded_with: VCR 2.9.3
|
@@ -1,39 +0,0 @@
|
|
1
|
-
---
|
2
|
-
recorded_with: VCR 2.9.3
|
3
|
-
http_interactions:
|
4
|
-
- request:
|
5
|
-
method: post
|
6
|
-
uri: http://localhost:8888/moodle28/webservice/rest/server.php?moodlewsrestformat=json&wsfunction=core_course_get_courses&wstoken=
|
7
|
-
body:
|
8
|
-
string: options[ids][0]=1
|
9
|
-
headers: {}
|
10
|
-
|
11
|
-
response:
|
12
|
-
status:
|
13
|
-
code: 200
|
14
|
-
message: OK
|
15
|
-
headers:
|
16
|
-
Pragma:
|
17
|
-
- no-cache
|
18
|
-
Accept-Ranges:
|
19
|
-
- none
|
20
|
-
Content-Length:
|
21
|
-
- "103"
|
22
|
-
Access-Control-Allow-Origin:
|
23
|
-
- "*"
|
24
|
-
Date:
|
25
|
-
- Mon, 20 Jun 2016 22:04:25 GMT
|
26
|
-
Expires:
|
27
|
-
- Thu, 01 Jan 1970 00:00:00 GMT
|
28
|
-
Content-Type:
|
29
|
-
- application/json
|
30
|
-
X-Powered-By:
|
31
|
-
- PHP/5.6.2
|
32
|
-
Server:
|
33
|
-
- Apache/2.2.29 (Unix) mod_fastcgi/2.4.6 mod_wsgi/3.4 Python/2.7.8 PHP/5.6.2 mod_ssl/2.2.29 OpenSSL/0.9.8zg DAV/2 mod_perl/2.0.8 Perl/v5.20.0
|
34
|
-
Cache-Control:
|
35
|
-
- private, must-revalidate, pre-check=0, post-check=0, max-age=0
|
36
|
-
body:
|
37
|
-
string: "{\"exception\":\"moodle_exception\",\"errorcode\":\"invalidtoken\",\"message\":\"Invalid token - token not found\"}"
|
38
|
-
http_version:
|
39
|
-
recorded_at: Mon, 20 Jun 2016 22:04:25 GMT
|
@@ -1,39 +0,0 @@
|
|
1
|
-
---
|
2
|
-
recorded_with: VCR 2.9.3
|
3
|
-
http_interactions:
|
4
|
-
- request:
|
5
|
-
method: post
|
6
|
-
uri: http://localhost:8888/moodle28/webservice/rest/server.php?moodlewsrestformat=json&wsfunction=enrol_manual_enrol_users&wstoken=60fc9c9415259404795094957e4ab32f
|
7
|
-
body:
|
8
|
-
string: enrolments[0][userid]=3&enrolments[0][courseid]=8&enrolments[0][roleid]=5
|
9
|
-
headers: {}
|
10
|
-
|
11
|
-
response:
|
12
|
-
status:
|
13
|
-
code: 200
|
14
|
-
message: OK
|
15
|
-
headers:
|
16
|
-
Access-Control-Allow-Origin:
|
17
|
-
- "*"
|
18
|
-
X-Powered-By:
|
19
|
-
- PHP/5.6.2
|
20
|
-
Content-Type:
|
21
|
-
- application/json
|
22
|
-
Date:
|
23
|
-
- Sun, 12 Apr 2015 01:06:20 GMT
|
24
|
-
Content-Length:
|
25
|
-
- "4"
|
26
|
-
Pragma:
|
27
|
-
- no-cache
|
28
|
-
Cache-Control:
|
29
|
-
- private, must-revalidate, pre-check=0, post-check=0, max-age=0
|
30
|
-
Server:
|
31
|
-
- Apache/2.2.29 (Unix) mod_fastcgi/2.4.6 mod_wsgi/3.4 Python/2.7.8 PHP/5.6.2 mod_ssl/2.2.29 OpenSSL/0.9.8zd DAV/2 mod_perl/2.0.8 Perl/v5.20.0
|
32
|
-
Expires:
|
33
|
-
- Thu, 01 Jan 1970 00:00:00 GMT
|
34
|
-
Accept-Ranges:
|
35
|
-
- none
|
36
|
-
body:
|
37
|
-
string: "null"
|
38
|
-
http_version:
|
39
|
-
recorded_at: Sun, 12 Apr 2015 01:06:20 GMT
|
@@ -1,39 +0,0 @@
|
|
1
|
-
---
|
2
|
-
recorded_with: VCR 2.9.3
|
3
|
-
http_interactions:
|
4
|
-
- request:
|
5
|
-
method: post
|
6
|
-
uri: http://localhost:8888/moodle28/webservice/rest/server.php?moodlewsrestformat=json&wsfunction=enrol_manual_enrol_users&wstoken=60fc9c9415259404795094957e4ab32f
|
7
|
-
body:
|
8
|
-
string: enrolments[0][userid]=9999&enrolments[0][courseid]=9999&enrolments[0][roleid]=5
|
9
|
-
headers: {}
|
10
|
-
|
11
|
-
response:
|
12
|
-
status:
|
13
|
-
code: 200
|
14
|
-
message: OK
|
15
|
-
headers:
|
16
|
-
Cache-Control:
|
17
|
-
- private, must-revalidate, pre-check=0, post-check=0, max-age=0
|
18
|
-
Content-Type:
|
19
|
-
- application/json
|
20
|
-
Accept-Ranges:
|
21
|
-
- none
|
22
|
-
Content-Length:
|
23
|
-
- "119"
|
24
|
-
Date:
|
25
|
-
- Sat, 11 Apr 2015 12:50:42 GMT
|
26
|
-
Expires:
|
27
|
-
- Thu, 01 Jan 1970 00:00:00 GMT
|
28
|
-
Access-Control-Allow-Origin:
|
29
|
-
- "*"
|
30
|
-
Server:
|
31
|
-
- Apache/2.2.29 (Unix) mod_fastcgi/2.4.6 mod_wsgi/3.4 Python/2.7.8 PHP/5.6.2 mod_ssl/2.2.29 OpenSSL/0.9.8zd DAV/2 mod_perl/2.0.8 Perl/v5.20.0
|
32
|
-
Pragma:
|
33
|
-
- no-cache
|
34
|
-
X-Powered-By:
|
35
|
-
- PHP/5.6.2
|
36
|
-
body:
|
37
|
-
string: "{\"exception\":\"invalid_parameter_exception\",\"errorcode\":\"invalidparameter\",\"message\":\"Invalid parameter value detected\"}"
|
38
|
-
http_version:
|
39
|
-
recorded_at: Sat, 11 Apr 2015 12:50:42 GMT
|
@@ -1,51 +0,0 @@
|
|
1
|
-
---
|
2
|
-
http_interactions:
|
3
|
-
- request:
|
4
|
-
method: post
|
5
|
-
uri: https://localhost:8888/moodle28/webservice/rest/server.php?moodlewsrestformat=json&wsfunction=enrol_manual_unenrol_users&wstoken=60fc9c9415259404795094957e4ab32f
|
6
|
-
body:
|
7
|
-
encoding: UTF-8
|
8
|
-
string: enrolments[0][userid]=7&enrolments[0][courseid]=5&enrolments[0][roleid]=5
|
9
|
-
headers: {}
|
10
|
-
response:
|
11
|
-
status:
|
12
|
-
code: 200
|
13
|
-
message: OK
|
14
|
-
headers:
|
15
|
-
Accept-Ranges:
|
16
|
-
- bytes
|
17
|
-
- none
|
18
|
-
Access-Control-Allow-Origin:
|
19
|
-
- "*"
|
20
|
-
Age:
|
21
|
-
- '0'
|
22
|
-
Cache-Control:
|
23
|
-
- private, must-revalidate, pre-check=0, post-check=0, max-age=0
|
24
|
-
Content-Type:
|
25
|
-
- application/json
|
26
|
-
Date:
|
27
|
-
- Tue, 11 Jan 2022 05:21:58 GMT
|
28
|
-
Expires:
|
29
|
-
- Thu, 01 Jan 1970 00:00:00 GMT
|
30
|
-
Pragma:
|
31
|
-
- no-cache
|
32
|
-
Server:
|
33
|
-
- Moodle
|
34
|
-
X-Cache:
|
35
|
-
- MISS
|
36
|
-
X-Clacks-Overhead:
|
37
|
-
- GNU Terry Pratchett
|
38
|
-
X-Ec2-Instance-Id:
|
39
|
-
- i-0afd4744d7a60c5d7
|
40
|
-
X-Powered-By:
|
41
|
-
- Moodle Ninjas
|
42
|
-
Content-Length:
|
43
|
-
- '4'
|
44
|
-
Connection:
|
45
|
-
- keep-alive
|
46
|
-
body:
|
47
|
-
encoding: UTF-8
|
48
|
-
string: 'null'
|
49
|
-
http_version:
|
50
|
-
recorded_at: Tue, 11 Jan 2022 05:21:25 GMT
|
51
|
-
recorded_with: VCR 2.9.3
|
@@ -1,52 +0,0 @@
|
|
1
|
-
---
|
2
|
-
http_interactions:
|
3
|
-
- request:
|
4
|
-
method: post
|
5
|
-
uri: https://localhost:8888/moodle28/webservice/rest/server.php?moodlewsrestformat=json&wsfunction=enrol_manual_unenrol_users&wstoken=60fc9c9415259404795094957e4ab32f
|
6
|
-
body:
|
7
|
-
encoding: UTF-8
|
8
|
-
string: enrolments[0][userid]=9999&enrolments[0][courseid]=9999&enrolments[0][roleid]=5
|
9
|
-
headers: {}
|
10
|
-
response:
|
11
|
-
status:
|
12
|
-
code: 200
|
13
|
-
message: OK
|
14
|
-
headers:
|
15
|
-
Accept-Ranges:
|
16
|
-
- bytes
|
17
|
-
- none
|
18
|
-
Access-Control-Allow-Origin:
|
19
|
-
- "*"
|
20
|
-
Age:
|
21
|
-
- '0'
|
22
|
-
Cache-Control:
|
23
|
-
- private, must-revalidate, pre-check=0, post-check=0, max-age=0
|
24
|
-
Content-Type:
|
25
|
-
- application/json
|
26
|
-
Date:
|
27
|
-
- Tue, 11 Jan 2022 05:21:58 GMT
|
28
|
-
Expires:
|
29
|
-
- Thu, 01 Jan 1970 00:00:00 GMT
|
30
|
-
Pragma:
|
31
|
-
- no-cache
|
32
|
-
Server:
|
33
|
-
- Moodle
|
34
|
-
X-Cache:
|
35
|
-
- MISS
|
36
|
-
X-Clacks-Overhead:
|
37
|
-
- GNU Terry Pratchett
|
38
|
-
X-Ec2-Instance-Id:
|
39
|
-
- i-08adafc8cf93e6451
|
40
|
-
X-Powered-By:
|
41
|
-
- Moodle Ninjas
|
42
|
-
Content-Length:
|
43
|
-
- '133'
|
44
|
-
Connection:
|
45
|
-
- keep-alive
|
46
|
-
body:
|
47
|
-
encoding: UTF-8
|
48
|
-
string: '{"exception":"dml_missing_record_exception","errorcode":"invalidrecord","message":"Can''t
|
49
|
-
find data record in database table course."}'
|
50
|
-
http_version:
|
51
|
-
recorded_at: Tue, 11 Jan 2022 05:21:26 GMT
|
52
|
-
recorded_with: VCR 2.9.3
|
@@ -1,39 +0,0 @@
|
|
1
|
-
---
|
2
|
-
http_interactions:
|
3
|
-
- request:
|
4
|
-
method: post
|
5
|
-
uri: http://localhost:8888/moodle28/webservice/rest/server.php?moodlewsrestformat=json&wsfunction=mod_assign_get_grades&wstoken=60fc9c9415259404795094957e4ab32f
|
6
|
-
body:
|
7
|
-
string: assignmentids[0]=1
|
8
|
-
headers: {}
|
9
|
-
|
10
|
-
response:
|
11
|
-
status:
|
12
|
-
code: 200
|
13
|
-
message: OK
|
14
|
-
headers:
|
15
|
-
Content-Length:
|
16
|
-
- "180"
|
17
|
-
Server:
|
18
|
-
- Apache/2.2.29 (Unix) mod_fastcgi/2.4.6 mod_wsgi/3.4 Python/2.7.8 PHP/5.6.2 mod_ssl/2.2.29 OpenSSL/0.9.8zd DAV/2 mod_perl/2.0.8 Perl/v5.20.0
|
19
|
-
Expires:
|
20
|
-
- Thu, 01 Jan 1970 00:00:00 GMT
|
21
|
-
Cache-Control:
|
22
|
-
- private, must-revalidate, pre-check=0, post-check=0, max-age=0
|
23
|
-
Pragma:
|
24
|
-
- no-cache
|
25
|
-
Content-Type:
|
26
|
-
- application/json
|
27
|
-
Accept-Ranges:
|
28
|
-
- none
|
29
|
-
Date:
|
30
|
-
- Wed, 22 Apr 2015 23:29:46 GMT
|
31
|
-
X-Powered-By:
|
32
|
-
- PHP/5.6.2
|
33
|
-
Access-Control-Allow-Origin:
|
34
|
-
- "*"
|
35
|
-
body:
|
36
|
-
string: "{\"assignments\":[{\"assignmentid\":1,\"grades\":[{\"id\":1,\"userid\":5,\"attemptnumber\":0,\"timecreated\":1428801844,\"timemodified\":1428801869,\"grader\":2,\"grade\":\"90.00000\"}]}],\"warnings\":[]}"
|
37
|
-
http_version:
|
38
|
-
recorded_at: Wed, 22 Apr 2015 23:29:46 GMT
|
39
|
-
recorded_with: VCR 2.9.3
|
@@ -1,39 +0,0 @@
|
|
1
|
-
---
|
2
|
-
http_interactions:
|
3
|
-
- request:
|
4
|
-
method: post
|
5
|
-
uri: http://localhost:8888/moodle28/webservice/rest/server.php?moodlewsrestformat=json&wsfunction=core_grades_get_grades&wstoken=60fc9c9415259404795094957e4ab32f
|
6
|
-
body:
|
7
|
-
string: courseid=8&userids[0]=5
|
8
|
-
headers: {}
|
9
|
-
|
10
|
-
response:
|
11
|
-
status:
|
12
|
-
code: 200
|
13
|
-
message: OK
|
14
|
-
headers:
|
15
|
-
Content-Length:
|
16
|
-
- "1192"
|
17
|
-
Server:
|
18
|
-
- Apache/2.2.29 (Unix) mod_fastcgi/2.4.6 mod_wsgi/3.4 Python/2.7.8 PHP/5.6.2 mod_ssl/2.2.29 OpenSSL/0.9.8zd DAV/2 mod_perl/2.0.8 Perl/v5.20.0
|
19
|
-
Expires:
|
20
|
-
- Thu, 01 Jan 1970 00:00:00 GMT
|
21
|
-
Cache-Control:
|
22
|
-
- private, must-revalidate, pre-check=0, post-check=0, max-age=0
|
23
|
-
Pragma:
|
24
|
-
- no-cache
|
25
|
-
Content-Type:
|
26
|
-
- application/json
|
27
|
-
Accept-Ranges:
|
28
|
-
- none
|
29
|
-
Date:
|
30
|
-
- Wed, 22 Apr 2015 23:29:46 GMT
|
31
|
-
X-Powered-By:
|
32
|
-
- PHP/5.6.2
|
33
|
-
Access-Control-Allow-Origin:
|
34
|
-
- "*"
|
35
|
-
body:
|
36
|
-
string: "{\"items\":[{\"activityid\":\"course\",\"itemnumber\":0,\"scaleid\":0,\"name\":\"Course total\",\"grademin\":0,\"grademax\":100,\"gradepass\":0,\"locked\":0,\"hidden\":0,\"grades\":[{\"userid\":5,\"grade\":85,\"locked\":0,\"hidden\":0,\"overridden\":0,\"feedback\":null,\"feedbackformat\":0,\"usermodified\":null,\"datesubmitted\":null,\"dategraded\":1428807511,\"str_grade\":\"85.00\",\"str_long_grade\":\"85.00 \\/ 100.00\",\"str_feedback\":\"\"}]},{\"activityid\":\"13\",\"itemnumber\":0,\"scaleid\":0,\"name\":\"TestAssignment\",\"grademin\":0,\"grademax\":100,\"gradepass\":0,\"locked\":0,\"hidden\":0,\"grades\":[{\"userid\":5,\"grade\":90,\"locked\":0,\"hidden\":0,\"overridden\":0,\"feedback\":\"<p>Good<\\/p>\",\"feedbackformat\":1,\"usermodified\":2,\"datesubmitted\":null,\"dategraded\":1428801869,\"str_grade\":\"90.00\",\"str_long_grade\":\"90.00 \\/ 100.00\",\"str_feedback\":\"<p>Good<\\/p>\"}]},{\"activityid\":\"14\",\"itemnumber\":0,\"scaleid\":0,\"name\":\"Topic 1 Assignment Test\",\"grademin\":0,\"grademax\":100,\"gradepass\":0,\"locked\":0,\"hidden\":0,\"grades\":[{\"userid\":5,\"grade\":80,\"locked\":0,\"hidden\":0,\"overridden\":0,\"feedback\":null,\"feedbackformat\":1,\"usermodified\":2,\"datesubmitted\":null,\"dategraded\":1428807511,\"str_grade\":\"80.00\",\"str_long_grade\":\"80.00 \\/ 100.00\",\"str_feedback\":\"\"}]}],\"outcomes\":[]}"
|
37
|
-
http_version:
|
38
|
-
recorded_at: Wed, 22 Apr 2015 23:29:46 GMT
|
39
|
-
recorded_with: VCR 2.9.3
|
@@ -1,39 +0,0 @@
|
|
1
|
-
---
|
2
|
-
http_interactions:
|
3
|
-
- request:
|
4
|
-
method: post
|
5
|
-
uri: http://localhost:8888/moodle28/webservice/rest/server.php?moodlewsrestformat=json&wsfunction=core_grades_get_grades&wstoken=60fc9c9415259404795094957e4ab32f
|
6
|
-
body:
|
7
|
-
string: userids[0]=ABC&courseid=8
|
8
|
-
headers: {}
|
9
|
-
|
10
|
-
response:
|
11
|
-
status:
|
12
|
-
code: 200
|
13
|
-
message: OK
|
14
|
-
headers:
|
15
|
-
Content-Length:
|
16
|
-
- "119"
|
17
|
-
Expires:
|
18
|
-
- Thu, 01 Jan 1970 00:00:00 GMT
|
19
|
-
Pragma:
|
20
|
-
- no-cache
|
21
|
-
Accept-Ranges:
|
22
|
-
- none
|
23
|
-
Content-Type:
|
24
|
-
- application/json
|
25
|
-
X-Powered-By:
|
26
|
-
- PHP/5.6.2
|
27
|
-
Cache-Control:
|
28
|
-
- private, must-revalidate, pre-check=0, post-check=0, max-age=0
|
29
|
-
Access-Control-Allow-Origin:
|
30
|
-
- "*"
|
31
|
-
Date:
|
32
|
-
- Wed, 10 Jun 2015 03:06:02 GMT
|
33
|
-
Server:
|
34
|
-
- Apache/2.2.29 (Unix) mod_fastcgi/2.4.6 mod_wsgi/3.4 Python/2.7.8 PHP/5.6.2 mod_ssl/2.2.29 OpenSSL/0.9.8zd DAV/2 mod_perl/2.0.8 Perl/v5.20.0
|
35
|
-
body:
|
36
|
-
string: "{\"exception\":\"invalid_parameter_exception\",\"errorcode\":\"invalidparameter\",\"message\":\"Invalid parameter value detected\"}"
|
37
|
-
http_version:
|
38
|
-
recorded_at: Wed, 10 Jun 2015 03:06:02 GMT
|
39
|
-
recorded_with: VCR 2.9.3
|
@@ -1,39 +0,0 @@
|
|
1
|
-
---
|
2
|
-
http_interactions:
|
3
|
-
- request:
|
4
|
-
method: post
|
5
|
-
uri: http://localhost:8888/moodle28/webservice/rest/server.php?moodlewsrestformat=json&wsfunction=core_user_create_users&wstoken=60fc9c9415259404795094957e4ab32f
|
6
|
-
body:
|
7
|
-
string: users[0][firstname]=Austin&users[0][password]=Password123!&users[0][lastname]=Powers&users[0][idnumber]=PAUST002&users[0][email]=austinp1%40jobready.com.au&users[0][username]=testuser1
|
8
|
-
headers: {}
|
9
|
-
|
10
|
-
response:
|
11
|
-
status:
|
12
|
-
code: 200
|
13
|
-
message: OK
|
14
|
-
headers:
|
15
|
-
Cache-Control:
|
16
|
-
- private, must-revalidate, pre-check=0, post-check=0, max-age=0
|
17
|
-
X-Powered-By:
|
18
|
-
- PHP/5.6.2
|
19
|
-
Pragma:
|
20
|
-
- no-cache
|
21
|
-
Content-Length:
|
22
|
-
- "33"
|
23
|
-
Server:
|
24
|
-
- Apache/2.2.29 (Unix) mod_fastcgi/2.4.6 mod_wsgi/3.4 Python/2.7.8 PHP/5.6.2 mod_ssl/2.2.29 OpenSSL/0.9.8zd DAV/2 mod_perl/2.0.8 Perl/v5.20.0
|
25
|
-
Access-Control-Allow-Origin:
|
26
|
-
- "*"
|
27
|
-
Accept-Ranges:
|
28
|
-
- none
|
29
|
-
Content-Type:
|
30
|
-
- application/json
|
31
|
-
Expires:
|
32
|
-
- Thu, 01 Jan 1970 00:00:00 GMT
|
33
|
-
Date:
|
34
|
-
- Sun, 12 Apr 2015 01:01:16 GMT
|
35
|
-
body:
|
36
|
-
string: "[{\"id\":5,\"username\":\"testuser1\"}]"
|
37
|
-
http_version:
|
38
|
-
recorded_at: Sun, 12 Apr 2015 01:01:16 GMT
|
39
|
-
recorded_with: VCR 2.9.3
|
@@ -1,39 +0,0 @@
|
|
1
|
-
---
|
2
|
-
http_interactions:
|
3
|
-
- request:
|
4
|
-
method: post
|
5
|
-
uri: http://localhost:8888/moodle28/webservice/rest/server.php?moodlewsrestformat=json&wsfunction=core_user_create_users&wstoken=60fc9c9415259404795094957e4ab32f
|
6
|
-
body:
|
7
|
-
string: users[0][username]=testuser1
|
8
|
-
headers: {}
|
9
|
-
|
10
|
-
response:
|
11
|
-
status:
|
12
|
-
code: 200
|
13
|
-
message: OK
|
14
|
-
headers:
|
15
|
-
Cache-Control:
|
16
|
-
- private, must-revalidate, pre-check=0, post-check=0, max-age=0
|
17
|
-
X-Powered-By:
|
18
|
-
- PHP/5.6.2
|
19
|
-
Pragma:
|
20
|
-
- no-cache
|
21
|
-
Content-Length:
|
22
|
-
- "119"
|
23
|
-
Server:
|
24
|
-
- Apache/2.2.29 (Unix) mod_fastcgi/2.4.6 mod_wsgi/3.4 Python/2.7.8 PHP/5.6.2 mod_ssl/2.2.29 OpenSSL/0.9.8zd DAV/2 mod_perl/2.0.8 Perl/v5.20.0
|
25
|
-
Access-Control-Allow-Origin:
|
26
|
-
- "*"
|
27
|
-
Accept-Ranges:
|
28
|
-
- none
|
29
|
-
Content-Type:
|
30
|
-
- application/json
|
31
|
-
Expires:
|
32
|
-
- Thu, 01 Jan 1970 00:00:00 GMT
|
33
|
-
Date:
|
34
|
-
- Sun, 12 Apr 2015 01:01:16 GMT
|
35
|
-
body:
|
36
|
-
string: "{\"exception\":\"invalid_parameter_exception\",\"errorcode\":\"invalidparameter\",\"message\":\"Invalid parameter value detected\"}"
|
37
|
-
http_version:
|
38
|
-
recorded_at: Sun, 12 Apr 2015 01:01:16 GMT
|
39
|
-
recorded_with: VCR 2.9.3
|
@@ -1,39 +0,0 @@
|
|
1
|
-
---
|
2
|
-
recorded_with: VCR 2.9.3
|
3
|
-
http_interactions:
|
4
|
-
- request:
|
5
|
-
method: post
|
6
|
-
uri: http://localhost:8888/moodle28/webservice/rest/server.php?moodlewsrestformat=json&wsfunction=core_user_delete_users&wstoken=60fc9c9415259404795094957e4ab32f
|
7
|
-
body:
|
8
|
-
string: userids[0]=5
|
9
|
-
headers: {}
|
10
|
-
|
11
|
-
response:
|
12
|
-
status:
|
13
|
-
code: 200
|
14
|
-
message: OK
|
15
|
-
headers:
|
16
|
-
Access-Control-Allow-Origin:
|
17
|
-
- "*"
|
18
|
-
Content-Type:
|
19
|
-
- application/json
|
20
|
-
Date:
|
21
|
-
- Sun, 12 Apr 2015 01:04:36 GMT
|
22
|
-
Content-Length:
|
23
|
-
- "4"
|
24
|
-
X-Powered-By:
|
25
|
-
- PHP/5.6.2
|
26
|
-
Accept-Ranges:
|
27
|
-
- none
|
28
|
-
Expires:
|
29
|
-
- Thu, 01 Jan 1970 00:00:00 GMT
|
30
|
-
Server:
|
31
|
-
- Apache/2.2.29 (Unix) mod_fastcgi/2.4.6 mod_wsgi/3.4 Python/2.7.8 PHP/5.6.2 mod_ssl/2.2.29 OpenSSL/0.9.8zd DAV/2 mod_perl/2.0.8 Perl/v5.20.0
|
32
|
-
Pragma:
|
33
|
-
- no-cache
|
34
|
-
Cache-Control:
|
35
|
-
- private, must-revalidate, pre-check=0, post-check=0, max-age=0
|
36
|
-
body:
|
37
|
-
string: "null"
|
38
|
-
http_version:
|
39
|
-
recorded_at: Sun, 12 Apr 2015 01:04:36 GMT
|
@@ -1,39 +0,0 @@
|
|
1
|
-
---
|
2
|
-
http_interactions:
|
3
|
-
- request:
|
4
|
-
method: post
|
5
|
-
uri: http://localhost:8888/moodle28/webservice/rest/server.php?moodlewsrestformat=json&wsfunction=core_user_delete_users&wstoken=60fc9c9415259404795094957e4ab32f
|
6
|
-
body:
|
7
|
-
string: userids[0]=999
|
8
|
-
headers: {}
|
9
|
-
|
10
|
-
response:
|
11
|
-
status:
|
12
|
-
code: 200
|
13
|
-
message: OK
|
14
|
-
headers:
|
15
|
-
Cache-Control:
|
16
|
-
- private, must-revalidate, pre-check=0, post-check=0, max-age=0
|
17
|
-
Content-Type:
|
18
|
-
- application/json
|
19
|
-
Access-Control-Allow-Origin:
|
20
|
-
- "*"
|
21
|
-
Pragma:
|
22
|
-
- no-cache
|
23
|
-
Expires:
|
24
|
-
- Thu, 01 Jan 1970 00:00:00 GMT
|
25
|
-
Accept-Ranges:
|
26
|
-
- none
|
27
|
-
Server:
|
28
|
-
- Apache/2.2.29 (Unix) mod_fastcgi/2.4.6 mod_wsgi/3.4 Python/2.7.8 PHP/5.6.2 mod_ssl/2.2.29 OpenSSL/0.9.8zd DAV/2 mod_perl/2.0.8 Perl/v5.20.0
|
29
|
-
X-Powered-By:
|
30
|
-
- PHP/5.6.2
|
31
|
-
Date:
|
32
|
-
- Sun, 12 Apr 2015 01:03:59 GMT
|
33
|
-
Content-Length:
|
34
|
-
- "95"
|
35
|
-
body:
|
36
|
-
string: "{\"exception\":\"dml_missing_record_exception\",\"errorcode\":\"invaliduser\",\"message\":\"Invalid user\"}"
|
37
|
-
http_version:
|
38
|
-
recorded_at: Sun, 12 Apr 2015 01:03:59 GMT
|
39
|
-
recorded_with: VCR 2.9.3
|
@@ -1,39 +0,0 @@
|
|
1
|
-
---
|
2
|
-
http_interactions:
|
3
|
-
- request:
|
4
|
-
method: post
|
5
|
-
uri: http://localhost:8888/moodle28/webservice/rest/server.php?moodlewsrestformat=json&wsfunction=core_user_delete_users&wstoken=
|
6
|
-
body:
|
7
|
-
string: userids[0]=-1
|
8
|
-
headers: {}
|
9
|
-
|
10
|
-
response:
|
11
|
-
status:
|
12
|
-
code: 200
|
13
|
-
message: OK
|
14
|
-
headers:
|
15
|
-
Pragma:
|
16
|
-
- no-cache
|
17
|
-
Date:
|
18
|
-
- Mon, 20 Jun 2016 22:34:35 GMT
|
19
|
-
Content-Length:
|
20
|
-
- "103"
|
21
|
-
Accept-Ranges:
|
22
|
-
- none
|
23
|
-
Content-Type:
|
24
|
-
- application/json
|
25
|
-
Access-Control-Allow-Origin:
|
26
|
-
- "*"
|
27
|
-
X-Powered-By:
|
28
|
-
- PHP/5.6.2
|
29
|
-
Expires:
|
30
|
-
- Thu, 01 Jan 1970 00:00:00 GMT
|
31
|
-
Server:
|
32
|
-
- Apache/2.2.29 (Unix) mod_fastcgi/2.4.6 mod_wsgi/3.4 Python/2.7.8 PHP/5.6.2 mod_ssl/2.2.29 OpenSSL/0.9.8zg DAV/2 mod_perl/2.0.8 Perl/v5.20.0
|
33
|
-
Cache-Control:
|
34
|
-
- private, must-revalidate, pre-check=0, post-check=0, max-age=0
|
35
|
-
body:
|
36
|
-
string: "{\"exception\":\"moodle_exception\",\"errorcode\":\"invalidtoken\",\"message\":\"Invalid token - token not found\"}"
|
37
|
-
http_version:
|
38
|
-
recorded_at: Mon, 20 Jun 2016 22:34:35 GMT
|
39
|
-
recorded_with: VCR 2.9.3
|
@@ -1,39 +0,0 @@
|
|
1
|
-
---
|
2
|
-
recorded_with: VCR 2.9.3
|
3
|
-
http_interactions:
|
4
|
-
- request:
|
5
|
-
method: post
|
6
|
-
uri: http://localhost:8888/moodle28/webservice/rest/server.php?moodlewsrestformat=json&wsfunction=core_enrol_get_users_courses&wstoken=60fc9c9415259404795094957e4ab32f
|
7
|
-
body:
|
8
|
-
string: userid=3
|
9
|
-
headers: {}
|
10
|
-
|
11
|
-
response:
|
12
|
-
status:
|
13
|
-
code: 200
|
14
|
-
message: OK
|
15
|
-
headers:
|
16
|
-
Accept-Ranges:
|
17
|
-
- none
|
18
|
-
Date:
|
19
|
-
- Sun, 12 Apr 2015 01:05:25 GMT
|
20
|
-
Cache-Control:
|
21
|
-
- private, must-revalidate, pre-check=0, post-check=0, max-age=0
|
22
|
-
Expires:
|
23
|
-
- Thu, 01 Jan 1970 00:00:00 GMT
|
24
|
-
Pragma:
|
25
|
-
- no-cache
|
26
|
-
X-Powered-By:
|
27
|
-
- PHP/5.6.2
|
28
|
-
Content-Type:
|
29
|
-
- application/json
|
30
|
-
Server:
|
31
|
-
- Apache/2.2.29 (Unix) mod_fastcgi/2.4.6 mod_wsgi/3.4 Python/2.7.8 PHP/5.6.2 mod_ssl/2.2.29 OpenSSL/0.9.8zd DAV/2 mod_perl/2.0.8 Perl/v5.20.0
|
32
|
-
Content-Length:
|
33
|
-
- "110"
|
34
|
-
Access-Control-Allow-Origin:
|
35
|
-
- "*"
|
36
|
-
body:
|
37
|
-
string: "[{\"id\":8,\"shortname\":\"TestC1\",\"fullname\":\"Test Course\",\"enrolledusercount\":1,\"idnumber\":\"ExtRef\",\"visible\":1}]"
|
38
|
-
http_version:
|
39
|
-
recorded_at: Sun, 12 Apr 2015 01:05:25 GMT
|