@easyedu/js-lsm-api 1.79.0 → 1.80.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 (50) hide show
  1. package/.openapi-generator/FILES +12 -0
  2. package/README.md +9 -2
  3. package/dist/apis/UserApi.d.ts +42 -0
  4. package/dist/apis/UserApi.js +79 -1
  5. package/dist/esm/apis/UserApi.d.ts +42 -0
  6. package/dist/esm/apis/UserApi.js +78 -0
  7. package/dist/esm/models/GetUserCourseList.d.ts +57 -0
  8. package/dist/esm/models/GetUserCourseList.js +60 -0
  9. package/dist/esm/models/GetUserCourseListItem.d.ts +54 -0
  10. package/dist/esm/models/GetUserCourseListItem.js +59 -0
  11. package/dist/esm/models/GetUserCourseListItemCertificate.d.ts +74 -0
  12. package/dist/esm/models/GetUserCourseListItemCertificate.js +75 -0
  13. package/dist/esm/models/GetUserCourseListItemCourse.d.ts +89 -0
  14. package/dist/esm/models/GetUserCourseListItemCourse.js +82 -0
  15. package/dist/esm/models/GetUserCourseListItemEnrollment.d.ts +111 -0
  16. package/dist/esm/models/GetUserCourseListItemEnrollment.js +105 -0
  17. package/dist/esm/models/GetUserCourseListItemProgress.d.ts +44 -0
  18. package/dist/esm/models/GetUserCourseListItemProgress.js +51 -0
  19. package/dist/esm/models/index.d.ts +6 -0
  20. package/dist/esm/models/index.js +6 -0
  21. package/dist/models/GetUserCourseList.d.ts +57 -0
  22. package/dist/models/GetUserCourseList.js +67 -0
  23. package/dist/models/GetUserCourseListItem.d.ts +54 -0
  24. package/dist/models/GetUserCourseListItem.js +66 -0
  25. package/dist/models/GetUserCourseListItemCertificate.d.ts +74 -0
  26. package/dist/models/GetUserCourseListItemCertificate.js +83 -0
  27. package/dist/models/GetUserCourseListItemCourse.d.ts +89 -0
  28. package/dist/models/GetUserCourseListItemCourse.js +90 -0
  29. package/dist/models/GetUserCourseListItemEnrollment.d.ts +111 -0
  30. package/dist/models/GetUserCourseListItemEnrollment.js +113 -0
  31. package/dist/models/GetUserCourseListItemProgress.d.ts +44 -0
  32. package/dist/models/GetUserCourseListItemProgress.js +58 -0
  33. package/dist/models/index.d.ts +6 -0
  34. package/dist/models/index.js +6 -0
  35. package/docs/GetUserCourseList.md +43 -0
  36. package/docs/GetUserCourseListItem.md +41 -0
  37. package/docs/GetUserCourseListItemCertificate.md +43 -0
  38. package/docs/GetUserCourseListItemCourse.md +51 -0
  39. package/docs/GetUserCourseListItemEnrollment.md +49 -0
  40. package/docs/GetUserCourseListItemProgress.md +39 -0
  41. package/docs/UserApi.md +90 -0
  42. package/package.json +1 -1
  43. package/src/apis/UserApi.ts +108 -0
  44. package/src/models/GetUserCourseList.ts +110 -0
  45. package/src/models/GetUserCourseListItem.ts +122 -0
  46. package/src/models/GetUserCourseListItemCertificate.ts +124 -0
  47. package/src/models/GetUserCourseListItemCourse.ts +149 -0
  48. package/src/models/GetUserCourseListItemEnrollment.ts +171 -0
  49. package/src/models/GetUserCourseListItemProgress.ts +84 -0
  50. package/src/models/index.ts +6 -0
