@easyedu/js-lsm-api 1.98.0 → 1.99.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 +10 -0
- package/README.md +10 -2
- package/dist/apis/PlayerApi.d.ts +57 -0
- package/dist/apis/PlayerApi.js +148 -0
- package/dist/esm/apis/PlayerApi.d.ts +57 -0
- package/dist/esm/apis/PlayerApi.js +148 -0
- package/dist/esm/models/GetCourseVersionItemSession.d.ts +6 -0
- package/dist/esm/models/GetCourseVersionItemSession.js +4 -0
- package/dist/esm/models/GetLibraryQuizSession.d.ts +6 -0
- package/dist/esm/models/GetLibraryQuizSession.js +4 -0
- package/dist/esm/models/GetResourceSession.d.ts +6 -0
- package/dist/esm/models/GetResourceSession.js +4 -0
- package/dist/esm/models/GetResourceSessionActivity.d.ts +125 -0
- package/dist/esm/models/GetResourceSessionActivity.js +97 -0
- package/dist/esm/models/GetResourceSessionActivityEvent.d.ts +62 -0
- package/dist/esm/models/GetResourceSessionActivityEvent.js +61 -0
- package/dist/esm/models/GetResourceSessionActivityEventList.d.ts +33 -0
- package/dist/esm/models/GetResourceSessionActivityEventList.js +44 -0
- package/dist/esm/models/GetResourceSessionActivityList.d.ts +33 -0
- package/dist/esm/models/GetResourceSessionActivityList.js +44 -0
- package/dist/esm/models/PostResourceSessionActivityEvent.d.ts +62 -0
- package/dist/esm/models/PostResourceSessionActivityEvent.js +66 -0
- package/dist/esm/models/index.d.ts +5 -0
- package/dist/esm/models/index.js +5 -0
- package/dist/models/GetCourseVersionItemSession.d.ts +6 -0
- package/dist/models/GetCourseVersionItemSession.js +4 -0
- package/dist/models/GetLibraryQuizSession.d.ts +6 -0
- package/dist/models/GetLibraryQuizSession.js +4 -0
- package/dist/models/GetResourceSession.d.ts +6 -0
- package/dist/models/GetResourceSession.js +4 -0
- package/dist/models/GetResourceSessionActivity.d.ts +125 -0
- package/dist/models/GetResourceSessionActivity.js +105 -0
- package/dist/models/GetResourceSessionActivityEvent.d.ts +62 -0
- package/dist/models/GetResourceSessionActivityEvent.js +68 -0
- package/dist/models/GetResourceSessionActivityEventList.d.ts +33 -0
- package/dist/models/GetResourceSessionActivityEventList.js +51 -0
- package/dist/models/GetResourceSessionActivityList.d.ts +33 -0
- package/dist/models/GetResourceSessionActivityList.js +51 -0
- package/dist/models/PostResourceSessionActivityEvent.d.ts +62 -0
- package/dist/models/PostResourceSessionActivityEvent.js +74 -0
- package/dist/models/index.d.ts +5 -0
- package/dist/models/index.js +5 -0
- package/docs/ContentLibraryQuizApi.md +2 -2
- package/docs/GetCourseVersionItemSession.md +2 -0
- package/docs/GetLibraryQuizSession.md +2 -0
- package/docs/GetResourceSession.md +2 -0
- package/docs/GetResourceSessionActivity.md +63 -0
- package/docs/GetResourceSessionActivityEvent.md +45 -0
- package/docs/GetResourceSessionActivityEventList.md +35 -0
- package/docs/GetResourceSessionActivityList.md +35 -0
- package/docs/PlayerApi.md +231 -6
- package/docs/PostResourceSessionActivityEvent.md +39 -0
- package/package.json +1 -1
- package/src/apis/PlayerApi.ts +217 -0
- package/src/models/GetCourseVersionItemSession.ts +9 -0
- package/src/models/GetLibraryQuizSession.ts +9 -0
- package/src/models/GetResourceSession.ts +9 -0
- package/src/models/GetResourceSessionActivity.ts +199 -0
- package/src/models/GetResourceSessionActivityEvent.ts +110 -0
- package/src/models/GetResourceSessionActivityEventList.ts +74 -0
- package/src/models/GetResourceSessionActivityList.ts +74 -0
- package/src/models/PostResourceSessionActivityEvent.ts +104 -0
- package/src/models/index.ts +5 -0
|
@@ -22,10 +22,14 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
22
22
|
};
|
|
23
23
|
import * as runtime from '../runtime';
|
|
24
24
|
import { GetResourceSessionFromJSON, } from '../models/GetResourceSession';
|
|
25
|
+
import { GetResourceSessionActivityFromJSON, } from '../models/GetResourceSessionActivity';
|
|
26
|
+
import { GetResourceSessionActivityEventListFromJSON, } from '../models/GetResourceSessionActivityEventList';
|
|
27
|
+
import { GetResourceSessionActivityListFromJSON, } from '../models/GetResourceSessionActivityList';
|
|
25
28
|
import { GetResourceSessionDiagnosticsFromJSON, } from '../models/GetResourceSessionDiagnostics';
|
|
26
29
|
import { GetResourceSessionListFromJSON, } from '../models/GetResourceSessionList';
|
|
27
30
|
import { GetResourceSessionScormApiLogsFromJSON, } from '../models/GetResourceSessionScormApiLogs';
|
|
28
31
|
import { GetResourceSessionScormDataFromJSON, } from '../models/GetResourceSessionScormData';
|
|
32
|
+
import { PostResourceSessionActivityEventToJSON, } from '../models/PostResourceSessionActivityEvent';
|
|
29
33
|
import { ScormGetValueResponseFromJSON, } from '../models/ScormGetValueResponse';
|
|
30
34
|
import { ScormSetValueRequestToJSON, } from '../models/ScormSetValueRequest';
|
|
31
35
|
import { ScormSetValueResponseFromJSON, } from '../models/ScormSetValueResponse';
|
|
@@ -42,6 +46,9 @@ export class PlayerApi extends runtime.BaseAPI {
|
|
|
42
46
|
throw new runtime.RequiredError('sessionId', 'Required parameter "sessionId" was null or undefined when calling commitResourceScormSession().');
|
|
43
47
|
}
|
|
44
48
|
const queryParameters = {};
|
|
49
|
+
if (requestParameters['activityId'] != null) {
|
|
50
|
+
queryParameters['activity_id'] = requestParameters['activityId'];
|
|
51
|
+
}
|
|
45
52
|
const headerParameters = {};
|
|
46
53
|
let urlPath = `/resource/sessions/{sessionId}/commit`;
|
|
47
54
|
urlPath = urlPath.replace('{sessionId}', encodeURIComponent(String(requestParameters['sessionId'])));
|
|
@@ -177,6 +184,9 @@ export class PlayerApi extends runtime.BaseAPI {
|
|
|
177
184
|
if (requestParameters['key'] != null) {
|
|
178
185
|
queryParameters['key'] = requestParameters['key'];
|
|
179
186
|
}
|
|
187
|
+
if (requestParameters['activityId'] != null) {
|
|
188
|
+
queryParameters['activity_id'] = requestParameters['activityId'];
|
|
189
|
+
}
|
|
180
190
|
const headerParameters = {};
|
|
181
191
|
let urlPath = `/resource/sessions/{sessionId}/get-value`;
|
|
182
192
|
urlPath = urlPath.replace('{sessionId}', encodeURIComponent(String(requestParameters['sessionId'])));
|
|
@@ -246,6 +256,84 @@ export class PlayerApi extends runtime.BaseAPI {
|
|
|
246
256
|
return yield response.value();
|
|
247
257
|
});
|
|
248
258
|
}
|
|
259
|
+
/**
|
|
260
|
+
* Creates request options for getResourceSessionActivities without sending the request
|
|
261
|
+
*/
|
|
262
|
+
getResourceSessionActivitiesRequestOpts(requestParameters) {
|
|
263
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
264
|
+
if (requestParameters['sessionId'] == null) {
|
|
265
|
+
throw new runtime.RequiredError('sessionId', 'Required parameter "sessionId" was null or undefined when calling getResourceSessionActivities().');
|
|
266
|
+
}
|
|
267
|
+
const queryParameters = {};
|
|
268
|
+
const headerParameters = {};
|
|
269
|
+
let urlPath = `/resource/sessions/{sessionId}/activities`;
|
|
270
|
+
urlPath = urlPath.replace('{sessionId}', encodeURIComponent(String(requestParameters['sessionId'])));
|
|
271
|
+
return {
|
|
272
|
+
path: urlPath,
|
|
273
|
+
method: 'GET',
|
|
274
|
+
headers: headerParameters,
|
|
275
|
+
query: queryParameters,
|
|
276
|
+
};
|
|
277
|
+
});
|
|
278
|
+
}
|
|
279
|
+
/**
|
|
280
|
+
* List tracked activities for a resource session
|
|
281
|
+
*/
|
|
282
|
+
getResourceSessionActivitiesRaw(requestParameters, initOverrides) {
|
|
283
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
284
|
+
const requestOptions = yield this.getResourceSessionActivitiesRequestOpts(requestParameters);
|
|
285
|
+
const response = yield this.request(requestOptions, initOverrides);
|
|
286
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => GetResourceSessionActivityListFromJSON(jsonValue));
|
|
287
|
+
});
|
|
288
|
+
}
|
|
289
|
+
/**
|
|
290
|
+
* List tracked activities for a resource session
|
|
291
|
+
*/
|
|
292
|
+
getResourceSessionActivities(requestParameters, initOverrides) {
|
|
293
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
294
|
+
const response = yield this.getResourceSessionActivitiesRaw(requestParameters, initOverrides);
|
|
295
|
+
return yield response.value();
|
|
296
|
+
});
|
|
297
|
+
}
|
|
298
|
+
/**
|
|
299
|
+
* Creates request options for getResourceSessionActivityEvents without sending the request
|
|
300
|
+
*/
|
|
301
|
+
getResourceSessionActivityEventsRequestOpts(requestParameters) {
|
|
302
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
303
|
+
if (requestParameters['sessionId'] == null) {
|
|
304
|
+
throw new runtime.RequiredError('sessionId', 'Required parameter "sessionId" was null or undefined when calling getResourceSessionActivityEvents().');
|
|
305
|
+
}
|
|
306
|
+
const queryParameters = {};
|
|
307
|
+
const headerParameters = {};
|
|
308
|
+
let urlPath = `/resource/sessions/{sessionId}/activity-events`;
|
|
309
|
+
urlPath = urlPath.replace('{sessionId}', encodeURIComponent(String(requestParameters['sessionId'])));
|
|
310
|
+
return {
|
|
311
|
+
path: urlPath,
|
|
312
|
+
method: 'GET',
|
|
313
|
+
headers: headerParameters,
|
|
314
|
+
query: queryParameters,
|
|
315
|
+
};
|
|
316
|
+
});
|
|
317
|
+
}
|
|
318
|
+
/**
|
|
319
|
+
* List recorded learner activity events for a resource session
|
|
320
|
+
*/
|
|
321
|
+
getResourceSessionActivityEventsRaw(requestParameters, initOverrides) {
|
|
322
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
323
|
+
const requestOptions = yield this.getResourceSessionActivityEventsRequestOpts(requestParameters);
|
|
324
|
+
const response = yield this.request(requestOptions, initOverrides);
|
|
325
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => GetResourceSessionActivityEventListFromJSON(jsonValue));
|
|
326
|
+
});
|
|
327
|
+
}
|
|
328
|
+
/**
|
|
329
|
+
* List recorded learner activity events for a resource session
|
|
330
|
+
*/
|
|
331
|
+
getResourceSessionActivityEvents(requestParameters, initOverrides) {
|
|
332
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
333
|
+
const response = yield this.getResourceSessionActivityEventsRaw(requestParameters, initOverrides);
|
|
334
|
+
return yield response.value();
|
|
335
|
+
});
|
|
336
|
+
}
|
|
249
337
|
/**
|
|
250
338
|
* Creates request options for getResourceSessionAsset without sending the request
|
|
251
339
|
*/
|
|
@@ -533,6 +621,9 @@ export class PlayerApi extends runtime.BaseAPI {
|
|
|
533
621
|
throw new runtime.RequiredError('sessionId', 'Required parameter "sessionId" was null or undefined when calling getResourceSessionScormData().');
|
|
534
622
|
}
|
|
535
623
|
const queryParameters = {};
|
|
624
|
+
if (requestParameters['activityId'] != null) {
|
|
625
|
+
queryParameters['activity_id'] = requestParameters['activityId'];
|
|
626
|
+
}
|
|
536
627
|
const headerParameters = {};
|
|
537
628
|
let urlPath = `/resource/sessions/{sessionId}/scorm-data`;
|
|
538
629
|
urlPath = urlPath.replace('{sessionId}', encodeURIComponent(String(requestParameters['sessionId'])));
|
|
@@ -572,6 +663,9 @@ export class PlayerApi extends runtime.BaseAPI {
|
|
|
572
663
|
throw new runtime.RequiredError('sessionId', 'Required parameter "sessionId" was null or undefined when calling initializeResourceScormSession().');
|
|
573
664
|
}
|
|
574
665
|
const queryParameters = {};
|
|
666
|
+
if (requestParameters['activityId'] != null) {
|
|
667
|
+
queryParameters['activity_id'] = requestParameters['activityId'];
|
|
668
|
+
}
|
|
575
669
|
const headerParameters = {};
|
|
576
670
|
let urlPath = `/resource/sessions/{sessionId}/initialize`;
|
|
577
671
|
urlPath = urlPath.replace('{sessionId}', encodeURIComponent(String(requestParameters['sessionId'])));
|
|
@@ -601,6 +695,54 @@ export class PlayerApi extends runtime.BaseAPI {
|
|
|
601
695
|
yield this.initializeResourceScormSessionRaw(requestParameters, initOverrides);
|
|
602
696
|
});
|
|
603
697
|
}
|
|
698
|
+
/**
|
|
699
|
+
* Creates request options for postResourceSessionActivityEvent without sending the request
|
|
700
|
+
*/
|
|
701
|
+
postResourceSessionActivityEventRequestOpts(requestParameters) {
|
|
702
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
703
|
+
if (requestParameters['sessionId'] == null) {
|
|
704
|
+
throw new runtime.RequiredError('sessionId', 'Required parameter "sessionId" was null or undefined when calling postResourceSessionActivityEvent().');
|
|
705
|
+
}
|
|
706
|
+
if (requestParameters['activityId'] == null) {
|
|
707
|
+
throw new runtime.RequiredError('activityId', 'Required parameter "activityId" was null or undefined when calling postResourceSessionActivityEvent().');
|
|
708
|
+
}
|
|
709
|
+
if (requestParameters['postResourceSessionActivityEvent'] == null) {
|
|
710
|
+
throw new runtime.RequiredError('postResourceSessionActivityEvent', 'Required parameter "postResourceSessionActivityEvent" was null or undefined when calling postResourceSessionActivityEvent().');
|
|
711
|
+
}
|
|
712
|
+
const queryParameters = {};
|
|
713
|
+
const headerParameters = {};
|
|
714
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
715
|
+
let urlPath = `/resource/sessions/{sessionId}/activities/{activityId}/events`;
|
|
716
|
+
urlPath = urlPath.replace('{sessionId}', encodeURIComponent(String(requestParameters['sessionId'])));
|
|
717
|
+
urlPath = urlPath.replace('{activityId}', encodeURIComponent(String(requestParameters['activityId'])));
|
|
718
|
+
return {
|
|
719
|
+
path: urlPath,
|
|
720
|
+
method: 'POST',
|
|
721
|
+
headers: headerParameters,
|
|
722
|
+
query: queryParameters,
|
|
723
|
+
body: PostResourceSessionActivityEventToJSON(requestParameters['postResourceSessionActivityEvent']),
|
|
724
|
+
};
|
|
725
|
+
});
|
|
726
|
+
}
|
|
727
|
+
/**
|
|
728
|
+
* Record learner activity and update active time
|
|
729
|
+
*/
|
|
730
|
+
postResourceSessionActivityEventRaw(requestParameters, initOverrides) {
|
|
731
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
732
|
+
const requestOptions = yield this.postResourceSessionActivityEventRequestOpts(requestParameters);
|
|
733
|
+
const response = yield this.request(requestOptions, initOverrides);
|
|
734
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => GetResourceSessionActivityFromJSON(jsonValue));
|
|
735
|
+
});
|
|
736
|
+
}
|
|
737
|
+
/**
|
|
738
|
+
* Record learner activity and update active time
|
|
739
|
+
*/
|
|
740
|
+
postResourceSessionActivityEvent(requestParameters, initOverrides) {
|
|
741
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
742
|
+
const response = yield this.postResourceSessionActivityEventRaw(requestParameters, initOverrides);
|
|
743
|
+
return yield response.value();
|
|
744
|
+
});
|
|
745
|
+
}
|
|
604
746
|
/**
|
|
605
747
|
* Creates request options for postResourceSessionComplete without sending the request
|
|
606
748
|
*/
|
|
@@ -652,6 +794,9 @@ export class PlayerApi extends runtime.BaseAPI {
|
|
|
652
794
|
throw new runtime.RequiredError('scormSetValueRequest', 'Required parameter "scormSetValueRequest" was null or undefined when calling setResourceScormValue().');
|
|
653
795
|
}
|
|
654
796
|
const queryParameters = {};
|
|
797
|
+
if (requestParameters['activityId'] != null) {
|
|
798
|
+
queryParameters['activity_id'] = requestParameters['activityId'];
|
|
799
|
+
}
|
|
655
800
|
const headerParameters = {};
|
|
656
801
|
headerParameters['Content-Type'] = 'application/json';
|
|
657
802
|
let urlPath = `/resource/sessions/{sessionId}/set-value`;
|
|
@@ -693,6 +838,9 @@ export class PlayerApi extends runtime.BaseAPI {
|
|
|
693
838
|
throw new runtime.RequiredError('sessionId', 'Required parameter "sessionId" was null or undefined when calling terminateResourceScormSession().');
|
|
694
839
|
}
|
|
695
840
|
const queryParameters = {};
|
|
841
|
+
if (requestParameters['activityId'] != null) {
|
|
842
|
+
queryParameters['activity_id'] = requestParameters['activityId'];
|
|
843
|
+
}
|
|
696
844
|
const headerParameters = {};
|
|
697
845
|
let urlPath = `/resource/sessions/{sessionId}/terminate`;
|
|
698
846
|
urlPath = urlPath.replace('{sessionId}', encodeURIComponent(String(requestParameters['sessionId'])));
|
|
@@ -102,6 +102,12 @@ export interface GetCourseVersionItemSession {
|
|
|
102
102
|
* @memberof GetCourseVersionItemSession
|
|
103
103
|
*/
|
|
104
104
|
scoreRaw?: number | null;
|
|
105
|
+
/**
|
|
106
|
+
* Accumulated active learner time across this session's activities.
|
|
107
|
+
* @type {number}
|
|
108
|
+
* @memberof GetCourseVersionItemSession
|
|
109
|
+
*/
|
|
110
|
+
durationSeconds: number;
|
|
105
111
|
/**
|
|
106
112
|
*
|
|
107
113
|
* @type {number}
|
|
@@ -44,6 +44,8 @@ export function instanceOfGetCourseVersionItemSession(value) {
|
|
|
44
44
|
return false;
|
|
45
45
|
if (!('gradeStatus' in value) || value['gradeStatus'] === undefined)
|
|
46
46
|
return false;
|
|
47
|
+
if (!('durationSeconds' in value) || value['durationSeconds'] === undefined)
|
|
48
|
+
return false;
|
|
47
49
|
if (!('createdAt' in value) || value['createdAt'] === undefined)
|
|
48
50
|
return false;
|
|
49
51
|
if (!('updatedAt' in value) || value['updatedAt'] === undefined)
|
|
@@ -72,6 +74,7 @@ export function GetCourseVersionItemSessionFromJSONTyped(json, ignoreDiscriminat
|
|
|
72
74
|
'completionStatus': json['completion_status'],
|
|
73
75
|
'gradeStatus': json['grade_status'],
|
|
74
76
|
'scoreRaw': json['score_raw'] == null ? undefined : json['score_raw'],
|
|
77
|
+
'durationSeconds': json['duration_seconds'],
|
|
75
78
|
'createdAt': json['created_at'],
|
|
76
79
|
'updatedAt': json['updated_at'],
|
|
77
80
|
'completedAt': json['completed_at'] == null ? undefined : json['completed_at'],
|
|
@@ -99,6 +102,7 @@ export function GetCourseVersionItemSessionToJSONTyped(value, ignoreDiscriminato
|
|
|
99
102
|
'completion_status': value['completionStatus'],
|
|
100
103
|
'grade_status': value['gradeStatus'],
|
|
101
104
|
'score_raw': value['scoreRaw'],
|
|
105
|
+
'duration_seconds': value['durationSeconds'],
|
|
102
106
|
'created_at': value['createdAt'],
|
|
103
107
|
'updated_at': value['updatedAt'],
|
|
104
108
|
'completed_at': value['completedAt'],
|
|
@@ -155,6 +155,12 @@ export interface GetLibraryQuizSession {
|
|
|
155
155
|
* @memberof GetLibraryQuizSession
|
|
156
156
|
*/
|
|
157
157
|
completedAt?: number | null;
|
|
158
|
+
/**
|
|
159
|
+
* Elapsed attempt time from start through completion, submission, or the latest saved activity.
|
|
160
|
+
* @type {number}
|
|
161
|
+
* @memberof GetLibraryQuizSession
|
|
162
|
+
*/
|
|
163
|
+
durationSeconds: number;
|
|
158
164
|
}
|
|
159
165
|
/**
|
|
160
166
|
* @export
|
|
@@ -59,6 +59,8 @@ export function instanceOfGetLibraryQuizSession(value) {
|
|
|
59
59
|
return false;
|
|
60
60
|
if (!('updatedAt' in value) || value['updatedAt'] === undefined)
|
|
61
61
|
return false;
|
|
62
|
+
if (!('durationSeconds' in value) || value['durationSeconds'] === undefined)
|
|
63
|
+
return false;
|
|
62
64
|
return true;
|
|
63
65
|
}
|
|
64
66
|
export function GetLibraryQuizSessionFromJSON(json) {
|
|
@@ -92,6 +94,7 @@ export function GetLibraryQuizSessionFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
92
94
|
'createdAt': json['created_at'],
|
|
93
95
|
'updatedAt': json['updated_at'],
|
|
94
96
|
'completedAt': json['completed_at'] == null ? undefined : json['completed_at'],
|
|
97
|
+
'durationSeconds': json['duration_seconds'],
|
|
95
98
|
};
|
|
96
99
|
}
|
|
97
100
|
export function GetLibraryQuizSessionToJSON(json) {
|
|
@@ -125,5 +128,6 @@ export function GetLibraryQuizSessionToJSONTyped(value, ignoreDiscriminator = fa
|
|
|
125
128
|
'created_at': value['createdAt'],
|
|
126
129
|
'updated_at': value['updatedAt'],
|
|
127
130
|
'completed_at': value['completedAt'],
|
|
131
|
+
'duration_seconds': value['durationSeconds'],
|
|
128
132
|
};
|
|
129
133
|
}
|
|
@@ -150,6 +150,12 @@ export interface GetResourceSession {
|
|
|
150
150
|
* @memberof GetResourceSession
|
|
151
151
|
*/
|
|
152
152
|
scoreRaw?: number | null;
|
|
153
|
+
/**
|
|
154
|
+
* Accumulated active learner time across this session's activities.
|
|
155
|
+
* @type {number}
|
|
156
|
+
* @memberof GetResourceSession
|
|
157
|
+
*/
|
|
158
|
+
durationSeconds: number;
|
|
153
159
|
/**
|
|
154
160
|
*
|
|
155
161
|
* @type {number}
|
|
@@ -46,6 +46,8 @@ export function instanceOfGetResourceSession(value) {
|
|
|
46
46
|
return false;
|
|
47
47
|
if (!('gradeStatus' in value) || value['gradeStatus'] === undefined)
|
|
48
48
|
return false;
|
|
49
|
+
if (!('durationSeconds' in value) || value['durationSeconds'] === undefined)
|
|
50
|
+
return false;
|
|
49
51
|
if (!('createdAt' in value) || value['createdAt'] === undefined)
|
|
50
52
|
return false;
|
|
51
53
|
if (!('updatedAt' in value) || value['updatedAt'] === undefined)
|
|
@@ -82,6 +84,7 @@ export function GetResourceSessionFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
82
84
|
'completionStatus': json['completion_status'],
|
|
83
85
|
'gradeStatus': json['grade_status'],
|
|
84
86
|
'scoreRaw': json['score_raw'] == null ? undefined : json['score_raw'],
|
|
87
|
+
'durationSeconds': json['duration_seconds'],
|
|
85
88
|
'initializedAt': json['initialized_at'] == null ? undefined : json['initialized_at'],
|
|
86
89
|
'terminatedAt': json['terminated_at'] == null ? undefined : json['terminated_at'],
|
|
87
90
|
'createdAt': json['created_at'],
|
|
@@ -119,6 +122,7 @@ export function GetResourceSessionToJSONTyped(value, ignoreDiscriminator = false
|
|
|
119
122
|
'completion_status': value['completionStatus'],
|
|
120
123
|
'grade_status': value['gradeStatus'],
|
|
121
124
|
'score_raw': value['scoreRaw'],
|
|
125
|
+
'duration_seconds': value['durationSeconds'],
|
|
122
126
|
'initialized_at': value['initializedAt'],
|
|
123
127
|
'terminated_at': value['terminatedAt'],
|
|
124
128
|
'created_at': value['createdAt'],
|
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* LMS API
|
|
3
|
+
* LMS API
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
/**
|
|
13
|
+
* Per-activity learner state within a resource-session attempt.
|
|
14
|
+
* @export
|
|
15
|
+
* @interface GetResourceSessionActivity
|
|
16
|
+
*/
|
|
17
|
+
export interface GetResourceSessionActivity {
|
|
18
|
+
/**
|
|
19
|
+
*
|
|
20
|
+
* @type {string}
|
|
21
|
+
* @memberof GetResourceSessionActivity
|
|
22
|
+
*/
|
|
23
|
+
id: string;
|
|
24
|
+
/**
|
|
25
|
+
* Stable source identifier, such as a SCORM activity identifier or resource.
|
|
26
|
+
* @type {string}
|
|
27
|
+
* @memberof GetResourceSessionActivity
|
|
28
|
+
*/
|
|
29
|
+
identifier: string;
|
|
30
|
+
/**
|
|
31
|
+
*
|
|
32
|
+
* @type {string}
|
|
33
|
+
* @memberof GetResourceSessionActivity
|
|
34
|
+
*/
|
|
35
|
+
title: string;
|
|
36
|
+
/**
|
|
37
|
+
*
|
|
38
|
+
* @type {GetResourceSessionActivityActivityTypeEnum}
|
|
39
|
+
* @memberof GetResourceSessionActivity
|
|
40
|
+
*/
|
|
41
|
+
activityType: GetResourceSessionActivityActivityTypeEnum;
|
|
42
|
+
/**
|
|
43
|
+
*
|
|
44
|
+
* @type {string}
|
|
45
|
+
* @memberof GetResourceSessionActivity
|
|
46
|
+
*/
|
|
47
|
+
completionStatus: string;
|
|
48
|
+
/**
|
|
49
|
+
*
|
|
50
|
+
* @type {string}
|
|
51
|
+
* @memberof GetResourceSessionActivity
|
|
52
|
+
*/
|
|
53
|
+
gradeStatus: string;
|
|
54
|
+
/**
|
|
55
|
+
*
|
|
56
|
+
* @type {number}
|
|
57
|
+
* @memberof GetResourceSessionActivity
|
|
58
|
+
*/
|
|
59
|
+
scoreRaw?: number | null;
|
|
60
|
+
/**
|
|
61
|
+
*
|
|
62
|
+
* @type {number}
|
|
63
|
+
* @memberof GetResourceSessionActivity
|
|
64
|
+
*/
|
|
65
|
+
durationSeconds: number;
|
|
66
|
+
/**
|
|
67
|
+
*
|
|
68
|
+
* @type {boolean}
|
|
69
|
+
* @memberof GetResourceSessionActivity
|
|
70
|
+
*/
|
|
71
|
+
isActive: boolean;
|
|
72
|
+
/**
|
|
73
|
+
*
|
|
74
|
+
* @type {number}
|
|
75
|
+
* @memberof GetResourceSessionActivity
|
|
76
|
+
*/
|
|
77
|
+
initializedAt?: number | null;
|
|
78
|
+
/**
|
|
79
|
+
*
|
|
80
|
+
* @type {number}
|
|
81
|
+
* @memberof GetResourceSessionActivity
|
|
82
|
+
*/
|
|
83
|
+
terminatedAt?: number | null;
|
|
84
|
+
/**
|
|
85
|
+
*
|
|
86
|
+
* @type {number}
|
|
87
|
+
* @memberof GetResourceSessionActivity
|
|
88
|
+
*/
|
|
89
|
+
completedAt?: number | null;
|
|
90
|
+
/**
|
|
91
|
+
*
|
|
92
|
+
* @type {number}
|
|
93
|
+
* @memberof GetResourceSessionActivity
|
|
94
|
+
*/
|
|
95
|
+
lastSeenAt?: number | null;
|
|
96
|
+
/**
|
|
97
|
+
*
|
|
98
|
+
* @type {number}
|
|
99
|
+
* @memberof GetResourceSessionActivity
|
|
100
|
+
*/
|
|
101
|
+
createdAt: number;
|
|
102
|
+
/**
|
|
103
|
+
*
|
|
104
|
+
* @type {number}
|
|
105
|
+
* @memberof GetResourceSessionActivity
|
|
106
|
+
*/
|
|
107
|
+
updatedAt: number;
|
|
108
|
+
}
|
|
109
|
+
/**
|
|
110
|
+
* @export
|
|
111
|
+
*/
|
|
112
|
+
export declare const GetResourceSessionActivityActivityTypeEnum: {
|
|
113
|
+
readonly Resource: "resource";
|
|
114
|
+
readonly Sco: "sco";
|
|
115
|
+
readonly Asset: "asset";
|
|
116
|
+
};
|
|
117
|
+
export type GetResourceSessionActivityActivityTypeEnum = typeof GetResourceSessionActivityActivityTypeEnum[keyof typeof GetResourceSessionActivityActivityTypeEnum];
|
|
118
|
+
/**
|
|
119
|
+
* Check if a given object implements the GetResourceSessionActivity interface.
|
|
120
|
+
*/
|
|
121
|
+
export declare function instanceOfGetResourceSessionActivity(value: object): value is GetResourceSessionActivity;
|
|
122
|
+
export declare function GetResourceSessionActivityFromJSON(json: any): GetResourceSessionActivity;
|
|
123
|
+
export declare function GetResourceSessionActivityFromJSONTyped(json: any, ignoreDiscriminator: boolean): GetResourceSessionActivity;
|
|
124
|
+
export declare function GetResourceSessionActivityToJSON(json: any): GetResourceSessionActivity;
|
|
125
|
+
export declare function GetResourceSessionActivityToJSONTyped(value?: GetResourceSessionActivity | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,97 @@
|
|
|
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
|
+
* @export
|
|
16
|
+
*/
|
|
17
|
+
export const GetResourceSessionActivityActivityTypeEnum = {
|
|
18
|
+
Resource: 'resource',
|
|
19
|
+
Sco: 'sco',
|
|
20
|
+
Asset: 'asset'
|
|
21
|
+
};
|
|
22
|
+
/**
|
|
23
|
+
* Check if a given object implements the GetResourceSessionActivity interface.
|
|
24
|
+
*/
|
|
25
|
+
export function instanceOfGetResourceSessionActivity(value) {
|
|
26
|
+
if (!('id' in value) || value['id'] === undefined)
|
|
27
|
+
return false;
|
|
28
|
+
if (!('identifier' in value) || value['identifier'] === undefined)
|
|
29
|
+
return false;
|
|
30
|
+
if (!('title' in value) || value['title'] === undefined)
|
|
31
|
+
return false;
|
|
32
|
+
if (!('activityType' in value) || value['activityType'] === undefined)
|
|
33
|
+
return false;
|
|
34
|
+
if (!('completionStatus' in value) || value['completionStatus'] === undefined)
|
|
35
|
+
return false;
|
|
36
|
+
if (!('gradeStatus' in value) || value['gradeStatus'] === undefined)
|
|
37
|
+
return false;
|
|
38
|
+
if (!('durationSeconds' in value) || value['durationSeconds'] === undefined)
|
|
39
|
+
return false;
|
|
40
|
+
if (!('isActive' in value) || value['isActive'] === undefined)
|
|
41
|
+
return false;
|
|
42
|
+
if (!('createdAt' in value) || value['createdAt'] === undefined)
|
|
43
|
+
return false;
|
|
44
|
+
if (!('updatedAt' in value) || value['updatedAt'] === undefined)
|
|
45
|
+
return false;
|
|
46
|
+
return true;
|
|
47
|
+
}
|
|
48
|
+
export function GetResourceSessionActivityFromJSON(json) {
|
|
49
|
+
return GetResourceSessionActivityFromJSONTyped(json, false);
|
|
50
|
+
}
|
|
51
|
+
export function GetResourceSessionActivityFromJSONTyped(json, ignoreDiscriminator) {
|
|
52
|
+
if (json == null) {
|
|
53
|
+
return json;
|
|
54
|
+
}
|
|
55
|
+
return {
|
|
56
|
+
'id': json['id'],
|
|
57
|
+
'identifier': json['identifier'],
|
|
58
|
+
'title': json['title'],
|
|
59
|
+
'activityType': json['activity_type'],
|
|
60
|
+
'completionStatus': json['completion_status'],
|
|
61
|
+
'gradeStatus': json['grade_status'],
|
|
62
|
+
'scoreRaw': json['score_raw'] == null ? undefined : json['score_raw'],
|
|
63
|
+
'durationSeconds': json['duration_seconds'],
|
|
64
|
+
'isActive': json['is_active'],
|
|
65
|
+
'initializedAt': json['initialized_at'] == null ? undefined : json['initialized_at'],
|
|
66
|
+
'terminatedAt': json['terminated_at'] == null ? undefined : json['terminated_at'],
|
|
67
|
+
'completedAt': json['completed_at'] == null ? undefined : json['completed_at'],
|
|
68
|
+
'lastSeenAt': json['last_seen_at'] == null ? undefined : json['last_seen_at'],
|
|
69
|
+
'createdAt': json['created_at'],
|
|
70
|
+
'updatedAt': json['updated_at'],
|
|
71
|
+
};
|
|
72
|
+
}
|
|
73
|
+
export function GetResourceSessionActivityToJSON(json) {
|
|
74
|
+
return GetResourceSessionActivityToJSONTyped(json, false);
|
|
75
|
+
}
|
|
76
|
+
export function GetResourceSessionActivityToJSONTyped(value, ignoreDiscriminator = false) {
|
|
77
|
+
if (value == null) {
|
|
78
|
+
return value;
|
|
79
|
+
}
|
|
80
|
+
return {
|
|
81
|
+
'id': value['id'],
|
|
82
|
+
'identifier': value['identifier'],
|
|
83
|
+
'title': value['title'],
|
|
84
|
+
'activity_type': value['activityType'],
|
|
85
|
+
'completion_status': value['completionStatus'],
|
|
86
|
+
'grade_status': value['gradeStatus'],
|
|
87
|
+
'score_raw': value['scoreRaw'],
|
|
88
|
+
'duration_seconds': value['durationSeconds'],
|
|
89
|
+
'is_active': value['isActive'],
|
|
90
|
+
'initialized_at': value['initializedAt'],
|
|
91
|
+
'terminated_at': value['terminatedAt'],
|
|
92
|
+
'completed_at': value['completedAt'],
|
|
93
|
+
'last_seen_at': value['lastSeenAt'],
|
|
94
|
+
'created_at': value['createdAt'],
|
|
95
|
+
'updated_at': value['updatedAt'],
|
|
96
|
+
};
|
|
97
|
+
}
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* LMS API
|
|
3
|
+
* LMS API
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
/**
|
|
13
|
+
* A recorded learner activity event.
|
|
14
|
+
* @export
|
|
15
|
+
* @interface GetResourceSessionActivityEvent
|
|
16
|
+
*/
|
|
17
|
+
export interface GetResourceSessionActivityEvent {
|
|
18
|
+
/**
|
|
19
|
+
*
|
|
20
|
+
* @type {number}
|
|
21
|
+
* @memberof GetResourceSessionActivityEvent
|
|
22
|
+
*/
|
|
23
|
+
id: number;
|
|
24
|
+
/**
|
|
25
|
+
*
|
|
26
|
+
* @type {string}
|
|
27
|
+
* @memberof GetResourceSessionActivityEvent
|
|
28
|
+
*/
|
|
29
|
+
eventId: string;
|
|
30
|
+
/**
|
|
31
|
+
*
|
|
32
|
+
* @type {string}
|
|
33
|
+
* @memberof GetResourceSessionActivityEvent
|
|
34
|
+
*/
|
|
35
|
+
activityId: string;
|
|
36
|
+
/**
|
|
37
|
+
*
|
|
38
|
+
* @type {string}
|
|
39
|
+
* @memberof GetResourceSessionActivityEvent
|
|
40
|
+
*/
|
|
41
|
+
eventType: string;
|
|
42
|
+
/**
|
|
43
|
+
*
|
|
44
|
+
* @type {number}
|
|
45
|
+
* @memberof GetResourceSessionActivityEvent
|
|
46
|
+
*/
|
|
47
|
+
positionSeconds?: number | null;
|
|
48
|
+
/**
|
|
49
|
+
*
|
|
50
|
+
* @type {number}
|
|
51
|
+
* @memberof GetResourceSessionActivityEvent
|
|
52
|
+
*/
|
|
53
|
+
createdAt: number;
|
|
54
|
+
}
|
|
55
|
+
/**
|
|
56
|
+
* Check if a given object implements the GetResourceSessionActivityEvent interface.
|
|
57
|
+
*/
|
|
58
|
+
export declare function instanceOfGetResourceSessionActivityEvent(value: object): value is GetResourceSessionActivityEvent;
|
|
59
|
+
export declare function GetResourceSessionActivityEventFromJSON(json: any): GetResourceSessionActivityEvent;
|
|
60
|
+
export declare function GetResourceSessionActivityEventFromJSONTyped(json: any, ignoreDiscriminator: boolean): GetResourceSessionActivityEvent;
|
|
61
|
+
export declare function GetResourceSessionActivityEventToJSON(json: any): GetResourceSessionActivityEvent;
|
|
62
|
+
export declare function GetResourceSessionActivityEventToJSONTyped(value?: GetResourceSessionActivityEvent | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,61 @@
|
|
|
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
|
+
* Check if a given object implements the GetResourceSessionActivityEvent interface.
|
|
16
|
+
*/
|
|
17
|
+
export function instanceOfGetResourceSessionActivityEvent(value) {
|
|
18
|
+
if (!('id' in value) || value['id'] === undefined)
|
|
19
|
+
return false;
|
|
20
|
+
if (!('eventId' in value) || value['eventId'] === undefined)
|
|
21
|
+
return false;
|
|
22
|
+
if (!('activityId' in value) || value['activityId'] === undefined)
|
|
23
|
+
return false;
|
|
24
|
+
if (!('eventType' in value) || value['eventType'] === undefined)
|
|
25
|
+
return false;
|
|
26
|
+
if (!('createdAt' in value) || value['createdAt'] === undefined)
|
|
27
|
+
return false;
|
|
28
|
+
return true;
|
|
29
|
+
}
|
|
30
|
+
export function GetResourceSessionActivityEventFromJSON(json) {
|
|
31
|
+
return GetResourceSessionActivityEventFromJSONTyped(json, false);
|
|
32
|
+
}
|
|
33
|
+
export function GetResourceSessionActivityEventFromJSONTyped(json, ignoreDiscriminator) {
|
|
34
|
+
if (json == null) {
|
|
35
|
+
return json;
|
|
36
|
+
}
|
|
37
|
+
return {
|
|
38
|
+
'id': json['id'],
|
|
39
|
+
'eventId': json['event_id'],
|
|
40
|
+
'activityId': json['activity_id'],
|
|
41
|
+
'eventType': json['event_type'],
|
|
42
|
+
'positionSeconds': json['position_seconds'] == null ? undefined : json['position_seconds'],
|
|
43
|
+
'createdAt': json['created_at'],
|
|
44
|
+
};
|
|
45
|
+
}
|
|
46
|
+
export function GetResourceSessionActivityEventToJSON(json) {
|
|
47
|
+
return GetResourceSessionActivityEventToJSONTyped(json, false);
|
|
48
|
+
}
|
|
49
|
+
export function GetResourceSessionActivityEventToJSONTyped(value, ignoreDiscriminator = false) {
|
|
50
|
+
if (value == null) {
|
|
51
|
+
return value;
|
|
52
|
+
}
|
|
53
|
+
return {
|
|
54
|
+
'id': value['id'],
|
|
55
|
+
'event_id': value['eventId'],
|
|
56
|
+
'activity_id': value['activityId'],
|
|
57
|
+
'event_type': value['eventType'],
|
|
58
|
+
'position_seconds': value['positionSeconds'],
|
|
59
|
+
'created_at': value['createdAt'],
|
|
60
|
+
};
|
|
61
|
+
}
|