@easyedu/js-lsm-api 1.88.0 → 1.90.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/.openapi-generator/FILES +8 -0
- package/README.md +11 -2
- package/dist/apis/ContentLibraryApi.d.ts +19 -0
- package/dist/apis/ContentLibraryApi.js +47 -0
- package/dist/apis/PlayerApi.d.ts +73 -0
- package/dist/apis/PlayerApi.js +188 -0
- package/dist/esm/apis/ContentLibraryApi.d.ts +19 -0
- package/dist/esm/apis/ContentLibraryApi.js +47 -0
- package/dist/esm/apis/PlayerApi.d.ts +73 -0
- package/dist/esm/apis/PlayerApi.js +188 -0
- package/dist/esm/models/CertificateCanvasImageElement.d.ts +0 -13
- package/dist/esm/models/CertificateCanvasImageElement.js +0 -10
- package/dist/esm/models/CertificateCanvasLineElement.d.ts +0 -13
- package/dist/esm/models/CertificateCanvasLineElement.js +0 -10
- package/dist/esm/models/CertificateCanvasPortalLogoElement.d.ts +0 -13
- package/dist/esm/models/CertificateCanvasPortalLogoElement.js +0 -10
- package/dist/esm/models/CertificateCanvasShapeElement.d.ts +0 -13
- package/dist/esm/models/CertificateCanvasShapeElement.js +0 -10
- package/dist/esm/models/CertificateCanvasTextElement.d.ts +0 -13
- package/dist/esm/models/CertificateCanvasTextElement.js +0 -10
- package/dist/esm/models/CertificateCanvasVerificationQrElement.d.ts +0 -13
- package/dist/esm/models/CertificateCanvasVerificationQrElement.js +0 -10
- package/dist/esm/models/GetCourseVersionItemSession.d.ts +7 -0
- package/dist/esm/models/GetCourseVersionItemSession.js +5 -0
- package/dist/esm/models/GetResourceSession.d.ts +161 -0
- package/dist/esm/models/GetResourceSession.js +112 -0
- package/dist/esm/models/GetResourceSessionList.d.ts +57 -0
- package/dist/esm/models/GetResourceSessionList.js +60 -0
- package/dist/esm/models/PostResourceVersionSession.d.ts +32 -0
- package/dist/esm/models/PostResourceVersionSession.js +41 -0
- package/dist/esm/models/ResourceSessionEnvironment.d.ts +25 -0
- package/dist/esm/models/ResourceSessionEnvironment.js +43 -0
- package/dist/esm/models/index.d.ts +4 -0
- package/dist/esm/models/index.js +4 -0
- package/dist/models/CertificateCanvasImageElement.d.ts +0 -13
- package/dist/models/CertificateCanvasImageElement.js +1 -11
- package/dist/models/CertificateCanvasLineElement.d.ts +0 -13
- package/dist/models/CertificateCanvasLineElement.js +0 -11
- package/dist/models/CertificateCanvasPortalLogoElement.d.ts +0 -13
- package/dist/models/CertificateCanvasPortalLogoElement.js +0 -11
- package/dist/models/CertificateCanvasShapeElement.d.ts +0 -13
- package/dist/models/CertificateCanvasShapeElement.js +0 -11
- package/dist/models/CertificateCanvasTextElement.d.ts +0 -13
- package/dist/models/CertificateCanvasTextElement.js +1 -11
- package/dist/models/CertificateCanvasVerificationQrElement.d.ts +0 -13
- package/dist/models/CertificateCanvasVerificationQrElement.js +0 -11
- package/dist/models/GetCourseVersionItemSession.d.ts +7 -0
- package/dist/models/GetCourseVersionItemSession.js +5 -0
- package/dist/models/GetResourceSession.d.ts +161 -0
- package/dist/models/GetResourceSession.js +119 -0
- package/dist/models/GetResourceSessionList.d.ts +57 -0
- package/dist/models/GetResourceSessionList.js +67 -0
- package/dist/models/PostResourceVersionSession.d.ts +32 -0
- package/dist/models/PostResourceVersionSession.js +48 -0
- package/dist/models/ResourceSessionEnvironment.d.ts +25 -0
- package/dist/models/ResourceSessionEnvironment.js +51 -0
- package/dist/models/index.d.ts +4 -0
- package/dist/models/index.js +4 -0
- package/docs/CertificateCanvasElement.md +2 -2
- package/docs/CertificateCanvasImageElement.md +0 -2
- package/docs/CertificateCanvasLineElement.md +0 -2
- package/docs/CertificateCanvasPortalLogoElement.md +0 -2
- package/docs/CertificateCanvasShapeElement.md +0 -2
- package/docs/CertificateCanvasTextElement.md +0 -2
- package/docs/CertificateCanvasVerificationQrElement.md +0 -2
- package/docs/ContentLibraryApi.md +73 -0
- package/docs/GetCourseVersionItemSession.md +2 -0
- package/docs/GetResourceSession.md +77 -0
- package/docs/GetResourceSessionList.md +43 -0
- package/docs/PlayerApi.md +296 -0
- package/docs/PostResourceVersionSession.md +35 -0
- package/docs/ResourceSessionEnvironment.md +33 -0
- package/package.json +1 -1
- package/src/apis/ContentLibraryApi.ts +72 -0
- package/src/apis/PlayerApi.ts +261 -0
- package/src/models/CertificateCanvasImageElement.ts +0 -17
- package/src/models/CertificateCanvasLineElement.ts +0 -19
- package/src/models/CertificateCanvasPortalLogoElement.ts +0 -19
- package/src/models/CertificateCanvasShapeElement.ts +0 -19
- package/src/models/CertificateCanvasTextElement.ts +0 -17
- package/src/models/CertificateCanvasVerificationQrElement.ts +0 -19
- package/src/models/GetCourseVersionItemSession.ts +16 -0
- package/src/models/GetResourceSession.ts +270 -0
- package/src/models/GetResourceSessionList.ts +110 -0
- package/src/models/PostResourceVersionSession.ts +65 -0
- package/src/models/ResourceSessionEnvironment.ts +53 -0
- package/src/models/index.ts +4 -0
|
@@ -0,0 +1,270 @@
|
|
|
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 { ResourceSessionEnvironment } from './ResourceSessionEnvironment';
|
|
17
|
+
import {
|
|
18
|
+
ResourceSessionEnvironmentFromJSON,
|
|
19
|
+
ResourceSessionEnvironmentFromJSONTyped,
|
|
20
|
+
ResourceSessionEnvironmentToJSON,
|
|
21
|
+
ResourceSessionEnvironmentToJSONTyped,
|
|
22
|
+
} from './ResourceSessionEnvironment';
|
|
23
|
+
import type { ResourceType } from './ResourceType';
|
|
24
|
+
import {
|
|
25
|
+
ResourceTypeFromJSON,
|
|
26
|
+
ResourceTypeFromJSONTyped,
|
|
27
|
+
ResourceTypeToJSON,
|
|
28
|
+
ResourceTypeToJSONTyped,
|
|
29
|
+
} from './ResourceType';
|
|
30
|
+
import type { ContentLaunchMode } from './ContentLaunchMode';
|
|
31
|
+
import {
|
|
32
|
+
ContentLaunchModeFromJSON,
|
|
33
|
+
ContentLaunchModeFromJSONTyped,
|
|
34
|
+
ContentLaunchModeToJSON,
|
|
35
|
+
ContentLaunchModeToJSONTyped,
|
|
36
|
+
} from './ContentLaunchMode';
|
|
37
|
+
|
|
38
|
+
/**
|
|
39
|
+
* A user-owned session pinned to an immutable Content Library resource version.
|
|
40
|
+
* @export
|
|
41
|
+
* @interface GetResourceSession
|
|
42
|
+
*/
|
|
43
|
+
export interface GetResourceSession {
|
|
44
|
+
/**
|
|
45
|
+
*
|
|
46
|
+
* @type {string}
|
|
47
|
+
* @memberof GetResourceSession
|
|
48
|
+
*/
|
|
49
|
+
id: string;
|
|
50
|
+
/**
|
|
51
|
+
*
|
|
52
|
+
* @type {string}
|
|
53
|
+
* @memberof GetResourceSession
|
|
54
|
+
*/
|
|
55
|
+
userId: string;
|
|
56
|
+
/**
|
|
57
|
+
*
|
|
58
|
+
* @type {ResourceSessionEnvironment}
|
|
59
|
+
* @memberof GetResourceSession
|
|
60
|
+
*/
|
|
61
|
+
environment: ResourceSessionEnvironment;
|
|
62
|
+
/**
|
|
63
|
+
*
|
|
64
|
+
* @type {string}
|
|
65
|
+
* @memberof GetResourceSession
|
|
66
|
+
*/
|
|
67
|
+
courseId?: string | null;
|
|
68
|
+
/**
|
|
69
|
+
*
|
|
70
|
+
* @type {string}
|
|
71
|
+
* @memberof GetResourceSession
|
|
72
|
+
*/
|
|
73
|
+
courseVersionId?: string | null;
|
|
74
|
+
/**
|
|
75
|
+
*
|
|
76
|
+
* @type {string}
|
|
77
|
+
* @memberof GetResourceSession
|
|
78
|
+
*/
|
|
79
|
+
itemId?: string | null;
|
|
80
|
+
/**
|
|
81
|
+
*
|
|
82
|
+
* @type {string}
|
|
83
|
+
* @memberof GetResourceSession
|
|
84
|
+
*/
|
|
85
|
+
contentLibraryItemId: string;
|
|
86
|
+
/**
|
|
87
|
+
*
|
|
88
|
+
* @type {string}
|
|
89
|
+
* @memberof GetResourceSession
|
|
90
|
+
*/
|
|
91
|
+
contentLibraryVersionId: string;
|
|
92
|
+
/**
|
|
93
|
+
*
|
|
94
|
+
* @type {string}
|
|
95
|
+
* @memberof GetResourceSession
|
|
96
|
+
*/
|
|
97
|
+
resourceName: string;
|
|
98
|
+
/**
|
|
99
|
+
*
|
|
100
|
+
* @type {ResourceType}
|
|
101
|
+
* @memberof GetResourceSession
|
|
102
|
+
*/
|
|
103
|
+
resourceType: ResourceType;
|
|
104
|
+
/**
|
|
105
|
+
*
|
|
106
|
+
* @type {ContentLaunchMode}
|
|
107
|
+
* @memberof GetResourceSession
|
|
108
|
+
*/
|
|
109
|
+
launchMode?: ContentLaunchMode | null;
|
|
110
|
+
/**
|
|
111
|
+
*
|
|
112
|
+
* @type {string}
|
|
113
|
+
* @memberof GetResourceSession
|
|
114
|
+
*/
|
|
115
|
+
launchUrl?: string | null;
|
|
116
|
+
/**
|
|
117
|
+
*
|
|
118
|
+
* @type {number}
|
|
119
|
+
* @memberof GetResourceSession
|
|
120
|
+
*/
|
|
121
|
+
attemptNumber: number;
|
|
122
|
+
/**
|
|
123
|
+
*
|
|
124
|
+
* @type {boolean}
|
|
125
|
+
* @memberof GetResourceSession
|
|
126
|
+
*/
|
|
127
|
+
isCurrent: boolean;
|
|
128
|
+
/**
|
|
129
|
+
*
|
|
130
|
+
* @type {string}
|
|
131
|
+
* @memberof GetResourceSession
|
|
132
|
+
*/
|
|
133
|
+
completionStatus: string;
|
|
134
|
+
/**
|
|
135
|
+
*
|
|
136
|
+
* @type {string}
|
|
137
|
+
* @memberof GetResourceSession
|
|
138
|
+
*/
|
|
139
|
+
gradeStatus: string;
|
|
140
|
+
/**
|
|
141
|
+
*
|
|
142
|
+
* @type {number}
|
|
143
|
+
* @memberof GetResourceSession
|
|
144
|
+
*/
|
|
145
|
+
scoreRaw?: number | null;
|
|
146
|
+
/**
|
|
147
|
+
*
|
|
148
|
+
* @type {number}
|
|
149
|
+
* @memberof GetResourceSession
|
|
150
|
+
*/
|
|
151
|
+
initializedAt?: number | null;
|
|
152
|
+
/**
|
|
153
|
+
*
|
|
154
|
+
* @type {number}
|
|
155
|
+
* @memberof GetResourceSession
|
|
156
|
+
*/
|
|
157
|
+
terminatedAt?: number | null;
|
|
158
|
+
/**
|
|
159
|
+
*
|
|
160
|
+
* @type {number}
|
|
161
|
+
* @memberof GetResourceSession
|
|
162
|
+
*/
|
|
163
|
+
createdAt: number;
|
|
164
|
+
/**
|
|
165
|
+
*
|
|
166
|
+
* @type {number}
|
|
167
|
+
* @memberof GetResourceSession
|
|
168
|
+
*/
|
|
169
|
+
updatedAt: number;
|
|
170
|
+
/**
|
|
171
|
+
*
|
|
172
|
+
* @type {number}
|
|
173
|
+
* @memberof GetResourceSession
|
|
174
|
+
*/
|
|
175
|
+
completedAt?: number | null;
|
|
176
|
+
}
|
|
177
|
+
|
|
178
|
+
|
|
179
|
+
|
|
180
|
+
/**
|
|
181
|
+
* Check if a given object implements the GetResourceSession interface.
|
|
182
|
+
*/
|
|
183
|
+
export function instanceOfGetResourceSession(value: object): value is GetResourceSession {
|
|
184
|
+
if (!('id' in value) || value['id'] === undefined) return false;
|
|
185
|
+
if (!('userId' in value) || value['userId'] === undefined) return false;
|
|
186
|
+
if (!('environment' in value) || value['environment'] === undefined) return false;
|
|
187
|
+
if (!('contentLibraryItemId' in value) || value['contentLibraryItemId'] === undefined) return false;
|
|
188
|
+
if (!('contentLibraryVersionId' in value) || value['contentLibraryVersionId'] === undefined) return false;
|
|
189
|
+
if (!('resourceName' in value) || value['resourceName'] === undefined) return false;
|
|
190
|
+
if (!('resourceType' in value) || value['resourceType'] === undefined) return false;
|
|
191
|
+
if (!('attemptNumber' in value) || value['attemptNumber'] === undefined) return false;
|
|
192
|
+
if (!('isCurrent' in value) || value['isCurrent'] === undefined) return false;
|
|
193
|
+
if (!('completionStatus' in value) || value['completionStatus'] === undefined) return false;
|
|
194
|
+
if (!('gradeStatus' in value) || value['gradeStatus'] === undefined) return false;
|
|
195
|
+
if (!('createdAt' in value) || value['createdAt'] === undefined) return false;
|
|
196
|
+
if (!('updatedAt' in value) || value['updatedAt'] === undefined) return false;
|
|
197
|
+
return true;
|
|
198
|
+
}
|
|
199
|
+
|
|
200
|
+
export function GetResourceSessionFromJSON(json: any): GetResourceSession {
|
|
201
|
+
return GetResourceSessionFromJSONTyped(json, false);
|
|
202
|
+
}
|
|
203
|
+
|
|
204
|
+
export function GetResourceSessionFromJSONTyped(json: any, ignoreDiscriminator: boolean): GetResourceSession {
|
|
205
|
+
if (json == null) {
|
|
206
|
+
return json;
|
|
207
|
+
}
|
|
208
|
+
return {
|
|
209
|
+
|
|
210
|
+
'id': json['id'],
|
|
211
|
+
'userId': json['user_id'],
|
|
212
|
+
'environment': ResourceSessionEnvironmentFromJSON(json['environment']),
|
|
213
|
+
'courseId': json['course_id'] == null ? undefined : json['course_id'],
|
|
214
|
+
'courseVersionId': json['course_version_id'] == null ? undefined : json['course_version_id'],
|
|
215
|
+
'itemId': json['item_id'] == null ? undefined : json['item_id'],
|
|
216
|
+
'contentLibraryItemId': json['content_library_item_id'],
|
|
217
|
+
'contentLibraryVersionId': json['content_library_version_id'],
|
|
218
|
+
'resourceName': json['resource_name'],
|
|
219
|
+
'resourceType': ResourceTypeFromJSON(json['resource_type']),
|
|
220
|
+
'launchMode': json['launch_mode'] == null ? undefined : ContentLaunchModeFromJSON(json['launch_mode']),
|
|
221
|
+
'launchUrl': json['launch_url'] == null ? undefined : json['launch_url'],
|
|
222
|
+
'attemptNumber': json['attempt_number'],
|
|
223
|
+
'isCurrent': json['is_current'],
|
|
224
|
+
'completionStatus': json['completion_status'],
|
|
225
|
+
'gradeStatus': json['grade_status'],
|
|
226
|
+
'scoreRaw': json['score_raw'] == null ? undefined : json['score_raw'],
|
|
227
|
+
'initializedAt': json['initialized_at'] == null ? undefined : json['initialized_at'],
|
|
228
|
+
'terminatedAt': json['terminated_at'] == null ? undefined : json['terminated_at'],
|
|
229
|
+
'createdAt': json['created_at'],
|
|
230
|
+
'updatedAt': json['updated_at'],
|
|
231
|
+
'completedAt': json['completed_at'] == null ? undefined : json['completed_at'],
|
|
232
|
+
};
|
|
233
|
+
}
|
|
234
|
+
|
|
235
|
+
export function GetResourceSessionToJSON(json: any): GetResourceSession {
|
|
236
|
+
return GetResourceSessionToJSONTyped(json, false);
|
|
237
|
+
}
|
|
238
|
+
|
|
239
|
+
export function GetResourceSessionToJSONTyped(value?: GetResourceSession | null, ignoreDiscriminator: boolean = false): any {
|
|
240
|
+
if (value == null) {
|
|
241
|
+
return value;
|
|
242
|
+
}
|
|
243
|
+
|
|
244
|
+
return {
|
|
245
|
+
|
|
246
|
+
'id': value['id'],
|
|
247
|
+
'user_id': value['userId'],
|
|
248
|
+
'environment': ResourceSessionEnvironmentToJSON(value['environment']),
|
|
249
|
+
'course_id': value['courseId'],
|
|
250
|
+
'course_version_id': value['courseVersionId'],
|
|
251
|
+
'item_id': value['itemId'],
|
|
252
|
+
'content_library_item_id': value['contentLibraryItemId'],
|
|
253
|
+
'content_library_version_id': value['contentLibraryVersionId'],
|
|
254
|
+
'resource_name': value['resourceName'],
|
|
255
|
+
'resource_type': ResourceTypeToJSON(value['resourceType']),
|
|
256
|
+
'launch_mode': ContentLaunchModeToJSON(value['launchMode']),
|
|
257
|
+
'launch_url': value['launchUrl'],
|
|
258
|
+
'attempt_number': value['attemptNumber'],
|
|
259
|
+
'is_current': value['isCurrent'],
|
|
260
|
+
'completion_status': value['completionStatus'],
|
|
261
|
+
'grade_status': value['gradeStatus'],
|
|
262
|
+
'score_raw': value['scoreRaw'],
|
|
263
|
+
'initialized_at': value['initializedAt'],
|
|
264
|
+
'terminated_at': value['terminatedAt'],
|
|
265
|
+
'created_at': value['createdAt'],
|
|
266
|
+
'updated_at': value['updatedAt'],
|
|
267
|
+
'completed_at': value['completedAt'],
|
|
268
|
+
};
|
|
269
|
+
}
|
|
270
|
+
|
|
@@ -0,0 +1,110 @@
|
|
|
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 { GetResourceSession } from './GetResourceSession';
|
|
17
|
+
import {
|
|
18
|
+
GetResourceSessionFromJSON,
|
|
19
|
+
GetResourceSessionFromJSONTyped,
|
|
20
|
+
GetResourceSessionToJSON,
|
|
21
|
+
GetResourceSessionToJSONTyped,
|
|
22
|
+
} from './GetResourceSession';
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
* A filtered page of resource sessions.
|
|
26
|
+
* @export
|
|
27
|
+
* @interface GetResourceSessionList
|
|
28
|
+
*/
|
|
29
|
+
export interface GetResourceSessionList {
|
|
30
|
+
/**
|
|
31
|
+
*
|
|
32
|
+
* @type {number}
|
|
33
|
+
* @memberof GetResourceSessionList
|
|
34
|
+
*/
|
|
35
|
+
page: number;
|
|
36
|
+
/**
|
|
37
|
+
*
|
|
38
|
+
* @type {number}
|
|
39
|
+
* @memberof GetResourceSessionList
|
|
40
|
+
*/
|
|
41
|
+
pageSize: number;
|
|
42
|
+
/**
|
|
43
|
+
*
|
|
44
|
+
* @type {number}
|
|
45
|
+
* @memberof GetResourceSessionList
|
|
46
|
+
*/
|
|
47
|
+
totalPages: number;
|
|
48
|
+
/**
|
|
49
|
+
*
|
|
50
|
+
* @type {number}
|
|
51
|
+
* @memberof GetResourceSessionList
|
|
52
|
+
*/
|
|
53
|
+
totalItems: number;
|
|
54
|
+
/**
|
|
55
|
+
*
|
|
56
|
+
* @type {Array<GetResourceSession>}
|
|
57
|
+
* @memberof GetResourceSessionList
|
|
58
|
+
*/
|
|
59
|
+
items: Array<GetResourceSession>;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
/**
|
|
63
|
+
* Check if a given object implements the GetResourceSessionList interface.
|
|
64
|
+
*/
|
|
65
|
+
export function instanceOfGetResourceSessionList(value: object): value is GetResourceSessionList {
|
|
66
|
+
if (!('page' in value) || value['page'] === undefined) return false;
|
|
67
|
+
if (!('pageSize' in value) || value['pageSize'] === undefined) return false;
|
|
68
|
+
if (!('totalPages' in value) || value['totalPages'] === undefined) return false;
|
|
69
|
+
if (!('totalItems' in value) || value['totalItems'] === undefined) return false;
|
|
70
|
+
if (!('items' in value) || value['items'] === undefined) return false;
|
|
71
|
+
return true;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
export function GetResourceSessionListFromJSON(json: any): GetResourceSessionList {
|
|
75
|
+
return GetResourceSessionListFromJSONTyped(json, false);
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
export function GetResourceSessionListFromJSONTyped(json: any, ignoreDiscriminator: boolean): GetResourceSessionList {
|
|
79
|
+
if (json == null) {
|
|
80
|
+
return json;
|
|
81
|
+
}
|
|
82
|
+
return {
|
|
83
|
+
|
|
84
|
+
'page': json['page'],
|
|
85
|
+
'pageSize': json['pageSize'],
|
|
86
|
+
'totalPages': json['totalPages'],
|
|
87
|
+
'totalItems': json['totalItems'],
|
|
88
|
+
'items': ((json['items'] as Array<any>).map(GetResourceSessionFromJSON)),
|
|
89
|
+
};
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
export function GetResourceSessionListToJSON(json: any): GetResourceSessionList {
|
|
93
|
+
return GetResourceSessionListToJSONTyped(json, false);
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
export function GetResourceSessionListToJSONTyped(value?: GetResourceSessionList | null, ignoreDiscriminator: boolean = false): any {
|
|
97
|
+
if (value == null) {
|
|
98
|
+
return value;
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
return {
|
|
102
|
+
|
|
103
|
+
'page': value['page'],
|
|
104
|
+
'pageSize': value['pageSize'],
|
|
105
|
+
'totalPages': value['totalPages'],
|
|
106
|
+
'totalItems': value['totalItems'],
|
|
107
|
+
'items': ((value['items'] as Array<any>).map(GetResourceSessionToJSON)),
|
|
108
|
+
};
|
|
109
|
+
}
|
|
110
|
+
|
|
@@ -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
|
+
* Start or resume an isolated demo session for an exact resource version.
|
|
18
|
+
* @export
|
|
19
|
+
* @interface PostResourceVersionSession
|
|
20
|
+
*/
|
|
21
|
+
export interface PostResourceVersionSession {
|
|
22
|
+
/**
|
|
23
|
+
* Create a clean demo attempt instead of resuming the current demo session.
|
|
24
|
+
* @type {boolean}
|
|
25
|
+
* @memberof PostResourceVersionSession
|
|
26
|
+
*/
|
|
27
|
+
restart?: boolean;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
/**
|
|
31
|
+
* Check if a given object implements the PostResourceVersionSession interface.
|
|
32
|
+
*/
|
|
33
|
+
export function instanceOfPostResourceVersionSession(value: object): value is PostResourceVersionSession {
|
|
34
|
+
return true;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
export function PostResourceVersionSessionFromJSON(json: any): PostResourceVersionSession {
|
|
38
|
+
return PostResourceVersionSessionFromJSONTyped(json, false);
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
export function PostResourceVersionSessionFromJSONTyped(json: any, ignoreDiscriminator: boolean): PostResourceVersionSession {
|
|
42
|
+
if (json == null) {
|
|
43
|
+
return json;
|
|
44
|
+
}
|
|
45
|
+
return {
|
|
46
|
+
|
|
47
|
+
'restart': json['restart'] == null ? undefined : json['restart'],
|
|
48
|
+
};
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
export function PostResourceVersionSessionToJSON(json: any): PostResourceVersionSession {
|
|
52
|
+
return PostResourceVersionSessionToJSONTyped(json, false);
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
export function PostResourceVersionSessionToJSONTyped(value?: PostResourceVersionSession | null, ignoreDiscriminator: boolean = false): any {
|
|
56
|
+
if (value == null) {
|
|
57
|
+
return value;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
return {
|
|
61
|
+
|
|
62
|
+
'restart': value['restart'],
|
|
63
|
+
};
|
|
64
|
+
}
|
|
65
|
+
|
|
@@ -0,0 +1,53 @@
|
|
|
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
|
+
|
|
16
|
+
/**
|
|
17
|
+
* Whether the session contributes to learner activity or is isolated administrator testing.
|
|
18
|
+
* @export
|
|
19
|
+
*/
|
|
20
|
+
export const ResourceSessionEnvironment = {
|
|
21
|
+
Live: 'live',
|
|
22
|
+
Demo: 'demo'
|
|
23
|
+
} as const;
|
|
24
|
+
export type ResourceSessionEnvironment = typeof ResourceSessionEnvironment[keyof typeof ResourceSessionEnvironment];
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
export function instanceOfResourceSessionEnvironment(value: any): boolean {
|
|
28
|
+
for (const key in ResourceSessionEnvironment) {
|
|
29
|
+
if (Object.prototype.hasOwnProperty.call(ResourceSessionEnvironment, key)) {
|
|
30
|
+
if (ResourceSessionEnvironment[key as keyof typeof ResourceSessionEnvironment] === value) {
|
|
31
|
+
return true;
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
return false;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
export function ResourceSessionEnvironmentFromJSON(json: any): ResourceSessionEnvironment {
|
|
39
|
+
return ResourceSessionEnvironmentFromJSONTyped(json, false);
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
export function ResourceSessionEnvironmentFromJSONTyped(json: any, ignoreDiscriminator: boolean): ResourceSessionEnvironment {
|
|
43
|
+
return json as ResourceSessionEnvironment;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
export function ResourceSessionEnvironmentToJSON(value?: ResourceSessionEnvironment | null): any {
|
|
47
|
+
return value as any;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
export function ResourceSessionEnvironmentToJSONTyped(value: any, ignoreDiscriminator: boolean): ResourceSessionEnvironment {
|
|
51
|
+
return value as ResourceSessionEnvironment;
|
|
52
|
+
}
|
|
53
|
+
|
package/src/models/index.ts
CHANGED
|
@@ -182,6 +182,8 @@ export * from './GetQuizResultsTiming';
|
|
|
182
182
|
export * from './GetQuizStatistics';
|
|
183
183
|
export * from './GetResource';
|
|
184
184
|
export * from './GetResourceList';
|
|
185
|
+
export * from './GetResourceSession';
|
|
186
|
+
export * from './GetResourceSessionList';
|
|
185
187
|
export * from './GetResourceUsage';
|
|
186
188
|
export * from './GetResourceUsageCoursesInner';
|
|
187
189
|
export * from './GetResourceVersionUpload';
|
|
@@ -299,6 +301,7 @@ export * from './PostResetPassword';
|
|
|
299
301
|
export * from './PostResource';
|
|
300
302
|
export * from './PostResourceVersion';
|
|
301
303
|
export * from './PostResourceVersionComplete';
|
|
304
|
+
export * from './PostResourceVersionSession';
|
|
302
305
|
export * from './PostResourceVersionUpload';
|
|
303
306
|
export * from './PostRevokeCertificate';
|
|
304
307
|
export * from './PostRichTextAssetComplete';
|
|
@@ -350,6 +353,7 @@ export * from './PutUser';
|
|
|
350
353
|
export * from './QuizContent';
|
|
351
354
|
export * from './QuizContentAssignment';
|
|
352
355
|
export * from './QuizContentSettings';
|
|
356
|
+
export * from './ResourceSessionEnvironment';
|
|
353
357
|
export * from './ResourceType';
|
|
354
358
|
export * from './RichTextAsset';
|
|
355
359
|
export * from './RichTextDocument';
|