@easyedu/js-lsm-api 1.28.0 → 1.30.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (63) hide show
  1. package/.openapi-generator/FILES +10 -0
  2. package/README.md +2 -2
  3. package/dist/apis/ContentApi.d.ts +71 -1
  4. package/dist/apis/ContentApi.js +158 -1
  5. package/dist/esm/apis/ContentApi.d.ts +71 -1
  6. package/dist/esm/apis/ContentApi.js +158 -1
  7. package/dist/esm/models/GetContentSessionDetail.d.ts +103 -0
  8. package/dist/esm/models/GetContentSessionDetail.js +96 -0
  9. package/dist/esm/models/GetContentSessionDetailScormSessionDataInner.d.ts +38 -0
  10. package/dist/esm/models/GetContentSessionDetailScormSessionDataInner.js +47 -0
  11. package/dist/esm/models/GetContentSessionDetailUserData.d.ts +38 -0
  12. package/dist/esm/models/GetContentSessionDetailUserData.js +47 -0
  13. package/dist/esm/models/GetContentSessionList.d.ts +57 -0
  14. package/dist/esm/models/GetContentSessionList.js +60 -0
  15. package/dist/esm/models/GetContentSessionListItem.d.ts +64 -0
  16. package/dist/esm/models/GetContentSessionListItem.js +65 -0
  17. package/dist/esm/models/GetContentSessionListItemScormSessionData.d.ts +32 -0
  18. package/dist/esm/models/GetContentSessionListItemScormSessionData.js +43 -0
  19. package/dist/esm/models/GetScormApiLogItem.d.ts +73 -0
  20. package/dist/esm/models/GetScormApiLogItem.js +73 -0
  21. package/dist/esm/models/GetScormApiLogs.d.ts +57 -0
  22. package/dist/esm/models/GetScormApiLogs.js +60 -0
  23. package/dist/esm/models/GetScormSessionData.d.ts +59 -0
  24. package/dist/esm/models/GetScormSessionData.js +60 -0
  25. package/dist/esm/models/GetScormSessionDataActivity.d.ts +38 -0
  26. package/dist/esm/models/GetScormSessionDataActivity.js +47 -0
  27. package/dist/esm/models/index.d.ts +10 -0
  28. package/dist/esm/models/index.js +10 -0
  29. package/dist/models/GetContentSessionDetail.d.ts +103 -0
  30. package/dist/models/GetContentSessionDetail.js +104 -0
  31. package/dist/models/GetContentSessionDetailScormSessionDataInner.d.ts +38 -0
  32. package/dist/models/GetContentSessionDetailScormSessionDataInner.js +54 -0
  33. package/dist/models/GetContentSessionDetailUserData.d.ts +38 -0
  34. package/dist/models/GetContentSessionDetailUserData.js +54 -0
  35. package/dist/models/GetContentSessionList.d.ts +57 -0
  36. package/dist/models/GetContentSessionList.js +67 -0
  37. package/dist/models/GetContentSessionListItem.d.ts +64 -0
  38. package/dist/models/GetContentSessionListItem.js +72 -0
  39. package/dist/models/GetContentSessionListItemScormSessionData.d.ts +32 -0
  40. package/dist/models/GetContentSessionListItemScormSessionData.js +50 -0
  41. package/dist/models/GetScormApiLogItem.d.ts +73 -0
  42. package/dist/models/GetScormApiLogItem.js +81 -0
  43. package/dist/models/GetScormApiLogs.d.ts +57 -0
  44. package/dist/models/GetScormApiLogs.js +67 -0
  45. package/dist/models/GetScormSessionData.d.ts +59 -0
  46. package/dist/models/GetScormSessionData.js +67 -0
  47. package/dist/models/GetScormSessionDataActivity.d.ts +38 -0
  48. package/dist/models/GetScormSessionDataActivity.js +54 -0
  49. package/dist/models/index.d.ts +10 -0
  50. package/dist/models/index.js +10 -0
  51. package/package.json +1 -1
  52. package/src/apis/ContentApi.ts +242 -0
  53. package/src/models/GetContentSessionDetail.ts +178 -0
  54. package/src/models/GetContentSessionDetailScormSessionDataInner.ts +75 -0
  55. package/src/models/GetContentSessionDetailUserData.ts +75 -0
  56. package/src/models/GetContentSessionList.ts +110 -0
  57. package/src/models/GetContentSessionListItem.ts +126 -0
  58. package/src/models/GetContentSessionListItemScormSessionData.ts +66 -0
  59. package/src/models/GetScormApiLogItem.ts +125 -0
  60. package/src/models/GetScormApiLogs.ts +110 -0
  61. package/src/models/GetScormSessionData.ts +110 -0
  62. package/src/models/GetScormSessionDataActivity.ts +75 -0
  63. package/src/models/index.ts +10 -0
