@easyedu/js-lsm-api 1.133.0 → 1.134.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 +2 -0
- package/README.md +5 -3
- package/dist/apis/IntegrationApi.d.ts +7 -3
- package/dist/apis/IntegrationApi.js +10 -5
- package/dist/apis/PortalApi.d.ts +21 -0
- package/dist/apis/PortalApi.js +52 -0
- package/dist/esm/apis/IntegrationApi.d.ts +7 -3
- package/dist/esm/apis/IntegrationApi.js +10 -5
- package/dist/esm/apis/PortalApi.d.ts +21 -0
- package/dist/esm/apis/PortalApi.js +52 -0
- package/dist/esm/models/GetCourse.d.ts +6 -0
- package/dist/esm/models/GetCourse.js +4 -0
- package/dist/esm/models/GetPortalUser.d.ts +6 -0
- package/dist/esm/models/GetPortalUser.js +4 -0
- package/dist/esm/models/GetResource.d.ts +6 -0
- package/dist/esm/models/GetResource.js +4 -0
- package/dist/esm/models/IntegrationEventCourse.d.ts +6 -0
- package/dist/esm/models/IntegrationEventCourse.js +2 -0
- package/dist/esm/models/IntegrationEventLearner.d.ts +6 -0
- package/dist/esm/models/IntegrationEventLearner.js +2 -0
- package/dist/esm/models/IntegrationEventUser.d.ts +6 -0
- package/dist/esm/models/IntegrationEventUser.js +2 -0
- package/dist/esm/models/PostCourse.d.ts +6 -0
- package/dist/esm/models/PostCourse.js +2 -0
- package/dist/esm/models/PostPortalInvite.d.ts +6 -0
- package/dist/esm/models/PostPortalInvite.js +2 -0
- package/dist/esm/models/PostResource.d.ts +6 -0
- package/dist/esm/models/PostResource.js +2 -0
- package/dist/esm/models/PostRichTextAssetUpload.d.ts +6 -0
- package/dist/esm/models/PostRichTextAssetUpload.js +2 -0
- package/dist/esm/models/PostZapierEnrollment.d.ts +16 -4
- package/dist/esm/models/PostZapierEnrollment.js +6 -6
- package/dist/esm/models/PostZapierShopifyCourseMapping.d.ts +8 -2
- package/dist/esm/models/PostZapierShopifyCourseMapping.js +3 -3
- package/dist/esm/models/PostZapierUser.d.ts +6 -0
- package/dist/esm/models/PostZapierUser.js +2 -0
- package/dist/esm/models/PutCourse.d.ts +6 -0
- package/dist/esm/models/PutCourse.js +2 -0
- package/dist/esm/models/PutPortalUser.d.ts +32 -0
- package/dist/esm/models/PutPortalUser.js +41 -0
- package/dist/esm/models/PutResource.d.ts +6 -0
- package/dist/esm/models/PutResource.js +2 -0
- package/dist/esm/models/RichTextAsset.d.ts +6 -0
- package/dist/esm/models/RichTextAsset.js +2 -0
- package/dist/esm/models/ZapierCourse.d.ts +6 -0
- package/dist/esm/models/ZapierCourse.js +4 -0
- package/dist/esm/models/ZapierEnrollment.d.ts +12 -0
- package/dist/esm/models/ZapierEnrollment.js +8 -0
- package/dist/esm/models/ZapierUser.d.ts +6 -0
- package/dist/esm/models/ZapierUser.js +4 -0
- package/dist/esm/models/index.d.ts +1 -0
- package/dist/esm/models/index.js +1 -0
- package/dist/models/GetCourse.d.ts +6 -0
- package/dist/models/GetCourse.js +4 -0
- package/dist/models/GetPortalUser.d.ts +6 -0
- package/dist/models/GetPortalUser.js +4 -0
- package/dist/models/GetResource.d.ts +6 -0
- package/dist/models/GetResource.js +4 -0
- package/dist/models/IntegrationEventCourse.d.ts +6 -0
- package/dist/models/IntegrationEventCourse.js +2 -0
- package/dist/models/IntegrationEventLearner.d.ts +6 -0
- package/dist/models/IntegrationEventLearner.js +2 -0
- package/dist/models/IntegrationEventUser.d.ts +6 -0
- package/dist/models/IntegrationEventUser.js +2 -0
- package/dist/models/PostCourse.d.ts +6 -0
- package/dist/models/PostCourse.js +2 -0
- package/dist/models/PostPortalInvite.d.ts +6 -0
- package/dist/models/PostPortalInvite.js +2 -0
- package/dist/models/PostResource.d.ts +6 -0
- package/dist/models/PostResource.js +2 -0
- package/dist/models/PostRichTextAssetUpload.d.ts +6 -0
- package/dist/models/PostRichTextAssetUpload.js +2 -0
- package/dist/models/PostZapierEnrollment.d.ts +16 -4
- package/dist/models/PostZapierEnrollment.js +6 -6
- package/dist/models/PostZapierShopifyCourseMapping.d.ts +8 -2
- package/dist/models/PostZapierShopifyCourseMapping.js +3 -3
- package/dist/models/PostZapierUser.d.ts +6 -0
- package/dist/models/PostZapierUser.js +2 -0
- package/dist/models/PutCourse.d.ts +6 -0
- package/dist/models/PutCourse.js +2 -0
- package/dist/models/PutPortalUser.d.ts +32 -0
- package/dist/models/PutPortalUser.js +48 -0
- package/dist/models/PutResource.d.ts +6 -0
- package/dist/models/PutResource.js +2 -0
- package/dist/models/RichTextAsset.d.ts +6 -0
- package/dist/models/RichTextAsset.js +2 -0
- package/dist/models/ZapierCourse.d.ts +6 -0
- package/dist/models/ZapierCourse.js +4 -0
- package/dist/models/ZapierEnrollment.d.ts +12 -0
- package/dist/models/ZapierEnrollment.js +8 -0
- package/dist/models/ZapierUser.d.ts +6 -0
- package/dist/models/ZapierUser.js +4 -0
- package/dist/models/index.d.ts +1 -0
- package/dist/models/index.js +1 -0
- package/docs/GetCourse.md +2 -0
- package/docs/GetPortalUser.md +2 -0
- package/docs/GetResource.md +2 -0
- package/docs/IntegrationApi.md +15 -6
- package/docs/IntegrationEventCourse.md +2 -0
- package/docs/IntegrationEventLearner.md +2 -0
- package/docs/IntegrationEventUser.md +2 -0
- package/docs/PortalApi.md +78 -0
- package/docs/PostCourse.md +2 -0
- package/docs/PostPortalInvite.md +2 -0
- package/docs/PostResource.md +2 -0
- package/docs/PostRichTextAssetUpload.md +2 -0
- package/docs/PostZapierEnrollment.md +4 -0
- package/docs/PostZapierShopifyCourseMapping.md +2 -0
- package/docs/PostZapierUser.md +2 -0
- package/docs/PutCourse.md +2 -0
- package/docs/PutPortalUser.md +35 -0
- package/docs/PutResource.md +2 -0
- package/docs/RichTextAsset.md +2 -0
- package/docs/ZapierCourse.md +2 -0
- package/docs/ZapierEnrollment.md +4 -0
- package/docs/ZapierUser.md +2 -0
- package/package.json +1 -1
- package/src/apis/IntegrationApi.ts +15 -10
- package/src/apis/PortalApi.ts +81 -0
- package/src/models/GetCourse.ts +9 -0
- package/src/models/GetPortalUser.ts +9 -0
- package/src/models/GetResource.ts +9 -0
- package/src/models/IntegrationEventCourse.ts +8 -0
- package/src/models/IntegrationEventLearner.ts +8 -0
- package/src/models/IntegrationEventUser.ts +8 -0
- package/src/models/PostCourse.ts +8 -0
- package/src/models/PostPortalInvite.ts +8 -0
- package/src/models/PostResource.ts +8 -0
- package/src/models/PostRichTextAssetUpload.ts +8 -0
- package/src/models/PostZapierEnrollment.ts +22 -8
- package/src/models/PostZapierShopifyCourseMapping.ts +11 -4
- package/src/models/PostZapierUser.ts +8 -0
- package/src/models/PutCourse.ts +8 -0
- package/src/models/PutPortalUser.ts +65 -0
- package/src/models/PutResource.ts +8 -0
- package/src/models/RichTextAsset.ts +8 -0
- package/src/models/ZapierCourse.ts +9 -0
- package/src/models/ZapierEnrollment.ts +18 -0
- package/src/models/ZapierUser.ts +9 -0
- package/src/models/index.ts +1 -0
|
@@ -149,6 +149,7 @@ export interface GetZapierCoursesRequest {
|
|
|
149
149
|
page?: number;
|
|
150
150
|
pageSize?: number;
|
|
151
151
|
search?: string;
|
|
152
|
+
customerRef?: string;
|
|
152
153
|
}
|
|
153
154
|
|
|
154
155
|
export interface GetZapierEventsRequest {
|
|
@@ -172,7 +173,8 @@ export interface GetZapierShopifyCourseMappingsRequest {
|
|
|
172
173
|
export interface GetZapierUsersRequest {
|
|
173
174
|
xAPIKEY: string;
|
|
174
175
|
xPORTALSUBDOMAIN: string;
|
|
175
|
-
email
|
|
176
|
+
email?: string;
|
|
177
|
+
customerRef?: string;
|
|
176
178
|
}
|
|
177
179
|
|
|
178
180
|
export interface PostCustomWebhookIntegrationRequest {
|
|
@@ -451,6 +453,10 @@ export class IntegrationApi extends runtime.BaseAPI {
|
|
|
451
453
|
queryParameters['search'] = requestParameters['search'];
|
|
452
454
|
}
|
|
453
455
|
|
|
456
|
+
if (requestParameters['customerRef'] != null) {
|
|
457
|
+
queryParameters['customer_ref'] = requestParameters['customerRef'];
|
|
458
|
+
}
|
|
459
|
+
|
|
454
460
|
const headerParameters: runtime.HTTPHeaders = {};
|
|
455
461
|
|
|
456
462
|
if (requestParameters['xAPIKEY'] != null) {
|
|
@@ -741,19 +747,16 @@ export class IntegrationApi extends runtime.BaseAPI {
|
|
|
741
747
|
);
|
|
742
748
|
}
|
|
743
749
|
|
|
744
|
-
if (requestParameters['email'] == null) {
|
|
745
|
-
throw new runtime.RequiredError(
|
|
746
|
-
'email',
|
|
747
|
-
'Required parameter "email" was null or undefined when calling getZapierUsers().'
|
|
748
|
-
);
|
|
749
|
-
}
|
|
750
|
-
|
|
751
750
|
const queryParameters: any = {};
|
|
752
751
|
|
|
753
752
|
if (requestParameters['email'] != null) {
|
|
754
753
|
queryParameters['email'] = requestParameters['email'];
|
|
755
754
|
}
|
|
756
755
|
|
|
756
|
+
if (requestParameters['customerRef'] != null) {
|
|
757
|
+
queryParameters['customer_ref'] = requestParameters['customerRef'];
|
|
758
|
+
}
|
|
759
|
+
|
|
757
760
|
const headerParameters: runtime.HTTPHeaders = {};
|
|
758
761
|
|
|
759
762
|
if (requestParameters['xAPIKEY'] != null) {
|
|
@@ -776,7 +779,8 @@ export class IntegrationApi extends runtime.BaseAPI {
|
|
|
776
779
|
}
|
|
777
780
|
|
|
778
781
|
/**
|
|
779
|
-
*
|
|
782
|
+
* Send email, customer_ref, or both. When both are sent the learner must match both.
|
|
783
|
+
* Find a learner by exact email address or customer_ref
|
|
780
784
|
*/
|
|
781
785
|
async getZapierUsersRaw(requestParameters: GetZapierUsersRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<GetZapierUsers>> {
|
|
782
786
|
const requestOptions = await this.getZapierUsersRequestOpts(requestParameters);
|
|
@@ -786,7 +790,8 @@ export class IntegrationApi extends runtime.BaseAPI {
|
|
|
786
790
|
}
|
|
787
791
|
|
|
788
792
|
/**
|
|
789
|
-
*
|
|
793
|
+
* Send email, customer_ref, or both. When both are sent the learner must match both.
|
|
794
|
+
* Find a learner by exact email address or customer_ref
|
|
790
795
|
*/
|
|
791
796
|
async getZapierUsers(requestParameters: GetZapierUsersRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GetZapierUsers> {
|
|
792
797
|
const response = await this.getZapierUsersRaw(requestParameters, initOverrides);
|
package/src/apis/PortalApi.ts
CHANGED
|
@@ -33,6 +33,11 @@ import {
|
|
|
33
33
|
GetPortalLogoUploadFromJSON,
|
|
34
34
|
GetPortalLogoUploadToJSON,
|
|
35
35
|
} from '../models/GetPortalLogoUpload';
|
|
36
|
+
import {
|
|
37
|
+
type GetPortalUser,
|
|
38
|
+
GetPortalUserFromJSON,
|
|
39
|
+
GetPortalUserToJSON,
|
|
40
|
+
} from '../models/GetPortalUser';
|
|
36
41
|
import {
|
|
37
42
|
type GetPortalUserFieldValues,
|
|
38
43
|
GetPortalUserFieldValuesFromJSON,
|
|
@@ -68,6 +73,11 @@ import {
|
|
|
68
73
|
PutPortalBrandingFromJSON,
|
|
69
74
|
PutPortalBrandingToJSON,
|
|
70
75
|
} from '../models/PutPortalBranding';
|
|
76
|
+
import {
|
|
77
|
+
type PutPortalUser,
|
|
78
|
+
PutPortalUserFromJSON,
|
|
79
|
+
PutPortalUserToJSON,
|
|
80
|
+
} from '../models/PutPortalUser';
|
|
71
81
|
import {
|
|
72
82
|
type PutPortalUserFieldValues,
|
|
73
83
|
PutPortalUserFieldValuesFromJSON,
|
|
@@ -142,6 +152,12 @@ export interface PutPortalBrandingRequest {
|
|
|
142
152
|
putPortalBranding: PutPortalBranding;
|
|
143
153
|
}
|
|
144
154
|
|
|
155
|
+
export interface PutPortalUserRequest {
|
|
156
|
+
portalId: string;
|
|
157
|
+
userId: string;
|
|
158
|
+
putPortalUser: PutPortalUser;
|
|
159
|
+
}
|
|
160
|
+
|
|
145
161
|
export interface PutPortalUserFieldConfigRequest {
|
|
146
162
|
portalId: string;
|
|
147
163
|
portalUserFieldConfig: PortalUserFieldConfig;
|
|
@@ -1013,6 +1029,71 @@ export class PortalApi extends runtime.BaseAPI {
|
|
|
1013
1029
|
return await response.value();
|
|
1014
1030
|
}
|
|
1015
1031
|
|
|
1032
|
+
/**
|
|
1033
|
+
* Creates request options for putPortalUser without sending the request
|
|
1034
|
+
*/
|
|
1035
|
+
async putPortalUserRequestOpts(requestParameters: PutPortalUserRequest): Promise<runtime.RequestOpts> {
|
|
1036
|
+
if (requestParameters['portalId'] == null) {
|
|
1037
|
+
throw new runtime.RequiredError(
|
|
1038
|
+
'portalId',
|
|
1039
|
+
'Required parameter "portalId" was null or undefined when calling putPortalUser().'
|
|
1040
|
+
);
|
|
1041
|
+
}
|
|
1042
|
+
|
|
1043
|
+
if (requestParameters['userId'] == null) {
|
|
1044
|
+
throw new runtime.RequiredError(
|
|
1045
|
+
'userId',
|
|
1046
|
+
'Required parameter "userId" was null or undefined when calling putPortalUser().'
|
|
1047
|
+
);
|
|
1048
|
+
}
|
|
1049
|
+
|
|
1050
|
+
if (requestParameters['putPortalUser'] == null) {
|
|
1051
|
+
throw new runtime.RequiredError(
|
|
1052
|
+
'putPortalUser',
|
|
1053
|
+
'Required parameter "putPortalUser" was null or undefined when calling putPortalUser().'
|
|
1054
|
+
);
|
|
1055
|
+
}
|
|
1056
|
+
|
|
1057
|
+
const queryParameters: any = {};
|
|
1058
|
+
|
|
1059
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
1060
|
+
|
|
1061
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
1062
|
+
|
|
1063
|
+
|
|
1064
|
+
let urlPath = `/portals/{portalId}/users/{userId}`;
|
|
1065
|
+
urlPath = urlPath.replace('{portalId}', encodeURIComponent(String(requestParameters['portalId'])));
|
|
1066
|
+
urlPath = urlPath.replace('{userId}', encodeURIComponent(String(requestParameters['userId'])));
|
|
1067
|
+
|
|
1068
|
+
return {
|
|
1069
|
+
path: urlPath,
|
|
1070
|
+
method: 'PUT',
|
|
1071
|
+
headers: headerParameters,
|
|
1072
|
+
query: queryParameters,
|
|
1073
|
+
body: PutPortalUserToJSON(requestParameters['putPortalUser']),
|
|
1074
|
+
};
|
|
1075
|
+
}
|
|
1076
|
+
|
|
1077
|
+
/**
|
|
1078
|
+
* Sets or clears the member\'s customer_ref for this portal.
|
|
1079
|
+
* Update admin-managed details for a portal member
|
|
1080
|
+
*/
|
|
1081
|
+
async putPortalUserRaw(requestParameters: PutPortalUserRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<GetPortalUser>> {
|
|
1082
|
+
const requestOptions = await this.putPortalUserRequestOpts(requestParameters);
|
|
1083
|
+
const response = await this.request(requestOptions, initOverrides);
|
|
1084
|
+
|
|
1085
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => GetPortalUserFromJSON(jsonValue));
|
|
1086
|
+
}
|
|
1087
|
+
|
|
1088
|
+
/**
|
|
1089
|
+
* Sets or clears the member\'s customer_ref for this portal.
|
|
1090
|
+
* Update admin-managed details for a portal member
|
|
1091
|
+
*/
|
|
1092
|
+
async putPortalUser(requestParameters: PutPortalUserRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GetPortalUser> {
|
|
1093
|
+
const response = await this.putPortalUserRaw(requestParameters, initOverrides);
|
|
1094
|
+
return await response.value();
|
|
1095
|
+
}
|
|
1096
|
+
|
|
1016
1097
|
/**
|
|
1017
1098
|
* Creates request options for putPortalUserFieldConfig without sending the request
|
|
1018
1099
|
*/
|
package/src/models/GetCourse.ts
CHANGED
|
@@ -87,6 +87,12 @@ export interface GetCourse {
|
|
|
87
87
|
* @memberof GetCourse
|
|
88
88
|
*/
|
|
89
89
|
tags: Array<ContentLibraryTag>;
|
|
90
|
+
/**
|
|
91
|
+
* Your own identifier for this course, unique within the portal. Integrations such as Zapier can use it in place of id.
|
|
92
|
+
* @type {string}
|
|
93
|
+
* @memberof GetCourse
|
|
94
|
+
*/
|
|
95
|
+
customerRef: string | null;
|
|
90
96
|
}
|
|
91
97
|
|
|
92
98
|
|
|
@@ -115,6 +121,7 @@ export function instanceOfGetCourse(value: object): value is GetCourse {
|
|
|
115
121
|
if (!('accessDurationDays' in value) || value['accessDurationDays'] === undefined) return false;
|
|
116
122
|
if (!('accessFixedEndAt' in value) || value['accessFixedEndAt'] === undefined) return false;
|
|
117
123
|
if (!('tags' in value) || value['tags'] === undefined) return false;
|
|
124
|
+
if (!('customerRef' in value) || value['customerRef'] === undefined) return false;
|
|
118
125
|
return true;
|
|
119
126
|
}
|
|
120
127
|
|
|
@@ -138,6 +145,7 @@ export function GetCourseFromJSONTyped(json: any, ignoreDiscriminator: boolean):
|
|
|
138
145
|
'accessDurationDays': json['access_duration_days'],
|
|
139
146
|
'accessFixedEndAt': json['access_fixed_end_at'],
|
|
140
147
|
'tags': ((json['tags'] as Array<any>).map(ContentLibraryTagFromJSON)),
|
|
148
|
+
'customerRef': json['customer_ref'],
|
|
141
149
|
};
|
|
142
150
|
}
|
|
143
151
|
|
|
@@ -161,6 +169,7 @@ export function GetCourseToJSONTyped(value?: Omit<GetCourse, 'id'> | null, ignor
|
|
|
161
169
|
'access_duration_days': value['accessDurationDays'],
|
|
162
170
|
'access_fixed_end_at': value['accessFixedEndAt'],
|
|
163
171
|
'tags': ((value['tags'] as Array<any>).map(ContentLibraryTagToJSON)),
|
|
172
|
+
'customer_ref': value['customerRef'],
|
|
164
173
|
};
|
|
165
174
|
}
|
|
166
175
|
|
|
@@ -69,6 +69,12 @@ export interface GetPortalUser {
|
|
|
69
69
|
* @memberof GetPortalUser
|
|
70
70
|
*/
|
|
71
71
|
invitation?: GetPortalInvitationSummary | null;
|
|
72
|
+
/**
|
|
73
|
+
* Your own identifier for this user in this portal, unique within the portal. Integrations such as Zapier can use it in place of the user id.
|
|
74
|
+
* @type {string}
|
|
75
|
+
* @memberof GetPortalUser
|
|
76
|
+
*/
|
|
77
|
+
customerRef: string | null;
|
|
72
78
|
}
|
|
73
79
|
|
|
74
80
|
/**
|
|
@@ -81,6 +87,7 @@ export function instanceOfGetPortalUser(value: object): value is GetPortalUser {
|
|
|
81
87
|
if (!('lastName' in value) || value['lastName'] === undefined) return false;
|
|
82
88
|
if (!('role' in value) || value['role'] === undefined) return false;
|
|
83
89
|
if (!('isActive' in value) || value['isActive'] === undefined) return false;
|
|
90
|
+
if (!('customerRef' in value) || value['customerRef'] === undefined) return false;
|
|
84
91
|
return true;
|
|
85
92
|
}
|
|
86
93
|
|
|
@@ -101,6 +108,7 @@ export function GetPortalUserFromJSONTyped(json: any, ignoreDiscriminator: boole
|
|
|
101
108
|
'role': json['role'],
|
|
102
109
|
'isActive': json['is_active'],
|
|
103
110
|
'invitation': json['invitation'] == null ? undefined : GetPortalInvitationSummaryFromJSON(json['invitation']),
|
|
111
|
+
'customerRef': json['customer_ref'],
|
|
104
112
|
};
|
|
105
113
|
}
|
|
106
114
|
|
|
@@ -122,6 +130,7 @@ export function GetPortalUserToJSONTyped(value?: GetPortalUser | null, ignoreDis
|
|
|
122
130
|
'role': value['role'],
|
|
123
131
|
'is_active': value['isActive'],
|
|
124
132
|
'invitation': GetPortalInvitationSummaryToJSON(value['invitation']),
|
|
133
|
+
'customer_ref': value['customerRef'],
|
|
125
134
|
};
|
|
126
135
|
}
|
|
127
136
|
|
|
@@ -137,6 +137,12 @@ export interface GetResource {
|
|
|
137
137
|
* @memberof GetResource
|
|
138
138
|
*/
|
|
139
139
|
archivedAt?: number | null;
|
|
140
|
+
/**
|
|
141
|
+
* Your own identifier for this resource, unique within the portal. Integrations can use it in place of id.
|
|
142
|
+
* @type {string}
|
|
143
|
+
* @memberof GetResource
|
|
144
|
+
*/
|
|
145
|
+
customerRef: string | null;
|
|
140
146
|
}
|
|
141
147
|
|
|
142
148
|
|
|
@@ -158,6 +164,7 @@ export function instanceOfGetResource(value: object): value is GetResource {
|
|
|
158
164
|
if (!('activeLearnerCount' in value) || value['activeLearnerCount'] === undefined) return false;
|
|
159
165
|
if (!('createdAt' in value) || value['createdAt'] === undefined) return false;
|
|
160
166
|
if (!('updatedAt' in value) || value['updatedAt'] === undefined) return false;
|
|
167
|
+
if (!('customerRef' in value) || value['customerRef'] === undefined) return false;
|
|
161
168
|
return true;
|
|
162
169
|
}
|
|
163
170
|
|
|
@@ -187,6 +194,7 @@ export function GetResourceFromJSONTyped(json: any, ignoreDiscriminator: boolean
|
|
|
187
194
|
'createdAt': json['created_at'],
|
|
188
195
|
'updatedAt': json['updated_at'],
|
|
189
196
|
'archivedAt': json['archived_at'] == null ? undefined : json['archived_at'],
|
|
197
|
+
'customerRef': json['customer_ref'],
|
|
190
198
|
};
|
|
191
199
|
}
|
|
192
200
|
|
|
@@ -217,6 +225,7 @@ export function GetResourceToJSONTyped(value?: GetResource | null, ignoreDiscrim
|
|
|
217
225
|
'created_at': value['createdAt'],
|
|
218
226
|
'updated_at': value['updatedAt'],
|
|
219
227
|
'archived_at': value['archivedAt'],
|
|
228
|
+
'customer_ref': value['customerRef'],
|
|
220
229
|
};
|
|
221
230
|
}
|
|
222
231
|
|
|
@@ -31,6 +31,12 @@ export interface IntegrationEventCourse {
|
|
|
31
31
|
* @memberof IntegrationEventCourse
|
|
32
32
|
*/
|
|
33
33
|
name: string;
|
|
34
|
+
/**
|
|
35
|
+
* Your identifier for this course, if set.
|
|
36
|
+
* @type {string}
|
|
37
|
+
* @memberof IntegrationEventCourse
|
|
38
|
+
*/
|
|
39
|
+
customerRef?: string | null;
|
|
34
40
|
}
|
|
35
41
|
|
|
36
42
|
/**
|
|
@@ -54,6 +60,7 @@ export function IntegrationEventCourseFromJSONTyped(json: any, ignoreDiscriminat
|
|
|
54
60
|
|
|
55
61
|
'id': json['id'],
|
|
56
62
|
'name': json['name'],
|
|
63
|
+
'customerRef': json['customer_ref'] == null ? undefined : json['customer_ref'],
|
|
57
64
|
};
|
|
58
65
|
}
|
|
59
66
|
|
|
@@ -70,6 +77,7 @@ export function IntegrationEventCourseToJSONTyped(value?: IntegrationEventCourse
|
|
|
70
77
|
|
|
71
78
|
'id': value['id'],
|
|
72
79
|
'name': value['name'],
|
|
80
|
+
'customer_ref': value['customerRef'],
|
|
73
81
|
};
|
|
74
82
|
}
|
|
75
83
|
|
|
@@ -43,6 +43,12 @@ export interface IntegrationEventLearner {
|
|
|
43
43
|
* @memberof IntegrationEventLearner
|
|
44
44
|
*/
|
|
45
45
|
lastName: string;
|
|
46
|
+
/**
|
|
47
|
+
* Your identifier for this learner in the event portal, if set.
|
|
48
|
+
* @type {string}
|
|
49
|
+
* @memberof IntegrationEventLearner
|
|
50
|
+
*/
|
|
51
|
+
customerRef?: string | null;
|
|
46
52
|
}
|
|
47
53
|
|
|
48
54
|
/**
|
|
@@ -70,6 +76,7 @@ export function IntegrationEventLearnerFromJSONTyped(json: any, ignoreDiscrimina
|
|
|
70
76
|
'email': json['email'],
|
|
71
77
|
'firstName': json['first_name'],
|
|
72
78
|
'lastName': json['last_name'],
|
|
79
|
+
'customerRef': json['customer_ref'] == null ? undefined : json['customer_ref'],
|
|
73
80
|
};
|
|
74
81
|
}
|
|
75
82
|
|
|
@@ -88,6 +95,7 @@ export function IntegrationEventLearnerToJSONTyped(value?: IntegrationEventLearn
|
|
|
88
95
|
'email': value['email'],
|
|
89
96
|
'first_name': value['firstName'],
|
|
90
97
|
'last_name': value['lastName'],
|
|
98
|
+
'customer_ref': value['customerRef'],
|
|
91
99
|
};
|
|
92
100
|
}
|
|
93
101
|
|
|
@@ -43,6 +43,12 @@ export interface IntegrationEventUser {
|
|
|
43
43
|
* @memberof IntegrationEventUser
|
|
44
44
|
*/
|
|
45
45
|
lastName: string;
|
|
46
|
+
/**
|
|
47
|
+
* Your identifier for this user in the event portal, if set.
|
|
48
|
+
* @type {string}
|
|
49
|
+
* @memberof IntegrationEventUser
|
|
50
|
+
*/
|
|
51
|
+
customerRef?: string | null;
|
|
46
52
|
}
|
|
47
53
|
|
|
48
54
|
/**
|
|
@@ -70,6 +76,7 @@ export function IntegrationEventUserFromJSONTyped(json: any, ignoreDiscriminator
|
|
|
70
76
|
'email': json['email'],
|
|
71
77
|
'firstName': json['first_name'],
|
|
72
78
|
'lastName': json['last_name'],
|
|
79
|
+
'customerRef': json['customer_ref'] == null ? undefined : json['customer_ref'],
|
|
73
80
|
};
|
|
74
81
|
}
|
|
75
82
|
|
|
@@ -88,6 +95,7 @@ export function IntegrationEventUserToJSONTyped(value?: IntegrationEventUser | n
|
|
|
88
95
|
'email': value['email'],
|
|
89
96
|
'first_name': value['firstName'],
|
|
90
97
|
'last_name': value['lastName'],
|
|
98
|
+
'customer_ref': value['customerRef'],
|
|
91
99
|
};
|
|
92
100
|
}
|
|
93
101
|
|
package/src/models/PostCourse.ts
CHANGED
|
@@ -57,6 +57,12 @@ export interface PostCourse {
|
|
|
57
57
|
* @memberof PostCourse
|
|
58
58
|
*/
|
|
59
59
|
tags?: Set<string>;
|
|
60
|
+
/**
|
|
61
|
+
* Your own identifier for this course, unique within the portal. Integrations such as Zapier can use it in place of id.
|
|
62
|
+
* @type {string}
|
|
63
|
+
* @memberof PostCourse
|
|
64
|
+
*/
|
|
65
|
+
customerRef?: string | null;
|
|
60
66
|
}
|
|
61
67
|
|
|
62
68
|
|
|
@@ -96,6 +102,7 @@ export function PostCourseFromJSONTyped(json: any, ignoreDiscriminator: boolean)
|
|
|
96
102
|
'accessDurationDays': json['access_duration_days'] == null ? undefined : json['access_duration_days'],
|
|
97
103
|
'accessFixedEndAt': json['access_fixed_end_at'] == null ? undefined : json['access_fixed_end_at'],
|
|
98
104
|
'tags': json['tags'] == null ? undefined : new Set(json['tags']),
|
|
105
|
+
'customerRef': json['customer_ref'] == null ? undefined : json['customer_ref'],
|
|
99
106
|
};
|
|
100
107
|
}
|
|
101
108
|
|
|
@@ -116,6 +123,7 @@ export function PostCourseToJSONTyped(value?: PostCourse | null, ignoreDiscrimin
|
|
|
116
123
|
'access_duration_days': value['accessDurationDays'],
|
|
117
124
|
'access_fixed_end_at': value['accessFixedEndAt'],
|
|
118
125
|
'tags': value['tags'] == null ? undefined : Array.from(value['tags'] as Set<any>),
|
|
126
|
+
'customer_ref': value['customerRef'],
|
|
119
127
|
};
|
|
120
128
|
}
|
|
121
129
|
|
|
@@ -43,6 +43,12 @@ export interface PostPortalInvite {
|
|
|
43
43
|
* @memberof PostPortalInvite
|
|
44
44
|
*/
|
|
45
45
|
userType: PostPortalInviteUserTypeEnum;
|
|
46
|
+
/**
|
|
47
|
+
* Your own identifier for this user in this portal, unique within the portal. Integrations such as Zapier can use it in place of the user id.
|
|
48
|
+
* @type {string}
|
|
49
|
+
* @memberof PostPortalInvite
|
|
50
|
+
*/
|
|
51
|
+
customerRef?: string | null;
|
|
46
52
|
}
|
|
47
53
|
|
|
48
54
|
|
|
@@ -86,6 +92,7 @@ export function PostPortalInviteFromJSONTyped(json: any, ignoreDiscriminator: bo
|
|
|
86
92
|
'firstName': json['first_name'],
|
|
87
93
|
'lastName': json['last_name'],
|
|
88
94
|
'userType': json['user_type'],
|
|
95
|
+
'customerRef': json['customer_ref'] == null ? undefined : json['customer_ref'],
|
|
89
96
|
};
|
|
90
97
|
}
|
|
91
98
|
|
|
@@ -104,6 +111,7 @@ export function PostPortalInviteToJSONTyped(value?: PostPortalInvite | null, ign
|
|
|
104
111
|
'first_name': value['firstName'],
|
|
105
112
|
'last_name': value['lastName'],
|
|
106
113
|
'user_type': value['userType'],
|
|
114
|
+
'customer_ref': value['customerRef'],
|
|
107
115
|
};
|
|
108
116
|
}
|
|
109
117
|
|
|
@@ -70,6 +70,12 @@ export interface PostResource {
|
|
|
70
70
|
* @memberof PostResource
|
|
71
71
|
*/
|
|
72
72
|
tags?: Set<string>;
|
|
73
|
+
/**
|
|
74
|
+
* Your own identifier for this resource, unique within the portal. Integrations can use it in place of id.
|
|
75
|
+
* @type {string}
|
|
76
|
+
* @memberof PostResource
|
|
77
|
+
*/
|
|
78
|
+
customerRef?: string | null;
|
|
73
79
|
}
|
|
74
80
|
|
|
75
81
|
|
|
@@ -99,6 +105,7 @@ export function PostResourceFromJSONTyped(json: any, ignoreDiscriminator: boolea
|
|
|
99
105
|
'linkUrl': json['link_url'] == null ? undefined : json['link_url'],
|
|
100
106
|
'richText': json['rich_text'] == null ? undefined : RichTextInputFromJSON(json['rich_text']),
|
|
101
107
|
'tags': json['tags'] == null ? undefined : new Set(json['tags']),
|
|
108
|
+
'customerRef': json['customer_ref'] == null ? undefined : json['customer_ref'],
|
|
102
109
|
};
|
|
103
110
|
}
|
|
104
111
|
|
|
@@ -119,6 +126,7 @@ export function PostResourceToJSONTyped(value?: PostResource | null, ignoreDiscr
|
|
|
119
126
|
'link_url': value['linkUrl'],
|
|
120
127
|
'rich_text': RichTextInputToJSON(value['richText']),
|
|
121
128
|
'tags': value['tags'] == null ? undefined : Array.from(value['tags'] as Set<any>),
|
|
129
|
+
'customer_ref': value['customerRef'],
|
|
122
130
|
};
|
|
123
131
|
}
|
|
124
132
|
|
|
@@ -55,6 +55,12 @@ export interface PostRichTextAssetUpload {
|
|
|
55
55
|
* @memberof PostRichTextAssetUpload
|
|
56
56
|
*/
|
|
57
57
|
usageContext: PostRichTextAssetUploadUsageContextEnum;
|
|
58
|
+
/**
|
|
59
|
+
* Your own identifier for this asset, unique within the portal.
|
|
60
|
+
* @type {string}
|
|
61
|
+
* @memberof PostRichTextAssetUpload
|
|
62
|
+
*/
|
|
63
|
+
customerRef?: string | null;
|
|
58
64
|
}
|
|
59
65
|
|
|
60
66
|
|
|
@@ -94,6 +100,7 @@ export function PostRichTextAssetUploadFromJSONTyped(json: any, ignoreDiscrimina
|
|
|
94
100
|
'width': json['width'] == null ? undefined : json['width'],
|
|
95
101
|
'height': json['height'] == null ? undefined : json['height'],
|
|
96
102
|
'usageContext': json['usage_context'],
|
|
103
|
+
'customerRef': json['customer_ref'] == null ? undefined : json['customer_ref'],
|
|
97
104
|
};
|
|
98
105
|
}
|
|
99
106
|
|
|
@@ -114,6 +121,7 @@ export function PostRichTextAssetUploadToJSONTyped(value?: PostRichTextAssetUplo
|
|
|
114
121
|
'width': value['width'],
|
|
115
122
|
'height': value['height'],
|
|
116
123
|
'usage_context': value['usageContext'],
|
|
124
|
+
'customer_ref': value['customerRef'],
|
|
117
125
|
};
|
|
118
126
|
}
|
|
119
127
|
|
|
@@ -20,17 +20,17 @@ import { mapValues } from '../runtime';
|
|
|
20
20
|
*/
|
|
21
21
|
export interface PostZapierEnrollment {
|
|
22
22
|
/**
|
|
23
|
-
*
|
|
23
|
+
* Course id. Send this or course_customer_ref.
|
|
24
24
|
* @type {string}
|
|
25
25
|
* @memberof PostZapierEnrollment
|
|
26
26
|
*/
|
|
27
|
-
courseId
|
|
27
|
+
courseId?: string;
|
|
28
28
|
/**
|
|
29
|
-
*
|
|
29
|
+
* User id. Send this or user_customer_ref.
|
|
30
30
|
* @type {string}
|
|
31
31
|
* @memberof PostZapierEnrollment
|
|
32
32
|
*/
|
|
33
|
-
userId
|
|
33
|
+
userId?: string;
|
|
34
34
|
/**
|
|
35
35
|
* Stable source event ID used to make retries safe.
|
|
36
36
|
* @type {string}
|
|
@@ -61,6 +61,18 @@ export interface PostZapierEnrollment {
|
|
|
61
61
|
* @memberof PostZapierEnrollment
|
|
62
62
|
*/
|
|
63
63
|
reEnrollmentMode?: PostZapierEnrollmentReEnrollmentModeEnum;
|
|
64
|
+
/**
|
|
65
|
+
* Your identifier for the course. Send this or course_id.
|
|
66
|
+
* @type {string}
|
|
67
|
+
* @memberof PostZapierEnrollment
|
|
68
|
+
*/
|
|
69
|
+
courseCustomerRef?: string | null;
|
|
70
|
+
/**
|
|
71
|
+
* Your identifier for the learner. Send this or user_id.
|
|
72
|
+
* @type {string}
|
|
73
|
+
* @memberof PostZapierEnrollment
|
|
74
|
+
*/
|
|
75
|
+
userCustomerRef?: string | null;
|
|
64
76
|
}
|
|
65
77
|
|
|
66
78
|
|
|
@@ -78,8 +90,6 @@ export type PostZapierEnrollmentReEnrollmentModeEnum = typeof PostZapierEnrollme
|
|
|
78
90
|
* Check if a given object implements the PostZapierEnrollment interface.
|
|
79
91
|
*/
|
|
80
92
|
export function instanceOfPostZapierEnrollment(value: object): value is PostZapierEnrollment {
|
|
81
|
-
if (!('courseId' in value) || value['courseId'] === undefined) return false;
|
|
82
|
-
if (!('userId' in value) || value['userId'] === undefined) return false;
|
|
83
93
|
return true;
|
|
84
94
|
}
|
|
85
95
|
|
|
@@ -93,13 +103,15 @@ export function PostZapierEnrollmentFromJSONTyped(json: any, ignoreDiscriminator
|
|
|
93
103
|
}
|
|
94
104
|
return {
|
|
95
105
|
|
|
96
|
-
'courseId': json['course_id'],
|
|
97
|
-
'userId': json['user_id'],
|
|
106
|
+
'courseId': json['course_id'] == null ? undefined : json['course_id'],
|
|
107
|
+
'userId': json['user_id'] == null ? undefined : json['user_id'],
|
|
98
108
|
'idempotencyKey': json['idempotency_key'] == null ? undefined : json['idempotency_key'],
|
|
99
109
|
'enrollmentDateStart': json['enrollment_date_start'] == null ? undefined : json['enrollment_date_start'],
|
|
100
110
|
'enrollmentDateEnd': json['enrollment_date_end'] == null ? undefined : json['enrollment_date_end'],
|
|
101
111
|
'notes': json['notes'] == null ? undefined : json['notes'],
|
|
102
112
|
'reEnrollmentMode': json['re_enrollment_mode'] == null ? undefined : json['re_enrollment_mode'],
|
|
113
|
+
'courseCustomerRef': json['course_customer_ref'] == null ? undefined : json['course_customer_ref'],
|
|
114
|
+
'userCustomerRef': json['user_customer_ref'] == null ? undefined : json['user_customer_ref'],
|
|
103
115
|
};
|
|
104
116
|
}
|
|
105
117
|
|
|
@@ -121,6 +133,8 @@ export function PostZapierEnrollmentToJSONTyped(value?: PostZapierEnrollment | n
|
|
|
121
133
|
'enrollment_date_end': value['enrollmentDateEnd'],
|
|
122
134
|
'notes': value['notes'],
|
|
123
135
|
're_enrollment_mode': value['reEnrollmentMode'],
|
|
136
|
+
'course_customer_ref': value['courseCustomerRef'],
|
|
137
|
+
'user_customer_ref': value['userCustomerRef'],
|
|
124
138
|
};
|
|
125
139
|
}
|
|
126
140
|
|
|
@@ -38,11 +38,17 @@ export interface PostZapierShopifyCourseMapping {
|
|
|
38
38
|
*/
|
|
39
39
|
productId?: string | null;
|
|
40
40
|
/**
|
|
41
|
-
* Stable external Edaxu course ID.
|
|
41
|
+
* Stable external Edaxu course ID. Send this or course_customer_ref.
|
|
42
42
|
* @type {string}
|
|
43
43
|
* @memberof PostZapierShopifyCourseMapping
|
|
44
44
|
*/
|
|
45
|
-
courseId
|
|
45
|
+
courseId?: string;
|
|
46
|
+
/**
|
|
47
|
+
* Your identifier for the course. Send this or course_id.
|
|
48
|
+
* @type {string}
|
|
49
|
+
* @memberof PostZapierShopifyCourseMapping
|
|
50
|
+
*/
|
|
51
|
+
courseCustomerRef?: string | null;
|
|
46
52
|
}
|
|
47
53
|
|
|
48
54
|
/**
|
|
@@ -51,7 +57,6 @@ export interface PostZapierShopifyCourseMapping {
|
|
|
51
57
|
export function instanceOfPostZapierShopifyCourseMapping(value: object): value is PostZapierShopifyCourseMapping {
|
|
52
58
|
if (!('shopDomain' in value) || value['shopDomain'] === undefined) return false;
|
|
53
59
|
if (!('variantId' in value) || value['variantId'] === undefined) return false;
|
|
54
|
-
if (!('courseId' in value) || value['courseId'] === undefined) return false;
|
|
55
60
|
return true;
|
|
56
61
|
}
|
|
57
62
|
|
|
@@ -68,7 +73,8 @@ export function PostZapierShopifyCourseMappingFromJSONTyped(json: any, ignoreDis
|
|
|
68
73
|
'shopDomain': json['shop_domain'],
|
|
69
74
|
'variantId': json['variant_id'],
|
|
70
75
|
'productId': json['product_id'] == null ? undefined : json['product_id'],
|
|
71
|
-
'courseId': json['course_id'],
|
|
76
|
+
'courseId': json['course_id'] == null ? undefined : json['course_id'],
|
|
77
|
+
'courseCustomerRef': json['course_customer_ref'] == null ? undefined : json['course_customer_ref'],
|
|
72
78
|
};
|
|
73
79
|
}
|
|
74
80
|
|
|
@@ -87,6 +93,7 @@ export function PostZapierShopifyCourseMappingToJSONTyped(value?: PostZapierShop
|
|
|
87
93
|
'variant_id': value['variantId'],
|
|
88
94
|
'product_id': value['productId'],
|
|
89
95
|
'course_id': value['courseId'],
|
|
96
|
+
'course_customer_ref': value['courseCustomerRef'],
|
|
90
97
|
};
|
|
91
98
|
}
|
|
92
99
|
|
|
@@ -37,6 +37,12 @@ export interface PostZapierUser {
|
|
|
37
37
|
* @memberof PostZapierUser
|
|
38
38
|
*/
|
|
39
39
|
lastName: string;
|
|
40
|
+
/**
|
|
41
|
+
* Your identifier for this learner. If a learner in this portal already has it, that learner is returned. Otherwise it is assigned to the matched or invited learner.
|
|
42
|
+
* @type {string}
|
|
43
|
+
* @memberof PostZapierUser
|
|
44
|
+
*/
|
|
45
|
+
customerRef?: string | null;
|
|
40
46
|
}
|
|
41
47
|
|
|
42
48
|
/**
|
|
@@ -62,6 +68,7 @@ export function PostZapierUserFromJSONTyped(json: any, ignoreDiscriminator: bool
|
|
|
62
68
|
'email': json['email'],
|
|
63
69
|
'firstName': json['first_name'],
|
|
64
70
|
'lastName': json['last_name'],
|
|
71
|
+
'customerRef': json['customer_ref'] == null ? undefined : json['customer_ref'],
|
|
65
72
|
};
|
|
66
73
|
}
|
|
67
74
|
|
|
@@ -79,6 +86,7 @@ export function PostZapierUserToJSONTyped(value?: PostZapierUser | null, ignoreD
|
|
|
79
86
|
'email': value['email'],
|
|
80
87
|
'first_name': value['firstName'],
|
|
81
88
|
'last_name': value['lastName'],
|
|
89
|
+
'customer_ref': value['customerRef'],
|
|
82
90
|
};
|
|
83
91
|
}
|
|
84
92
|
|
package/src/models/PutCourse.ts
CHANGED
|
@@ -67,6 +67,12 @@ export interface PutCourse {
|
|
|
67
67
|
* @memberof PutCourse
|
|
68
68
|
*/
|
|
69
69
|
tags?: Set<string>;
|
|
70
|
+
/**
|
|
71
|
+
* Your own identifier, unique within the portal. Omit to leave unchanged, send null to clear.
|
|
72
|
+
* @type {string}
|
|
73
|
+
* @memberof PutCourse
|
|
74
|
+
*/
|
|
75
|
+
customerRef?: string | null;
|
|
70
76
|
}
|
|
71
77
|
|
|
72
78
|
|
|
@@ -106,6 +112,7 @@ export function PutCourseFromJSONTyped(json: any, ignoreDiscriminator: boolean):
|
|
|
106
112
|
'accessDurationDays': json['access_duration_days'] == null ? undefined : json['access_duration_days'],
|
|
107
113
|
'accessFixedEndAt': json['access_fixed_end_at'] == null ? undefined : json['access_fixed_end_at'],
|
|
108
114
|
'tags': json['tags'] == null ? undefined : new Set(json['tags']),
|
|
115
|
+
'customerRef': json['customer_ref'] == null ? undefined : json['customer_ref'],
|
|
109
116
|
};
|
|
110
117
|
}
|
|
111
118
|
|
|
@@ -127,6 +134,7 @@ export function PutCourseToJSONTyped(value?: Omit<PutCourse, 'id'> | null, ignor
|
|
|
127
134
|
'access_duration_days': value['accessDurationDays'],
|
|
128
135
|
'access_fixed_end_at': value['accessFixedEndAt'],
|
|
129
136
|
'tags': value['tags'] == null ? undefined : Array.from(value['tags'] as Set<any>),
|
|
137
|
+
'customer_ref': value['customerRef'],
|
|
130
138
|
};
|
|
131
139
|
}
|
|
132
140
|
|