clever-ruby 0.6.2 → 0.7.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (88) hide show
  1. checksums.yaml +8 -8
  2. data/CHANGELOG.md +5 -0
  3. data/lib/clever-ruby.rb +3 -0
  4. data/lib/clever-ruby/api_operations/nested_list.rb +46 -0
  5. data/lib/clever-ruby/api_resource.rb +67 -27
  6. data/lib/clever-ruby/clever_object.rb +8 -2
  7. data/lib/clever-ruby/district.rb +25 -11
  8. data/lib/clever-ruby/event.rb +1 -1
  9. data/lib/clever-ruby/nested_resource.rb +40 -0
  10. data/lib/clever-ruby/school.rb +1 -1
  11. data/lib/clever-ruby/section.rb +1 -1
  12. data/lib/clever-ruby/student.rb +13 -1
  13. data/lib/clever-ruby/teacher.rb +1 -1
  14. data/lib/clever-ruby/util.rb +16 -17
  15. data/lib/clever-ruby/version.rb +1 -1
  16. data/test/data/vcr_cassettes/district_count.yml +6 -6
  17. data/test/data/vcr_cassettes/{districts_events.yml → district_events.yml} +29 -164
  18. data/test/data/vcr_cassettes/district_find_by_page.yml +12 -12
  19. data/test/data/vcr_cassettes/district_find_multiple.yml +12 -12
  20. data/test/data/vcr_cassettes/district_find_one.yml +12 -12
  21. data/test/data/vcr_cassettes/{districts_schools.yml → district_schools.yml} +25 -148
  22. data/test/data/vcr_cassettes/district_sections.yml +2289 -0
  23. data/test/data/vcr_cassettes/district_students.yml +2339 -0
  24. data/test/data/vcr_cassettes/{districts_teachers.yml → district_teachers.yml} +25 -148
  25. data/test/data/vcr_cassettes/districts.yml +12 -12
  26. data/test/data/vcr_cassettes/districts_event_pages.yml +76 -469
  27. data/test/data/vcr_cassettes/districts_school_pages.yml +31 -154
  28. data/test/data/vcr_cassettes/districts_section_pages.yml +284 -407
  29. data/test/data/vcr_cassettes/districts_student_pages.yml +165 -288
  30. data/test/data/vcr_cassettes/districts_teacher_pages.yml +81 -204
  31. data/test/data/vcr_cassettes/error_handling.yml +17 -58
  32. data/test/data/vcr_cassettes/event_count.yml +7 -7
  33. data/test/data/vcr_cassettes/event_find_by_page.yml +16 -22
  34. data/test/data/vcr_cassettes/event_find_multiple.yml +19 -28
  35. data/test/data/vcr_cassettes/event_find_one.yml +16 -22
  36. data/test/data/vcr_cassettes/events.yml +16 -22
  37. data/test/data/vcr_cassettes/school_count.yml +6 -6
  38. data/test/data/vcr_cassettes/school_district.yml +140 -0
  39. data/test/data/vcr_cassettes/school_events.yml +181 -0
  40. data/test/data/vcr_cassettes/school_find_by_page.yml +13 -13
  41. data/test/data/vcr_cassettes/school_find_multiple.yml +14 -14
  42. data/test/data/vcr_cassettes/school_find_one.yml +13 -13
  43. data/test/data/vcr_cassettes/school_sections.yml +1119 -0
  44. data/test/data/vcr_cassettes/school_students.yml +1033 -0
  45. data/test/data/vcr_cassettes/school_teachers.yml +257 -0
  46. data/test/data/vcr_cassettes/schools.yml +13 -13
  47. data/test/data/vcr_cassettes/schools_optional_attributes.yml +7 -7
  48. data/test/data/vcr_cassettes/section_count.yml +6 -6
  49. data/test/data/vcr_cassettes/section_district.yml +393 -0
  50. data/test/data/vcr_cassettes/section_events.yml +434 -0
  51. data/test/data/vcr_cassettes/section_find_by_page.yml +34 -34
  52. data/test/data/vcr_cassettes/section_find_multiple.yml +14 -14
  53. data/test/data/vcr_cassettes/section_find_one.yml +14 -14
  54. data/test/data/vcr_cassettes/section_school.yml +396 -0
  55. data/test/data/vcr_cassettes/section_students.yml +456 -0
  56. data/test/data/vcr_cassettes/section_teacher.yml +394 -0
  57. data/test/data/vcr_cassettes/sections.yml +34 -34
  58. data/test/data/vcr_cassettes/student_count.yml +6 -6
  59. data/test/data/vcr_cassettes/student_district.yml +202 -0
  60. data/test/data/vcr_cassettes/student_events.yml +243 -0
  61. data/test/data/vcr_cassettes/student_find_by_page.yml +83 -83
  62. data/test/data/vcr_cassettes/student_find_multiple.yml +14 -14
  63. data/test/data/vcr_cassettes/student_find_one.yml +14 -14
  64. data/test/data/vcr_cassettes/student_school.yml +205 -0
  65. data/test/data/vcr_cassettes/student_sections.yml +269 -0
  66. data/test/data/vcr_cassettes/student_teacher.yml +161 -0
  67. data/test/data/vcr_cassettes/student_teachers.yml +245 -0
  68. data/test/data/vcr_cassettes/students.yml +83 -83
  69. data/test/data/vcr_cassettes/teacher_count.yml +6 -6
  70. data/test/data/vcr_cassettes/teacher_district.yml +218 -0
  71. data/test/data/vcr_cassettes/teacher_events.yml +259 -0
  72. data/test/data/vcr_cassettes/teacher_find_by_page.yml +13 -13
  73. data/test/data/vcr_cassettes/teacher_find_multiple.yml +14 -14
  74. data/test/data/vcr_cassettes/teacher_find_one.yml +13 -13
  75. data/test/data/vcr_cassettes/teacher_school.yml +221 -0
  76. data/test/data/vcr_cassettes/teacher_sections.yml +291 -0
  77. data/test/data/vcr_cassettes/teacher_students.yml +293 -0
  78. data/test/data/vcr_cassettes/teachers.yml +13 -13
  79. data/test/integration/api_operations/list_test.rb +1 -1
  80. data/test/integration/district_test.rb +17 -49
  81. data/test/integration/error_handling_test.rb +1 -1
  82. data/test/integration/nested_resource_test.rb +27 -0
  83. data/test/unit/api_resource_test.rb +32 -0
  84. data/test/unit/optional_attributes_test.rb +7 -13
  85. metadata +60 -14
  86. data/test/data/vcr_cassettes/districts_sections.yml +0 -818
  87. data/test/data/vcr_cassettes/districts_students.yml +0 -436
  88. data/test/data/vcr_cassettes/districts_students_filtered.yml +0 -170
