@easyedu/js-lsm-api 1.125.0 → 1.126.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 (73) hide show
  1. package/.openapi-generator/FILES +4 -0
  2. package/README.md +5 -3
  3. package/dist/apis/CertificateTemplateApi.d.ts +10 -5
  4. package/dist/apis/CertificateTemplateApi.js +17 -12
  5. package/dist/apis/ContentLibraryApi.d.ts +4 -2
  6. package/dist/apis/ContentLibraryApi.js +5 -3
  7. package/dist/apis/CourseApi.d.ts +1 -0
  8. package/dist/apis/CourseApi.js +3 -0
  9. package/dist/esm/apis/CertificateTemplateApi.d.ts +10 -5
  10. package/dist/esm/apis/CertificateTemplateApi.js +17 -12
  11. package/dist/esm/apis/ContentLibraryApi.d.ts +4 -2
  12. package/dist/esm/apis/ContentLibraryApi.js +5 -3
  13. package/dist/esm/apis/CourseApi.d.ts +1 -0
  14. package/dist/esm/apis/CourseApi.js +3 -0
  15. package/dist/esm/models/CertificateTemplate.d.ts +7 -0
  16. package/dist/esm/models/CertificateTemplate.js +5 -0
  17. package/dist/esm/models/ContentLibraryTag.d.ts +12 -0
  18. package/dist/esm/models/ContentLibraryTag.js +8 -0
  19. package/dist/esm/models/ContentLibraryTagItem.d.ts +2 -0
  20. package/dist/esm/models/ContentLibraryTagItem.js +3 -1
  21. package/dist/esm/models/GetCourse.d.ts +7 -0
  22. package/dist/esm/models/GetCourse.js +5 -0
  23. package/dist/esm/models/PostCourse.d.ts +6 -0
  24. package/dist/esm/models/PostCourse.js +2 -0
  25. package/dist/esm/models/PostPortalCertificateTemplate.d.ts +57 -0
  26. package/dist/esm/models/PostPortalCertificateTemplate.js +52 -0
  27. package/dist/esm/models/PutCourse.d.ts +6 -0
  28. package/dist/esm/models/PutCourse.js +2 -0
  29. package/dist/esm/models/PutPortalCertificateTemplate.d.ts +50 -0
  30. package/dist/esm/models/PutPortalCertificateTemplate.js +47 -0
  31. package/dist/esm/models/index.d.ts +2 -0
  32. package/dist/esm/models/index.js +2 -0
  33. package/dist/models/CertificateTemplate.d.ts +7 -0
  34. package/dist/models/CertificateTemplate.js +5 -0
  35. package/dist/models/ContentLibraryTag.d.ts +12 -0
  36. package/dist/models/ContentLibraryTag.js +8 -0
  37. package/dist/models/ContentLibraryTagItem.d.ts +2 -0
  38. package/dist/models/ContentLibraryTagItem.js +3 -1
  39. package/dist/models/GetCourse.d.ts +7 -0
  40. package/dist/models/GetCourse.js +5 -0
  41. package/dist/models/PostCourse.d.ts +6 -0
  42. package/dist/models/PostCourse.js +2 -0
  43. package/dist/models/PostPortalCertificateTemplate.d.ts +57 -0
  44. package/dist/models/PostPortalCertificateTemplate.js +59 -0
  45. package/dist/models/PutCourse.d.ts +6 -0
  46. package/dist/models/PutCourse.js +2 -0
  47. package/dist/models/PutPortalCertificateTemplate.d.ts +50 -0
  48. package/dist/models/PutPortalCertificateTemplate.js +54 -0
  49. package/dist/models/index.d.ts +2 -0
  50. package/dist/models/index.js +2 -0
  51. package/docs/CertificateTemplate.md +2 -0
  52. package/docs/CertificateTemplateApi.md +19 -11
  53. package/docs/ContentLibraryApi.md +4 -4
  54. package/docs/ContentLibraryTag.md +4 -0
  55. package/docs/CourseApi.md +5 -2
  56. package/docs/GetCourse.md +2 -0
  57. package/docs/PostCourse.md +2 -0
  58. package/docs/PostPortalCertificateTemplate.md +42 -0
  59. package/docs/PutCourse.md +2 -0
  60. package/docs/PutPortalCertificateTemplate.md +40 -0
  61. package/package.json +1 -1
  62. package/src/apis/CertificateTemplateApi.ts +33 -15
  63. package/src/apis/ContentLibraryApi.ts +5 -3
  64. package/src/apis/CourseApi.ts +5 -0
  65. package/src/models/CertificateTemplate.ts +16 -0
  66. package/src/models/ContentLibraryTag.ts +18 -0
  67. package/src/models/ContentLibraryTagItem.ts +3 -1
  68. package/src/models/GetCourse.ts +17 -0
  69. package/src/models/PostCourse.ts +8 -0
  70. package/src/models/PostPortalCertificateTemplate.ts +106 -0
  71. package/src/models/PutCourse.ts +8 -0
  72. package/src/models/PutPortalCertificateTemplate.ts +89 -0
  73. package/src/models/index.ts +2 -0