@@ -0,0 +1,149 @@
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
+ * Course fields for an enrolled user's course list item.
18
+ * @export
19
+ * @interface GetUserCourseListItemCourse
20
+ */
21
+ export interface GetUserCourseListItemCourse {
22
+ /**
23
+ *
24
+ * @type {string}
25
+ * @memberof GetUserCourseListItemCourse
26
+ */
27
+ readonly id: string;
28
+ /**
29
+ *
30
+ * @type {string}
31
+ * @memberof GetUserCourseListItemCourse
32
+ */
33
+ name: string;
34
+ /**
35
+ *
36
+ * @type {string}
37
+ * @memberof GetUserCourseListItemCourse
38
+ */
39
+ description: string;
40
+ /**
41
+ *
42
+ * @type {string}
43
+ * @memberof GetUserCourseListItemCourse
44
+ */
45
+ imageUrl: string;
46
+ /**
47
+ *
48
+ * @type {boolean}
49
+ * @memberof GetUserCourseListItemCourse
50
+ */
51
+ published: boolean;
52
+ /**
53
+ *
54
+ * @type {number}
55
+ * @memberof GetUserCourseListItemCourse
56
+ */
57
+ createdAt: number;
58
+ /**
59
+ *
60
+ * @type {GetUserCourseListItemCourseAccessPolicyTypeEnum}
61
+ * @memberof GetUserCourseListItemCourse
62
+ */
63
+ accessPolicyType: GetUserCourseListItemCourseAccessPolicyTypeEnum;
64
+ /**
65
+ *
66
+ * @type {number}
67
+ * @memberof GetUserCourseListItemCourse
68
+ */
69
+ accessDurationDays: number | null;
70
+ /**
71
+ *
72
+ * @type {number}
73
+ * @memberof GetUserCourseListItemCourse
74
+ */
75
+ accessFixedEndAt: number | null;
76
+ }
77
+
78
+
79
+ /**
80
+ * @export
81
+ */
82
+ export const GetUserCourseListItemCourseAccessPolicyTypeEnum = {
83
+ DurationDays: 'duration_days',
84
+ FixedEndDate: 'fixed_end_date',
85
+ NeverExpires: 'never_expires'
86
+ } as const;
87
+ export type GetUserCourseListItemCourseAccessPolicyTypeEnum = typeof GetUserCourseListItemCourseAccessPolicyTypeEnum[keyof typeof GetUserCourseListItemCourseAccessPolicyTypeEnum];
88
+
89
+
90
+ /**
91
+ * Check if a given object implements the GetUserCourseListItemCourse interface.
92
+ */
93
+ export function instanceOfGetUserCourseListItemCourse(value: object): value is GetUserCourseListItemCourse {
94
+ if (!('id' in value) || value['id'] === undefined) return false;
95
+ if (!('name' in value) || value['name'] === undefined) return false;
96
+ if (!('description' in value) || value['description'] === undefined) return false;
97
+ if (!('imageUrl' in value) || value['imageUrl'] === undefined) return false;
98
+ if (!('published' in value) || value['published'] === undefined) return false;
99
+ if (!('createdAt' in value) || value['createdAt'] === undefined) return false;
100
+ if (!('accessPolicyType' in value) || value['accessPolicyType'] === undefined) return false;
101
+ if (!('accessDurationDays' in value) || value['accessDurationDays'] === undefined) return false;
102
+ if (!('accessFixedEndAt' in value) || value['accessFixedEndAt'] === undefined) return false;
103
+ return true;
104
+ }
105
+
106
+ export function GetUserCourseListItemCourseFromJSON(json: any): GetUserCourseListItemCourse {
107
+ return GetUserCourseListItemCourseFromJSONTyped(json, false);
108
+ }
109
+
110
+ export function GetUserCourseListItemCourseFromJSONTyped(json: any, ignoreDiscriminator: boolean): GetUserCourseListItemCourse {
111
+ if (json == null) {
112
+ return json;
113
+ }
114
+ return {
115
+
116
+ 'id': json['id'],
117
+ 'name': json['name'],
118
+ 'description': json['description'],
119
+ 'imageUrl': json['image_url'],
120
+ 'published': json['published'],
121
+ 'createdAt': json['created_at'],
122
+ 'accessPolicyType': json['access_policy_type'],
123
+ 'accessDurationDays': json['access_duration_days'],
124
+ 'accessFixedEndAt': json['access_fixed_end_at'],
125
+ };
126
+ }
127
+
128
+ export function GetUserCourseListItemCourseToJSON(json: any): GetUserCourseListItemCourse {
129
+ return GetUserCourseListItemCourseToJSONTyped(json, false);
130
+ }
131
+
132
+ export function GetUserCourseListItemCourseToJSONTyped(value?: Omit<GetUserCourseListItemCourse, 'id'> | null, ignoreDiscriminator: boolean = false): any {
133
+ if (value == null) {
134
+ return value;
135
+ }
136
+
137
+ return {
138
+
139
+ 'name': value['name'],
140
+ 'description': value['description'],
141
+ 'image_url': value['imageUrl'],
142
+ 'published': value['published'],
143
+ 'created_at': value['createdAt'],
144
+ 'access_policy_type': value['accessPolicyType'],
145
+ 'access_duration_days': value['accessDurationDays'],
146
+ 'access_fixed_end_at': value['accessFixedEndAt'],
147
+ };
148
+ }
149
+
@@ -0,0 +1,171 @@
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
+ * Selected enrollment fields for an enrolled user's course list item.
18
+ * @export
19
+ * @interface GetUserCourseListItemEnrollment
20
+ */
21
+ export interface GetUserCourseListItemEnrollment {
22
+ /**
23
+ * The external ID of the selected enrollment.
24
+ * @type {string}
25
+ * @memberof GetUserCourseListItemEnrollment
26
+ */
27
+ id: string;
28
+ /**
29
+ *
30
+ * @type {GetUserCourseListItemEnrollmentStatusEnum}
31
+ * @memberof GetUserCourseListItemEnrollment
32
+ */
33
+ status: GetUserCourseListItemEnrollmentStatusEnum;
34
+ /**
35
+ *
36
+ * @type {GetUserCourseListItemEnrollmentAccessStateEnum}
37
+ * @memberof GetUserCourseListItemEnrollment
38
+ */
39
+ accessState: GetUserCourseListItemEnrollmentAccessStateEnum;
40
+ /**
41
+ *
42
+ * @type {number}
43
+ * @memberof GetUserCourseListItemEnrollment
44
+ */
45
+ daysUntilExpiry: number | null;
46
+ /**
47
+ *
48
+ * @type {GetUserCourseListItemEnrollmentUserTypeEnum}
49
+ * @memberof GetUserCourseListItemEnrollment
50
+ */
51
+ userType: GetUserCourseListItemEnrollmentUserTypeEnum;
52
+ /**
53
+ *
54
+ * @type {number}
55
+ * @memberof GetUserCourseListItemEnrollment
56
+ */
57
+ enrollmentDateStart: number;
58
+ /**
59
+ *
60
+ * @type {number}
61
+ * @memberof GetUserCourseListItemEnrollment
62
+ */
63
+ enrollmentDateEnd: number | null;
64
+ /**
65
+ *
66
+ * @type {number}
67
+ * @memberof GetUserCourseListItemEnrollment
68
+ */
69
+ completionDate: number | null;
70
+ }
71
+
72
+
73
+ /**
74
+ * @export
75
+ */
76
+ export const GetUserCourseListItemEnrollmentStatusEnum = {
77
+ Enrolled: 'Enrolled',
78
+ InProgress: 'InProgress',
79
+ Completed: 'Completed',
80
+ Failed: 'Failed',
81
+ Expired: 'Expired',
82
+ Withdrawn: 'Withdrawn',
83
+ Removed: 'Removed',
84
+ Archived: 'Archived',
85
+ Suspended: 'Suspended'
86
+ } as const;
87
+ export type GetUserCourseListItemEnrollmentStatusEnum = typeof GetUserCourseListItemEnrollmentStatusEnum[keyof typeof GetUserCourseListItemEnrollmentStatusEnum];
88
+
89
+ /**
90
+ * @export
91
+ */
92
+ export const GetUserCourseListItemEnrollmentAccessStateEnum = {
93
+ Active: 'active',
94
+ CompletedReview: 'completed_review',
95
+ Expired: 'expired',
96
+ Suspended: 'suspended',
97
+ Failed: 'failed',
98
+ Withdrawn: 'withdrawn',
99
+ Removed: 'removed',
100
+ Archived: 'archived'
101
+ } as const;
102
+ export type GetUserCourseListItemEnrollmentAccessStateEnum = typeof GetUserCourseListItemEnrollmentAccessStateEnum[keyof typeof GetUserCourseListItemEnrollmentAccessStateEnum];
103
+
104
+ /**
105
+ * @export
106
+ */
107
+ export const GetUserCourseListItemEnrollmentUserTypeEnum = {
108
+ Student: 'Student',
109
+ Instructor: 'Instructor'
110
+ } as const;
111
+ export type GetUserCourseListItemEnrollmentUserTypeEnum = typeof GetUserCourseListItemEnrollmentUserTypeEnum[keyof typeof GetUserCourseListItemEnrollmentUserTypeEnum];
112
+
113
+
114
+ /**
115
+ * Check if a given object implements the GetUserCourseListItemEnrollment interface.
116
+ */
117
+ export function instanceOfGetUserCourseListItemEnrollment(value: object): value is GetUserCourseListItemEnrollment {
118
+ if (!('id' in value) || value['id'] === undefined) return false;
119
+ if (!('status' in value) || value['status'] === undefined) return false;
120
+ if (!('accessState' in value) || value['accessState'] === undefined) return false;
121
+ if (!('daysUntilExpiry' in value) || value['daysUntilExpiry'] === undefined) return false;
122
+ if (!('userType' in value) || value['userType'] === undefined) return false;
123
+ if (!('enrollmentDateStart' in value) || value['enrollmentDateStart'] === undefined) return false;
124
+ if (!('enrollmentDateEnd' in value) || value['enrollmentDateEnd'] === undefined) return false;
125
+ if (!('completionDate' in value) || value['completionDate'] === undefined) return false;
126
+ return true;
127
+ }
128
+
129
+ export function GetUserCourseListItemEnrollmentFromJSON(json: any): GetUserCourseListItemEnrollment {
130
+ return GetUserCourseListItemEnrollmentFromJSONTyped(json, false);
131
+ }
132
+
133
+ export function GetUserCourseListItemEnrollmentFromJSONTyped(json: any, ignoreDiscriminator: boolean): GetUserCourseListItemEnrollment {
134
+ if (json == null) {
135
+ return json;
136
+ }
137
+ return {
138
+
139
+ 'id': json['id'],
140
+ 'status': json['status'],
141
+ 'accessState': json['access_state'],
142
+ 'daysUntilExpiry': json['days_until_expiry'],
143
+ 'userType': json['user_type'],
144
+ 'enrollmentDateStart': json['enrollment_date_start'],
145
+ 'enrollmentDateEnd': json['enrollment_date_end'],
146
+ 'completionDate': json['completion_date'],
147
+ };
148
+ }
149
+
150
+ export function GetUserCourseListItemEnrollmentToJSON(json: any): GetUserCourseListItemEnrollment {
151
+ return GetUserCourseListItemEnrollmentToJSONTyped(json, false);
152
+ }
153
+
154
+ export function GetUserCourseListItemEnrollmentToJSONTyped(value?: GetUserCourseListItemEnrollment | null, ignoreDiscriminator: boolean = false): any {
155
+ if (value == null) {
156
+ return value;
157
+ }
158
+
159
+ return {
160
+
161
+ 'id': value['id'],
162
+ 'status': value['status'],
163
+ 'access_state': value['accessState'],
164
+ 'days_until_expiry': value['daysUntilExpiry'],
165
+ 'user_type': value['userType'],
166
+ 'enrollment_date_start': value['enrollmentDateStart'],
167
+ 'enrollment_date_end': value['enrollmentDateEnd'],
168
+ 'completion_date': value['completionDate'],
169
+ };
170
+ }
171
+
@@ -0,0 +1,84 @@
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
+ * Learner progress for an enrolled user's course list item.
18
+ * @export
19
+ * @interface GetUserCourseListItemProgress
20
+ */
21
+ export interface GetUserCourseListItemProgress {
22
+ /**
23
+ * Completed visible content divided by total visible content. Null when total content count is zero.
24
+ * @type {number}
25
+ * @memberof GetUserCourseListItemProgress
26
+ */
27
+ completionPercentage: number | null;
28
+ /**
29
+ *
30
+ * @type {number}
31
+ * @memberof GetUserCourseListItemProgress
32
+ */
33
+ completedContentCount: number;
34
+ /**
35
+ *
36
+ * @type {number}
37
+ * @memberof GetUserCourseListItemProgress
38
+ */
39
+ totalContentCount: number;
40
+ }
41
+
42
+ /**
43
+ * Check if a given object implements the GetUserCourseListItemProgress interface.
44
+ */
45
+ export function instanceOfGetUserCourseListItemProgress(value: object): value is GetUserCourseListItemProgress {
46
+ if (!('completionPercentage' in value) || value['completionPercentage'] === undefined) return false;
47
+ if (!('completedContentCount' in value) || value['completedContentCount'] === undefined) return false;
48
+ if (!('totalContentCount' in value) || value['totalContentCount'] === undefined) return false;
49
+ return true;
50
+ }
51
+
52
+ export function GetUserCourseListItemProgressFromJSON(json: any): GetUserCourseListItemProgress {
53
+ return GetUserCourseListItemProgressFromJSONTyped(json, false);
54
+ }
55
+
56
+ export function GetUserCourseListItemProgressFromJSONTyped(json: any, ignoreDiscriminator: boolean): GetUserCourseListItemProgress {
57
+ if (json == null) {
58
+ return json;
59
+ }
60
+ return {
61
+
62
+ 'completionPercentage': json['completion_percentage'],
63
+ 'completedContentCount': json['completed_content_count'],
64
+ 'totalContentCount': json['total_content_count'],
65
+ };
66
+ }
67
+
68
+ export function GetUserCourseListItemProgressToJSON(json: any): GetUserCourseListItemProgress {
69
+ return GetUserCourseListItemProgressToJSONTyped(json, false);
70
+ }
71
+
72
+ export function GetUserCourseListItemProgressToJSONTyped(value?: GetUserCourseListItemProgress | null, ignoreDiscriminator: boolean = false): any {
73
+ if (value == null) {
74
+ return value;
75
+ }
76
+
77
+ return {
78
+
79
+ 'completion_percentage': value['completionPercentage'],
80
+ 'completed_content_count': value['completedContentCount'],
81
+ 'total_content_count': value['totalContentCount'],
82
+ };
83
+ }
84
+
@@ -155,6 +155,12 @@ export * from './GetSystemBillingList';
155
155
  export * from './GetSystemMetrics';
156
156
  export * from './GetUser';
157
157
  export * from './GetUserAvatarUpload';
158
+ export * from './GetUserCourseList';
159
+ export * from './GetUserCourseListItem';
160
+ export * from './GetUserCourseListItemCertificate';
161
+ export * from './GetUserCourseListItemCourse';
162
+ export * from './GetUserCourseListItemEnrollment';
163
+ export * from './GetUserCourseListItemProgress';
158
164
  export * from './GetUserQuizAttempts';
159
165
  export * from './GetUserQuizAttemptsAllOfAttempts';
160
166
  export * from './GetUserQuizAttemptsAllOfFilters';