@@ -8,7 +8,7 @@ http_interactions:
8
8
  string: ''
9
9
  headers:
10
10
  Accept:
11
- - "*/*; q=0.5, application/xml"
11
+ - ! '*/*; q=0.5, application/xml'
12
12
  Accept-Encoding:
13
13
  - gzip, deflate
14
14
  User-Agent:
@@ -23,30 +23,24 @@ http_interactions:
23
23
  Access-Control-Allow-Methods:
24
24
  - GET,PATCH,POST,DELETE
25
25
  Access-Control-Allow-Origin:
26
- - "*"
26
+ - ! '*'
27
27
  Content-Type:
28
28
  - application/json; charset=utf-8
29
29
  Date:
30
- - Tue, 09 Sep 2014 21:49:01 GMT
30
+ - Fri, 12 Sep 2014 20:48:33 GMT
31
31
  Etag:
32
- - '"-1223191133"'
32
+ - ! '"-214069741"'
33
33
  Server:
34
34
  - nginx/1.4.7
35
35
  X-Powered-By:
36
36
  - Express
37
37
  Content-Length:
38
- - '15673'
38
+ - '9308'
39
39
  Connection:
40
40
  - keep-alive
41
41
  body:
42
- encoding: UTF-8
43
- string: '{"data":[{"data":{"type":"students.updated","data":{"object":{"district":"4fd43cc56d11340000000005","dob":"8/31/1997","ell_status":"N","email":"monique.g@example.net","frl_status":"Paid","gender":"F","grade":"10","hispanic_ethnicity":"Y","iep_status":"","race":"Asian","school":"530e595026403103360ff9fd","sis_id":"556584559","state_id":"485279646","student_number":"556584559","credentials":{"district_username":"moniqueg59","district_password":"EPhie9th"},"location":{"zip":"10020"},"name":{"first":"Monique","middle":"J","last":"Gutmann"},"last_modified":"2014-06-04T14:10:42.770Z","created":"2014-02-26T21:15:16.916Z","id":"530e5964049e75a9262d0304"},"previous_attributes":{"ell_status":"Y"}},"created":"2014-08-11T18:35:19.401Z","id":"53e90ce782399c964b0009e2"},"uri":"/v1.1/events/53e90ce782399c964b0009e2"},{"data":{"type":"students.updated","data":{"object":{"district":"4fd43cc56d11340000000005","dob":"11/4/1998","ell_status":"N","email":"h_william@example.net","frl_status":"Paid","gender":"M","grade":"9","hispanic_ethnicity":"Y","iep_status":"","race":"Black
44
- or African American","school":"530e595026403103360ff9fd","sis_id":"617499409","state_id":"979518299","student_number":"617499409","credentials":{"district_username":"williamh09","district_password":"roosh5Oo"},"location":{"zip":"11428"},"name":{"first":"William","middle":"M","last":"Hodkiewicz"},"last_modified":"2014-06-04T14:10:43.010Z","created":"2014-02-26T21:15:17.612Z","id":"530e5965049e75a9262d038f"},"previous_attributes":{"ell_status":"Y"}},"created":"2014-08-11T18:35:19.402Z","id":"53e90ce782399c964b0009e3"},"uri":"/v1.1/events/53e90ce782399c964b0009e3"},{"data":{"type":"students.updated","data":{"object":{"district":"4fd43cc56d11340000000005","dob":"5/17/1998","ell_status":"N","email":"corina.w@example.com","frl_status":"Paid","gender":"F","grade":"9","hispanic_ethnicity":"Y","iep_status":"","race":"American
45
- Indian","school":"530e595026403103360ff9fd","sis_id":"670807511","state_id":"814185233","student_number":"670807511","credentials":{"district_username":"corinaw11","district_password":"Eiph5aeX"},"location":{"zip":"10004"},"name":{"first":"Corina","middle":"L","last":"Watsica"},"last_modified":"2014-06-04T14:10:43.290Z","created":"2014-02-26T21:15:18.067Z","id":"530e5966049e75a9262d03fc"},"previous_attributes":{"dob":"5/7/1998"}},"created":"2014-08-11T18:35:19.406Z","id":"53e90ce782399c964b0009e4"},"uri":"/v1.1/events/53e90ce782399c964b0009e4"},{"data":{"type":"students.updated","data":{"object":{"district":"4fd43cc56d11340000000005","dob":"5/13/1998","ell_status":"Y","email":"kim_j@example.org","frl_status":"Paid","gender":"F","grade":"9","hispanic_ethnicity":"N","iep_status":"","race":"Asian","school":"530e595026403103360ff9fd","sis_id":"841688312","state_id":"484726796","student_number":"841688312","credentials":{"district_username":"kimj12","district_password":"phee7kah3R"},"location":{"zip":"11377"},"name":{"first":"Kimberly","last":"Jacobi","middle":"J"},"last_modified":"2014-06-04T14:10:44.004Z","created":"2014-02-26T21:15:19.645Z","id":"530e5967049e75a9262d057e"},"previous_attributes":{"name":{"first":"Kim","last":"Jacobi","middle":"J"}}},"created":"2014-08-11T18:35:19.406Z","id":"53e90ce782399c964b0009e5"},"uri":"/v1.1/events/53e90ce782399c964b0009e5"},{"data":{"type":"sections.updated","data":{"object":{"course_name":"Group
46
- Guidance","course_number":"101","district":"4fd43cc56d11340000000005","grade":"10","name":"Group
47
- Guidance - 101 - B. Greene (Section 1)","period":"0","school":"530e595026403103360ff9fd","sis_id":"581","subject":"homeroom/advisory","teacher":"530e5955d50c310f36112c11","term":{"name":"Y1","start_date":"2012-08-01","end_date":"2013-06-01"},"students":["530e5961049e75a9262cffd9","530e5961049e75a9262d0010","530e5961049e75a9262d004e","530e5961049e75a9262d0080","530e5962049e75a9262d0156","530e5963049e75a9262d01b7","530e5963049e75a9262d0253","530e5966049e75a9262d0418","530e5966049e75a9262d0475","530e5966049e75a9262d04b4","530e5967049e75a9262d0503","530e5968049e75a9262d05e9","530e5968049e75a9262d061f","530e5968049e75a9262d0632","530e5968049e75a9262d0647"],"last_modified":"2014-02-26T21:15:37.930Z","created":"2014-02-26T21:15:37.927Z","id":"530e5979049e75a9262d0af2"},"previous_attributes":{"students":["530e5961049e75a9262cffd9","530e5961049e75a9262d0010","530e5961049e75a9262d004e","530e5961049e75a9262d0080","530e5962049e75a9262d0156","530e5963049e75a9262d01b7","530e5963049e75a9262d0253","530e5966049e75a9262d0418","530e5966049e75a9262d0475","530e5966049e75a9262d04b4","530e5966049e75a9262d04ba","530e5967049e75a9262d0503","530e5968049e75a9262d05e9","530e5968049e75a9262d061f","530e5968049e75a9262d0632","530e5968049e75a9262d0647"]}},"created":"2014-08-11T18:35:19.418Z","id":"53e90ce782399c964b0009e6"},"uri":"/v1.1/events/53e90ce782399c964b0009e6"},{"data":{"type":"sections.updated","data":{"object":{"course_name":"Group
48
- Guidance","course_number":"901","district":"4fd43cc56d11340000000005","grade":"9","name":"Group
49
- Guidance - 901 - B. Greene (Section 1)","period":"0","school":"530e595026403103360ff9fd","sis_id":"596","subject":"homeroom/advisory","teacher":"530e5955d50c310f36112c11","term":{"name":"Y1","start_date":"2012-08-01","end_date":"2013-06-01"},"students":["530e5961049e75a9262d001a","530e5961049e75a9262d0034","530e5962049e75a9262d0110","530e5963049e75a9262d01db","530e5963049e75a9262d022f","530e5964049e75a9262d0284","530e5964049e75a9262d0309","530e5965049e75a9262d038e","530e5965049e75a9262d038f","530e5966049e75a9262d046c","530e5966049e75a9262d0471","530e5966049e75a9262d04b4","530e5967049e75a9262d057e","530e5968049e75a9262d0614","530e5968049e75a9262d061c","530e5968049e75a9262d0640"],"last_modified":"2014-02-26T21:15:37.996Z","created":"2014-02-26T21:15:37.994Z","id":"530e5979049e75a9262d0b01"},"previous_attributes":{"students":["530e5961049e75a9262d001a","530e5961049e75a9262d0034","530e5962049e75a9262d0110","530e5963049e75a9262d01db","530e5963049e75a9262d022f","530e5964049e75a9262d0284","530e5964049e75a9262d0309","530e5965049e75a9262d038e","530e5965049e75a9262d038f","530e5966049e75a9262d046c","530e5966049e75a9262d0471","530e5967049e75a9262d057e","530e5968049e75a9262d0614","530e5968049e75a9262d061c","530e5968049e75a9262d063a","530e5968049e75a9262d0640"]}},"created":"2014-08-11T18:35:19.420Z","id":"53e90ce782399c964b0009e7"},"uri":"/v1.1/events/53e90ce782399c964b0009e7"},{"data":{"type":"sections.updated","data":{"object":{"course_name":"Grade
42
+ encoding: US-ASCII
43
+ string: ! '{"data":[{"data":{"type":"sections.updated","data":{"object":{"course_name":"Grade
50
44
  3 Math, Class 301","course_number":"301","district":"4fd43cc56d11340000000005","grade":"3","name":"Grade