@@ -58,6 +58,11 @@ import {
58
58
  PostCertificateTemplatePreviewFromJSON,
59
59
  PostCertificateTemplatePreviewToJSON,
60
60
  } from '../models/PostCertificateTemplatePreview';
61
+ import {
62
+ type PostPortalCertificateTemplate,
63
+ PostPortalCertificateTemplateFromJSON,
64
+ PostPortalCertificateTemplateToJSON,
65
+ } from '../models/PostPortalCertificateTemplate';
61
66
  import {
62
67
  type PutCertificateTemplate,
63
68
  PutCertificateTemplateFromJSON,
@@ -68,6 +73,11 @@ import {
68
73
  PutCertificateTemplateDraftFromJSON,
69
74
  PutCertificateTemplateDraftToJSON,
70
75
  } from '../models/PutCertificateTemplateDraft';
76
+ import {
77
+ type PutPortalCertificateTemplate,
78
+ PutPortalCertificateTemplateFromJSON,
79
+ PutPortalCertificateTemplateToJSON,
80
+ } from '../models/PutPortalCertificateTemplate';
71
81
 
72
82
  export interface DeleteCertificateTemplateDraftRequest {
73
83
  templateId: string;
@@ -85,6 +95,10 @@ export interface GetCertificateTemplateRequest {
85
95
  templateId: string;
86
96
  }
87
97
 
98
+ export interface GetCertificateTemplateListRequest {
99
+ tagId?: string;
100
+ }
101
+
88
102
  export interface GetCertificateTemplateVersionsRequest {
89
103
  templateId: string;
90
104
  }
@@ -115,7 +129,7 @@ export interface PostCertificateAssetUploadRequest {
115
129
  }
116
130
 
117
131
  export interface PostCertificateTemplateRequest {
118
- postCertificateTemplate: PostCertificateTemplate;
132
+ postPortalCertificateTemplate: PostPortalCertificateTemplate;
119
133
  }
120
134
 
121
135
  export interface PostCertificateTemplateArchiveRequest {
@@ -200,7 +214,7 @@ export interface PutCertificateAssetFileRequest {
200
214
 
201
215
  export interface PutCertificateTemplateRequest {
202
216
  templateId: string;
203
- putCertificateTemplate: PutCertificateTemplate;
217
+ putPortalCertificateTemplate: PutPortalCertificateTemplate;
204
218
  }
205
219
 
206
220
  export interface PutCertificateTemplateDraftRequest {
@@ -409,9 +423,13 @@ export class CertificateTemplateApi extends runtime.BaseAPI {
409
423
  /**
410
424
  * Creates request options for getCertificateTemplateList without sending the request
411
425
  */
412
- async getCertificateTemplateListRequestOpts(): Promise<runtime.RequestOpts> {
426
+ async getCertificateTemplateListRequestOpts(requestParameters: GetCertificateTemplateListRequest): Promise<runtime.RequestOpts> {
413
427
  const queryParameters: any = {};
414
428
 
429
+ if (requestParameters['tagId'] != null) {
430
+ queryParameters['tag_id'] = requestParameters['tagId'];
431
+ }
432
+
415
433
  const headerParameters: runtime.HTTPHeaders = {};
416
434
 
417
435
 
@@ -428,8 +446,8 @@ export class CertificateTemplateApi extends runtime.BaseAPI {
428
446
  /**
429
447
  * List local and inherited certificate designs
430
448
  */
431
- async getCertificateTemplateListRaw(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<GetCertificateTemplateList>> {
432
- const requestOptions = await this.getCertificateTemplateListRequestOpts();
449
+ async getCertificateTemplateListRaw(requestParameters: GetCertificateTemplateListRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<GetCertificateTemplateList>> {
450
+ const requestOptions = await this.getCertificateTemplateListRequestOpts(requestParameters);
433
451
  const response = await this.request(requestOptions, initOverrides);
434
452
 
435
453
  return new runtime.JSONApiResponse(response, (jsonValue) => GetCertificateTemplateListFromJSON(jsonValue));
@@ -438,8 +456,8 @@ export class CertificateTemplateApi extends runtime.BaseAPI {
438
456
  /**
439
457
  * List local and inherited certificate designs
440
458
  */
441
- async getCertificateTemplateList(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GetCertificateTemplateList> {
442
- const response = await this.getCertificateTemplateListRaw(initOverrides);
459
+ async getCertificateTemplateList(requestParameters: GetCertificateTemplateListRequest = {}, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GetCertificateTemplateList> {
460
+ const response = await this.getCertificateTemplateListRaw(requestParameters, initOverrides);
443
461
  return await response.value();
444
462
  }
445
463
 
@@ -811,10 +829,10 @@ export class CertificateTemplateApi extends runtime.BaseAPI {
811
829
  * Creates request options for postCertificateTemplate without sending the request
812
830
  */
813
831
  async postCertificateTemplateRequestOpts(requestParameters: PostCertificateTemplateRequest): Promise<runtime.RequestOpts> {
814
- if (requestParameters['postCertificateTemplate'] == null) {
832
+ if (requestParameters['postPortalCertificateTemplate'] == null) {
815
833
  throw new runtime.RequiredError(
816
- 'postCertificateTemplate',
817
- 'Required parameter "postCertificateTemplate" was null or undefined when calling postCertificateTemplate().'
834
+ 'postPortalCertificateTemplate',
835
+ 'Required parameter "postPortalCertificateTemplate" was null or undefined when calling postCertificateTemplate().'
818
836
  );
819
837
  }
820
838
 
@@ -832,7 +850,7 @@ export class CertificateTemplateApi extends runtime.BaseAPI {
832
850
  method: 'POST',
833
851
  headers: headerParameters,
834
852
  query: queryParameters,
835
- body: PostCertificateTemplateToJSON(requestParameters['postCertificateTemplate']),
853
+ body: PostPortalCertificateTemplateToJSON(requestParameters['postPortalCertificateTemplate']),
836
854
  };
837
855
  }
838
856
 
@@ -1754,10 +1772,10 @@ export class CertificateTemplateApi extends runtime.BaseAPI {
1754
1772
  );
1755
1773
  }
1756
1774
 
1757
- if (requestParameters['putCertificateTemplate'] == null) {
1775
+ if (requestParameters['putPortalCertificateTemplate'] == null) {
1758
1776
  throw new runtime.RequiredError(
1759
- 'putCertificateTemplate',
1760
- 'Required parameter "putCertificateTemplate" was null or undefined when calling putCertificateTemplate().'
1777
+ 'putPortalCertificateTemplate',
1778
+ 'Required parameter "putPortalCertificateTemplate" was null or undefined when calling putCertificateTemplate().'
1761
1779
  );
1762
1780
  }
1763
1781
 
@@ -1776,7 +1794,7 @@ export class CertificateTemplateApi extends runtime.BaseAPI {
1776
1794
  method: 'PUT',
1777
1795
  headers: headerParameters,
1778
1796
  query: queryParameters,
1779
- body: PutCertificateTemplateToJSON(requestParameters['putCertificateTemplate']),
1797
+ body: PutPortalCertificateTemplateToJSON(requestParameters['putPortalCertificateTemplate']),
1780
1798
  };
1781
1799
  }
1782
1800
 
@@ -510,7 +510,7 @@ export class ContentLibraryApi extends runtime.BaseAPI {
510
510
  }
511
511
 
512
512
  /**
513
- * List resources, quizzes, and questions associated with a tag
513
+ * List resources, quizzes, questions, courses, and certificate designs associated with a tag
514
514
  */
515
515
  async getContentLibraryTagItemListRaw(requestParameters: GetContentLibraryTagItemListRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<GetContentLibraryTagItemList>> {
516
516
  const requestOptions = await this.getContentLibraryTagItemListRequestOpts(requestParameters);
@@ -520,7 +520,7 @@ export class ContentLibraryApi extends runtime.BaseAPI {
520
520
  }
521
521
 
522
522
  /**
523
- * List resources, quizzes, and questions associated with a tag
523
+ * List resources, quizzes, questions, courses, and certificate designs associated with a tag
524
524
  */
525
525
  async getContentLibraryTagItemList(requestParameters: GetContentLibraryTagItemListRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GetContentLibraryTagItemList> {
526
526
  const response = await this.getContentLibraryTagItemListRaw(requestParameters, initOverrides);
@@ -1651,7 +1651,9 @@ export class ContentLibraryApi extends runtime.BaseAPI {
1651
1651
  export const GetContentLibraryTagItemListKindEnum = {
1652
1652
  Resource: 'resource',
1653
1653
  Quiz: 'quiz',
1654
- Question: 'question'
1654
+ Question: 'question',
1655
+ Course: 'course',
1656
+ CertificateTemplate: 'certificate_template'
1655
1657
  } as const;
1656
1658
  export type GetContentLibraryTagItemListKindEnum = typeof GetContentLibraryTagItemListKindEnum[keyof typeof GetContentLibraryTagItemListKindEnum];
1657
1659
  /**
@@ -289,6 +289,7 @@ export interface GetCourseListRequest {
289
289
  enrolled?: boolean;
290
290
  search?: string;
291
291
  recentActivitySince?: number;
292
+ tagId?: string;
292
293
  }
293
294
 
294
295
  export interface GetCourseVersionRequest {
@@ -1232,6 +1233,10 @@ export class CourseApi extends runtime.BaseAPI {
1232
1233
  queryParameters['recentActivitySince'] = requestParameters['recentActivitySince'];
1233
1234
  }
1234
1235
 
1236
+ if (requestParameters['tagId'] != null) {
1237
+ queryParameters['tag_id'] = requestParameters['tagId'];
1238
+ }
1239
+
1235
1240
  const headerParameters: runtime.HTTPHeaders = {};
1236
1241
 
1237
1242
 
@@ -13,6 +13,13 @@
13
13
  */
14
14
 
15
15
  import { mapValues } from '../runtime';
16
+ import type { ContentLibraryTag } from './ContentLibraryTag';
17
+ import {
18
+ ContentLibraryTagFromJSON,
19
+ ContentLibraryTagFromJSONTyped,
20
+ ContentLibraryTagToJSON,
21
+ ContentLibraryTagToJSONTyped,
22
+ } from './ContentLibraryTag';
16
23
  import type { CertificateTemplateVersion } from './CertificateTemplateVersion';
17
24
  import {
18
25
  CertificateTemplateVersionFromJSON,
@@ -75,6 +82,12 @@ export interface CertificateTemplate {
75
82
  * @memberof CertificateTemplate
76
83
  */
77
84
  effectiveSourcePortalId?: string | null;
85
+ /**
86
+ *
87
+ * @type {Array<ContentLibraryTag>}
88
+ * @memberof CertificateTemplate
89
+ */
90
+ tags: Array<ContentLibraryTag>;
78
91
  /**
79
92
  *
80
93
  * @type {CertificateTemplateVersion}
@@ -136,6 +149,7 @@ export function instanceOfCertificateTemplate(value: object): value is Certifica
136
149
  if (!('isDefault' in value) || value['isDefault'] === undefined) return false;
137
150
  if (!('isInherited' in value) || value['isInherited'] === undefined) return false;
138
151
  if (!('effectiveSource' in value) || value['effectiveSource'] === undefined) return false;
152
+ if (!('tags' in value) || value['tags'] === undefined) return false;
139
153
  if (!('activeVersion' in value) || value['activeVersion'] === undefined) return false;
140
154
  if (!('versions' in value) || value['versions'] === undefined) return false;
141
155
  if (!('createdAt' in value) || value['createdAt'] === undefined) return false;
@@ -161,6 +175,7 @@ export function CertificateTemplateFromJSONTyped(json: any, ignoreDiscriminator:
161
175
  'isInherited': json['is_inherited'],
162
176
  'effectiveSource': json['effective_source'],
163
177
  'effectiveSourcePortalId': json['effective_source_portal_id'] == null ? undefined : json['effective_source_portal_id'],
178
+ 'tags': ((json['tags'] as Array<any>).map(ContentLibraryTagFromJSON)),
164
179
  'activeVersion': CertificateTemplateVersionFromJSON(json['active_version']),
165
180
  'draftVersion': json['draft_version'] == null ? undefined : CertificateTemplateVersionFromJSON(json['draft_version']),
166
181
  'versions': ((json['versions'] as Array<any>).map(CertificateTemplateVersionFromJSON)),
@@ -189,6 +204,7 @@ export function CertificateTemplateToJSONTyped(value?: CertificateTemplate | nul
189
204
  'is_inherited': value['isInherited'],
190
205
  'effective_source': value['effectiveSource'],
191
206
  'effective_source_portal_id': value['effectiveSourcePortalId'],
207
+ 'tags': ((value['tags'] as Array<any>).map(ContentLibraryTagToJSON)),
192
208
  'active_version': CertificateTemplateVersionToJSON(value['activeVersion']),
193
209
  'draft_version': CertificateTemplateVersionToJSON(value['draftVersion']),
194
210
  'versions': ((value['versions'] as Array<any>).map(CertificateTemplateVersionToJSON)),
@@ -91,6 +91,18 @@ export interface ContentLibraryTag {
91
91
  * @memberof ContentLibraryTag
92
92
  */
93
93
  questionCount: number;
94
+ /**
95
+ *
96
+ * @type {number}
97
+ * @memberof ContentLibraryTag
98
+ */
99
+ courseCount: number;
100
+ /**
101
+ *
102
+ * @type {number}
103
+ * @memberof ContentLibraryTag
104
+ */
105
+ certificateTemplateCount: number;
94
106
  /**
95
107
  *
96
108
  * @type {number}
@@ -118,6 +130,8 @@ export function instanceOfContentLibraryTag(value: object): value is ContentLibr
118
130
  if (!('resourceCount' in value) || value['resourceCount'] === undefined) return false;
119
131
  if (!('quizCount' in value) || value['quizCount'] === undefined) return false;
120
132
  if (!('questionCount' in value) || value['questionCount'] === undefined) return false;
133
+ if (!('courseCount' in value) || value['courseCount'] === undefined) return false;
134
+ if (!('certificateTemplateCount' in value) || value['certificateTemplateCount'] === undefined) return false;
121
135
  if (!('createdAt' in value) || value['createdAt'] === undefined) return false;
122
136
  if (!('updatedAt' in value) || value['updatedAt'] === undefined) return false;
123
137
  return true;
@@ -145,6 +159,8 @@ export function ContentLibraryTagFromJSONTyped(json: any, ignoreDiscriminator: b
145
159
  'resourceCount': json['resource_count'],
146
160
  'quizCount': json['quiz_count'],
147
161
  'questionCount': json['question_count'],
162
+ 'courseCount': json['course_count'],
163
+ 'certificateTemplateCount': json['certificate_template_count'],
148
164
  'createdAt': json['created_at'],
149
165
  'updatedAt': json['updated_at'],
150
166
  };
@@ -173,6 +189,8 @@ export function ContentLibraryTagToJSONTyped(value?: ContentLibraryTag | null, i
173
189
  'resource_count': value['resourceCount'],
174
190
  'quiz_count': value['quizCount'],
175
191
  'question_count': value['questionCount'],
192
+ 'course_count': value['courseCount'],
193
+ 'certificate_template_count': value['certificateTemplateCount'],
176
194
  'created_at': value['createdAt'],
177
195
  'updated_at': value['updatedAt'],
178
196
  };
@@ -91,7 +91,9 @@ export interface ContentLibraryTagItem {
91
91
  export const ContentLibraryTagItemKindEnum = {
92
92
  Resource: 'resource',
93
93
  Quiz: 'quiz',
94
- Question: 'question'
94
+ Question: 'question',
95
+ Course: 'course',
96
+ CertificateTemplate: 'certificate_template'
95
97
  } as const;
96
98
  export type ContentLibraryTagItemKindEnum = typeof ContentLibraryTagItemKindEnum[keyof typeof ContentLibraryTagItemKindEnum];
97
99
 
@@ -13,6 +13,14 @@
13
13
  */
14
14
 
15
15
  import { mapValues } from '../runtime';
16
+ import type { ContentLibraryTag } from './ContentLibraryTag';
17
+ import {
18
+ ContentLibraryTagFromJSON,
19
+ ContentLibraryTagFromJSONTyped,
20
+ ContentLibraryTagToJSON,
21
+ ContentLibraryTagToJSONTyped,
22
+ } from './ContentLibraryTag';
23
+
16
24
  /**
17
25
  *
18
26
  * @export
@@ -73,6 +81,12 @@ export interface GetCourse {
73
81
  * @memberof GetCourse
74
82
  */
75
83
  accessFixedEndAt: number | null;
84
+ /**
85
+ *
86
+ * @type {Array<ContentLibraryTag>}
87
+ * @memberof GetCourse
88
+ */
89
+ tags: Array<ContentLibraryTag>;
76
90
  }
77
91
 
78
92
 
@@ -100,6 +114,7 @@ export function instanceOfGetCourse(value: object): value is GetCourse {
100
114
  if (!('accessPolicyType' in value) || value['accessPolicyType'] === undefined) return false;
101
115
  if (!('accessDurationDays' in value) || value['accessDurationDays'] === undefined) return false;
102
116
  if (!('accessFixedEndAt' in value) || value['accessFixedEndAt'] === undefined) return false;
117
+ if (!('tags' in value) || value['tags'] === undefined) return false;
103
118
  return true;
104
119
  }
105
120
 
@@ -122,6 +137,7 @@ export function GetCourseFromJSONTyped(json: any, ignoreDiscriminator: boolean):
122
137
  'accessPolicyType': json['access_policy_type'],
123
138
  'accessDurationDays': json['access_duration_days'],
124
139
  'accessFixedEndAt': json['access_fixed_end_at'],
140
+ 'tags': ((json['tags'] as Array<any>).map(ContentLibraryTagFromJSON)),
125
141
  };
126
142
  }
127
143
 
@@ -144,6 +160,7 @@ export function GetCourseToJSONTyped(value?: Omit<GetCourse, 'id'> | null, ignor
144
160
  'access_policy_type': value['accessPolicyType'],
145
161
  'access_duration_days': value['accessDurationDays'],
146
162
  'access_fixed_end_at': value['accessFixedEndAt'],
163
+ 'tags': ((value['tags'] as Array<any>).map(ContentLibraryTagToJSON)),
147
164
  };
148
165
  }
149
166
 
@@ -51,6 +51,12 @@ export interface PostCourse {
51
51
  * @memberof PostCourse
52
52
  */
53
53
  accessFixedEndAt?: number | null;
54
+ /**
55
+ *
56
+ * @type {Set<string>}
57
+ * @memberof PostCourse
58
+ */
59
+ tags?: Set<string>;
54
60
  }
55
61
 
56
62
 
@@ -89,6 +95,7 @@ export function PostCourseFromJSONTyped(json: any, ignoreDiscriminator: boolean)
89
95
  'accessPolicyType': json['access_policy_type'] == null ? undefined : json['access_policy_type'],
90
96
  'accessDurationDays': json['access_duration_days'] == null ? undefined : json['access_duration_days'],
91
97
  'accessFixedEndAt': json['access_fixed_end_at'] == null ? undefined : json['access_fixed_end_at'],
98
+ 'tags': json['tags'] == null ? undefined : new Set(json['tags']),
92
99
  };
93
100
  }
94
101
 
@@ -108,6 +115,7 @@ export function PostCourseToJSONTyped(value?: PostCourse | null, ignoreDiscrimin
108
115
  'access_policy_type': value['accessPolicyType'],
109
116
  'access_duration_days': value['accessDurationDays'],
110
117
  'access_fixed_end_at': value['accessFixedEndAt'],
118
+ 'tags': value['tags'] == null ? undefined : Array.from(value['tags'] as Set<any>),
111
119
  };
112
120
  }
113
121
 
@@ -0,0 +1,106 @@
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 { CertificateCanvasDocument } from './CertificateCanvasDocument';
17
+ import {
18
+ CertificateCanvasDocumentFromJSON,
19
+ CertificateCanvasDocumentFromJSONTyped,
20
+ CertificateCanvasDocumentToJSON,
21
+ CertificateCanvasDocumentToJSONTyped,
22
+ } from './CertificateCanvasDocument';
23
+
24
+ /**
25
+ *
26
+ * @export
27
+ * @interface PostPortalCertificateTemplate
28
+ */
29
+ export interface PostPortalCertificateTemplate {
30
+ /**
31
+ *
32
+ * @type {string}
33
+ * @memberof PostPortalCertificateTemplate
34
+ */
35
+ name: string;
36
+ /**
37
+ *
38
+ * @type {string}
39
+ * @memberof PostPortalCertificateTemplate
40
+ */
41
+ description?: string;
42
+ /**
43
+ *
44
+ * @type {boolean}
45
+ * @memberof PostPortalCertificateTemplate
46
+ */
47
+ isDefault?: boolean;
48
+ /**
49
+ *
50
+ * @type {CertificateCanvasDocument}
51
+ * @memberof PostPortalCertificateTemplate
52
+ */
53
+ designDocument?: CertificateCanvasDocument;
54
+ /**
55
+ *
56
+ * @type {Set<string>}
57
+ * @memberof PostPortalCertificateTemplate
58
+ */
59
+ tags?: Set<string>;
60
+ }
61
+
62
+ /**
63
+ * Check if a given object implements the PostPortalCertificateTemplate interface.
64
+ */
65
+ export function instanceOfPostPortalCertificateTemplate(value: object): value is PostPortalCertificateTemplate {
66
+ if (!('name' in value) || value['name'] === undefined) return false;
67
+ return true;
68
+ }
69
+
70
+ export function PostPortalCertificateTemplateFromJSON(json: any): PostPortalCertificateTemplate {
71
+ return PostPortalCertificateTemplateFromJSONTyped(json, false);
72
+ }
73
+
74
+ export function PostPortalCertificateTemplateFromJSONTyped(json: any, ignoreDiscriminator: boolean): PostPortalCertificateTemplate {
75
+ if (json == null) {
76
+ return json;
77
+ }
78
+ return {
79
+
80
+ 'name': json['name'],
81
+ 'description': json['description'] == null ? undefined : json['description'],
82
+ 'isDefault': json['is_default'] == null ? undefined : json['is_default'],
83
+ 'designDocument': json['design_document'] == null ? undefined : CertificateCanvasDocumentFromJSON(json['design_document']),
84
+ 'tags': json['tags'] == null ? undefined : new Set(json['tags']),
85
+ };
86
+ }
87
+
88
+ export function PostPortalCertificateTemplateToJSON(json: any): PostPortalCertificateTemplate {
89
+ return PostPortalCertificateTemplateToJSONTyped(json, false);
90
+ }
91
+
92
+ export function PostPortalCertificateTemplateToJSONTyped(value?: PostPortalCertificateTemplate | null, ignoreDiscriminator: boolean = false): any {
93
+ if (value == null) {
94
+ return value;
95
+ }
96
+
97
+ return {
98
+
99
+ 'name': value['name'],
100
+ 'description': value['description'],
101
+ 'is_default': value['isDefault'],
102
+ 'design_document': CertificateCanvasDocumentToJSON(value['designDocument']),
103
+ 'tags': value['tags'] == null ? undefined : Array.from(value['tags'] as Set<any>),
104
+ };
105
+ }
106
+
@@ -61,6 +61,12 @@ export interface PutCourse {
61
61
  * @memberof PutCourse
62
62
  */
63
63
  accessFixedEndAt?: number | null;
64
+ /**
65
+ *
66
+ * @type {Set<string>}
67
+ * @memberof PutCourse
68
+ */
69
+ tags?: Set<string>;
64
70
  }
65
71
 
66
72
 
@@ -99,6 +105,7 @@ export function PutCourseFromJSONTyped(json: any, ignoreDiscriminator: boolean):
99
105
  'accessPolicyType': json['access_policy_type'] == null ? undefined : json['access_policy_type'],
100
106
  'accessDurationDays': json['access_duration_days'] == null ? undefined : json['access_duration_days'],
101
107
  'accessFixedEndAt': json['access_fixed_end_at'] == null ? undefined : json['access_fixed_end_at'],
108
+ 'tags': json['tags'] == null ? undefined : new Set(json['tags']),
102
109
  };
103
110
  }
104
111
 
@@ -119,6 +126,7 @@ export function PutCourseToJSONTyped(value?: Omit<PutCourse, 'id'> | null, ignor
119
126
  'access_policy_type': value['accessPolicyType'],
120
127
  'access_duration_days': value['accessDurationDays'],
121
128
  'access_fixed_end_at': value['accessFixedEndAt'],
129
+ 'tags': value['tags'] == null ? undefined : Array.from(value['tags'] as Set<any>),
122
130
  };
123
131
  }
124
132
 
@@ -0,0 +1,89 @@
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
+ *
18
+ * @export
19
+ * @interface PutPortalCertificateTemplate
20
+ */
21
+ export interface PutPortalCertificateTemplate {
22
+ /**
23
+ *
24
+ * @type {string}
25
+ * @memberof PutPortalCertificateTemplate
26
+ */
27
+ name?: string;
28
+ /**
29
+ *
30
+ * @type {string}
31
+ * @memberof PutPortalCertificateTemplate
32
+ */
33
+ description?: string;
34
+ /**
35
+ *
36
+ * @type {boolean}
37
+ * @memberof PutPortalCertificateTemplate
38
+ */
39
+ isDefault?: boolean;
40
+ /**
41
+ *
42
+ * @type {Set<string>}
43
+ * @memberof PutPortalCertificateTemplate
44
+ */
45
+ tags?: Set<string>;
46
+ }
47
+
48
+ /**
49
+ * Check if a given object implements the PutPortalCertificateTemplate interface.
50
+ */
51
+ export function instanceOfPutPortalCertificateTemplate(value: object): value is PutPortalCertificateTemplate {
52
+ return true;
53
+ }
54
+
55
+ export function PutPortalCertificateTemplateFromJSON(json: any): PutPortalCertificateTemplate {
56
+ return PutPortalCertificateTemplateFromJSONTyped(json, false);
57
+ }
58
+
59
+ export function PutPortalCertificateTemplateFromJSONTyped(json: any, ignoreDiscriminator: boolean): PutPortalCertificateTemplate {
60
+ if (json == null) {
61
+ return json;
62
+ }
63
+ return {
64
+
65
+ 'name': json['name'] == null ? undefined : json['name'],
66
+ 'description': json['description'] == null ? undefined : json['description'],
67
+ 'isDefault': json['is_default'] == null ? undefined : json['is_default'],
68
+ 'tags': json['tags'] == null ? undefined : new Set(json['tags']),
69
+ };
70
+ }
71
+
72
+ export function PutPortalCertificateTemplateToJSON(json: any): PutPortalCertificateTemplate {
73
+ return PutPortalCertificateTemplateToJSONTyped(json, false);
74
+ }
75
+
76
+ export function PutPortalCertificateTemplateToJSONTyped(value?: PutPortalCertificateTemplate | null, ignoreDiscriminator: boolean = false): any {
77
+ if (value == null) {
78
+ return value;
79
+ }
80
+
81
+ return {
82
+
83
+ 'name': value['name'],
84
+ 'description': value['description'],
85
+ 'is_default': value['isDefault'],
86
+ 'tags': value['tags'] == null ? undefined : Array.from(value['tags'] as Set<any>),
87
+ };
88
+ }
89
+
@@ -265,6 +265,7 @@ export * from './PostOfferCatalogResponse';
265
265
  export * from './PostOfferCourse';
266
266
  export * from './PostOfferCourseResponse';
267
267
  export * from './PostPortal';
268
+ export * from './PostPortalCertificateTemplate';
268
269
  export * from './PostPortalInvite';
269
270
  export * from './PostQuestion';
270
271
  export * from './PostQuestionAnswerChoicesInner';
@@ -324,6 +325,7 @@ export * from './PutLibraryQuizSessionGrade';
324
325
  export * from './PutLibraryQuizSessionOverride';
325
326
  export * from './PutLibraryQuizVersion';
326
327
  export * from './PutPortalBranding';
328
+ export * from './PutPortalCertificateTemplate';
327
329
  export * from './PutPortalSublicense';
328
330
  export * from './PutPortalUserFieldValues';
329
331
  export * from './PutQuestion';