@easyedu/js-lsm-api 1.46.0 → 1.48.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 (121) hide show
  1. package/.openapi-generator/FILES +4 -0
  2. package/README.md +6 -2
  3. package/dist/apis/ContentApi.d.ts +18 -1
  4. package/dist/apis/ContentApi.js +47 -0
  5. package/dist/apis/ModuleApi.d.ts +17 -1
  6. package/dist/apis/ModuleApi.js +43 -0
  7. package/dist/apis/QuestionApi.d.ts +0 -1
  8. package/dist/apis/QuestionApi.js +0 -3
  9. package/dist/esm/apis/ContentApi.d.ts +18 -1
  10. package/dist/esm/apis/ContentApi.js +48 -1
  11. package/dist/esm/apis/ModuleApi.d.ts +17 -1
  12. package/dist/esm/apis/ModuleApi.js +44 -1
  13. package/dist/esm/apis/QuestionApi.d.ts +0 -1
  14. package/dist/esm/apis/QuestionApi.js +0 -3
  15. package/dist/esm/models/CriteriaBasedSelectionCriteria.d.ts +0 -6
  16. package/dist/esm/models/CriteriaBasedSelectionCriteria.js +0 -2
  17. package/dist/esm/models/GetQuestion.d.ts +0 -6
  18. package/dist/esm/models/GetQuestion.js +0 -2
  19. package/dist/esm/models/GetQuestionListFilters.d.ts +0 -6
  20. package/dist/esm/models/GetQuestionListFilters.js +0 -2
  21. package/dist/esm/models/GetQuizCriteriaItem.d.ts +0 -6
  22. package/dist/esm/models/GetQuizCriteriaItem.js +0 -2
  23. package/dist/esm/models/GetQuizCriteriaListItemsInner.d.ts +0 -6
  24. package/dist/esm/models/GetQuizCriteriaListItemsInner.js +0 -2
  25. package/dist/esm/models/GetQuizQuestionsItemsInnerQuestionDetails.d.ts +0 -6
  26. package/dist/esm/models/GetQuizQuestionsItemsInnerQuestionDetails.js +0 -2
  27. package/dist/esm/models/PostContentQuiz.d.ts +6 -0
  28. package/dist/esm/models/PostContentQuiz.js +2 -0
  29. package/dist/esm/models/PostContentUpload.d.ts +6 -0
  30. package/dist/esm/models/PostContentUpload.js +2 -0
  31. package/dist/esm/models/PostModule.d.ts +1 -1
  32. package/dist/esm/models/PostModule.js +1 -3
  33. package/dist/esm/models/PostQuestion.d.ts +0 -6
  34. package/dist/esm/models/PostQuestion.js +0 -2
  35. package/dist/esm/models/PostQuizCriteriaCriteriaInner.d.ts +0 -6
  36. package/dist/esm/models/PostQuizCriteriaCriteriaInner.js +0 -2
  37. package/dist/esm/models/PutContentReorder.d.ts +32 -0
  38. package/dist/esm/models/PutContentReorder.js +43 -0
  39. package/dist/esm/models/PutCourse.d.ts +0 -6
  40. package/dist/esm/models/PutCourse.js +0 -2
  41. package/dist/esm/models/PutModule.d.ts +0 -6
  42. package/dist/esm/models/PutModule.js +0 -2
  43. package/dist/esm/models/PutModuleReorder.d.ts +32 -0
  44. package/dist/esm/models/PutModuleReorder.js +43 -0
  45. package/dist/esm/models/PutQuestion.d.ts +0 -6
  46. package/dist/esm/models/PutQuestion.js +0 -2
  47. package/dist/esm/models/index.d.ts +2 -0
  48. package/dist/esm/models/index.js +2 -0
  49. package/dist/models/CriteriaBasedSelectionCriteria.d.ts +0 -6
  50. package/dist/models/CriteriaBasedSelectionCriteria.js +0 -2
  51. package/dist/models/GetQuestion.d.ts +0 -6
  52. package/dist/models/GetQuestion.js +0 -2
  53. package/dist/models/GetQuestionListFilters.d.ts +0 -6
  54. package/dist/models/GetQuestionListFilters.js +0 -2
  55. package/dist/models/GetQuizCriteriaItem.d.ts +0 -6
  56. package/dist/models/GetQuizCriteriaItem.js +0 -2
  57. package/dist/models/GetQuizCriteriaListItemsInner.d.ts +0 -6
  58. package/dist/models/GetQuizCriteriaListItemsInner.js +0 -2
  59. package/dist/models/GetQuizQuestionsItemsInnerQuestionDetails.d.ts +0 -6
  60. package/dist/models/GetQuizQuestionsItemsInnerQuestionDetails.js +0 -2
  61. package/dist/models/PostContentQuiz.d.ts +6 -0
  62. package/dist/models/PostContentQuiz.js +2 -0
  63. package/dist/models/PostContentUpload.d.ts +6 -0
  64. package/dist/models/PostContentUpload.js +2 -0
  65. package/dist/models/PostModule.d.ts +1 -1
  66. package/dist/models/PostModule.js +1 -3
  67. package/dist/models/PostQuestion.d.ts +0 -6
  68. package/dist/models/PostQuestion.js +0 -2
  69. package/dist/models/PostQuizCriteriaCriteriaInner.d.ts +0 -6
  70. package/dist/models/PostQuizCriteriaCriteriaInner.js +0 -2
  71. package/dist/models/PutContentReorder.d.ts +32 -0
  72. package/dist/models/PutContentReorder.js +50 -0
  73. package/dist/models/PutCourse.d.ts +0 -6
  74. package/dist/models/PutCourse.js +0 -2
  75. package/dist/models/PutModule.d.ts +0 -6
  76. package/dist/models/PutModule.js +0 -2
  77. package/dist/models/PutModuleReorder.d.ts +32 -0
  78. package/dist/models/PutModuleReorder.js +50 -0
  79. package/dist/models/PutQuestion.d.ts +0 -6
  80. package/dist/models/PutQuestion.js +0 -2
  81. package/dist/models/index.d.ts +2 -0
  82. package/dist/models/index.js +2 -0
  83. package/docs/ContentApi.md +72 -0
  84. package/docs/CriteriaBasedSelectionCriteria.md +0 -2
  85. package/docs/GetQuestion.md +0 -2
  86. package/docs/GetQuestionListFilters.md +0 -2
  87. package/docs/GetQuizCriteriaItem.md +0 -2
  88. package/docs/GetQuizCriteriaListItemsInner.md +0 -2
  89. package/docs/GetQuizQuestionsItemsInnerQuestionDetails.md +0 -2
  90. package/docs/ModuleApi.md +69 -0
  91. package/docs/PostContentQuiz.md +2 -0
  92. package/docs/PostContentUpload.md +2 -0
  93. package/docs/PostQuestion.md +0 -2
  94. package/docs/PostQuizCriteriaCriteriaInner.md +0 -2
  95. package/docs/PutContentReorder.md +34 -0
  96. package/docs/PutCourse.md +0 -2
  97. package/docs/PutModule.md +0 -2
  98. package/docs/PutModuleReorder.md +34 -0
  99. package/docs/PutQuestion.md +0 -2
  100. package/docs/QuestionApi.md +1 -4
  101. package/package.json +1 -1
  102. package/src/apis/ContentApi.ts +71 -0
  103. package/src/apis/ModuleApi.ts +62 -0
  104. package/src/apis/QuestionApi.ts +0 -5
  105. package/src/models/CriteriaBasedSelectionCriteria.ts +0 -8
  106. package/src/models/GetQuestion.ts +0 -8
  107. package/src/models/GetQuestionListFilters.ts +0 -8
  108. package/src/models/GetQuizCriteriaItem.ts +0 -8
  109. package/src/models/GetQuizCriteriaListItemsInner.ts +0 -8
  110. package/src/models/GetQuizQuestionsItemsInnerQuestionDetails.ts +0 -8
  111. package/src/models/PostContentQuiz.ts +8 -0
  112. package/src/models/PostContentUpload.ts +8 -0
  113. package/src/models/PostModule.ts +2 -3
  114. package/src/models/PostQuestion.ts +0 -8
  115. package/src/models/PostQuizCriteriaCriteriaInner.ts +0 -8
  116. package/src/models/PutContentReorder.ts +66 -0
  117. package/src/models/PutCourse.ts +0 -8
  118. package/src/models/PutModule.ts +0 -8
  119. package/src/models/PutModuleReorder.ts +66 -0
  120. package/src/models/PutQuestion.ts +0 -8
  121. package/src/models/index.ts +2 -0
