@easyedu/js-lsm-api 1.90.0 → 1.92.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.
Files changed (241) hide show
  1. package/.openapi-generator/FILES +70 -0
  2. package/README.md +65 -2
  3. package/dist/apis/ContentLibraryQuizApi.d.ts +451 -0
  4. package/dist/apis/ContentLibraryQuizApi.js +1162 -0
  5. package/dist/apis/PlayerApi.d.ts +130 -1
  6. package/dist/apis/PlayerApi.js +257 -1
  7. package/dist/apis/index.d.ts +1 -0
  8. package/dist/apis/index.js +1 -0
  9. package/dist/esm/apis/ContentLibraryQuizApi.d.ts +451 -0
  10. package/dist/esm/apis/ContentLibraryQuizApi.js +1158 -0
  11. package/dist/esm/apis/PlayerApi.d.ts +130 -1
  12. package/dist/esm/apis/PlayerApi.js +256 -0
  13. package/dist/esm/apis/index.d.ts +1 -0
  14. package/dist/esm/apis/index.js +1 -0
  15. package/dist/esm/models/GetCourseVersionItem.d.ts +14 -0
  16. package/dist/esm/models/GetCourseVersionItem.js +9 -0
  17. package/dist/esm/models/GetLibraryQuiz.d.ts +124 -0
  18. package/dist/esm/models/GetLibraryQuiz.js +100 -0
  19. package/dist/esm/models/GetLibraryQuizAnalytics.d.ts +68 -0
  20. package/dist/esm/models/GetLibraryQuizAnalytics.js +67 -0
  21. package/dist/esm/models/GetLibraryQuizList.d.ts +57 -0
  22. package/dist/esm/models/GetLibraryQuizList.js +60 -0
  23. package/dist/esm/models/GetLibraryQuizResult.d.ts +94 -0
  24. package/dist/esm/models/GetLibraryQuizResult.js +79 -0
  25. package/dist/esm/models/GetLibraryQuizSession.d.ts +177 -0
  26. package/dist/esm/models/GetLibraryQuizSession.js +129 -0
  27. package/dist/esm/models/GetLibraryQuizSessionList.d.ts +57 -0
  28. package/dist/esm/models/GetLibraryQuizSessionList.js +60 -0
  29. package/dist/esm/models/GetLibraryQuizUsage.d.ts +56 -0
  30. package/dist/esm/models/GetLibraryQuizUsage.js +59 -0
  31. package/dist/esm/models/GetLibraryQuizVersion.d.ts +170 -0
  32. package/dist/esm/models/GetLibraryQuizVersion.js +125 -0
  33. package/dist/esm/models/GetResourceSession.d.ts +30 -0
  34. package/dist/esm/models/GetResourceSession.js +16 -0
  35. package/dist/esm/models/GetResourceSessionDiagnostics.d.ts +76 -0
  36. package/dist/esm/models/GetResourceSessionDiagnostics.js +69 -0
  37. package/dist/esm/models/GetResourceSessionDiagnosticsCourseContext.d.ts +81 -0
  38. package/dist/esm/models/GetResourceSessionDiagnosticsCourseContext.js +76 -0
  39. package/dist/esm/models/GetResourceSessionDiagnosticsResource.d.ts +51 -0
  40. package/dist/esm/models/GetResourceSessionDiagnosticsResource.js +56 -0
  41. package/dist/esm/models/GetResourceSessionDiagnosticsScormSummary.d.ts +74 -0
  42. package/dist/esm/models/GetResourceSessionDiagnosticsScormSummary.js +59 -0
  43. package/dist/esm/models/GetResourceSessionDiagnosticsUser.d.ts +38 -0
  44. package/dist/esm/models/GetResourceSessionDiagnosticsUser.js +47 -0
  45. package/dist/esm/models/GetResourceSessionDiagnosticsVersion.d.ts +88 -0
  46. package/dist/esm/models/GetResourceSessionDiagnosticsVersion.js +67 -0
  47. package/dist/esm/models/GetResourceSessionScormApiLogs.d.ts +57 -0
  48. package/dist/esm/models/GetResourceSessionScormApiLogs.js +60 -0
  49. package/dist/esm/models/GetResourceSessionScormData.d.ts +77 -0
  50. package/dist/esm/models/GetResourceSessionScormData.js +66 -0
  51. package/dist/esm/models/GetResourceSessionScormDataActivity.d.ts +44 -0
  52. package/dist/esm/models/GetResourceSessionScormDataActivity.js +45 -0
  53. package/dist/esm/models/LibraryQuizCriterion.d.ts +95 -0
  54. package/dist/esm/models/LibraryQuizCriterion.js +76 -0
  55. package/dist/esm/models/LibraryQuizQuestion.d.ts +70 -0
  56. package/dist/esm/models/LibraryQuizQuestion.js +63 -0
  57. package/dist/esm/models/LibraryQuizQuestionInput.d.ts +50 -0
  58. package/dist/esm/models/LibraryQuizQuestionInput.js +51 -0
  59. package/dist/esm/models/LibraryQuizSessionAnswerChoice.d.ts +51 -0
  60. package/dist/esm/models/LibraryQuizSessionAnswerChoice.js +54 -0
  61. package/dist/esm/models/LibraryQuizSessionQuestion.d.ts +96 -0
  62. package/dist/esm/models/LibraryQuizSessionQuestion.js +84 -0
  63. package/dist/esm/models/PostCourseLibraryQuizSession.d.ts +32 -0
  64. package/dist/esm/models/PostCourseLibraryQuizSession.js +41 -0
  65. package/dist/esm/models/PostLibraryQuiz.d.ts +107 -0
  66. package/dist/esm/models/PostLibraryQuiz.js +70 -0
  67. package/dist/esm/models/PostLibraryQuizSession.d.ts +32 -0
  68. package/dist/esm/models/PostLibraryQuizSession.js +41 -0
  69. package/dist/esm/models/PostLibraryQuizVersion.d.ts +32 -0
  70. package/dist/esm/models/PostLibraryQuizVersion.js +41 -0
  71. package/dist/esm/models/PutLibraryQuiz.d.ts +38 -0
  72. package/dist/esm/models/PutLibraryQuiz.js +43 -0
  73. package/dist/esm/models/PutLibraryQuizCriteria.d.ts +33 -0
  74. package/dist/esm/models/PutLibraryQuizCriteria.js +44 -0
  75. package/dist/esm/models/PutLibraryQuizQuestions.d.ts +33 -0
  76. package/dist/esm/models/PutLibraryQuizQuestions.js +44 -0
  77. package/dist/esm/models/PutLibraryQuizSessionAnswer.d.ts +40 -0
  78. package/dist/esm/models/PutLibraryQuizSessionAnswer.js +45 -0
  79. package/dist/esm/models/PutLibraryQuizSessionGrade.d.ts +38 -0
  80. package/dist/esm/models/PutLibraryQuizSessionGrade.js +45 -0
  81. package/dist/esm/models/PutLibraryQuizVersion.d.ts +101 -0
  82. package/dist/esm/models/PutLibraryQuizVersion.js +64 -0
  83. package/dist/esm/models/QuestionSelectionMethod.d.ts +25 -0
  84. package/dist/esm/models/QuestionSelectionMethod.js +43 -0
  85. package/dist/esm/models/ResourceSessionScormApiLogItem.d.ts +79 -0
  86. package/dist/esm/models/ResourceSessionScormApiLogItem.js +73 -0
  87. package/dist/esm/models/index.d.ts +34 -0
  88. package/dist/esm/models/index.js +34 -0
  89. package/dist/models/GetCourseVersionItem.d.ts +14 -0
  90. package/dist/models/GetCourseVersionItem.js +10 -1
  91. package/dist/models/GetLibraryQuiz.d.ts +124 -0
  92. package/dist/models/GetLibraryQuiz.js +108 -0
  93. package/dist/models/GetLibraryQuizAnalytics.d.ts +68 -0
  94. package/dist/models/GetLibraryQuizAnalytics.js +74 -0
  95. package/dist/models/GetLibraryQuizList.d.ts +57 -0
  96. package/dist/models/GetLibraryQuizList.js +67 -0
  97. package/dist/models/GetLibraryQuizResult.d.ts +94 -0
  98. package/dist/models/GetLibraryQuizResult.js +86 -0
  99. package/dist/models/GetLibraryQuizSession.d.ts +177 -0
  100. package/dist/models/GetLibraryQuizSession.js +137 -0
  101. package/dist/models/GetLibraryQuizSessionList.d.ts +57 -0
  102. package/dist/models/GetLibraryQuizSessionList.js +67 -0
  103. package/dist/models/GetLibraryQuizUsage.d.ts +56 -0
  104. package/dist/models/GetLibraryQuizUsage.js +66 -0
  105. package/dist/models/GetLibraryQuizVersion.d.ts +170 -0
  106. package/dist/models/GetLibraryQuizVersion.js +132 -0
  107. package/dist/models/GetResourceSession.d.ts +30 -0
  108. package/dist/models/GetResourceSession.js +16 -0
  109. package/dist/models/GetResourceSessionDiagnostics.d.ts +76 -0
  110. package/dist/models/GetResourceSessionDiagnostics.js +76 -0
  111. package/dist/models/GetResourceSessionDiagnosticsCourseContext.d.ts +81 -0
  112. package/dist/models/GetResourceSessionDiagnosticsCourseContext.js +83 -0
  113. package/dist/models/GetResourceSessionDiagnosticsResource.d.ts +51 -0
  114. package/dist/models/GetResourceSessionDiagnosticsResource.js +63 -0
  115. package/dist/models/GetResourceSessionDiagnosticsScormSummary.d.ts +74 -0
  116. package/dist/models/GetResourceSessionDiagnosticsScormSummary.js +66 -0
  117. package/dist/models/GetResourceSessionDiagnosticsUser.d.ts +38 -0
  118. package/dist/models/GetResourceSessionDiagnosticsUser.js +54 -0
  119. package/dist/models/GetResourceSessionDiagnosticsVersion.d.ts +88 -0
  120. package/dist/models/GetResourceSessionDiagnosticsVersion.js +74 -0
  121. package/dist/models/GetResourceSessionScormApiLogs.d.ts +57 -0
  122. package/dist/models/GetResourceSessionScormApiLogs.js +67 -0
  123. package/dist/models/GetResourceSessionScormData.d.ts +77 -0
  124. package/dist/models/GetResourceSessionScormData.js +73 -0
  125. package/dist/models/GetResourceSessionScormDataActivity.d.ts +44 -0
  126. package/dist/models/GetResourceSessionScormDataActivity.js +52 -0
  127. package/dist/models/LibraryQuizCriterion.d.ts +95 -0
  128. package/dist/models/LibraryQuizCriterion.js +84 -0
  129. package/dist/models/LibraryQuizQuestion.d.ts +70 -0
  130. package/dist/models/LibraryQuizQuestion.js +70 -0
  131. package/dist/models/LibraryQuizQuestionInput.d.ts +50 -0
  132. package/dist/models/LibraryQuizQuestionInput.js +58 -0
  133. package/dist/models/LibraryQuizSessionAnswerChoice.d.ts +51 -0
  134. package/dist/models/LibraryQuizSessionAnswerChoice.js +61 -0
  135. package/dist/models/LibraryQuizSessionQuestion.d.ts +96 -0
  136. package/dist/models/LibraryQuizSessionQuestion.js +92 -0
  137. package/dist/models/PostCourseLibraryQuizSession.d.ts +32 -0
  138. package/dist/models/PostCourseLibraryQuizSession.js +48 -0
  139. package/dist/models/PostLibraryQuiz.d.ts +107 -0
  140. package/dist/models/PostLibraryQuiz.js +77 -0
  141. package/dist/models/PostLibraryQuizSession.d.ts +32 -0
  142. package/dist/models/PostLibraryQuizSession.js +48 -0
  143. package/dist/models/PostLibraryQuizVersion.d.ts +32 -0
  144. package/dist/models/PostLibraryQuizVersion.js +48 -0
  145. package/dist/models/PutLibraryQuiz.d.ts +38 -0
  146. package/dist/models/PutLibraryQuiz.js +50 -0
  147. package/dist/models/PutLibraryQuizCriteria.d.ts +33 -0
  148. package/dist/models/PutLibraryQuizCriteria.js +51 -0
  149. package/dist/models/PutLibraryQuizQuestions.d.ts +33 -0
  150. package/dist/models/PutLibraryQuizQuestions.js +51 -0
  151. package/dist/models/PutLibraryQuizSessionAnswer.d.ts +40 -0
  152. package/dist/models/PutLibraryQuizSessionAnswer.js +52 -0
  153. package/dist/models/PutLibraryQuizSessionGrade.d.ts +38 -0
  154. package/dist/models/PutLibraryQuizSessionGrade.js +52 -0
  155. package/dist/models/PutLibraryQuizVersion.d.ts +101 -0
  156. package/dist/models/PutLibraryQuizVersion.js +71 -0
  157. package/dist/models/QuestionSelectionMethod.d.ts +25 -0
  158. package/dist/models/QuestionSelectionMethod.js +51 -0
  159. package/dist/models/ResourceSessionScormApiLogItem.d.ts +79 -0
  160. package/dist/models/ResourceSessionScormApiLogItem.js +81 -0
  161. package/dist/models/index.d.ts +34 -0
  162. package/dist/models/index.js +34 -0
  163. package/docs/ContentLibraryQuizApi.md +1780 -0
  164. package/docs/GetCourseVersionItem.md +2 -0
  165. package/docs/GetLibraryQuiz.md +62 -0
  166. package/docs/GetLibraryQuizAnalytics.md +46 -0
  167. package/docs/GetLibraryQuizList.md +42 -0
  168. package/docs/GetLibraryQuizResult.md +54 -0
  169. package/docs/GetLibraryQuizSession.md +78 -0
  170. package/docs/GetLibraryQuizSessionList.md +42 -0
  171. package/docs/GetLibraryQuizUsage.md +42 -0
  172. package/docs/GetLibraryQuizVersion.md +78 -0
  173. package/docs/GetResourceSession.md +10 -0
  174. package/docs/GetResourceSessionDiagnostics.md +47 -0
  175. package/docs/GetResourceSessionDiagnosticsCourseContext.md +50 -0
  176. package/docs/GetResourceSessionDiagnosticsResource.md +40 -0
  177. package/docs/GetResourceSessionDiagnosticsScormSummary.md +48 -0
  178. package/docs/GetResourceSessionDiagnosticsUser.md +36 -0
  179. package/docs/GetResourceSessionDiagnosticsVersion.md +52 -0
  180. package/docs/GetResourceSessionScormApiLogs.md +43 -0
  181. package/docs/GetResourceSessionScormData.md +49 -0
  182. package/docs/GetResourceSessionScormDataActivity.md +38 -0
  183. package/docs/LibraryQuizCriterion.md +48 -0
  184. package/docs/LibraryQuizQuestion.md +46 -0
  185. package/docs/LibraryQuizQuestionInput.md +40 -0
  186. package/docs/LibraryQuizSessionAnswerChoice.md +40 -0
  187. package/docs/LibraryQuizSessionQuestion.md +50 -0
  188. package/docs/PlayerApi.md +320 -3
  189. package/docs/PostCourseLibraryQuizSession.md +34 -0
  190. package/docs/PostLibraryQuiz.md +58 -0
  191. package/docs/PostLibraryQuizSession.md +34 -0
  192. package/docs/PostLibraryQuizVersion.md +34 -0
  193. package/docs/PutLibraryQuiz.md +36 -0
  194. package/docs/PutLibraryQuizCriteria.md +34 -0
  195. package/docs/PutLibraryQuizQuestions.md +34 -0
  196. package/docs/PutLibraryQuizSessionAnswer.md +36 -0
  197. package/docs/PutLibraryQuizSessionGrade.md +36 -0
  198. package/docs/PutLibraryQuizVersion.md +56 -0
  199. package/docs/QuestionSelectionMethod.md +32 -0
  200. package/docs/ResourceSessionScormApiLogItem.md +47 -0
  201. package/package.json +1 -1
  202. package/src/apis/ContentLibraryQuizApi.ts +1624 -0
  203. package/src/apis/PlayerApi.ts +351 -1
  204. package/src/apis/index.ts +1 -0
  205. package/src/models/GetCourseVersionItem.ts +17 -0
  206. package/src/models/GetLibraryQuiz.ts +207 -0
  207. package/src/models/GetLibraryQuizAnalytics.ts +120 -0
  208. package/src/models/GetLibraryQuizList.ts +110 -0
  209. package/src/models/GetLibraryQuizResult.ts +154 -0
  210. package/src/models/GetLibraryQuizSession.ts +286 -0
  211. package/src/models/GetLibraryQuizSessionList.ts +110 -0
  212. package/src/models/GetLibraryQuizUsage.ts +102 -0
  213. package/src/models/GetLibraryQuizVersion.ts +290 -0
  214. package/src/models/GetResourceSession.ts +43 -0
  215. package/src/models/GetResourceSessionDiagnostics.ts +161 -0
  216. package/src/models/GetResourceSessionDiagnosticsCourseContext.ts +148 -0
  217. package/src/models/GetResourceSessionDiagnosticsResource.ts +103 -0
  218. package/src/models/GetResourceSessionDiagnosticsScormSummary.ts +123 -0
  219. package/src/models/GetResourceSessionDiagnosticsUser.ts +75 -0
  220. package/src/models/GetResourceSessionDiagnosticsVersion.ts +141 -0
  221. package/src/models/GetResourceSessionScormApiLogs.ts +110 -0
  222. package/src/models/GetResourceSessionScormData.ts +134 -0
  223. package/src/models/GetResourceSessionScormDataActivity.ts +81 -0
  224. package/src/models/LibraryQuizCriterion.ts +147 -0
  225. package/src/models/LibraryQuizQuestion.ts +118 -0
  226. package/src/models/LibraryQuizQuestionInput.ts +91 -0
  227. package/src/models/LibraryQuizSessionAnswerChoice.ts +100 -0
  228. package/src/models/LibraryQuizSessionQuestion.ts +166 -0
  229. package/src/models/PostCourseLibraryQuizSession.ts +65 -0
  230. package/src/models/PostLibraryQuiz.ts +173 -0
  231. package/src/models/PostLibraryQuizSession.ts +65 -0
  232. package/src/models/PostLibraryQuizVersion.ts +65 -0
  233. package/src/models/PutLibraryQuiz.ts +73 -0
  234. package/src/models/PutLibraryQuizCriteria.ts +74 -0
  235. package/src/models/PutLibraryQuizQuestions.ts +74 -0
  236. package/src/models/PutLibraryQuizSessionAnswer.ts +74 -0
  237. package/src/models/PutLibraryQuizSessionGrade.ts +74 -0
  238. package/src/models/PutLibraryQuizVersion.ts +163 -0
  239. package/src/models/QuestionSelectionMethod.ts +53 -0
  240. package/src/models/ResourceSessionScormApiLogItem.ts +132 -0
  241. package/src/models/index.ts +34 -0