51
45
  3 Math, Class 301 - 301 - S. Block","period":"5","school":"530e595026403103360ff9fe","sis_id":"771","subject":"math","teacher":"530e5955d50c310f36112c15","term":{"name":"Y1","start_date":"2012-08-01","end_date":"2013-06-01"},"students":["530e5962049e75a9262d00fb","530e5962049e75a9262d015a","530e5963049e75a9262d0219","530e5964049e75a9262d0270","530e5964049e75a9262d02cf","530e5964049e75a9262d02fc","530e5965049e75a9262d0341","530e5965049e75a9262d0343","530e5965049e75a9262d038d","530e5965049e75a9262d03a7","530e5966049e75a9262d0415","530e5966049e75a9262d0439","530e5966049e75a9262d0458","530e5966049e75a9262d04d5","530e5967049e75a9262d04f4","530e5967049e75a9262d051f"],"last_modified":"2014-07-07T15:46:35.850Z","created":"2014-02-26T21:15:38.738Z","id":"530e597a049e75a9262d0baf"},"previous_attributes":{"students":["530e5960049e75a9262cff56","530e5962049e75a9262d00fb","530e5962049e75a9262d015a","530e5963049e75a9262d0219","530e5964049e75a9262d0270","530e5964049e75a9262d02cf","530e5964049e75a9262d02fc","530e5965049e75a9262d0341","530e5965049e75a9262d0343","530e5965049e75a9262d038d","530e5965049e75a9262d03a7","530e5966049e75a9262d0415","530e5966049e75a9262d0439","530e5966049e75a9262d0458","530e5966049e75a9262d04d5","530e5967049e75a9262d04f4","530e5967049e75a9262d051f"]}},"created":"2014-08-28T18:01:13.872Z","id":"53ff6e6b322eced002000088"},"uri":"/v1.1/events/53ff6e6b322eced002000088"},{"data":{"type":"sections.updated","data":{"object":{"course_name":"Kindergarten