package/docs/ModuleApi.md CHANGED
@@ -8,6 +8,7 @@ All URIs are relative to *https://sbzw93t49b.execute-api.us-east-2.amazonaws.com
8
8
  | [**getModuleList**](ModuleApi.md#getmodulelist) | **GET** /courses/{courseId}/modules | get module list |
9
9
  | [**postModule**](ModuleApi.md#postmodule) | **POST** /courses/{courseId}/modules | Post a new module |
10
10
  | [**putModule**](ModuleApi.md#putmodule) | **PUT** /courses/{courseId}/modules/{moduleId} | Update a module by id |
11
+ | [**putModuleReorder**](ModuleApi.md#putmodulereorder) | **PUT** /courses/{courseId}/modules/reorder | Reorder modules in a course |
11
12
 
12
13
 
13
14
 
@@ -282,3 +283,71 @@ No authorization required
282
283
 
283
284
  [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
284
285
 
286
+
287
+ ## putModuleReorder
288
+
289
+ > putModuleReorder(courseId, putModuleReorder)
290
+
291
+ Reorder modules in a course
292
+
293
+ ### Example
294
+
295
+ ```ts
296
+ import {
297
+ Configuration,
298
+ ModuleApi,
299
+ } from '@easyedu/js-lsm-api';
300
+ import type { PutModuleReorderRequest } from '@easyedu/js-lsm-api';
301
+
302
+ async function example() {
303
+ console.log("🚀 Testing @easyedu/js-lsm-api SDK...");
304
+ const api = new ModuleApi();
305
+
306
+ const body = {
307
+ // string
308
+ courseId: courseId_example,
309
+ // PutModuleReorder | Ordered list of module IDs
310
+ putModuleReorder: ...,
311
+ } satisfies PutModuleReorderRequest;
312
+
313
+ try {
314
+ const data = await api.putModuleReorder(body);
315
+ console.log(data);
316
+ } catch (error) {
317
+ console.error(error);
318
+ }
319
+ }
320
+
321
+ // Run the test
322
+ example().catch(console.error);
323
+ ```
324
+
325
+ ### Parameters
326
+
327
+
328
+ | Name | Type | Description | Notes |
329
+ |------------- | ------------- | ------------- | -------------|
330
+ | **courseId** | `string` | | [Defaults to `undefined`] |
331
+ | **putModuleReorder** | [PutModuleReorder](PutModuleReorder.md) | Ordered list of module IDs | |
332
+
333
+ ### Return type
334
+
335
+ `void` (Empty response body)
336
+
337
+ ### Authorization
338
+
339
+ No authorization required
340
+
341
+ ### HTTP request headers
342
+
343
+ - **Content-Type**: `application/json`
344
+ - **Accept**: Not defined
345
+
346
+
347
+ ### HTTP response details
348
+ | Status code | Description | Response headers |
349
+ |-------------|-------------|------------------|
350
+ | **200** | Modules reordered successfully | - |
351
+
352
+ [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
353
+
@@ -10,6 +10,7 @@ Name | Type
10
10
  `description` | string
11
11
  `questionSelection` | [PostContentQuizQuestionSelection](PostContentQuizQuestionSelection.md)
12
12
  `settings` | [PostContentQuizSettings](PostContentQuizSettings.md)
13
+ `order` | number
13
14
  `assignment` | [PostContentQuizAssignment](PostContentQuizAssignment.md)
14
15
 
15
16
  ## Example
@@ -23,6 +24,7 @@ const example = {
23
24
  "description": null,
24
25
  "questionSelection": null,
25
26
  "settings": null,
27
+ "order": null,
26
28
  "assignment": null,
27
29
  } satisfies PostContentQuiz
28
30
 
@@ -8,6 +8,7 @@ Name | Type
8
8
  ------------ | -------------
9
9
  `name` | string
10
10
  `contentType` | string
11
+ `order` | number
11
12
 
12
13
  ## Example
13
14
 
@@ -18,6 +19,7 @@ import type { PostContentUpload } from '@easyedu/js-lsm-api'
18
19
  const example = {
19
20
  "name": null,
20
21
  "contentType": null,
22
+ "order": null,
21
23
  } satisfies PostContentUpload
22
24
 
23
25
  console.log(example)
@@ -12,7 +12,6 @@ Name | Type
12
12
  `correctAnswer` | string
13
13
  `explanation` | string
14
14
  `topic` | string
15
- `course` | string
16
15
  `difficultyLevel` | string
17
16
  `tags` | Array<string>
18
17
  `version` | string
@@ -30,7 +29,6 @@ const example = {
30
29
  "correctAnswer": null,
31
30
  "explanation": null,
32
31
  "topic": null,
33
- "course": null,
34
32
  "difficultyLevel": null,
35
33
  "tags": null,
36
34
  "version": null,
@@ -11,7 +11,6 @@ Name | Type
11
11
  `difficultyLevel` | string
12
12
  `questionType` | string
13
13
  `tags` | Array<string>
14
- `course` | string
15
14
  `minQuestions` | number
16
15
  `maxQuestions` | number
17
16
  `priority` | number
@@ -27,7 +26,6 @@ const example = {
27
26
  "difficultyLevel": null,
28
27
  "questionType": null,
29
28
  "tags": null,
30
- "course": null,
31
29
  "minQuestions": null,
32
30
  "maxQuestions": null,
33
31
  "priority": null,
@@ -0,0 +1,34 @@
1
+
2
+ # PutContentReorder
3
+
4
+
5
+ ## Properties
6
+
7
+ Name | Type
8
+ ------------ | -------------
9
+ `ids` | Array<string>
10
+
11
+ ## Example
12
+
13
+ ```typescript
14
+ import type { PutContentReorder } from '@easyedu/js-lsm-api'
15
+
16
+ // TODO: Update the object below with actual values
17
+ const example = {
18
+ "ids": null,
19
+ } satisfies PutContentReorder
20
+
21
+ console.log(example)
22
+
23
+ // Convert the instance to a JSON string
24
+ const exampleJSON: string = JSON.stringify(example)
25
+ console.log(exampleJSON)
26
+
27
+ // Parse the JSON string back to an object
28
+ const exampleParsed = JSON.parse(exampleJSON) as PutContentReorder
29
+ console.log(exampleParsed)
30
+ ```
31
+
32
+ [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
33
+
34
+
package/docs/PutCourse.md CHANGED
@@ -9,7 +9,6 @@ Name | Type
9
9
  `id` | string
10
10
  `name` | string
11
11
  `description` | string
12
- `instructor` | string
13
12
  `published` | boolean
14
13
 
15
14
  ## Example
@@ -22,7 +21,6 @@ const example = {
22
21
  "id": null,
23
22
  "name": null,
24
23
  "description": null,
25
- "instructor": null,
26
24
  "published": null,
27
25
  } satisfies PutCourse
28
26
 
package/docs/PutModule.md CHANGED
@@ -8,7 +8,6 @@ Name | Type
8
8
  ------------ | -------------
9
9
  `name` | string
10
10
  `description` | string
11
- `order` | number
12
11
  `published` | boolean
13
12
 
14
13
  ## Example
@@ -20,7 +19,6 @@ import type { PutModule } from '@easyedu/js-lsm-api'
20
19
  const example = {
21
20
  "name": null,
22
21
  "description": null,
23
- "order": null,
24
22
  "published": null,
25
23
  } satisfies PutModule
26
24
 
@@ -0,0 +1,34 @@
1
+
2
+ # PutModuleReorder
3
+
4
+
5
+ ## Properties
6
+
7
+ Name | Type
8
+ ------------ | -------------
9
+ `ids` | Array<string>
10
+
11
+ ## Example
12
+
13
+ ```typescript
14
+ import type { PutModuleReorder } from '@easyedu/js-lsm-api'
15
+
16
+ // TODO: Update the object below with actual values
17
+ const example = {
18
+ "ids": null,
19
+ } satisfies PutModuleReorder
20
+
21
+ console.log(example)
22
+
23
+ // Convert the instance to a JSON string
24
+ const exampleJSON: string = JSON.stringify(example)
25
+ console.log(exampleJSON)
26
+
27
+ // Parse the JSON string back to an object
28
+ const exampleParsed = JSON.parse(exampleJSON) as PutModuleReorder
29
+ console.log(exampleParsed)
30
+ ```
31
+
32
+ [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
33
+
34
+
@@ -12,7 +12,6 @@ Name | Type
12
12
  `correctAnswer` | string
13
13
  `explanation` | string
14
14
  `topic` | string
15
- `course` | string
16
15
  `difficultyLevel` | string
17
16
  `tags` | Array<string>
18
17
  `version` | string
@@ -30,7 +29,6 @@ const example = {
30
29
  "correctAnswer": null,
31
30
  "explanation": null,
32
31
  "topic": null,
33
- "course": null,
34
32
  "difficultyLevel": null,
35
33
  "tags": null,
36
34
  "version": null,
@@ -147,7 +147,7 @@ No authorization required
147
147
 
148
148
  ## getQuestionList
149
149
 
150
- > GetQuestionList getQuestionList(page, pageSize, topic, course, questionType, difficultyLevel, tags, search)
150
+ > GetQuestionList getQuestionList(page, pageSize, topic, questionType, difficultyLevel, tags, search)
151
151
 
152
152
  Get list of questions with filtering and pagination
153
153
 
@@ -171,8 +171,6 @@ async function example() {
171
171
  pageSize: 56,
172
172
  // string | Filter by topic (optional)
173
173
  topic: topic_example,
174
- // string | Filter by course (optional)
175
- course: course_example,
176
174
  // 'single_answer' | 'multiple_answer' | 'fill_in_blank' | Filter by question type (optional)
177
175
  questionType: questionType_example,
178
176
  // 'beginner' | 'intermediate' | 'advanced' | Filter by difficulty level (optional)
@@ -203,7 +201,6 @@ example().catch(console.error);
203
201
  | **page** | `number` | Page number | [Optional] [Defaults to `1`] |
204
202
  | **pageSize** | `number` | Number of items per page | [Optional] [Defaults to `20`] |
205
203
  | **topic** | `string` | Filter by topic | [Optional] [Defaults to `undefined`] |
206
- | **course** | `string` | Filter by course | [Optional] [Defaults to `undefined`] |
207
204
  | **questionType** | `single_answer`, `multiple_answer`, `fill_in_blank` | Filter by question type | [Optional] [Defaults to `undefined`] [Enum: single_answer, multiple_answer, fill_in_blank] |
208
205
  | **difficultyLevel** | `beginner`, `intermediate`, `advanced` | Filter by difficulty level | [Optional] [Defaults to `undefined`] [Enum: beginner, intermediate, advanced] |
209
206
  | **tags** | `Array<string>` | Filter by tags | [Optional] |
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@easyedu/js-lsm-api",
3
- "version": "1.46.0",
3
+ "version": "1.48.0",
4
4
  "description": "OpenAPI client for @easyedu/js-lsm-api",
5
5
  "author": "OpenAPI-Generator",
6
6
  "repository": {
@@ -31,6 +31,7 @@ import type {
31
31
  PostContentUpload,
32
32
  PostVerifyManifest,
33
33
  PutContent,
34
+ PutContentReorder,
34
35
  PutContentVersion,
35
36
  ScormGetValueResponse,
36
37
  ScormSetValueRequest,
@@ -69,6 +70,8 @@ import {
69
70
  PostVerifyManifestToJSON,
70
71
  PutContentFromJSON,
71
72
  PutContentToJSON,
73
+ PutContentReorderFromJSON,
74
+ PutContentReorderToJSON,
72
75
  PutContentVersionFromJSON,
73
76
  PutContentVersionToJSON,
74
77
  ScormGetValueResponseFromJSON,
@@ -187,6 +190,12 @@ export interface PutContentRequest {
187
190
  putContent: PutContent;
188
191
  }
189
192
 
193
+ export interface PutContentReorderRequest {
194
+ moduleId: string;
195
+ courseId: string;
196
+ putContentReorder: PutContentReorder;
197
+ }
198
+
190
199
  export interface PutContentVersionRequest {
191
200
  contentId: string;
192
201
  moduleId: string;
@@ -1305,6 +1314,68 @@ export class ContentApi extends runtime.BaseAPI {
1305
1314
  return await response.value();
1306
1315
  }
1307
1316
 
1317
+ /**
1318
+ * Creates request options for putContentReorder without sending the request
1319
+ */
1320
+ async putContentReorderRequestOpts(requestParameters: PutContentReorderRequest): Promise<runtime.RequestOpts> {
1321
+ if (requestParameters['moduleId'] == null) {
1322
+ throw new runtime.RequiredError(
1323
+ 'moduleId',
1324
+ 'Required parameter "moduleId" was null or undefined when calling putContentReorder().'
1325
+ );
1326
+ }
1327
+
1328
+ if (requestParameters['courseId'] == null) {
1329
+ throw new runtime.RequiredError(
1330
+ 'courseId',
1331
+ 'Required parameter "courseId" was null or undefined when calling putContentReorder().'
1332
+ );
1333
+ }
1334
+
1335
+ if (requestParameters['putContentReorder'] == null) {
1336
+ throw new runtime.RequiredError(
1337
+ 'putContentReorder',
1338
+ 'Required parameter "putContentReorder" was null or undefined when calling putContentReorder().'
1339
+ );
1340
+ }
1341
+
1342
+ const queryParameters: any = {};
1343
+
1344
+ const headerParameters: runtime.HTTPHeaders = {};
1345
+
1346
+ headerParameters['Content-Type'] = 'application/json';
1347
+
1348
+
1349
+ let urlPath = `/courses/{courseId}/modules/{moduleId}/contents/reorder`;
1350
+ urlPath = urlPath.replace(`{${"moduleId"}}`, encodeURIComponent(String(requestParameters['moduleId'])));
1351
+ urlPath = urlPath.replace(`{${"courseId"}}`, encodeURIComponent(String(requestParameters['courseId'])));
1352
+
1353
+ return {
1354
+ path: urlPath,
1355
+ method: 'PUT',
1356
+ headers: headerParameters,
1357
+ query: queryParameters,
1358
+ body: PutContentReorderToJSON(requestParameters['putContentReorder']),
1359
+ };
1360
+ }
1361
+
1362
+ /**
1363
+ * Reorder content in a module
1364
+ */
1365
+ async putContentReorderRaw(requestParameters: PutContentReorderRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>> {
1366
+ const requestOptions = await this.putContentReorderRequestOpts(requestParameters);
1367
+ const response = await this.request(requestOptions, initOverrides);
1368
+
1369
+ return new runtime.VoidApiResponse(response);
1370
+ }
1371
+
1372
+ /**
1373
+ * Reorder content in a module
1374
+ */
1375
+ async putContentReorder(requestParameters: PutContentReorderRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void> {
1376
+ await this.putContentReorderRaw(requestParameters, initOverrides);
1377
+ }
1378
+
1308
1379
  /**
1309
1380
  * Creates request options for putContentVersion without sending the request
1310
1381
  */
@@ -19,6 +19,7 @@ import type {
19
19
  GetModuleList,
20
20
  PostModule,
21
21
  PutModule,
22
+ PutModuleReorder,
22
23
  } from '../models/index';
23
24
  import {
24
25
  GetModuleFromJSON,
@@ -29,6 +30,8 @@ import {
29
30
  PostModuleToJSON,
30
31
  PutModuleFromJSON,
31
32
  PutModuleToJSON,
33
+ PutModuleReorderFromJSON,
34
+ PutModuleReorderToJSON,
32
35
  } from '../models/index';
33
36
 
34
37
  export interface GetModuleRequest {
@@ -51,6 +54,11 @@ export interface PutModuleRequest {
51
54
  putModule: PutModule;
52
55
  }
53
56
 
57
+ export interface PutModuleReorderRequest {
58
+ courseId: string;
59
+ putModuleReorder: PutModuleReorder;
60
+ }
61
+
54
62
  /**
55
63
  *
56
64
  */
@@ -272,4 +280,58 @@ export class ModuleApi extends runtime.BaseAPI {
272
280
  return await response.value();
273
281
  }
274
282
 
283
+ /**
284
+ * Creates request options for putModuleReorder without sending the request
285
+ */
286
+ async putModuleReorderRequestOpts(requestParameters: PutModuleReorderRequest): Promise<runtime.RequestOpts> {
287
+ if (requestParameters['courseId'] == null) {
288
+ throw new runtime.RequiredError(
289
+ 'courseId',
290
+ 'Required parameter "courseId" was null or undefined when calling putModuleReorder().'
291
+ );
292
+ }
293
+
294
+ if (requestParameters['putModuleReorder'] == null) {
295
+ throw new runtime.RequiredError(
296
+ 'putModuleReorder',
297
+ 'Required parameter "putModuleReorder" was null or undefined when calling putModuleReorder().'
298
+ );
299
+ }
300
+
301
+ const queryParameters: any = {};
302
+
303
+ const headerParameters: runtime.HTTPHeaders = {};
304
+
305
+ headerParameters['Content-Type'] = 'application/json';
306
+
307
+
308
+ let urlPath = `/courses/{courseId}/modules/reorder`;
309
+ urlPath = urlPath.replace(`{${"courseId"}}`, encodeURIComponent(String(requestParameters['courseId'])));
310
+
311
+ return {
312
+ path: urlPath,
313
+ method: 'PUT',
314
+ headers: headerParameters,
315
+ query: queryParameters,
316
+ body: PutModuleReorderToJSON(requestParameters['putModuleReorder']),
317
+ };
318
+ }
319
+
320
+ /**
321
+ * Reorder modules in a course
322
+ */
323
+ async putModuleReorderRaw(requestParameters: PutModuleReorderRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>> {
324
+ const requestOptions = await this.putModuleReorderRequestOpts(requestParameters);
325
+ const response = await this.request(requestOptions, initOverrides);
326
+
327
+ return new runtime.VoidApiResponse(response);
328
+ }
329
+
330
+ /**
331
+ * Reorder modules in a course
332
+ */
333
+ async putModuleReorder(requestParameters: PutModuleReorderRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void> {
334
+ await this.putModuleReorderRaw(requestParameters, initOverrides);
335
+ }
336
+
275
337
  }
@@ -43,7 +43,6 @@ export interface GetQuestionListRequest {
43
43
  page?: number;
44
44
  pageSize?: number;
45
45
  topic?: string;
46
- course?: string;
47
46
  questionType?: GetQuestionListQuestionTypeEnum;
48
47
  difficultyLevel?: GetQuestionListDifficultyLevelEnum;
49
48
  tags?: Array<string>;
@@ -171,10 +170,6 @@ export class QuestionApi extends runtime.BaseAPI {
171
170
  queryParameters['topic'] = requestParameters['topic'];
172
171
  }
173
172
 
174
- if (requestParameters['course'] != null) {
175
- queryParameters['course'] = requestParameters['course'];
176
- }
177
-
178
173
  if (requestParameters['questionType'] != null) {
179
174
  queryParameters['question_type'] = requestParameters['questionType'];
180
175
  }
@@ -43,12 +43,6 @@ export interface CriteriaBasedSelectionCriteria {
43
43
  * @memberof CriteriaBasedSelectionCriteria
44
44
  */
45
45
  tags?: Array<string>;
46
- /**
47
- * Course to filter by
48
- * @type {string}
49
- * @memberof CriteriaBasedSelectionCriteria
50
- */
51
- course?: string;
52
46
  }
53
47
 
54
48
 
@@ -97,7 +91,6 @@ export function CriteriaBasedSelectionCriteriaFromJSONTyped(json: any, ignoreDis
97
91
  'difficultyLevels': json['difficulty_levels'] == null ? undefined : json['difficulty_levels'],
98
92
  'questionTypes': json['question_types'] == null ? undefined : json['question_types'],
99
93
  'tags': json['tags'] == null ? undefined : json['tags'],
100
- 'course': json['course'] == null ? undefined : json['course'],
101
94
  };
102
95
  }
103
96
 
@@ -116,7 +109,6 @@ export function CriteriaBasedSelectionCriteriaToJSONTyped(value?: CriteriaBasedS
116
109
  'difficulty_levels': value['difficultyLevels'],
117
110
  'question_types': value['questionTypes'],
118
111
  'tags': value['tags'],
119
- 'course': value['course'],
120
112
  };
121
113
  }
122
114
 
@@ -76,12 +76,6 @@ export interface GetQuestion {
76
76
  * @memberof GetQuestion
77
77
  */
78
78
  topic: string;
79
- /**
80
- * Associated course identifier (e.g., FA 102 2022)
81
- * @type {string}
82
- * @memberof GetQuestion
83
- */
84
- course?: string;
85
79
  /**
86
80
  * Difficulty level of the question
87
81
  * @type {GetQuestionDifficultyLevelEnum}
@@ -188,7 +182,6 @@ export function GetQuestionFromJSONTyped(json: any, ignoreDiscriminator: boolean
188
182
  'correctAnswer': json['correct_answer'] == null ? undefined : json['correct_answer'],
189
183
  'explanation': json['explanation'] == null ? undefined : json['explanation'],
190
184
  'topic': json['topic'],
191
- 'course': json['course'] == null ? undefined : json['course'],
192
185
  'difficultyLevel': json['difficulty_level'],
193
186
  'tags': json['tags'] == null ? undefined : json['tags'],
194
187
  'version': json['version'] == null ? undefined : json['version'],
@@ -217,7 +210,6 @@ export function GetQuestionToJSONTyped(value?: Omit<GetQuestion, 'id'|'created_d
217
210
  'correct_answer': value['correctAnswer'],
218
211
  'explanation': value['explanation'],
219
212
  'topic': value['topic'],
220
- 'course': value['course'],
221
213
  'difficulty_level': value['difficultyLevel'],
222
214
  'tags': value['tags'],
223
215
  'version': value['version'],
@@ -25,12 +25,6 @@ export interface GetQuestionListFilters {
25
25
  * @memberof GetQuestionListFilters
26
26
  */
27
27
  topic?: string;
28
- /**
29
- * Filter by course
30
- * @type {string}
31
- * @memberof GetQuestionListFilters
32
- */
33
- course?: string;
34
28
  /**
35
29
  * Filter by question type
36
30
  * @type {GetQuestionListFiltersQuestionTypeEnum}
@@ -112,7 +106,6 @@ export function GetQuestionListFiltersFromJSONTyped(json: any, ignoreDiscriminat
112
106
  return {
113
107
 
114
108
  'topic': json['topic'] == null ? undefined : json['topic'],
115
- 'course': json['course'] == null ? undefined : json['course'],
116
109
  'questionType': json['question_type'] == null ? undefined : json['question_type'],
117
110
  'difficultyLevel': json['difficulty_level'] == null ? undefined : json['difficulty_level'],
118
111
  'tags': json['tags'] == null ? undefined : json['tags'],
@@ -134,7 +127,6 @@ export function GetQuestionListFiltersToJSONTyped(value?: GetQuestionListFilters
134
127
  return {
135
128
 
136
129
  'topic': value['topic'],
137
- 'course': value['course'],
138
130
  'question_type': value['questionType'],
139
131
  'difficulty_level': value['difficultyLevel'],
140
132
  'tags': value['tags'],
@@ -55,12 +55,6 @@ export interface GetQuizCriteriaItem {
55
55
  * @memberof GetQuizCriteriaItem
56
56
  */
57
57
  tags?: Array<string>;
58
- /**
59
- * Course filter (null for any course)
60
- * @type {string}
61
- * @memberof GetQuizCriteriaItem
62
- */
63
- course?: string;
64
58
  /**
65
59
  * Minimum questions from this criteria
66
60
  * @type {number}
@@ -153,7 +147,6 @@ export function GetQuizCriteriaItemFromJSONTyped(json: any, ignoreDiscriminator:
153
147
  'difficultyLevel': json['difficulty_level'] == null ? undefined : json['difficulty_level'],
154
148
  'questionType': json['question_type'] == null ? undefined : json['question_type'],
155
149
  'tags': json['tags'] == null ? undefined : json['tags'],
156
- 'course': json['course'] == null ? undefined : json['course'],
157
150
  'minQuestions': json['min_questions'] == null ? undefined : json['min_questions'],
158
151
  'maxQuestions': json['max_questions'] == null ? undefined : json['max_questions'],
159
152
  'priority': json['priority'],
@@ -180,7 +173,6 @@ export function GetQuizCriteriaItemToJSONTyped(value?: GetQuizCriteriaItem | nul
180
173
  'difficulty_level': value['difficultyLevel'],
181
174
  'question_type': value['questionType'],
182
175
  'tags': value['tags'],
183
- 'course': value['course'],
184
176
  'min_questions': value['minQuestions'],
185
177
  'max_questions': value['maxQuestions'],
186
178
  'priority': value['priority'],
@@ -55,12 +55,6 @@ export interface GetQuizCriteriaListItemsInner {
55
55
  * @memberof GetQuizCriteriaListItemsInner
56
56
  */
57
57
  tags?: Array<string>;
58
- /**
59
- * Course filter (null for any course)
60
- * @type {string}
61
- * @memberof GetQuizCriteriaListItemsInner
62
- */
63
- course?: string;
64
58
  /**
65
59
  * Minimum questions from this criteria
66
60
  * @type {number}
@@ -153,7 +147,6 @@ export function GetQuizCriteriaListItemsInnerFromJSONTyped(json: any, ignoreDisc
153
147
  'difficultyLevel': json['difficulty_level'] == null ? undefined : json['difficulty_level'],
154
148
  'questionType': json['question_type'] == null ? undefined : json['question_type'],
155
149
  'tags': json['tags'] == null ? undefined : json['tags'],
156
- 'course': json['course'] == null ? undefined : json['course'],
157
150
  'minQuestions': json['min_questions'] == null ? undefined : json['min_questions'],
158
151
  'maxQuestions': json['max_questions'] == null ? undefined : json['max_questions'],
159
152
  'priority': json['priority'],
@@ -180,7 +173,6 @@ export function GetQuizCriteriaListItemsInnerToJSONTyped(value?: GetQuizCriteria
180
173
  'difficulty_level': value['difficultyLevel'],
181
174
  'question_type': value['questionType'],
182
175
  'tags': value['tags'],
183
- 'course': value['course'],
184
176
  'min_questions': value['minQuestions'],
185
177
  'max_questions': value['maxQuestions'],
186
178
  'priority': value['priority'],
@@ -51,12 +51,6 @@ export interface GetQuizQuestionsItemsInnerQuestionDetails {
51
51
  * @memberof GetQuizQuestionsItemsInnerQuestionDetails
52
52
  */
53
53
  difficultyLevel: GetQuizQuestionsItemsInnerQuestionDetailsDifficultyLevelEnum;
54
- /**
55
- * Course associated with question
56
- * @type {string}
57
- * @memberof GetQuizQuestionsItemsInnerQuestionDetails
58
- */
59
- course?: string;
60
54
  /**
61
55
  * Explanation of correct answer
62
56
  * @type {string}
@@ -139,7 +133,6 @@ export function GetQuizQuestionsItemsInnerQuestionDetailsFromJSONTyped(json: any
139
133
  'questionType': json['question_type'],
140
134
  'topic': json['topic'],
141
135
  'difficultyLevel': json['difficulty_level'],
142
- 'course': json['course'] == null ? undefined : json['course'],
143
136
  'explanation': json['explanation'] == null ? undefined : json['explanation'],
144
137
  'tags': json['tags'] == null ? undefined : json['tags'],
145
138
  'versionNumber': json['version_number'] == null ? undefined : json['version_number'],
@@ -163,7 +156,6 @@ export function GetQuizQuestionsItemsInnerQuestionDetailsToJSONTyped(value?: Get
163
156
  'question_type': value['questionType'],
164
157
  'topic': value['topic'],
165
158
  'difficulty_level': value['difficultyLevel'],
166
- 'course': value['course'],
167
159
  'explanation': value['explanation'],
168
160
  'tags': value['tags'],
169
161
  'version_number': value['versionNumber'],