@@ -0,0 +1,118 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * LMS API
5
+ * LMS API
6
+ *
7
+ * The version of the OpenAPI document: 1.0.0
8
+ *
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+
15
+ import { mapValues } from '../runtime';
16
+ /**
17
+ *
18
+ * @export
19
+ * @interface LibraryQuizQuestion
20
+ */
21
+ export interface LibraryQuizQuestion {
22
+ /**
23
+ *
24
+ * @type {string}
25
+ * @memberof LibraryQuizQuestion
26
+ */
27
+ id: string;
28
+ /**
29
+ *
30
+ * @type {string}
31
+ * @memberof LibraryQuizQuestion
32
+ */
33
+ questionId: string;
34
+ /**
35
+ *
36
+ * @type {string}
37
+ * @memberof LibraryQuizQuestion
38
+ */
39
+ questionGroupId?: string | null;
40
+ /**
41
+ *
42
+ * @type {number}
43
+ * @memberof LibraryQuizQuestion
44
+ */
45
+ displayOrder: number;
46
+ /**
47
+ *
48
+ * @type {number}
49
+ * @memberof LibraryQuizQuestion
50
+ */
51
+ points: number;
52
+ /**
53
+ *
54
+ * @type {boolean}
55
+ * @memberof LibraryQuizQuestion
56
+ */
57
+ versionLocked: boolean;
58
+ /**
59
+ *
60
+ * @type {{ [key: string]: any; }}
61
+ * @memberof LibraryQuizQuestion
62
+ */
63
+ snapshot?: { [key: string]: any; } | null;
64
+ }
65
+
66
+ /**
67
+ * Check if a given object implements the LibraryQuizQuestion interface.
68
+ */
69
+ export function instanceOfLibraryQuizQuestion(value: object): value is LibraryQuizQuestion {
70
+ if (!('id' in value) || value['id'] === undefined) return false;
71
+ if (!('questionId' in value) || value['questionId'] === undefined) return false;
72
+ if (!('displayOrder' in value) || value['displayOrder'] === undefined) return false;
73
+ if (!('points' in value) || value['points'] === undefined) return false;
74
+ if (!('versionLocked' in value) || value['versionLocked'] === undefined) return false;
75
+ return true;
76
+ }
77
+
78
+ export function LibraryQuizQuestionFromJSON(json: any): LibraryQuizQuestion {
79
+ return LibraryQuizQuestionFromJSONTyped(json, false);
80
+ }
81
+
82
+ export function LibraryQuizQuestionFromJSONTyped(json: any, ignoreDiscriminator: boolean): LibraryQuizQuestion {
83
+ if (json == null) {
84
+ return json;
85
+ }
86
+ return {
87
+
88
+ 'id': json['id'],
89
+ 'questionId': json['question_id'],
90
+ 'questionGroupId': json['question_group_id'] == null ? undefined : json['question_group_id'],
91
+ 'displayOrder': json['display_order'],
92
+ 'points': json['points'],
93
+ 'versionLocked': json['version_locked'],
94
+ 'snapshot': json['snapshot'] == null ? undefined : json['snapshot'],
95
+ };
96
+ }
97
+
98
+ export function LibraryQuizQuestionToJSON(json: any): LibraryQuizQuestion {
99
+ return LibraryQuizQuestionToJSONTyped(json, false);
100
+ }
101
+
102
+ export function LibraryQuizQuestionToJSONTyped(value?: LibraryQuizQuestion | null, ignoreDiscriminator: boolean = false): any {
103
+ if (value == null) {
104
+ return value;
105
+ }
106
+
107
+ return {
108
+
109
+ 'id': value['id'],
110
+ 'question_id': value['questionId'],
111
+ 'question_group_id': value['questionGroupId'],
112
+ 'display_order': value['displayOrder'],
113
+ 'points': value['points'],
114
+ 'version_locked': value['versionLocked'],
115
+ 'snapshot': value['snapshot'],
116
+ };
117
+ }
118
+
@@ -0,0 +1,91 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * LMS API
5
+ * LMS API
6
+ *
7
+ * The version of the OpenAPI document: 1.0.0
8
+ *
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+
15
+ import { mapValues } from '../runtime';
16
+ /**
17
+ *
18
+ * @export
19
+ * @interface LibraryQuizQuestionInput
20
+ */
21
+ export interface LibraryQuizQuestionInput {
22
+ /**
23
+ * External ID of the selected question version.
24
+ * @type {string}
25
+ * @memberof LibraryQuizQuestionInput
26
+ */
27
+ questionId: string;
28
+ /**
29
+ *
30
+ * @type {number}
31
+ * @memberof LibraryQuizQuestionInput
32
+ */
33
+ displayOrder: number;
34
+ /**
35
+ *
36
+ * @type {number}
37
+ * @memberof LibraryQuizQuestionInput
38
+ */
39
+ points?: number;
40
+ /**
41
+ * When false, publication resolves the latest question in the same version group.
42
+ * @type {boolean}
43
+ * @memberof LibraryQuizQuestionInput
44
+ */
45
+ versionLocked?: boolean;
46
+ }
47
+
48
+ /**
49
+ * Check if a given object implements the LibraryQuizQuestionInput interface.
50
+ */
51
+ export function instanceOfLibraryQuizQuestionInput(value: object): value is LibraryQuizQuestionInput {
52
+ if (!('questionId' in value) || value['questionId'] === undefined) return false;
53
+ if (!('displayOrder' in value) || value['displayOrder'] === undefined) return false;
54
+ return true;
55
+ }
56
+
57
+ export function LibraryQuizQuestionInputFromJSON(json: any): LibraryQuizQuestionInput {
58
+ return LibraryQuizQuestionInputFromJSONTyped(json, false);
59
+ }
60
+
61
+ export function LibraryQuizQuestionInputFromJSONTyped(json: any, ignoreDiscriminator: boolean): LibraryQuizQuestionInput {
62
+ if (json == null) {
63
+ return json;
64
+ }
65
+ return {
66
+
67
+ 'questionId': json['question_id'],
68
+ 'displayOrder': json['display_order'],
69
+ 'points': json['points'] == null ? undefined : json['points'],
70
+ 'versionLocked': json['version_locked'] == null ? undefined : json['version_locked'],
71
+ };
72
+ }
73
+
74
+ export function LibraryQuizQuestionInputToJSON(json: any): LibraryQuizQuestionInput {
75
+ return LibraryQuizQuestionInputToJSONTyped(json, false);
76
+ }
77
+
78
+ export function LibraryQuizQuestionInputToJSONTyped(value?: LibraryQuizQuestionInput | null, ignoreDiscriminator: boolean = false): any {
79
+ if (value == null) {
80
+ return value;
81
+ }
82
+
83
+ return {
84
+
85
+ 'question_id': value['questionId'],
86
+ 'display_order': value['displayOrder'],
87
+ 'points': value['points'],
88
+ 'version_locked': value['versionLocked'],
89
+ };
90
+ }
91
+
@@ -0,0 +1,100 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * LMS API
5
+ * LMS API
6
+ *
7
+ * The version of the OpenAPI document: 1.0.0
8
+ *
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+
15
+ import { mapValues } from '../runtime';
16
+ import type { RichTextDocument } from './RichTextDocument';
17
+ import {
18
+ RichTextDocumentFromJSON,
19
+ RichTextDocumentFromJSONTyped,
20
+ RichTextDocumentToJSON,
21
+ RichTextDocumentToJSONTyped,
22
+ } from './RichTextDocument';
23
+
24
+ /**
25
+ *
26
+ * @export
27
+ * @interface LibraryQuizSessionAnswerChoice
28
+ */
29
+ export interface LibraryQuizSessionAnswerChoice {
30
+ /**
31
+ *
32
+ * @type {string}
33
+ * @memberof LibraryQuizSessionAnswerChoice
34
+ */
35
+ id: string;
36
+ /**
37
+ *
38
+ * @type {string}
39
+ * @memberof LibraryQuizSessionAnswerChoice
40
+ */
41
+ text: string;
42
+ /**
43
+ *
44
+ * @type {RichTextDocument}
45
+ * @memberof LibraryQuizSessionAnswerChoice
46
+ */
47
+ textRich?: RichTextDocument | null;
48
+ /**
49
+ *
50
+ * @type {number}
51
+ * @memberof LibraryQuizSessionAnswerChoice
52
+ */
53
+ displayOrder: number;
54
+ }
55
+
56
+ /**
57
+ * Check if a given object implements the LibraryQuizSessionAnswerChoice interface.
58
+ */
59
+ export function instanceOfLibraryQuizSessionAnswerChoice(value: object): value is LibraryQuizSessionAnswerChoice {
60
+ if (!('id' in value) || value['id'] === undefined) return false;
61
+ if (!('text' in value) || value['text'] === undefined) return false;
62
+ if (!('displayOrder' in value) || value['displayOrder'] === undefined) return false;
63
+ return true;
64
+ }
65
+
66
+ export function LibraryQuizSessionAnswerChoiceFromJSON(json: any): LibraryQuizSessionAnswerChoice {
67
+ return LibraryQuizSessionAnswerChoiceFromJSONTyped(json, false);
68
+ }
69
+
70
+ export function LibraryQuizSessionAnswerChoiceFromJSONTyped(json: any, ignoreDiscriminator: boolean): LibraryQuizSessionAnswerChoice {
71
+ if (json == null) {
72
+ return json;
73
+ }
74
+ return {
75
+
76
+ 'id': json['id'],
77
+ 'text': json['text'],
78
+ 'textRich': json['text_rich'] == null ? undefined : RichTextDocumentFromJSON(json['text_rich']),
79
+ 'displayOrder': json['display_order'],
80
+ };
81
+ }
82
+
83
+ export function LibraryQuizSessionAnswerChoiceToJSON(json: any): LibraryQuizSessionAnswerChoice {
84
+ return LibraryQuizSessionAnswerChoiceToJSONTyped(json, false);
85
+ }
86
+
87
+ export function LibraryQuizSessionAnswerChoiceToJSONTyped(value?: LibraryQuizSessionAnswerChoice | null, ignoreDiscriminator: boolean = false): any {
88
+ if (value == null) {
89
+ return value;
90
+ }
91
+
92
+ return {
93
+
94
+ 'id': value['id'],
95
+ 'text': value['text'],
96
+ 'text_rich': RichTextDocumentToJSON(value['textRich']),
97
+ 'display_order': value['displayOrder'],
98
+ };
99
+ }
100
+
@@ -0,0 +1,166 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * LMS API
5
+ * LMS API
6
+ *
7
+ * The version of the OpenAPI document: 1.0.0
8
+ *
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+
15
+ import { mapValues } from '../runtime';
16
+ import type { RichTextDocument } from './RichTextDocument';
17
+ import {
18
+ RichTextDocumentFromJSON,
19
+ RichTextDocumentFromJSONTyped,
20
+ RichTextDocumentToJSON,
21
+ RichTextDocumentToJSONTyped,
22
+ } from './RichTextDocument';
23
+ import type { LibraryQuizSessionAnswerChoice } from './LibraryQuizSessionAnswerChoice';
24
+ import {
25
+ LibraryQuizSessionAnswerChoiceFromJSON,
26
+ LibraryQuizSessionAnswerChoiceFromJSONTyped,
27
+ LibraryQuizSessionAnswerChoiceToJSON,
28
+ LibraryQuizSessionAnswerChoiceToJSONTyped,
29
+ } from './LibraryQuizSessionAnswerChoice';
30
+
31
+ /**
32
+ *
33
+ * @export
34
+ * @interface LibraryQuizSessionQuestion
35
+ */
36
+ export interface LibraryQuizSessionQuestion {
37
+ /**
38
+ *
39
+ * @type {string}
40
+ * @memberof LibraryQuizSessionQuestion
41
+ */
42
+ id: string;
43
+ /**
44
+ *
45
+ * @type {number}
46
+ * @memberof LibraryQuizSessionQuestion
47
+ */
48
+ displayOrder: number;
49
+ /**
50
+ *
51
+ * @type {number}
52
+ * @memberof LibraryQuizSessionQuestion
53
+ */
54
+ points: number;
55
+ /**
56
+ *
57
+ * @type {LibraryQuizSessionQuestionQuestionTypeEnum}
58
+ * @memberof LibraryQuizSessionQuestion
59
+ */
60
+ questionType: LibraryQuizSessionQuestionQuestionTypeEnum;
61
+ /**
62
+ *
63
+ * @type {string}
64
+ * @memberof LibraryQuizSessionQuestion
65
+ */
66
+ questionText: string;
67
+ /**
68
+ *
69
+ * @type {RichTextDocument}
70
+ * @memberof LibraryQuizSessionQuestion
71
+ */
72
+ questionTextRich?: RichTextDocument | null;
73
+ /**
74
+ *
75
+ * @type {Array<LibraryQuizSessionAnswerChoice>}
76
+ * @memberof LibraryQuizSessionQuestion
77
+ */
78
+ answerChoices: Array<LibraryQuizSessionAnswerChoice>;
79
+ /**
80
+ *
81
+ * @type {boolean}
82
+ * @memberof LibraryQuizSessionQuestion
83
+ */
84
+ isAnswered: boolean;
85
+ /**
86
+ *
87
+ * @type {{ [key: string]: any; }}
88
+ * @memberof LibraryQuizSessionQuestion
89
+ */
90
+ answer?: { [key: string]: any; } | null;
91
+ }
92
+
93
+
94
+ /**
95
+ * @export
96
+ */
97
+ export const LibraryQuizSessionQuestionQuestionTypeEnum = {
98
+ SingleAnswer: 'single_answer',
99
+ MultipleAnswer: 'multiple_answer',
100
+ FillInBlank: 'fill_in_blank',
101
+ ShortAnswer: 'short_answer',
102
+ Matching: 'matching',
103
+ Essay: 'essay'
104
+ } as const;
105
+ export type LibraryQuizSessionQuestionQuestionTypeEnum = typeof LibraryQuizSessionQuestionQuestionTypeEnum[keyof typeof LibraryQuizSessionQuestionQuestionTypeEnum];
106
+
107
+
108
+ /**
109
+ * Check if a given object implements the LibraryQuizSessionQuestion interface.
110
+ */
111
+ export function instanceOfLibraryQuizSessionQuestion(value: object): value is LibraryQuizSessionQuestion {
112
+ if (!('id' in value) || value['id'] === undefined) return false;
113
+ if (!('displayOrder' in value) || value['displayOrder'] === undefined) return false;
114
+ if (!('points' in value) || value['points'] === undefined) return false;
115
+ if (!('questionType' in value) || value['questionType'] === undefined) return false;
116
+ if (!('questionText' in value) || value['questionText'] === undefined) return false;
117
+ if (!('answerChoices' in value) || value['answerChoices'] === undefined) return false;
118
+ if (!('isAnswered' in value) || value['isAnswered'] === undefined) return false;
119
+ return true;
120
+ }
121
+
122
+ export function LibraryQuizSessionQuestionFromJSON(json: any): LibraryQuizSessionQuestion {
123
+ return LibraryQuizSessionQuestionFromJSONTyped(json, false);
124
+ }
125
+
126
+ export function LibraryQuizSessionQuestionFromJSONTyped(json: any, ignoreDiscriminator: boolean): LibraryQuizSessionQuestion {
127
+ if (json == null) {
128
+ return json;
129
+ }
130
+ return {
131
+
132
+ 'id': json['id'],
133
+ 'displayOrder': json['display_order'],
134
+ 'points': json['points'],
135
+ 'questionType': json['question_type'],
136
+ 'questionText': json['question_text'],
137
+ 'questionTextRich': json['question_text_rich'] == null ? undefined : RichTextDocumentFromJSON(json['question_text_rich']),
138
+ 'answerChoices': ((json['answer_choices'] as Array<any>).map(LibraryQuizSessionAnswerChoiceFromJSON)),
139
+ 'isAnswered': json['is_answered'],
140
+ 'answer': json['answer'] == null ? undefined : json['answer'],
141
+ };
142
+ }
143
+
144
+ export function LibraryQuizSessionQuestionToJSON(json: any): LibraryQuizSessionQuestion {
145
+ return LibraryQuizSessionQuestionToJSONTyped(json, false);
146
+ }
147
+
148
+ export function LibraryQuizSessionQuestionToJSONTyped(value?: LibraryQuizSessionQuestion | null, ignoreDiscriminator: boolean = false): any {
149
+ if (value == null) {
150
+ return value;
151
+ }
152
+
153
+ return {
154
+
155
+ 'id': value['id'],
156
+ 'display_order': value['displayOrder'],
157
+ 'points': value['points'],
158
+ 'question_type': value['questionType'],
159
+ 'question_text': value['questionText'],
160
+ 'question_text_rich': RichTextDocumentToJSON(value['questionTextRich']),
161
+ 'answer_choices': ((value['answerChoices'] as Array<any>).map(LibraryQuizSessionAnswerChoiceToJSON)),
162
+ 'is_answered': value['isAnswered'],
163
+ 'answer': value['answer'],
164
+ };
165
+ }
166
+
@@ -0,0 +1,65 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * LMS API
5
+ * LMS API
6
+ *
7
+ * The version of the OpenAPI document: 1.0.0
8
+ *
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+
15
+ import { mapValues } from '../runtime';
16
+ /**
17
+ *
18
+ * @export
19
+ * @interface PostCourseLibraryQuizSession
20
+ */
21
+ export interface PostCourseLibraryQuizSession {
22
+ /**
23
+ *
24
+ * @type {boolean}
25
+ * @memberof PostCourseLibraryQuizSession
26
+ */
27
+ retake?: boolean;
28
+ }
29
+
30
+ /**
31
+ * Check if a given object implements the PostCourseLibraryQuizSession interface.
32
+ */
33
+ export function instanceOfPostCourseLibraryQuizSession(value: object): value is PostCourseLibraryQuizSession {
34
+ return true;
35
+ }
36
+
37
+ export function PostCourseLibraryQuizSessionFromJSON(json: any): PostCourseLibraryQuizSession {
38
+ return PostCourseLibraryQuizSessionFromJSONTyped(json, false);
39
+ }
40
+
41
+ export function PostCourseLibraryQuizSessionFromJSONTyped(json: any, ignoreDiscriminator: boolean): PostCourseLibraryQuizSession {
42
+ if (json == null) {
43
+ return json;
44
+ }
45
+ return {
46
+
47
+ 'retake': json['retake'] == null ? undefined : json['retake'],
48
+ };
49
+ }
50
+
51
+ export function PostCourseLibraryQuizSessionToJSON(json: any): PostCourseLibraryQuizSession {
52
+ return PostCourseLibraryQuizSessionToJSONTyped(json, false);
53
+ }
54
+
55
+ export function PostCourseLibraryQuizSessionToJSONTyped(value?: PostCourseLibraryQuizSession | null, ignoreDiscriminator: boolean = false): any {
56
+ if (value == null) {
57
+ return value;
58
+ }
59
+
60
+ return {
61
+
62
+ 'retake': value['retake'],
63
+ };
64
+ }
65
+