@easyedu/js-lsm-api 1.109.0 → 1.110.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.
- package/README.md +4 -4
- package/dist/apis/ContentLibraryApi.d.ts +5 -4
- package/dist/apis/ContentLibraryApi.js +6 -5
- package/dist/apis/QuestionApi.d.ts +1 -11
- package/dist/apis/QuestionApi.js +3 -14
- package/dist/esm/apis/ContentLibraryApi.d.ts +5 -4
- package/dist/esm/apis/ContentLibraryApi.js +6 -5
- package/dist/esm/apis/QuestionApi.d.ts +1 -11
- package/dist/esm/apis/QuestionApi.js +2 -13
- package/dist/esm/models/ContentLibraryTag.d.ts +6 -0
- package/dist/esm/models/ContentLibraryTag.js +4 -0
- package/dist/esm/models/ContentLibraryTagItem.d.ts +1 -0
- package/dist/esm/models/ContentLibraryTagItem.js +2 -1
- package/dist/esm/models/GetQuestion.d.ts +4 -18
- package/dist/esm/models/GetQuestion.js +3 -14
- package/dist/esm/models/GetQuestionListFilters.d.ts +3 -18
- package/dist/esm/models/GetQuestionListFilters.js +2 -12
- package/dist/esm/models/LibraryQuizCriteriaPreviewQuestion.d.ts +0 -15
- package/dist/esm/models/LibraryQuizCriteriaPreviewQuestion.js +0 -12
- package/dist/esm/models/LibraryQuizCriterion.d.ts +0 -15
- package/dist/esm/models/LibraryQuizCriterion.js +0 -10
- package/dist/esm/models/PostQuestion.d.ts +0 -15
- package/dist/esm/models/PostQuestion.js +0 -12
- package/dist/esm/models/PutQuestion.d.ts +0 -15
- package/dist/esm/models/PutQuestion.js +0 -10
- package/dist/models/ContentLibraryTag.d.ts +6 -0
- package/dist/models/ContentLibraryTag.js +4 -0
- package/dist/models/ContentLibraryTagItem.d.ts +1 -0
- package/dist/models/ContentLibraryTagItem.js +2 -1
- package/dist/models/GetQuestion.d.ts +4 -18
- package/dist/models/GetQuestion.js +4 -15
- package/dist/models/GetQuestionListFilters.d.ts +3 -18
- package/dist/models/GetQuestionListFilters.js +3 -13
- package/dist/models/LibraryQuizCriteriaPreviewQuestion.d.ts +0 -15
- package/dist/models/LibraryQuizCriteriaPreviewQuestion.js +1 -13
- package/dist/models/LibraryQuizCriterion.d.ts +0 -15
- package/dist/models/LibraryQuizCriterion.js +1 -11
- package/dist/models/PostQuestion.d.ts +0 -15
- package/dist/models/PostQuestion.js +1 -13
- package/dist/models/PutQuestion.d.ts +0 -15
- package/dist/models/PutQuestion.js +1 -11
- package/docs/ContentLibraryApi.md +7 -7
- package/docs/ContentLibraryTag.md +2 -0
- package/docs/GetQuestion.md +1 -3
- package/docs/GetQuestionListFilters.md +2 -4
- package/docs/LibraryQuizCriteriaPreviewQuestion.md +0 -2
- package/docs/LibraryQuizCriterion.md +0 -2
- package/docs/PostQuestion.md +0 -2
- package/docs/PutQuestion.md +0 -2
- package/docs/QuestionApi.md +4 -7
- package/package.json +1 -1
- package/src/apis/ContentLibraryApi.ts +6 -5
- package/src/apis/QuestionApi.ts +3 -17
- package/src/models/ContentLibraryTag.ts +9 -0
- package/src/models/ContentLibraryTagItem.ts +2 -1
- package/src/models/GetQuestion.ts +12 -24
- package/src/models/GetQuestionListFilters.ts +5 -23
- package/src/models/LibraryQuizCriteriaPreviewQuestion.ts +0 -19
- package/src/models/LibraryQuizCriterion.ts +0 -18
- package/src/models/PostQuestion.ts +0 -19
- package/src/models/PutQuestion.ts +0 -18
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
* Do not edit the class manually.
|
|
14
14
|
*/
|
|
15
15
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
-
exports.
|
|
16
|
+
exports.PutQuestionQuestionTypeEnum = void 0;
|
|
17
17
|
exports.instanceOfPutQuestion = instanceOfPutQuestion;
|
|
18
18
|
exports.PutQuestionFromJSON = PutQuestionFromJSON;
|
|
19
19
|
exports.PutQuestionFromJSONTyped = PutQuestionFromJSONTyped;
|
|
@@ -32,14 +32,6 @@ exports.PutQuestionQuestionTypeEnum = {
|
|
|
32
32
|
Matching: 'matching',
|
|
33
33
|
Essay: 'essay'
|
|
34
34
|
};
|
|
35
|
-
/**
|
|
36
|
-
* @export
|
|
37
|
-
*/
|
|
38
|
-
exports.PutQuestionDifficultyLevelEnum = {
|
|
39
|
-
Beginner: 'beginner',
|
|
40
|
-
Intermediate: 'intermediate',
|
|
41
|
-
Advanced: 'advanced'
|
|
42
|
-
};
|
|
43
35
|
/**
|
|
44
36
|
* Check if a given object implements the PutQuestion interface.
|
|
45
37
|
*/
|
|
@@ -59,7 +51,6 @@ function PutQuestionFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
59
51
|
'answerChoices': json['answer_choices'] == null ? undefined : (json['answer_choices'].map(PutQuestionAnswerChoicesInner_1.PutQuestionAnswerChoicesInnerFromJSON)),
|
|
60
52
|
'correctAnswer': json['correct_answer'] == null ? undefined : json['correct_answer'],
|
|
61
53
|
'explanation': json['explanation'] == null ? undefined : (0, RichTextInput_1.RichTextInputFromJSON)(json['explanation']),
|
|
62
|
-
'difficultyLevel': json['difficulty_level'] == null ? undefined : json['difficulty_level'],
|
|
63
54
|
'tags': json['tags'] == null ? undefined : json['tags'],
|
|
64
55
|
'version': json['version'] == null ? undefined : json['version'],
|
|
65
56
|
};
|
|
@@ -77,7 +68,6 @@ function PutQuestionToJSONTyped(value, ignoreDiscriminator = false) {
|
|
|
77
68
|
'answer_choices': value['answerChoices'] == null ? undefined : (value['answerChoices'].map(PutQuestionAnswerChoicesInner_1.PutQuestionAnswerChoicesInnerToJSON)),
|
|
78
69
|
'correct_answer': value['correctAnswer'],
|
|
79
70
|
'explanation': (0, RichTextInput_1.RichTextInputToJSON)(value['explanation']),
|
|
80
|
-
'difficulty_level': value['difficultyLevel'],
|
|
81
71
|
'tags': value['tags'],
|
|
82
72
|
'version': value['version'],
|
|
83
73
|
};
|
|
@@ -4,11 +4,11 @@ All URIs are relative to *https://sbzw93t49b.execute-api.us-east-2.amazonaws.com
|
|
|
4
4
|
|
|
5
5
|
| Method | HTTP request | Description |
|
|
6
6
|
|------------- | ------------- | -------------|
|
|
7
|
-
| [**deleteContentLibraryTag**](ContentLibraryApi.md#deletecontentlibrarytag) | **DELETE** /content-library/tags/{tagId} | Delete
|
|
7
|
+
| [**deleteContentLibraryTag**](ContentLibraryApi.md#deletecontentlibrarytag) | **DELETE** /content-library/tags/{tagId} | Delete a Content Library tag and remove it from associated content |
|
|
8
8
|
| [**deleteResourceVersion**](ContentLibraryApi.md#deleteresourceversion) | **DELETE** /content-library/resources/{resourceId}/versions/{versionId} | Discard an unreferenced draft resource version |
|
|
9
9
|
| [**getContentLibraryItemList**](ContentLibraryApi.md#getcontentlibraryitemlist) | **GET** /content-library/items | Search Content Library items |
|
|
10
10
|
| [**getContentLibraryTag**](ContentLibraryApi.md#getcontentlibrarytag) | **GET** /content-library/tags/{tagId} | Get a Content Library tag |
|
|
11
|
-
| [**getContentLibraryTagItemList**](ContentLibraryApi.md#getcontentlibrarytagitemlist) | **GET** /content-library/tags/{tagId}/items | List resources and
|
|
11
|
+
| [**getContentLibraryTagItemList**](ContentLibraryApi.md#getcontentlibrarytagitemlist) | **GET** /content-library/tags/{tagId}/items | List resources, quizzes, and questions associated with a tag |
|
|
12
12
|
| [**getContentLibraryTagList**](ContentLibraryApi.md#getcontentlibrarytaglist) | **GET** /content-library/tags | List portal Content Library tags |
|
|
13
13
|
| [**getResource**](ContentLibraryApi.md#getresource) | **GET** /content-library/resources/{resourceId} | Get a resource and all versions |
|
|
14
14
|
| [**getResourceList**](ContentLibraryApi.md#getresourcelist) | **GET** /content-library/resources | List reusable resources |
|
|
@@ -37,7 +37,7 @@ All URIs are relative to *https://sbzw93t49b.execute-api.us-east-2.amazonaws.com
|
|
|
37
37
|
|
|
38
38
|
> deleteContentLibraryTag(tagId)
|
|
39
39
|
|
|
40
|
-
Delete
|
|
40
|
+
Delete a Content Library tag and remove it from associated content
|
|
41
41
|
|
|
42
42
|
### Example
|
|
43
43
|
|
|
@@ -94,7 +94,7 @@ No authorization required
|
|
|
94
94
|
| Status code | Description | Response headers |
|
|
95
95
|
|-------------|-------------|------------------|
|
|
96
96
|
| **204** | Tag deleted | - |
|
|
97
|
-
| **409** | Tag is
|
|
97
|
+
| **409** | Tag is retained as a merge alias or target | - |
|
|
98
98
|
|
|
99
99
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
100
100
|
|
|
@@ -318,7 +318,7 @@ No authorization required
|
|
|
318
318
|
|
|
319
319
|
> GetContentLibraryTagItemList getContentLibraryTagItemList(tagId, kind, search, includeArchived, page, pageSize)
|
|
320
320
|
|
|
321
|
-
List resources and
|
|
321
|
+
List resources, quizzes, and questions associated with a tag
|
|
322
322
|
|
|
323
323
|
### Example
|
|
324
324
|
|
|
@@ -336,7 +336,7 @@ async function example() {
|
|
|
336
336
|
const body = {
|
|
337
337
|
// string
|
|
338
338
|
tagId: 38400000-8cf0-11bd-b23e-10b96e4ef00d,
|
|
339
|
-
// 'resource' | 'quiz' (optional)
|
|
339
|
+
// 'resource' | 'quiz' | 'question' (optional)
|
|
340
340
|
kind: kind_example,
|
|
341
341
|
// string (optional)
|
|
342
342
|
search: search_example,
|
|
@@ -366,7 +366,7 @@ example().catch(console.error);
|
|
|
366
366
|
| Name | Type | Description | Notes |
|
|
367
367
|
|------------- | ------------- | ------------- | -------------|
|
|
368
368
|
| **tagId** | `string` | | [Defaults to `undefined`] |
|
|
369
|
-
| **kind** | `resource`, `quiz` | | [Optional] [Defaults to `undefined`] [Enum: resource, quiz] |
|
|
369
|
+
| **kind** | `resource`, `quiz`, `question` | | [Optional] [Defaults to `undefined`] [Enum: resource, quiz, question] |
|
|
370
370
|
| **search** | `string` | | [Optional] [Defaults to `undefined`] |
|
|
371
371
|
| **includeArchived** | `boolean` | | [Optional] [Defaults to `false`] |
|
|
372
372
|
| **page** | `number` | | [Optional] [Defaults to `1`] |
|
|
@@ -17,6 +17,7 @@ Name | Type
|
|
|
17
17
|
`archivedItemCount` | number
|
|
18
18
|
`resourceCount` | number
|
|
19
19
|
`quizCount` | number
|
|
20
|
+
`questionCount` | number
|
|
20
21
|
`createdAt` | number
|
|
21
22
|
`updatedAt` | number
|
|
22
23
|
|
|
@@ -38,6 +39,7 @@ const example = {
|
|
|
38
39
|
"archivedItemCount": null,
|
|
39
40
|
"resourceCount": null,
|
|
40
41
|
"quizCount": null,
|
|
42
|
+
"questionCount": null,
|
|
41
43
|
"createdAt": null,
|
|
42
44
|
"updatedAt": null,
|
|
43
45
|
} satisfies ContentLibraryTag
|
package/docs/GetQuestion.md
CHANGED
|
@@ -12,8 +12,7 @@ Name | Type
|
|
|
12
12
|
`answerChoices` | [Array<GetQuestionAnswerChoicesInner>](GetQuestionAnswerChoicesInner.md)
|
|
13
13
|
`correctAnswer` | string
|
|
14
14
|
`explanation` | [RichTextDocument](RichTextDocument.md)
|
|
15
|
-
`
|
|
16
|
-
`tags` | Array<string>
|
|
15
|
+
`tags` | [Array<ContentLibraryTag>](ContentLibraryTag.md)
|
|
17
16
|
`version` | string
|
|
18
17
|
`versionNumber` | number
|
|
19
18
|
`createdDate` | Date
|
|
@@ -35,7 +34,6 @@ const example = {
|
|
|
35
34
|
"answerChoices": null,
|
|
36
35
|
"correctAnswer": null,
|
|
37
36
|
"explanation": null,
|
|
38
|
-
"difficultyLevel": null,
|
|
39
37
|
"tags": null,
|
|
40
38
|
"version": null,
|
|
41
39
|
"versionNumber": null,
|
|
@@ -7,8 +7,7 @@
|
|
|
7
7
|
Name | Type
|
|
8
8
|
------------ | -------------
|
|
9
9
|
`questionType` | string
|
|
10
|
-
`
|
|
11
|
-
`tags` | Array<string>
|
|
10
|
+
`tagId` | string
|
|
12
11
|
`search` | string
|
|
13
12
|
`createdAfter` | Date
|
|
14
13
|
`createdBefore` | Date
|
|
@@ -21,8 +20,7 @@ import type { GetQuestionListFilters } from '@easyedu/js-lsm-api'
|
|
|
21
20
|
// TODO: Update the object below with actual values
|
|
22
21
|
const example = {
|
|
23
22
|
"questionType": null,
|
|
24
|
-
"
|
|
25
|
-
"tags": null,
|
|
23
|
+
"tagId": null,
|
|
26
24
|
"search": null,
|
|
27
25
|
"createdAfter": null,
|
|
28
26
|
"createdBefore": null,
|
|
@@ -11,7 +11,6 @@ Name | Type
|
|
|
11
11
|
`questionType` | string
|
|
12
12
|
`versionNumber` | number
|
|
13
13
|
`version` | string
|
|
14
|
-
`difficultyLevel` | string
|
|
15
14
|
`tags` | Array<string>
|
|
16
15
|
|
|
17
16
|
## Example
|
|
@@ -26,7 +25,6 @@ const example = {
|
|
|
26
25
|
"questionType": null,
|
|
27
26
|
"versionNumber": null,
|
|
28
27
|
"version": null,
|
|
29
|
-
"difficultyLevel": null,
|
|
30
28
|
"tags": null,
|
|
31
29
|
} satisfies LibraryQuizCriteriaPreviewQuestion
|
|
32
30
|
|
|
@@ -7,7 +7,6 @@
|
|
|
7
7
|
Name | Type
|
|
8
8
|
------------ | -------------
|
|
9
9
|
`id` | string
|
|
10
|
-
`difficultyLevel` | string
|
|
11
10
|
`questionType` | string
|
|
12
11
|
`tags` | Array<string>
|
|
13
12
|
`minQuestions` | number
|
|
@@ -22,7 +21,6 @@ import type { LibraryQuizCriterion } from '@easyedu/js-lsm-api'
|
|
|
22
21
|
// TODO: Update the object below with actual values
|
|
23
22
|
const example = {
|
|
24
23
|
"id": null,
|
|
25
|
-
"difficultyLevel": null,
|
|
26
24
|
"questionType": null,
|
|
27
25
|
"tags": null,
|
|
28
26
|
"minQuestions": null,
|
package/docs/PostQuestion.md
CHANGED
|
@@ -11,7 +11,6 @@ Name | Type
|
|
|
11
11
|
`answerChoices` | [Array<PostQuestionAnswerChoicesInner>](PostQuestionAnswerChoicesInner.md)
|
|
12
12
|
`correctAnswer` | string
|
|
13
13
|
`explanation` | [RichTextInput](RichTextInput.md)
|
|
14
|
-
`difficultyLevel` | string
|
|
15
14
|
`tags` | Array<string>
|
|
16
15
|
`version` | string
|
|
17
16
|
|
|
@@ -27,7 +26,6 @@ const example = {
|
|
|
27
26
|
"answerChoices": null,
|
|
28
27
|
"correctAnswer": null,
|
|
29
28
|
"explanation": null,
|
|
30
|
-
"difficultyLevel": null,
|
|
31
29
|
"tags": null,
|
|
32
30
|
"version": null,
|
|
33
31
|
} satisfies PostQuestion
|
package/docs/PutQuestion.md
CHANGED
|
@@ -11,7 +11,6 @@ Name | Type
|
|
|
11
11
|
`answerChoices` | [Array<PutQuestionAnswerChoicesInner>](PutQuestionAnswerChoicesInner.md)
|
|
12
12
|
`correctAnswer` | string
|
|
13
13
|
`explanation` | [RichTextInput](RichTextInput.md)
|
|
14
|
-
`difficultyLevel` | string
|
|
15
14
|
`tags` | Array<string>
|
|
16
15
|
`version` | string
|
|
17
16
|
|
|
@@ -27,7 +26,6 @@ const example = {
|
|
|
27
26
|
"answerChoices": null,
|
|
28
27
|
"correctAnswer": null,
|
|
29
28
|
"explanation": null,
|
|
30
|
-
"difficultyLevel": null,
|
|
31
29
|
"tags": null,
|
|
32
30
|
"version": null,
|
|
33
31
|
} satisfies PutQuestion
|
package/docs/QuestionApi.md
CHANGED
|
@@ -147,7 +147,7 @@ No authorization required
|
|
|
147
147
|
|
|
148
148
|
## getQuestionList
|
|
149
149
|
|
|
150
|
-
> GetQuestionList getQuestionList(page, pageSize, questionType,
|
|
150
|
+
> GetQuestionList getQuestionList(page, pageSize, questionType, tagId, search)
|
|
151
151
|
|
|
152
152
|
Get list of questions with filtering and pagination
|
|
153
153
|
|
|
@@ -171,10 +171,8 @@ async function example() {
|
|
|
171
171
|
pageSize: 56,
|
|
172
172
|
// 'single_answer' | 'multiple_answer' | 'fill_in_blank' | Filter by question type (optional)
|
|
173
173
|
questionType: questionType_example,
|
|
174
|
-
//
|
|
175
|
-
|
|
176
|
-
// Array<string> | Filter by tags (optional)
|
|
177
|
-
tags: ...,
|
|
174
|
+
// string | Filter by a shared tag (optional)
|
|
175
|
+
tagId: 38400000-8cf0-11bd-b23e-10b96e4ef00d,
|
|
178
176
|
// string | Search in question text (optional)
|
|
179
177
|
search: search_example,
|
|
180
178
|
} satisfies GetQuestionListRequest;
|
|
@@ -199,8 +197,7 @@ example().catch(console.error);
|
|
|
199
197
|
| **page** | `number` | Page number | [Optional] [Defaults to `1`] |
|
|
200
198
|
| **pageSize** | `number` | Number of items per page | [Optional] [Defaults to `20`] |
|
|
201
199
|
| **questionType** | `single_answer`, `multiple_answer`, `fill_in_blank` | Filter by question type | [Optional] [Defaults to `undefined`] [Enum: single_answer, multiple_answer, fill_in_blank] |
|
|
202
|
-
| **
|
|
203
|
-
| **tags** | `Array<string>` | Filter by tags | [Optional] |
|
|
200
|
+
| **tagId** | `string` | Filter by a shared tag | [Optional] [Defaults to `undefined`] |
|
|
204
201
|
| **search** | `string` | Search in question text | [Optional] [Defaults to `undefined`] |
|
|
205
202
|
|
|
206
203
|
### Return type
|
package/package.json
CHANGED
|
@@ -288,7 +288,7 @@ export class ContentLibraryApi extends runtime.BaseAPI {
|
|
|
288
288
|
}
|
|
289
289
|
|
|
290
290
|
/**
|
|
291
|
-
* Delete
|
|
291
|
+
* Delete a Content Library tag and remove it from associated content
|
|
292
292
|
*/
|
|
293
293
|
async deleteContentLibraryTagRaw(requestParameters: DeleteContentLibraryTagRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>> {
|
|
294
294
|
const requestOptions = await this.deleteContentLibraryTagRequestOpts(requestParameters);
|
|
@@ -298,7 +298,7 @@ export class ContentLibraryApi extends runtime.BaseAPI {
|
|
|
298
298
|
}
|
|
299
299
|
|
|
300
300
|
/**
|
|
301
|
-
* Delete
|
|
301
|
+
* Delete a Content Library tag and remove it from associated content
|
|
302
302
|
*/
|
|
303
303
|
async deleteContentLibraryTag(requestParameters: DeleteContentLibraryTagRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void> {
|
|
304
304
|
await this.deleteContentLibraryTagRaw(requestParameters, initOverrides);
|
|
@@ -510,7 +510,7 @@ export class ContentLibraryApi extends runtime.BaseAPI {
|
|
|
510
510
|
}
|
|
511
511
|
|
|
512
512
|
/**
|
|
513
|
-
* List resources and
|
|
513
|
+
* List resources, quizzes, and questions associated with a tag
|
|
514
514
|
*/
|
|
515
515
|
async getContentLibraryTagItemListRaw(requestParameters: GetContentLibraryTagItemListRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<GetContentLibraryTagItemList>> {
|
|
516
516
|
const requestOptions = await this.getContentLibraryTagItemListRequestOpts(requestParameters);
|
|
@@ -520,7 +520,7 @@ export class ContentLibraryApi extends runtime.BaseAPI {
|
|
|
520
520
|
}
|
|
521
521
|
|
|
522
522
|
/**
|
|
523
|
-
* List resources and
|
|
523
|
+
* List resources, quizzes, and questions associated with a tag
|
|
524
524
|
*/
|
|
525
525
|
async getContentLibraryTagItemList(requestParameters: GetContentLibraryTagItemListRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GetContentLibraryTagItemList> {
|
|
526
526
|
const response = await this.getContentLibraryTagItemListRaw(requestParameters, initOverrides);
|
|
@@ -1650,7 +1650,8 @@ export class ContentLibraryApi extends runtime.BaseAPI {
|
|
|
1650
1650
|
*/
|
|
1651
1651
|
export const GetContentLibraryTagItemListKindEnum = {
|
|
1652
1652
|
Resource: 'resource',
|
|
1653
|
-
Quiz: 'quiz'
|
|
1653
|
+
Quiz: 'quiz',
|
|
1654
|
+
Question: 'question'
|
|
1654
1655
|
} as const;
|
|
1655
1656
|
export type GetContentLibraryTagItemListKindEnum = typeof GetContentLibraryTagItemListKindEnum[keyof typeof GetContentLibraryTagItemListKindEnum];
|
|
1656
1657
|
/**
|
package/src/apis/QuestionApi.ts
CHANGED
|
@@ -46,8 +46,7 @@ export interface GetQuestionListRequest {
|
|
|
46
46
|
page?: number;
|
|
47
47
|
pageSize?: number;
|
|
48
48
|
questionType?: GetQuestionListQuestionTypeEnum;
|
|
49
|
-
|
|
50
|
-
tags?: Array<string>;
|
|
49
|
+
tagId?: string;
|
|
51
50
|
search?: string;
|
|
52
51
|
}
|
|
53
52
|
|
|
@@ -172,12 +171,8 @@ export class QuestionApi extends runtime.BaseAPI {
|
|
|
172
171
|
queryParameters['question_type'] = requestParameters['questionType'];
|
|
173
172
|
}
|
|
174
173
|
|
|
175
|
-
if (requestParameters['
|
|
176
|
-
queryParameters['
|
|
177
|
-
}
|
|
178
|
-
|
|
179
|
-
if (requestParameters['tags'] != null) {
|
|
180
|
-
queryParameters['tags'] = requestParameters['tags'];
|
|
174
|
+
if (requestParameters['tagId'] != null) {
|
|
175
|
+
queryParameters['tag_id'] = requestParameters['tagId'];
|
|
181
176
|
}
|
|
182
177
|
|
|
183
178
|
if (requestParameters['search'] != null) {
|
|
@@ -328,12 +323,3 @@ export const GetQuestionListQuestionTypeEnum = {
|
|
|
328
323
|
FillInBlank: 'fill_in_blank'
|
|
329
324
|
} as const;
|
|
330
325
|
export type GetQuestionListQuestionTypeEnum = typeof GetQuestionListQuestionTypeEnum[keyof typeof GetQuestionListQuestionTypeEnum];
|
|
331
|
-
/**
|
|
332
|
-
* @export
|
|
333
|
-
*/
|
|
334
|
-
export const GetQuestionListDifficultyLevelEnum = {
|
|
335
|
-
Beginner: 'beginner',
|
|
336
|
-
Intermediate: 'intermediate',
|
|
337
|
-
Advanced: 'advanced'
|
|
338
|
-
} as const;
|
|
339
|
-
export type GetQuestionListDifficultyLevelEnum = typeof GetQuestionListDifficultyLevelEnum[keyof typeof GetQuestionListDifficultyLevelEnum];
|
|
@@ -85,6 +85,12 @@ export interface ContentLibraryTag {
|
|
|
85
85
|
* @memberof ContentLibraryTag
|
|
86
86
|
*/
|
|
87
87
|
quizCount: number;
|
|
88
|
+
/**
|
|
89
|
+
*
|
|
90
|
+
* @type {number}
|
|
91
|
+
* @memberof ContentLibraryTag
|
|
92
|
+
*/
|
|
93
|
+
questionCount: number;
|
|
88
94
|
/**
|
|
89
95
|
*
|
|
90
96
|
* @type {number}
|
|
@@ -111,6 +117,7 @@ export function instanceOfContentLibraryTag(value: object): value is ContentLibr
|
|
|
111
117
|
if (!('archivedItemCount' in value) || value['archivedItemCount'] === undefined) return false;
|
|
112
118
|
if (!('resourceCount' in value) || value['resourceCount'] === undefined) return false;
|
|
113
119
|
if (!('quizCount' in value) || value['quizCount'] === undefined) return false;
|
|
120
|
+
if (!('questionCount' in value) || value['questionCount'] === undefined) return false;
|
|
114
121
|
if (!('createdAt' in value) || value['createdAt'] === undefined) return false;
|
|
115
122
|
if (!('updatedAt' in value) || value['updatedAt'] === undefined) return false;
|
|
116
123
|
return true;
|
|
@@ -137,6 +144,7 @@ export function ContentLibraryTagFromJSONTyped(json: any, ignoreDiscriminator: b
|
|
|
137
144
|
'archivedItemCount': json['archived_item_count'],
|
|
138
145
|
'resourceCount': json['resource_count'],
|
|
139
146
|
'quizCount': json['quiz_count'],
|
|
147
|
+
'questionCount': json['question_count'],
|
|
140
148
|
'createdAt': json['created_at'],
|
|
141
149
|
'updatedAt': json['updated_at'],
|
|
142
150
|
};
|
|
@@ -164,6 +172,7 @@ export function ContentLibraryTagToJSONTyped(value?: ContentLibraryTag | null, i
|
|
|
164
172
|
'archived_item_count': value['archivedItemCount'],
|
|
165
173
|
'resource_count': value['resourceCount'],
|
|
166
174
|
'quiz_count': value['quizCount'],
|
|
175
|
+
'question_count': value['questionCount'],
|
|
167
176
|
'created_at': value['createdAt'],
|
|
168
177
|
'updated_at': value['updatedAt'],
|
|
169
178
|
};
|
|
@@ -90,7 +90,8 @@ export interface ContentLibraryTagItem {
|
|
|
90
90
|
*/
|
|
91
91
|
export const ContentLibraryTagItemKindEnum = {
|
|
92
92
|
Resource: 'resource',
|
|
93
|
-
Quiz: 'quiz'
|
|
93
|
+
Quiz: 'quiz',
|
|
94
|
+
Question: 'question'
|
|
94
95
|
} as const;
|
|
95
96
|
export type ContentLibraryTagItemKindEnum = typeof ContentLibraryTagItemKindEnum[keyof typeof ContentLibraryTagItemKindEnum];
|
|
96
97
|
|
|
@@ -20,6 +20,13 @@ import {
|
|
|
20
20
|
RichTextDocumentToJSON,
|
|
21
21
|
RichTextDocumentToJSONTyped,
|
|
22
22
|
} from './RichTextDocument';
|
|
23
|
+
import type { ContentLibraryTag } from './ContentLibraryTag';
|
|
24
|
+
import {
|
|
25
|
+
ContentLibraryTagFromJSON,
|
|
26
|
+
ContentLibraryTagFromJSONTyped,
|
|
27
|
+
ContentLibraryTagToJSON,
|
|
28
|
+
ContentLibraryTagToJSONTyped,
|
|
29
|
+
} from './ContentLibraryTag';
|
|
23
30
|
import type { GetQuestionAnswerChoicesInner } from './GetQuestionAnswerChoicesInner';
|
|
24
31
|
import {
|
|
25
32
|
GetQuestionAnswerChoicesInnerFromJSON,
|
|
@@ -78,17 +85,11 @@ export interface GetQuestion {
|
|
|
78
85
|
*/
|
|
79
86
|
explanation?: RichTextDocument;
|
|
80
87
|
/**
|
|
81
|
-
*
|
|
82
|
-
* @type {
|
|
88
|
+
* Shared tags associated with the question
|
|
89
|
+
* @type {Array<ContentLibraryTag>}
|
|
83
90
|
* @memberof GetQuestion
|
|
84
91
|
*/
|
|
85
|
-
|
|
86
|
-
/**
|
|
87
|
-
* Keywords/tags for granular filtering
|
|
88
|
-
* @type {Array<string>}
|
|
89
|
-
* @memberof GetQuestion
|
|
90
|
-
*/
|
|
91
|
-
tags?: Array<string>;
|
|
92
|
+
tags?: Array<ContentLibraryTag>;
|
|
92
93
|
/**
|
|
93
94
|
* Version identifier for triannual updates
|
|
94
95
|
* @type {string}
|
|
@@ -147,16 +148,6 @@ export const GetQuestionQuestionTypeEnum = {
|
|
|
147
148
|
} as const;
|
|
148
149
|
export type GetQuestionQuestionTypeEnum = typeof GetQuestionQuestionTypeEnum[keyof typeof GetQuestionQuestionTypeEnum];
|
|
149
150
|
|
|
150
|
-
/**
|
|
151
|
-
* @export
|
|
152
|
-
*/
|
|
153
|
-
export const GetQuestionDifficultyLevelEnum = {
|
|
154
|
-
Beginner: 'beginner',
|
|
155
|
-
Intermediate: 'intermediate',
|
|
156
|
-
Advanced: 'advanced'
|
|
157
|
-
} as const;
|
|
158
|
-
export type GetQuestionDifficultyLevelEnum = typeof GetQuestionDifficultyLevelEnum[keyof typeof GetQuestionDifficultyLevelEnum];
|
|
159
|
-
|
|
160
151
|
|
|
161
152
|
/**
|
|
162
153
|
* Check if a given object implements the GetQuestion interface.
|
|
@@ -165,7 +156,6 @@ export function instanceOfGetQuestion(value: object): value is GetQuestion {
|
|
|
165
156
|
if (!('id' in value) || value['id'] === undefined) return false;
|
|
166
157
|
if (!('questionText' in value) || value['questionText'] === undefined) return false;
|
|
167
158
|
if (!('questionType' in value) || value['questionType'] === undefined) return false;
|
|
168
|
-
if (!('difficultyLevel' in value) || value['difficultyLevel'] === undefined) return false;
|
|
169
159
|
if (!('versionNumber' in value) || value['versionNumber'] === undefined) return false;
|
|
170
160
|
if (!('createdDate' in value) || value['createdDate'] === undefined) return false;
|
|
171
161
|
if (!('updatedDate' in value) || value['updatedDate'] === undefined) return false;
|
|
@@ -188,8 +178,7 @@ export function GetQuestionFromJSONTyped(json: any, ignoreDiscriminator: boolean
|
|
|
188
178
|
'answerChoices': json['answer_choices'] == null ? undefined : ((json['answer_choices'] as Array<any>).map(GetQuestionAnswerChoicesInnerFromJSON)),
|
|
189
179
|
'correctAnswer': json['correct_answer'] == null ? undefined : json['correct_answer'],
|
|
190
180
|
'explanation': json['explanation'] == null ? undefined : RichTextDocumentFromJSON(json['explanation']),
|
|
191
|
-
'
|
|
192
|
-
'tags': json['tags'] == null ? undefined : json['tags'],
|
|
181
|
+
'tags': json['tags'] == null ? undefined : ((json['tags'] as Array<any>).map(ContentLibraryTagFromJSON)),
|
|
193
182
|
'version': json['version'] == null ? undefined : json['version'],
|
|
194
183
|
'versionNumber': json['version_number'],
|
|
195
184
|
'createdDate': (new Date(json['created_date'])),
|
|
@@ -216,8 +205,7 @@ export function GetQuestionToJSONTyped(value?: Omit<GetQuestion, 'id'|'version_n
|
|
|
216
205
|
'answer_choices': value['answerChoices'] == null ? undefined : ((value['answerChoices'] as Array<any>).map(GetQuestionAnswerChoicesInnerToJSON)),
|
|
217
206
|
'correct_answer': value['correctAnswer'],
|
|
218
207
|
'explanation': RichTextDocumentToJSON(value['explanation']),
|
|
219
|
-
'
|
|
220
|
-
'tags': value['tags'],
|
|
208
|
+
'tags': value['tags'] == null ? undefined : ((value['tags'] as Array<any>).map(ContentLibraryTagToJSON)),
|
|
221
209
|
'version': value['version'],
|
|
222
210
|
};
|
|
223
211
|
}
|
|
@@ -26,17 +26,11 @@ export interface GetQuestionListFilters {
|
|
|
26
26
|
*/
|
|
27
27
|
questionType?: GetQuestionListFiltersQuestionTypeEnum;
|
|
28
28
|
/**
|
|
29
|
-
* Filter by
|
|
30
|
-
* @type {
|
|
31
|
-
* @memberof GetQuestionListFilters
|
|
32
|
-
*/
|
|
33
|
-
difficultyLevel?: GetQuestionListFiltersDifficultyLevelEnum;
|
|
34
|
-
/**
|
|
35
|
-
* Filter by tags/keywords
|
|
36
|
-
* @type {Array<string>}
|
|
29
|
+
* Filter by a shared tag
|
|
30
|
+
* @type {string}
|
|
37
31
|
* @memberof GetQuestionListFilters
|
|
38
32
|
*/
|
|
39
|
-
|
|
33
|
+
tagId?: string;
|
|
40
34
|
/**
|
|
41
35
|
* Search in question text
|
|
42
36
|
* @type {string}
|
|
@@ -71,16 +65,6 @@ export const GetQuestionListFiltersQuestionTypeEnum = {
|
|
|
71
65
|
} as const;
|
|
72
66
|
export type GetQuestionListFiltersQuestionTypeEnum = typeof GetQuestionListFiltersQuestionTypeEnum[keyof typeof GetQuestionListFiltersQuestionTypeEnum];
|
|
73
67
|
|
|
74
|
-
/**
|
|
75
|
-
* @export
|
|
76
|
-
*/
|
|
77
|
-
export const GetQuestionListFiltersDifficultyLevelEnum = {
|
|
78
|
-
Beginner: 'beginner',
|
|
79
|
-
Intermediate: 'intermediate',
|
|
80
|
-
Advanced: 'advanced'
|
|
81
|
-
} as const;
|
|
82
|
-
export type GetQuestionListFiltersDifficultyLevelEnum = typeof GetQuestionListFiltersDifficultyLevelEnum[keyof typeof GetQuestionListFiltersDifficultyLevelEnum];
|
|
83
|
-
|
|
84
68
|
|
|
85
69
|
/**
|
|
86
70
|
* Check if a given object implements the GetQuestionListFilters interface.
|
|
@@ -100,8 +84,7 @@ export function GetQuestionListFiltersFromJSONTyped(json: any, ignoreDiscriminat
|
|
|
100
84
|
return {
|
|
101
85
|
|
|
102
86
|
'questionType': json['question_type'] == null ? undefined : json['question_type'],
|
|
103
|
-
'
|
|
104
|
-
'tags': json['tags'] == null ? undefined : json['tags'],
|
|
87
|
+
'tagId': json['tag_id'] == null ? undefined : json['tag_id'],
|
|
105
88
|
'search': json['search'] == null ? undefined : json['search'],
|
|
106
89
|
'createdAfter': json['created_after'] == null ? undefined : (new Date(json['created_after'])),
|
|
107
90
|
'createdBefore': json['created_before'] == null ? undefined : (new Date(json['created_before'])),
|
|
@@ -120,8 +103,7 @@ export function GetQuestionListFiltersToJSONTyped(value?: GetQuestionListFilters
|
|
|
120
103
|
return {
|
|
121
104
|
|
|
122
105
|
'question_type': value['questionType'],
|
|
123
|
-
'
|
|
124
|
-
'tags': value['tags'],
|
|
106
|
+
'tag_id': value['tagId'],
|
|
125
107
|
'search': value['search'],
|
|
126
108
|
'created_after': value['createdAfter'] == null ? value['createdAfter'] : value['createdAfter'].toISOString().substring(0,10),
|
|
127
109
|
'created_before': value['createdBefore'] == null ? value['createdBefore'] : value['createdBefore'].toISOString().substring(0,10),
|
|
@@ -57,12 +57,6 @@ export interface LibraryQuizCriteriaPreviewQuestion {
|
|
|
57
57
|
* @memberof LibraryQuizCriteriaPreviewQuestion
|
|
58
58
|
*/
|
|
59
59
|
version?: string | null;
|
|
60
|
-
/**
|
|
61
|
-
*
|
|
62
|
-
* @type {LibraryQuizCriteriaPreviewQuestionDifficultyLevelEnum}
|
|
63
|
-
* @memberof LibraryQuizCriteriaPreviewQuestion
|
|
64
|
-
*/
|
|
65
|
-
difficultyLevel: LibraryQuizCriteriaPreviewQuestionDifficultyLevelEnum;
|
|
66
60
|
/**
|
|
67
61
|
*
|
|
68
62
|
* @type {Array<string>}
|
|
@@ -85,16 +79,6 @@ export const LibraryQuizCriteriaPreviewQuestionQuestionTypeEnum = {
|
|
|
85
79
|
} as const;
|
|
86
80
|
export type LibraryQuizCriteriaPreviewQuestionQuestionTypeEnum = typeof LibraryQuizCriteriaPreviewQuestionQuestionTypeEnum[keyof typeof LibraryQuizCriteriaPreviewQuestionQuestionTypeEnum];
|
|
87
81
|
|
|
88
|
-
/**
|
|
89
|
-
* @export
|
|
90
|
-
*/
|
|
91
|
-
export const LibraryQuizCriteriaPreviewQuestionDifficultyLevelEnum = {
|
|
92
|
-
Beginner: 'beginner',
|
|
93
|
-
Intermediate: 'intermediate',
|
|
94
|
-
Advanced: 'advanced'
|
|
95
|
-
} as const;
|
|
96
|
-
export type LibraryQuizCriteriaPreviewQuestionDifficultyLevelEnum = typeof LibraryQuizCriteriaPreviewQuestionDifficultyLevelEnum[keyof typeof LibraryQuizCriteriaPreviewQuestionDifficultyLevelEnum];
|
|
97
|
-
|
|
98
82
|
|
|
99
83
|
/**
|
|
100
84
|
* Check if a given object implements the LibraryQuizCriteriaPreviewQuestion interface.
|
|
@@ -104,7 +88,6 @@ export function instanceOfLibraryQuizCriteriaPreviewQuestion(value: object): val
|
|
|
104
88
|
if (!('questionText' in value) || value['questionText'] === undefined) return false;
|
|
105
89
|
if (!('questionType' in value) || value['questionType'] === undefined) return false;
|
|
106
90
|
if (!('versionNumber' in value) || value['versionNumber'] === undefined) return false;
|
|
107
|
-
if (!('difficultyLevel' in value) || value['difficultyLevel'] === undefined) return false;
|
|
108
91
|
if (!('tags' in value) || value['tags'] === undefined) return false;
|
|
109
92
|
return true;
|
|
110
93
|
}
|
|
@@ -124,7 +107,6 @@ export function LibraryQuizCriteriaPreviewQuestionFromJSONTyped(json: any, ignor
|
|
|
124
107
|
'questionType': json['question_type'],
|
|
125
108
|
'versionNumber': json['version_number'],
|
|
126
109
|
'version': json['version'] == null ? undefined : json['version'],
|
|
127
|
-
'difficultyLevel': json['difficulty_level'],
|
|
128
110
|
'tags': json['tags'],
|
|
129
111
|
};
|
|
130
112
|
}
|
|
@@ -145,7 +127,6 @@ export function LibraryQuizCriteriaPreviewQuestionToJSONTyped(value?: LibraryQui
|
|
|
145
127
|
'question_type': value['questionType'],
|
|
146
128
|
'version_number': value['versionNumber'],
|
|
147
129
|
'version': value['version'],
|
|
148
|
-
'difficulty_level': value['difficultyLevel'],
|
|
149
130
|
'tags': value['tags'],
|
|
150
131
|
};
|
|
151
132
|
}
|
|
@@ -25,12 +25,6 @@ export interface LibraryQuizCriterion {
|
|
|
25
25
|
* @memberof LibraryQuizCriterion
|
|
26
26
|
*/
|
|
27
27
|
id?: string | null;
|
|
28
|
-
/**
|
|
29
|
-
*
|
|
30
|
-
* @type {LibraryQuizCriterionDifficultyLevelEnum}
|
|
31
|
-
* @memberof LibraryQuizCriterion
|
|
32
|
-
*/
|
|
33
|
-
difficultyLevel?: LibraryQuizCriterionDifficultyLevelEnum | null;
|
|
34
28
|
/**
|
|
35
29
|
*
|
|
36
30
|
* @type {LibraryQuizCriterionQuestionTypeEnum}
|
|
@@ -64,16 +58,6 @@ export interface LibraryQuizCriterion {
|
|
|
64
58
|
}
|
|
65
59
|
|
|
66
60
|
|
|
67
|
-
/**
|
|
68
|
-
* @export
|
|
69
|
-
*/
|
|
70
|
-
export const LibraryQuizCriterionDifficultyLevelEnum = {
|
|
71
|
-
Beginner: 'beginner',
|
|
72
|
-
Intermediate: 'intermediate',
|
|
73
|
-
Advanced: 'advanced'
|
|
74
|
-
} as const;
|
|
75
|
-
export type LibraryQuizCriterionDifficultyLevelEnum = typeof LibraryQuizCriterionDifficultyLevelEnum[keyof typeof LibraryQuizCriterionDifficultyLevelEnum];
|
|
76
|
-
|
|
77
61
|
/**
|
|
78
62
|
* @export
|
|
79
63
|
*/
|
|
@@ -107,7 +91,6 @@ export function LibraryQuizCriterionFromJSONTyped(json: any, ignoreDiscriminator
|
|
|
107
91
|
return {
|
|
108
92
|
|
|
109
93
|
'id': json['id'] == null ? undefined : json['id'],
|
|
110
|
-
'difficultyLevel': json['difficulty_level'] == null ? undefined : json['difficulty_level'],
|
|
111
94
|
'questionType': json['question_type'] == null ? undefined : json['question_type'],
|
|
112
95
|
'tags': json['tags'] == null ? undefined : json['tags'],
|
|
113
96
|
'minQuestions': json['min_questions'] == null ? undefined : json['min_questions'],
|
|
@@ -128,7 +111,6 @@ export function LibraryQuizCriterionToJSONTyped(value?: LibraryQuizCriterion | n
|
|
|
128
111
|
return {
|
|
129
112
|
|
|
130
113
|
'id': value['id'],
|
|
131
|
-
'difficulty_level': value['difficultyLevel'],
|
|
132
114
|
'question_type': value['questionType'],
|
|
133
115
|
'tags': value['tags'],
|
|
134
116
|
'min_questions': value['minQuestions'],
|