52
46
  Music, Class 001","course_number":"1","district":"4fd43cc56d11340000000005","grade":"Kindergarten","name":"Kindergarten
@@ -63,9 +57,9 @@ http_interactions:
63
57
  Science, Class 002","course_number":"2","district":"4fd43cc56d11340000000005","grade":"Kindergarten","name":"Kindergarten
64
58
  Science, Class 002 - 002 - S. Schoen","period":"3","school":"530e595026403103360ff9fe","sis_id":"865","subject":"science","teacher":"530e5955d50c310f36112c03","term":{"name":"Y1","start_date":"2012-08-01","end_date":"2013-06-01"},"students":["530e5960049e75a9262cff1d","530e5960049e75a9262cff55","530e5961049e75a9262cffc2","530e5961049e75a9262d0012","530e5962049e75a9262d00c0","530e5962049e75a9262d010d","530e5962049e75a9262d0136","530e5962049e75a9262d0151","530e5962049e75a9262d0162","530e5963049e75a9262d01bb","530e5963049e75a9262d01f0","530e5964049e75a9262d0295","530e5964049e75a9262d02a7","530e5964049e75a9262d02d8","530e5965049e75a9262d0320","530e5965049e75a9262d03b9","530e5966049e75a9262d0491","530e5966049e75a9262d04c4","530e5967049e75a9262d0520","530e5968049e75a9262d0615"],"last_modified":"2014-02-26T21:15:39.183Z","created":"2014-02-26T21:15:39.181Z","id":"530e597b049e75a9262d0c0e"},"previous_attributes":{"subject":"homeroom/advisory"}},"created":"2014-08-28T18:01:14.076Z","id":"53ff6e6b322eced00200008d"},"uri":"/v1.1/events/53ff6e6b322eced00200008d"},{"data":{"type":"sections.updated","data":{"object":{"course_name":"Kindergarten
65
59
  Science, Class 003","course_number":"3","district":"4fd43cc56d11340000000005","grade":"Kindergarten","name":"Kindergarten
66
- Science, Class 003 - 003 - J. Stark","period":"4","school":"530e595026403103360ff9fe","sis_id":"866","subject":"science","teacher":"50c20477987eda0d3d02d310","term":{"name":"Y1","start_date":"2012-08-01","end_date":"2013-06-01"},"students":["530e5961049e75a9262cffbe","530e5961049e75a9262cffc3","530e5961049e75a9262d0000","530e5961049e75a9262d0036","530e5961049e75a9262d0074","530e5962049e75a9262d00c5","530e5963049e75a9262d01fa","530e5964049e75a9262d027e","530e5964049e75a9262d02a8","530e5964049e75a9262d02ab","530e5964049e75a9262d02f7","530e5965049e75a9262d03b2","530e5965049e75a9262d03bf","530e5966049e75a9262d040a","530e5966049e75a9262d0449","530e5967049e75a9262d051b","530e5967049e75a9262d0565","530e5968049e75a9262d05f0","530e5968049e75a9262d061e","530e5968049e75a9262d0623"],"last_modified":"2014-02-26T21:15:39.195Z","created":"2014-02-26T21:15:39.193Z","id":"530e597b049e75a9262d0c12"},"previous_attributes":{"subject":"homeroom/advisory"}},"created":"2014-08-28T18:01:14.088Z","id":"53ff6e6b322eced00200008e"},"uri":"/v1.1/events/53ff6e6b322eced00200008e"}],"paging":{"current":1,"total":1,"count":13},"links":[{"rel":"self","uri":"/v1.1/events"}]}'
60
+ Science, Class 003 - 003 - J. Stark","period":"4","school":"530e595026403103360ff9fe","sis_id":"866","subject":"science","teacher":"50c20477987eda0d3d02d310","term":{"name":"Y1","start_date":"2012-08-01","end_date":"2013-06-01"},"students":["530e5961049e75a9262cffbe","530e5961049e75a9262cffc3","530e5961049e75a9262d0000","530e5961049e75a9262d0036","530e5961049e75a9262d0074","530e5962049e75a9262d00c5","530e5963049e75a9262d01fa","530e5964049e75a9262d027e","530e5964049e75a9262d02a8","530e5964049e75a9262d02ab","530e5964049e75a9262d02f7","530e5965049e75a9262d03b2","530e5965049e75a9262d03bf","530e5966049e75a9262d040a","530e5966049e75a9262d0449","530e5967049e75a9262d051b","530e5967049e75a9262d0565","530e5968049e75a9262d05f0","530e5968049e75a9262d061e","530e5968049e75a9262d0623"],"last_modified":"2014-02-26T21:15:39.195Z","created":"2014-02-26T21:15:39.193Z","id":"530e597b049e75a9262d0c12"},"previous_attributes":{"subject":"homeroom/advisory"}},"created":"2014-08-28T18:01:14.088Z","id":"53ff6e6b322eced00200008e"},"uri":"/v1.1/events/53ff6e6b322eced00200008e"}],"paging":{"current":1,"total":1,"count":7},"links":[{"rel":"self","uri":"/v1.1/events"}]}'
67
61
  http_version:
68
- recorded_at: Tue, 09 Sep 2014 21:49:01 GMT
62
+ recorded_at: Fri, 12 Sep 2014 20:48:33 GMT
69
63
  - request:
70
64
  method: get
71
65
  uri: https://DEMO_KEY:@api.clever.com/v1.1/events?count=true
@@ -74,7 +68,7 @@ http_interactions:
74
68
  string: ''
75
69
  headers:
76
70
  Accept:
77
- - "*/*; q=0.5, application/xml"
71
+ - ! '*/*; q=0.5, application/xml'
78
72
  Accept-Encoding:
79
73
  - gzip, deflate
80
74
  User-Agent:
@@ -89,22 +83,22 @@ http_interactions:
89
83
  Access-Control-Allow-Methods:
90
84
  - GET,PATCH,POST,DELETE
91
85
  Access-Control-Allow-Origin:
92
- - "*"
86
+ - ! '*'
93
87
  Content-Type:
94
88
  - application/json; charset=utf-8
95
89
  Date:
96
- - Tue, 09 Sep 2014 21:49:01 GMT
90
+ - Fri, 12 Sep 2014 20:48:33 GMT
97
91
  Server:
98
92
  - nginx/1.4.7
99
93
  X-Powered-By:
100
94
  - Express
101
95
  Content-Length:
102
- - '69'
96
+ - '68'
103
97
  Connection:
104
98
  - keep-alive
105
99
  body:
106
- encoding: UTF-8
107
- string: '{"count":13,"links":[{"rel":"self","uri":"/v1.1/events?count=true"}]}'
100
+ encoding: US-ASCII
101
+ string: ! '{"count":7,"links":[{"rel":"self","uri":"/v1.1/events?count=true"}]}'
108
102
  http_version:
109
- recorded_at: Tue, 09 Sep 2014 21:49:01 GMT
103
+ recorded_at: Fri, 12 Sep 2014 20:48:33 GMT
110
104
  recorded_with: VCR 2.4.0
@@ -8,7 +8,7 @@ http_interactions:
8
8
  string: ''
9
9
  headers:
10
10
  Accept:
11
- - "*/*; q=0.5, application/xml"
11
+ - ! '*/*; q=0.5, application/xml'
12
12
  Accept-Encoding:
13
13
  - gzip, deflate
14
14
  User-Agent:
@@ -23,11 +23,11 @@ http_interactions:
23
23
  Access-Control-Allow-Methods:
24
24
  - GET,PATCH,POST,DELETE
25
25
  Access-Control-Allow-Origin:
26
- - "*"
26
+ - ! '*'
27
27
  Content-Type:
28
28
  - application/json; charset=utf-8
29
29
  Date:
30
- - Tue, 09 Sep 2014 21:48:50 GMT
30
+ - Fri, 12 Sep 2014 20:48:34 GMT
31
31
  Server:
32
32
  - nginx/1.4.7
33
33
  X-Powered-By:
@@ -37,8 +37,8 @@ http_interactions:
37
37
  Connection:
38
38
  - keep-alive
39
39
  body:
40
- encoding: UTF-8
41
- string: '{"count":3,"links":[{"rel":"self","uri":"/v1.1/schools?count=true"}]}'
40
+ encoding: US-ASCII
41
+ string: ! '{"count":3,"links":[{"rel":"self","uri":"/v1.1/schools?count=true"}]}'
42
42
  http_version:
43
- recorded_at: Tue, 09 Sep 2014 21:48:50 GMT
43
+ recorded_at: Fri, 12 Sep 2014 20:48:34 GMT
44
44
  recorded_with: VCR 2.4.0