@@ -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 { GetContentSessionListItem } from './GetContentSessionListItem';
17
+ import {
18
+ GetContentSessionListItemFromJSON,
19
+ GetContentSessionListItemFromJSONTyped,
20
+ GetContentSessionListItemToJSON,
21
+ GetContentSessionListItemToJSONTyped,
22
+ } from './GetContentSessionListItem';
23
+
24
+ /**
25
+ * A list of content sessions with pagination information
26
+ * @export
27
+ * @interface GetContentSessionList
28
+ */
29
+ export interface GetContentSessionList {
30
+ /**
31
+ * The current page number
32
+ * @type {number}
33
+ * @memberof GetContentSessionList
34
+ */
35
+ page: number;
36
+ /**
37
+ * The number of items per page
38
+ * @type {number}
39
+ * @memberof GetContentSessionList
40
+ */
41
+ pageSize: number;
42
+ /**
43
+ * The total number of pages
44
+ * @type {number}
45
+ * @memberof GetContentSessionList
46
+ */
47
+ totalPages: number;
48
+ /**
49
+ * The total number of items
50
+ * @type {number}
51
+ * @memberof GetContentSessionList
52
+ */
53
+ totalItems: number;
54
+ /**
55
+ *
56
+ * @type {Array<GetContentSessionListItem>}
57
+ * @memberof GetContentSessionList
58
+ */
59
+ items: Array<GetContentSessionListItem>;
60
+ }
61
+
62
+ /**
63
+ * Check if a given object implements the GetContentSessionList interface.
64
+ */
65
+ export function instanceOfGetContentSessionList(value: object): value is GetContentSessionList {
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 GetContentSessionListFromJSON(json: any): GetContentSessionList {
75
+ return GetContentSessionListFromJSONTyped(json, false);
76
+ }
77
+
78
+ export function GetContentSessionListFromJSONTyped(json: any, ignoreDiscriminator: boolean): GetContentSessionList {
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(GetContentSessionListItemFromJSON)),
89
+ };
90
+ }
91
+
92
+ export function GetContentSessionListToJSON(json: any): GetContentSessionList {
93
+ return GetContentSessionListToJSONTyped(json, false);
94
+ }
95
+
96
+ export function GetContentSessionListToJSONTyped(value?: GetContentSessionList | 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(GetContentSessionListItemToJSON)),
108
+ };
109
+ }
110
+
@@ -0,0 +1,126 @@
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 { GetContentSessionListItemScormSessionData } from './GetContentSessionListItemScormSessionData';
17
+ import {
18
+ GetContentSessionListItemScormSessionDataFromJSON,
19
+ GetContentSessionListItemScormSessionDataFromJSONTyped,
20
+ GetContentSessionListItemScormSessionDataToJSON,
21
+ GetContentSessionListItemScormSessionDataToJSONTyped,
22
+ } from './GetContentSessionListItemScormSessionData';
23
+ import type { GetContentSessionDetailUserData } from './GetContentSessionDetailUserData';
24
+ import {
25
+ GetContentSessionDetailUserDataFromJSON,
26
+ GetContentSessionDetailUserDataFromJSONTyped,
27
+ GetContentSessionDetailUserDataToJSON,
28
+ GetContentSessionDetailUserDataToJSONTyped,
29
+ } from './GetContentSessionDetailUserData';
30
+
31
+ /**
32
+ * A content session list item
33
+ * @export
34
+ * @interface GetContentSessionListItem
35
+ */
36
+ export interface GetContentSessionListItem {
37
+ /**
38
+ * The external ID of the content session
39
+ * @type {string}
40
+ * @memberof GetContentSessionListItem
41
+ */
42
+ id: string;
43
+ /**
44
+ * The date and time the content session was created (Unix timestamp)
45
+ * @type {number}
46
+ * @memberof GetContentSessionListItem
47
+ */
48
+ createdAt: number;
49
+ /**
50
+ * The date and time the content session was updated (Unix timestamp)
51
+ * @type {number}
52
+ * @memberof GetContentSessionListItem
53
+ */
54
+ updatedAt: number;
55
+ /**
56
+ * The external ID of the content
57
+ * @type {string}
58
+ * @memberof GetContentSessionListItem
59
+ */
60
+ contentId: string;
61
+ /**
62
+ *
63
+ * @type {GetContentSessionDetailUserData}
64
+ * @memberof GetContentSessionListItem
65
+ */
66
+ userData: GetContentSessionDetailUserData;
67
+ /**
68
+ *
69
+ * @type {GetContentSessionListItemScormSessionData}
70
+ * @memberof GetContentSessionListItem
71
+ */
72
+ scormSessionData: GetContentSessionListItemScormSessionData | null;
73
+ }
74
+
75
+ /**
76
+ * Check if a given object implements the GetContentSessionListItem interface.
77
+ */
78
+ export function instanceOfGetContentSessionListItem(value: object): value is GetContentSessionListItem {
79
+ if (!('id' in value) || value['id'] === undefined) return false;
80
+ if (!('createdAt' in value) || value['createdAt'] === undefined) return false;
81
+ if (!('updatedAt' in value) || value['updatedAt'] === undefined) return false;
82
+ if (!('contentId' in value) || value['contentId'] === undefined) return false;
83
+ if (!('userData' in value) || value['userData'] === undefined) return false;
84
+ if (!('scormSessionData' in value) || value['scormSessionData'] === undefined) return false;
85
+ return true;
86
+ }
87
+
88
+ export function GetContentSessionListItemFromJSON(json: any): GetContentSessionListItem {
89
+ return GetContentSessionListItemFromJSONTyped(json, false);
90
+ }
91
+
92
+ export function GetContentSessionListItemFromJSONTyped(json: any, ignoreDiscriminator: boolean): GetContentSessionListItem {
93
+ if (json == null) {
94
+ return json;
95
+ }
96
+ return {
97
+
98
+ 'id': json['id'],
99
+ 'createdAt': json['created_at'],
100
+ 'updatedAt': json['updated_at'],
101
+ 'contentId': json['content_id'],
102
+ 'userData': GetContentSessionDetailUserDataFromJSON(json['user_data']),
103
+ 'scormSessionData': GetContentSessionListItemScormSessionDataFromJSON(json['scorm_session_data']),
104
+ };
105
+ }
106
+
107
+ export function GetContentSessionListItemToJSON(json: any): GetContentSessionListItem {
108
+ return GetContentSessionListItemToJSONTyped(json, false);
109
+ }
110
+
111
+ export function GetContentSessionListItemToJSONTyped(value?: GetContentSessionListItem | null, ignoreDiscriminator: boolean = false): any {
112
+ if (value == null) {
113
+ return value;
114
+ }
115
+
116
+ return {
117
+
118
+ 'id': value['id'],
119
+ 'created_at': value['createdAt'],
120
+ 'updated_at': value['updatedAt'],
121
+ 'content_id': value['contentId'],
122
+ 'user_data': GetContentSessionDetailUserDataToJSON(value['userData']),
123
+ 'scorm_session_data': GetContentSessionListItemScormSessionDataToJSON(value['scormSessionData']),
124
+ };
125
+ }
126
+
@@ -0,0 +1,66 @@
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
+ * SCORM session data if this is a SCORM session, null otherwise
18
+ * @export
19
+ * @interface GetContentSessionListItemScormSessionData
20
+ */
21
+ export interface GetContentSessionListItemScormSessionData {
22
+ /**
23
+ * The external ID of the SCORM session
24
+ * @type {string}
25
+ * @memberof GetContentSessionListItemScormSessionData
26
+ */
27
+ scormSessionId: string;
28
+ }
29
+
30
+ /**
31
+ * Check if a given object implements the GetContentSessionListItemScormSessionData interface.
32
+ */
33
+ export function instanceOfGetContentSessionListItemScormSessionData(value: object): value is GetContentSessionListItemScormSessionData {
34
+ if (!('scormSessionId' in value) || value['scormSessionId'] === undefined) return false;
35
+ return true;
36
+ }
37
+
38
+ export function GetContentSessionListItemScormSessionDataFromJSON(json: any): GetContentSessionListItemScormSessionData {
39
+ return GetContentSessionListItemScormSessionDataFromJSONTyped(json, false);
40
+ }
41
+
42
+ export function GetContentSessionListItemScormSessionDataFromJSONTyped(json: any, ignoreDiscriminator: boolean): GetContentSessionListItemScormSessionData {
43
+ if (json == null) {
44
+ return json;
45
+ }
46
+ return {
47
+
48
+ 'scormSessionId': json['scorm_session_id'],
49
+ };
50
+ }
51
+
52
+ export function GetContentSessionListItemScormSessionDataToJSON(json: any): GetContentSessionListItemScormSessionData {
53
+ return GetContentSessionListItemScormSessionDataToJSONTyped(json, false);
54
+ }
55
+
56
+ export function GetContentSessionListItemScormSessionDataToJSONTyped(value?: GetContentSessionListItemScormSessionData | null, ignoreDiscriminator: boolean = false): any {
57
+ if (value == null) {
58
+ return value;
59
+ }
60
+
61
+ return {
62
+
63
+ 'scorm_session_id': value['scormSessionId'],
64
+ };
65
+ }
66
+
@@ -0,0 +1,125 @@
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
+ * A SCORM API call log entry
18
+ * @export
19
+ * @interface GetScormApiLogItem
20
+ */
21
+ export interface GetScormApiLogItem {
22
+ /**
23
+ * The ID of the log entry
24
+ * @type {number}
25
+ * @memberof GetScormApiLogItem
26
+ */
27
+ id: number;
28
+ /**
29
+ * The date and time the API call was made (Unix timestamp)
30
+ * @type {number}
31
+ * @memberof GetScormApiLogItem
32
+ */
33
+ createdAt: number;
34
+ /**
35
+ * The SCORM API method that was called
36
+ * @type {string}
37
+ * @memberof GetScormApiLogItem
38
+ */
39
+ method: GetScormApiLogItemMethodEnum;
40
+ /**
41
+ * The CMI element (e.g., 'cmi.score.raw') - nullable for Initialize, Commit, Terminate
42
+ * @type {string}
43
+ * @memberof GetScormApiLogItem
44
+ */
45
+ element: string | null;
46
+ /**
47
+ * The value set or returned - nullable for some operations
48
+ * @type {string}
49
+ * @memberof GetScormApiLogItem
50
+ */
51
+ value: string | null;
52
+ /**
53
+ * The SCORM error code ('0' for success, '301', '401', etc.')
54
+ * @type {string}
55
+ * @memberof GetScormApiLogItem
56
+ */
57
+ errorCode: string;
58
+ }
59
+
60
+
61
+ /**
62
+ * @export
63
+ */
64
+ export const GetScormApiLogItemMethodEnum = {
65
+ Initialize: 'Initialize',
66
+ SetValue: 'SetValue',
67
+ GetValue: 'GetValue',
68
+ Commit: 'Commit',
69
+ Terminate: 'Terminate'
70
+ } as const;
71
+ export type GetScormApiLogItemMethodEnum = typeof GetScormApiLogItemMethodEnum[keyof typeof GetScormApiLogItemMethodEnum];
72
+
73
+
74
+ /**
75
+ * Check if a given object implements the GetScormApiLogItem interface.
76
+ */
77
+ export function instanceOfGetScormApiLogItem(value: object): value is GetScormApiLogItem {
78
+ if (!('id' in value) || value['id'] === undefined) return false;
79
+ if (!('createdAt' in value) || value['createdAt'] === undefined) return false;
80
+ if (!('method' in value) || value['method'] === undefined) return false;
81
+ if (!('element' in value) || value['element'] === undefined) return false;
82
+ if (!('value' in value) || value['value'] === undefined) return false;
83
+ if (!('errorCode' in value) || value['errorCode'] === undefined) return false;
84
+ return true;
85
+ }
86
+
87
+ export function GetScormApiLogItemFromJSON(json: any): GetScormApiLogItem {
88
+ return GetScormApiLogItemFromJSONTyped(json, false);
89
+ }
90
+
91
+ export function GetScormApiLogItemFromJSONTyped(json: any, ignoreDiscriminator: boolean): GetScormApiLogItem {
92
+ if (json == null) {
93
+ return json;
94
+ }
95
+ return {
96
+
97
+ 'id': json['id'],
98
+ 'createdAt': json['created_at'],
99
+ 'method': json['method'],
100
+ 'element': json['element'],
101
+ 'value': json['value'],
102
+ 'errorCode': json['error_code'],
103
+ };
104
+ }
105
+
106
+ export function GetScormApiLogItemToJSON(json: any): GetScormApiLogItem {
107
+ return GetScormApiLogItemToJSONTyped(json, false);
108
+ }
109
+
110
+ export function GetScormApiLogItemToJSONTyped(value?: GetScormApiLogItem | null, ignoreDiscriminator: boolean = false): any {
111
+ if (value == null) {
112
+ return value;
113
+ }
114
+
115
+ return {
116
+
117
+ 'id': value['id'],
118
+ 'created_at': value['createdAt'],
119
+ 'method': value['method'],
120
+ 'element': value['element'],
121
+ 'value': value['value'],
122
+ 'error_code': value['errorCode'],
123
+ };
124
+ }
125
+
@@ -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 { GetScormApiLogItem } from './GetScormApiLogItem';
17
+ import {
18
+ GetScormApiLogItemFromJSON,
19
+ GetScormApiLogItemFromJSONTyped,
20
+ GetScormApiLogItemToJSON,
21
+ GetScormApiLogItemToJSONTyped,
22
+ } from './GetScormApiLogItem';
23
+
24
+ /**
25
+ * A list of SCORM API logs with pagination information
26
+ * @export
27
+ * @interface GetScormApiLogs
28
+ */
29
+ export interface GetScormApiLogs {
30
+ /**
31
+ * The current page number
32
+ * @type {number}
33
+ * @memberof GetScormApiLogs
34
+ */
35
+ page: number;
36
+ /**
37
+ * The number of items per page
38
+ * @type {number}
39
+ * @memberof GetScormApiLogs
40
+ */
41
+ pageSize: number;
42
+ /**
43
+ * The total number of pages
44
+ * @type {number}
45
+ * @memberof GetScormApiLogs
46
+ */
47
+ totalPages: number;
48
+ /**
49
+ * The total number of items
50
+ * @type {number}
51
+ * @memberof GetScormApiLogs
52
+ */
53
+ totalItems: number;
54
+ /**
55
+ *
56
+ * @type {Array<GetScormApiLogItem>}
57
+ * @memberof GetScormApiLogs
58
+ */
59
+ items: Array<GetScormApiLogItem>;
60
+ }
61
+
62
+ /**
63
+ * Check if a given object implements the GetScormApiLogs interface.
64
+ */
65
+ export function instanceOfGetScormApiLogs(value: object): value is GetScormApiLogs {
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 GetScormApiLogsFromJSON(json: any): GetScormApiLogs {
75
+ return GetScormApiLogsFromJSONTyped(json, false);
76
+ }
77
+
78
+ export function GetScormApiLogsFromJSONTyped(json: any, ignoreDiscriminator: boolean): GetScormApiLogs {
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(GetScormApiLogItemFromJSON)),
89
+ };
90
+ }
91
+
92
+ export function GetScormApiLogsToJSON(json: any): GetScormApiLogs {
93
+ return GetScormApiLogsToJSONTyped(json, false);
94
+ }
95
+
96
+ export function GetScormApiLogsToJSONTyped(value?: GetScormApiLogs | 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(GetScormApiLogItemToJSON)),
108
+ };
109
+ }
110
+
@@ -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 { GetScormSessionDataActivity } from './GetScormSessionDataActivity';
17
+ import {
18
+ GetScormSessionDataActivityFromJSON,
19
+ GetScormSessionDataActivityFromJSONTyped,
20
+ GetScormSessionDataActivityToJSON,
21
+ GetScormSessionDataActivityToJSONTyped,
22
+ } from './GetScormSessionDataActivity';
23
+
24
+ /**
25
+ * SCORM session data with CMI information
26
+ * @export
27
+ * @interface GetScormSessionData
28
+ */
29
+ export interface GetScormSessionData {
30
+ /**
31
+ * The external ID of the SCORM session
32
+ * @type {string}
33
+ * @memberof GetScormSessionData
34
+ */
35
+ id: string;
36
+ /**
37
+ * The date and time the SCORM session was created (Unix timestamp)
38
+ * @type {number}
39
+ * @memberof GetScormSessionData
40
+ */
41
+ createdAt: number;
42
+ /**
43
+ * The date and time the SCORM session was updated (Unix timestamp)
44
+ * @type {number}
45
+ * @memberof GetScormSessionData
46
+ */
47
+ updatedAt: number;
48
+ /**
49
+ * The SCORM CMI data (complete dump of scorm_data)
50
+ * @type {{ [key: string]: any; }}
51
+ * @memberof GetScormSessionData
52
+ */
53
+ cmiData: { [key: string]: any; };
54
+ /**
55
+ *
56
+ * @type {GetScormSessionDataActivity}
57
+ * @memberof GetScormSessionData
58
+ */
59
+ activity: GetScormSessionDataActivity;
60
+ }
61
+
62
+ /**
63
+ * Check if a given object implements the GetScormSessionData interface.
64
+ */
65
+ export function instanceOfGetScormSessionData(value: object): value is GetScormSessionData {
66
+ if (!('id' in value) || value['id'] === undefined) return false;
67
+ if (!('createdAt' in value) || value['createdAt'] === undefined) return false;
68
+ if (!('updatedAt' in value) || value['updatedAt'] === undefined) return false;
69
+ if (!('cmiData' in value) || value['cmiData'] === undefined) return false;
70
+ if (!('activity' in value) || value['activity'] === undefined) return false;
71
+ return true;
72
+ }
73
+
74
+ export function GetScormSessionDataFromJSON(json: any): GetScormSessionData {
75
+ return GetScormSessionDataFromJSONTyped(json, false);
76
+ }
77
+
78
+ export function GetScormSessionDataFromJSONTyped(json: any, ignoreDiscriminator: boolean): GetScormSessionData {
79
+ if (json == null) {
80
+ return json;
81
+ }
82
+ return {
83
+
84
+ 'id': json['id'],
85
+ 'createdAt': json['created_at'],
86
+ 'updatedAt': json['updated_at'],
87
+ 'cmiData': json['cmi_data'],
88
+ 'activity': GetScormSessionDataActivityFromJSON(json['activity']),
89
+ };
90
+ }
91
+
92
+ export function GetScormSessionDataToJSON(json: any): GetScormSessionData {
93
+ return GetScormSessionDataToJSONTyped(json, false);
94
+ }
95
+
96
+ export function GetScormSessionDataToJSONTyped(value?: GetScormSessionData | null, ignoreDiscriminator: boolean = false): any {
97
+ if (value == null) {
98
+ return value;
99
+ }
100
+
101
+ return {
102
+
103
+ 'id': value['id'],
104
+ 'created_at': value['createdAt'],
105
+ 'updated_at': value['updatedAt'],
106
+ 'cmi_data': value['cmiData'],
107
+ 'activity': GetScormSessionDataActivityToJSON(value['activity']),
108
+ };
109
+ }
110
+