@@ -0,0 +1,140 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: get
5
+ uri: https://DEMO_KEY:@api.clever.com/v1.1/schools
6
+ body:
7
+ encoding: US-ASCII
8
+ string: ''
9
+ headers:
10
+ Accept:
11
+ - ! '*/*; q=0.5, application/xml'
12
+ Accept-Encoding:
13
+ - gzip, deflate
14
+ User-Agent:
15
+ - Ruby
16
+ response:
17
+ status:
18
+ code: 200
19
+ message: OK
20
+ headers:
21
+ Access-Control-Allow-Headers:
22
+ - Content-Type,Authorization,X-Requested-With,Accept,Origin,Referer,User-Agent
23
+ Access-Control-Allow-Methods:
24
+ - GET,PATCH,POST,DELETE
25
+ Access-Control-Allow-Origin:
26
+ - ! '*'
27
+ Content-Type:
28
+ - application/json; charset=utf-8
29
+ Date:
30
+ - Fri, 12 Sep 2014 20:48:16 GMT
31
+ Etag:
32
+ - ! '"1408105812"'
33
+ Server:
34
+ - nginx/1.4.7
35
+ X-Powered-By:
36
+ - Express
37
+ Content-Length:
38
+ - '1764'
39
+ Connection:
40
+ - keep-alive
41
+ body:
42
+ encoding: US-ASCII
43
+ string: ! '{"data":[{"data":{"created":"2014-02-26T21:14:56.662Z","district":"4fd43cc56d11340000000005","high_grade":"12","last_modified":"2014-02-26T21:14:56.665Z","location":{"address":"350
44
+ 5th Avenue","city":"New York","state":"NY","zip":"10001"},"low_grade":"9","name":"Clever
45
+ High School","nces_id":"360008000000","phone":"(212) 555-1212","principal":{"name":"Theodora
46
+ Khan","email":"tdkhan@mailinator.com"},"school_number":"02M800","sis_id":"02M800","state_id":"712345","id":"530e595026403103360ff9fd"},"uri":"/v1.1/schools/530e595026403103360ff9fd"},{"data":{"created":"2014-02-26T21:14:56.668Z","district":"4fd43cc56d11340000000005","high_grade":"5","last_modified":"2014-02-26T21:14:56.670Z","location":{"address":"110
47
+ Pineapple Street","city":"Brooklyn","state":"NY","zip":"11201"},"low_grade":"Kindergarten","name":"Clever
48
+ Elementary School","nces_id":"360007000000","phone":"(718) 555-4567","principal":{"name":"Cecilia
49
+ Roderick","email":"ceciliar@mailinator.com"},"school_number":"13K123","sis_id":"13K123","state_id":"30890","id":"530e595026403103360ff9fe"},"uri":"/v1.1/schools/530e595026403103360ff9fe"},{"data":{"created":"2014-02-26T21:14:56.671Z","district":"4fd43cc56d11340000000005","high_grade":"8","last_modified":"2014-02-26T21:14:56.673Z","location":{"address":"322
50
+ Old Beach 88th Street","city":"Rockaway Beach","state":"NY","zip":"11693"},"low_grade":"6","name":"Clever
51
+ Middle School","nces_id":"360001000000","phone":"(718) 555-8989","principal":{"name":"Leonard
52
+ Springsteen","email":"lspringsteen@mailinator.com"},"school_number":"27Q321","sis_id":"27Q321","state_id":"412","id":"530e595026403103360ff9ff"},"uri":"/v1.1/schools/530e595026403103360ff9ff"}],"paging":{"current":1,"total":1,"count":3},"links":[{"rel":"self","uri":"/v1.1/schools"}]}'
53
+ http_version:
54
+ recorded_at: Fri, 12 Sep 2014 20:48:16 GMT
55
+ - request:
56
+ method: get
57
+ uri: https://DEMO_KEY:@api.clever.com/v1.1/schools/530e595026403103360ff9fd
58
+ body:
59
+ encoding: US-ASCII
60
+ string: ''
61
+ headers:
62
+ Accept:
63
+ - ! '*/*; q=0.5, application/xml'
64
+ Accept-Encoding:
65
+ - gzip, deflate
66
+ User-Agent:
67
+ - Ruby
68
+ response:
69
+ status:
70
+ code: 200
71
+ message: OK
72
+ headers:
73
+ Access-Control-Allow-Headers:
74
+ - Content-Type,Authorization,X-Requested-With,Accept,Origin,Referer,User-Agent
75
+ Access-Control-Allow-Methods:
76
+ - GET,PATCH,POST,DELETE
77
+ Access-Control-Allow-Origin:
78
+ - ! '*'
79
+ Content-Type:
80
+ - application/json; charset=utf-8
81
+ Date:
82
+ - Fri, 12 Sep 2014 20:48:17 GMT
83
+ Server:
84
+ - nginx/1.4.7
85
+ X-Powered-By:
86
+ - Express
87
+ Content-Length:
88
+ - '932'
89
+ Connection:
90
+ - keep-alive
91
+ body:
92
+ encoding: US-ASCII
93
+ string: ! '{"data":{"created":"2014-02-26T21:14:56.662Z","district":"4fd43cc56d11340000000005","high_grade":"12","last_modified":"2014-02-26T21:14:56.665Z","location":{"address":"350
94
+ 5th Avenue","city":"New York","state":"NY","zip":"10001"},"low_grade":"9","name":"Clever
95
+ High School","nces_id":"360008000000","phone":"(212) 555-1212","principal":{"name":"Theodora
96
+ Khan","email":"tdkhan@mailinator.com"},"school_number":"02M800","sis_id":"02M800","state_id":"712345","id":"530e595026403103360ff9fd"},"links":[{"rel":"self","uri":"/v1.1/schools/530e595026403103360ff9fd"},{"rel":"district","uri":"/v1.1/schools/530e595026403103360ff9fd/district"},{"rel":"teachers","uri":"/v1.1/schools/530e595026403103360ff9fd/teachers"},{"rel":"students","uri":"/v1.1/schools/530e595026403103360ff9fd/students"},{"rel":"sections","uri":"/v1.1/schools/530e595026403103360ff9fd/sections"},{"rel":"events","uri":"/v1.1/schools/530e595026403103360ff9fd/events"}]}'
97
+ http_version:
98
+ recorded_at: Fri, 12 Sep 2014 20:48:16 GMT
99
+ - request:
100
+ method: get
101
+ uri: https://DEMO_KEY:@api.clever.com//v1.1/schools/530e595026403103360ff9fd/district
102
+ body:
103
+ encoding: US-ASCII
104
+ string: ''
105
+ headers:
106
+ Accept:
107
+ - ! '*/*; q=0.5, application/xml'
108
+ Accept-Encoding:
109
+ - gzip, deflate
110
+ User-Agent:
111
+ - Ruby
112
+ response:
113
+ status:
114
+ code: 200
115
+ message: OK
116
+ headers:
117
+ Access-Control-Allow-Headers:
118
+ - Content-Type,Authorization,X-Requested-With,Accept,Origin,Referer,User-Agent
119
+ Access-Control-Allow-Methods:
120
+ - GET,PATCH,POST,DELETE
121
+ Access-Control-Allow-Origin:
122
+ - ! '*'
123
+ Content-Type:
124
+ - application/json; charset=utf-8
125
+ Date:
126
+ - Fri, 12 Sep 2014 20:48:17 GMT
127
+ Server:
128
+ - nginx/1.4.7
129
+ X-Powered-By:
130
+ - Express
131
+ Content-Length:
132
+ - '139'
133
+ Connection:
134
+ - keep-alive
135
+ body:
136
+ encoding: US-ASCII
137
+ string: ! '{"data":{"name":"Demo District","id":"4fd43cc56d11340000000005"},"links":[{"rel":"self","uri":"/v1.1/districts/4fd43cc56d11340000000005"}]}'
138
+ http_version:
139
+ recorded_at: Fri, 12 Sep 2014 20:48:17 GMT
140
+ recorded_with: VCR 2.4.0
@@ -0,0 +1,181 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: get
5
+ uri: https://DEMO_KEY:@api.clever.com/v1.1/schools
6
+ body:
7
+ encoding: US-ASCII
8
+ string: ''
9
+ headers:
10
+ Accept:
11
+ - ! '*/*; q=0.5, application/xml'
12
+ Accept-Encoding:
13
+ - gzip, deflate
14
+ User-Agent:
15
+ - Ruby
16
+ response:
17
+ status:
18
+ code: 200
19
+ message: OK
20
+ headers:
21
+ Access-Control-Allow-Headers:
22
+ - Content-Type,Authorization,X-Requested-With,Accept,Origin,Referer,User-Agent
23
+ Access-Control-Allow-Methods:
24
+ - GET,PATCH,POST,DELETE
25
+ Access-Control-Allow-Origin:
26
+ - ! '*'
27
+ Content-Type:
28
+ - application/json; charset=utf-8
29
+ Date:
30
+ - Fri, 12 Sep 2014 20:48:17 GMT
31
+ Etag:
32
+ - ! '"1408105812"'
33
+ Server:
34
+ - nginx/1.4.7
35
+ X-Powered-By:
36
+ - Express
37
+ Content-Length:
38
+ - '1764'
39
+ Connection:
40
+ - keep-alive
41
+ body:
42
+ encoding: US-ASCII
43
+ string: ! '{"data":[{"data":{"created":"2014-02-26T21:14:56.662Z","district":"4fd43cc56d11340000000005","high_grade":"12","last_modified":"2014-02-26T21:14:56.665Z","location":{"address":"350
44
+ 5th Avenue","city":"New York","state":"NY","zip":"10001"},"low_grade":"9","name":"Clever
45
+ High School","nces_id":"360008000000","phone":"(212) 555-1212","principal":{"name":"Theodora
46
+ Khan","email":"tdkhan@mailinator.com"},"school_number":"02M800","sis_id":"02M800","state_id":"712345","id":"530e595026403103360ff9fd"},"uri":"/v1.1/schools/530e595026403103360ff9fd"},{"data":{"created":"2014-02-26T21:14:56.668Z","district":"4fd43cc56d11340000000005","high_grade":"5","last_modified":"2014-02-26T21:14:56.670Z","location":{"address":"110
47
+ Pineapple Street","city":"Brooklyn","state":"NY","zip":"11201"},"low_grade":"Kindergarten","name":"Clever
48
+ Elementary School","nces_id":"360007000000","phone":"(718) 555-4567","principal":{"name":"Cecilia
49
+ Roderick","email":"ceciliar@mailinator.com"},"school_number":"13K123","sis_id":"13K123","state_id":"30890","id":"530e595026403103360ff9fe"},"uri":"/v1.1/schools/530e595026403103360ff9fe"},{"data":{"created":"2014-02-26T21:14:56.671Z","district":"4fd43cc56d11340000000005","high_grade":"8","last_modified":"2014-02-26T21:14:56.673Z","location":{"address":"322
50
+ Old Beach 88th Street","city":"Rockaway Beach","state":"NY","zip":"11693"},"low_grade":"6","name":"Clever
51
+ Middle School","nces_id":"360001000000","phone":"(718) 555-8989","principal":{"name":"Leonard
52
+ Springsteen","email":"lspringsteen@mailinator.com"},"school_number":"27Q321","sis_id":"27Q321","state_id":"412","id":"530e595026403103360ff9ff"},"uri":"/v1.1/schools/530e595026403103360ff9ff"}],"paging":{"current":1,"total":1,"count":3},"links":[{"rel":"self","uri":"/v1.1/schools"}]}'
53
+ http_version:
54
+ recorded_at: Fri, 12 Sep 2014 20:48:17 GMT
55
+ - request:
56
+ method: get
57
+ uri: https://DEMO_KEY:@api.clever.com/v1.1/schools/530e595026403103360ff9fd
58
+ body:
59
+ encoding: US-ASCII
60
+ string: ''
61
+ headers:
62
+ Accept:
63
+ - ! '*/*; q=0.5, application/xml'
64
+ Accept-Encoding:
65
+ - gzip, deflate
66
+ User-Agent:
67
+ - Ruby
68
+ response:
69
+ status:
70
+ code: 200
71
+ message: OK
72
+ headers:
73
+ Access-Control-Allow-Headers:
74
+ - Content-Type,Authorization,X-Requested-With,Accept,Origin,Referer,User-Agent
75
+ Access-Control-Allow-Methods:
76
+ - GET,PATCH,POST,DELETE
77
+ Access-Control-Allow-Origin:
78
+ - ! '*'
79
+ Content-Type:
80
+ - application/json; charset=utf-8
81
+ Date:
82
+ - Fri, 12 Sep 2014 20:48:17 GMT
83
+ Server:
84
+ - nginx/1.4.7
85
+ X-Powered-By:
86
+ - Express
87
+ Content-Length:
88
+ - '932'
89
+ Connection:
90
+ - keep-alive
91
+ body:
92
+ encoding: US-ASCII
93
+ string: ! '{"data":{"created":"2014-02-26T21:14:56.662Z","district":"4fd43cc56d11340000000005","high_grade":"12","last_modified":"2014-02-26T21:14:56.665Z","location":{"address":"350
94
+ 5th Avenue","city":"New York","state":"NY","zip":"10001"},"low_grade":"9","name":"Clever
95
+ High School","nces_id":"360008000000","phone":"(212) 555-1212","principal":{"name":"Theodora
96
+ Khan","email":"tdkhan@mailinator.com"},"school_number":"02M800","sis_id":"02M800","state_id":"712345","id":"530e595026403103360ff9fd"},"links":[{"rel":"self","uri":"/v1.1/schools/530e595026403103360ff9fd"},{"rel":"district","uri":"/v1.1/schools/530e595026403103360ff9fd/district"},{"rel":"teachers","uri":"/v1.1/schools/530e595026403103360ff9fd/teachers"},{"rel":"students","uri":"/v1.1/schools/530e595026403103360ff9fd/students"},{"rel":"sections","uri":"/v1.1/schools/530e595026403103360ff9fd/sections"},{"rel":"events","uri":"/v1.1/schools/530e595026403103360ff9fd/events"}]}'
97
+ http_version:
98
+ recorded_at: Fri, 12 Sep 2014 20:48:17 GMT
99
+ - request:
100
+ method: get
101
+ uri: https://DEMO_KEY:@api.clever.com//v1.1/schools/530e595026403103360ff9fd/events
102
+ body:
103
+ encoding: US-ASCII
104
+ string: ''
105
+ headers:
106
+ Accept:
107
+ - ! '*/*; q=0.5, application/xml'
108
+ Accept-Encoding:
109
+ - gzip, deflate
110
+ User-Agent:
111
+ - Ruby
112
+ response:
113
+ status:
114
+ code: 200
115
+ message: OK
116
+ headers:
117
+ Access-Control-Allow-Headers:
118
+ - Content-Type,Authorization,X-Requested-With,Accept,Origin,Referer,User-Agent
119
+ Access-Control-Allow-Methods:
120
+ - GET,PATCH,POST,DELETE
121
+ Access-Control-Allow-Origin:
122
+ - ! '*'
123
+ Content-Type:
124
+ - application/json; charset=utf-8
125
+ Date:
126
+ - Fri, 12 Sep 2014 20:48:17 GMT
127
+ Server:
128
+ - nginx/1.4.7
129
+ X-Powered-By:
130
+ - Express
131
+ Content-Length:
132
+ - '133'
133
+ Connection:
134
+ - keep-alive
135
+ body:
136
+ encoding: US-ASCII
137
+ string: ! '{"data":[],"paging":{"current":0,"total":0,"count":0},"links":[{"rel":"self","uri":"/v1.1/schools/530e595026403103360ff9fd/events"}]}'
138
+ http_version:
139
+ recorded_at: Fri, 12 Sep 2014 20:48:17 GMT
140
+ - request:
141
+ method: get
142
+ uri: https://DEMO_KEY:@api.clever.com//v1.1/schools/530e595026403103360ff9fd/events
143
+ body:
144
+ encoding: US-ASCII
145
+ string: ''
146
+ headers:
147
+ Accept:
148
+ - ! '*/*; q=0.5, application/xml'
149
+ Accept-Encoding:
150
+ - gzip, deflate
151
+ User-Agent:
152
+ - Ruby
153
+ response:
154
+ status:
155
+ code: 200
156
+ message: OK
157
+ headers:
158
+ Access-Control-Allow-Headers:
159
+ - Content-Type,Authorization,X-Requested-With,Accept,Origin,Referer,User-Agent
160
+ Access-Control-Allow-Methods:
161
+ - GET,PATCH,POST,DELETE
162
+ Access-Control-Allow-Origin:
163
+ - ! '*'
164
+ Content-Type:
165
+ - application/json; charset=utf-8
166
+ Date:
167
+ - Fri, 12 Sep 2014 20:48:17 GMT
168
+ Server:
169
+ - nginx/1.4.7
170
+ X-Powered-By:
171
+ - Express
172
+ Content-Length:
173
+ - '133'
174
+ Connection:
175
+ - keep-alive
176
+ body:
177
+ encoding: US-ASCII
178
+ string: ! '{"data":[],"paging":{"current":0,"total":0,"count":0},"links":[{"rel":"self","uri":"/v1.1/schools/530e595026403103360ff9fd/events"}]}'
179
+ http_version:
180
+ recorded_at: Fri, 12 Sep 2014 20:48:17 GMT
181
+ recorded_with: VCR 2.4.0