@easyedu/js-lsm-api 1.115.0 → 1.116.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 +24 -0
- package/README.md +21 -2
- package/dist/apis/IntegrationApi.d.ts +132 -0
- package/dist/apis/IntegrationApi.js +378 -0
- package/dist/esm/apis/IntegrationApi.d.ts +132 -0
- package/dist/esm/apis/IntegrationApi.js +378 -0
- package/dist/esm/models/GetZapierCourses.d.ts +51 -0
- package/dist/esm/models/GetZapierCourses.js +56 -0
- package/dist/esm/models/GetZapierShopifyCourseMappings.d.ts +33 -0
- package/dist/esm/models/GetZapierShopifyCourseMappings.js +44 -0
- package/dist/esm/models/GetZapierUsers.d.ts +33 -0
- package/dist/esm/models/GetZapierUsers.js +44 -0
- package/dist/esm/models/PostZapierEnrollment.d.ts +76 -0
- package/dist/esm/models/PostZapierEnrollment.js +64 -0
- package/dist/esm/models/PostZapierShopifyCourseMapping.d.ts +50 -0
- package/dist/esm/models/PostZapierShopifyCourseMapping.js +53 -0
- package/dist/esm/models/PostZapierShopifyEnrollment.d.ts +100 -0
- package/dist/esm/models/PostZapierShopifyEnrollment.js +82 -0
- package/dist/esm/models/PostZapierShopifyEnrollmentResponse.d.ts +47 -0
- package/dist/esm/models/PostZapierShopifyEnrollmentResponse.js +54 -0
- package/dist/esm/models/PostZapierUser.d.ts +44 -0
- package/dist/esm/models/PostZapierUser.js +51 -0
- package/dist/esm/models/ZapierCourse.d.ts +50 -0
- package/dist/esm/models/ZapierCourse.js +55 -0
- package/dist/esm/models/ZapierEnrollment.d.ts +74 -0
- package/dist/esm/models/ZapierEnrollment.js +69 -0
- package/dist/esm/models/ZapierShopifyCourseMapping.d.ts +69 -0
- package/dist/esm/models/ZapierShopifyCourseMapping.js +66 -0
- package/dist/esm/models/ZapierUser.d.ts +56 -0
- package/dist/esm/models/ZapierUser.js +59 -0
- package/dist/esm/models/index.d.ts +12 -0
- package/dist/esm/models/index.js +12 -0
- package/dist/models/GetZapierCourses.d.ts +51 -0
- package/dist/models/GetZapierCourses.js +63 -0
- package/dist/models/GetZapierShopifyCourseMappings.d.ts +33 -0
- package/dist/models/GetZapierShopifyCourseMappings.js +51 -0
- package/dist/models/GetZapierUsers.d.ts +33 -0
- package/dist/models/GetZapierUsers.js +51 -0
- package/dist/models/PostZapierEnrollment.d.ts +76 -0
- package/dist/models/PostZapierEnrollment.js +72 -0
- package/dist/models/PostZapierShopifyCourseMapping.d.ts +50 -0
- package/dist/models/PostZapierShopifyCourseMapping.js +60 -0
- package/dist/models/PostZapierShopifyEnrollment.d.ts +100 -0
- package/dist/models/PostZapierShopifyEnrollment.js +90 -0
- package/dist/models/PostZapierShopifyEnrollmentResponse.d.ts +47 -0
- package/dist/models/PostZapierShopifyEnrollmentResponse.js +61 -0
- package/dist/models/PostZapierUser.d.ts +44 -0
- package/dist/models/PostZapierUser.js +58 -0
- package/dist/models/ZapierCourse.d.ts +50 -0
- package/dist/models/ZapierCourse.js +62 -0
- package/dist/models/ZapierEnrollment.d.ts +74 -0
- package/dist/models/ZapierEnrollment.js +76 -0
- package/dist/models/ZapierShopifyCourseMapping.d.ts +69 -0
- package/dist/models/ZapierShopifyCourseMapping.js +73 -0
- package/dist/models/ZapierUser.d.ts +56 -0
- package/dist/models/ZapierUser.js +66 -0
- package/dist/models/index.d.ts +12 -0
- package/dist/models/index.js +12 -0
- package/docs/GetZapierCourses.md +40 -0
- package/docs/GetZapierShopifyCourseMappings.md +34 -0
- package/docs/GetZapierUsers.md +34 -0
- package/docs/IntegrationApi.md +536 -0
- package/docs/PostZapierEnrollment.md +46 -0
- package/docs/PostZapierShopifyCourseMapping.md +40 -0
- package/docs/PostZapierShopifyEnrollment.md +54 -0
- package/docs/PostZapierShopifyEnrollmentResponse.md +38 -0
- package/docs/PostZapierUser.md +38 -0
- package/docs/ZapierCourse.md +40 -0
- package/docs/ZapierEnrollment.md +48 -0
- package/docs/ZapierShopifyCourseMapping.md +46 -0
- package/docs/ZapierUser.md +42 -0
- package/package.json +1 -1
- package/src/apis/IntegrationApi.ts +579 -0
- package/src/models/GetZapierCourses.ts +101 -0
- package/src/models/GetZapierShopifyCourseMappings.ts +74 -0
- package/src/models/GetZapierUsers.ts +74 -0
- package/src/models/PostZapierEnrollment.ts +126 -0
- package/src/models/PostZapierShopifyCourseMapping.ts +92 -0
- package/src/models/PostZapierShopifyEnrollment.ts +163 -0
- package/src/models/PostZapierShopifyEnrollmentResponse.ts +106 -0
- package/src/models/PostZapierUser.ts +84 -0
- package/src/models/ZapierCourse.ts +93 -0
- package/src/models/ZapierEnrollment.ts +128 -0
- package/src/models/ZapierShopifyCourseMapping.ts +127 -0
- package/src/models/ZapierUser.ts +102 -0
- package/src/models/index.ts +12 -0
|
@@ -24,12 +24,23 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
24
24
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
25
25
|
exports.IntegrationApi = void 0;
|
|
26
26
|
const runtime = require("../runtime");
|
|
27
|
+
const GetZapierCourses_1 = require("../models/GetZapierCourses");
|
|
27
28
|
const GetZapierMe_1 = require("../models/GetZapierMe");
|
|
28
29
|
const GetZapierSetup_1 = require("../models/GetZapierSetup");
|
|
30
|
+
const GetZapierShopifyCourseMappings_1 = require("../models/GetZapierShopifyCourseMappings");
|
|
31
|
+
const GetZapierUsers_1 = require("../models/GetZapierUsers");
|
|
32
|
+
const PostZapierEnrollment_1 = require("../models/PostZapierEnrollment");
|
|
29
33
|
const PostZapierSetup_1 = require("../models/PostZapierSetup");
|
|
30
34
|
const PostZapierSetupResponse_1 = require("../models/PostZapierSetupResponse");
|
|
35
|
+
const PostZapierShopifyCourseMapping_1 = require("../models/PostZapierShopifyCourseMapping");
|
|
36
|
+
const PostZapierShopifyEnrollment_1 = require("../models/PostZapierShopifyEnrollment");
|
|
37
|
+
const PostZapierShopifyEnrollmentResponse_1 = require("../models/PostZapierShopifyEnrollmentResponse");
|
|
38
|
+
const PostZapierUser_1 = require("../models/PostZapierUser");
|
|
31
39
|
const PutZapierSetup_1 = require("../models/PutZapierSetup");
|
|
40
|
+
const ZapierEnrollment_1 = require("../models/ZapierEnrollment");
|
|
32
41
|
const ZapierIntegration_1 = require("../models/ZapierIntegration");
|
|
42
|
+
const ZapierShopifyCourseMapping_1 = require("../models/ZapierShopifyCourseMapping");
|
|
43
|
+
const ZapierUser_1 = require("../models/ZapierUser");
|
|
33
44
|
/**
|
|
34
45
|
*
|
|
35
46
|
*/
|
|
@@ -72,6 +83,62 @@ class IntegrationApi extends runtime.BaseAPI {
|
|
|
72
83
|
yield this.deleteZapierSetupRaw(requestParameters, initOverrides);
|
|
73
84
|
});
|
|
74
85
|
}
|
|
86
|
+
/**
|
|
87
|
+
* Creates request options for getZapierCourses without sending the request
|
|
88
|
+
*/
|
|
89
|
+
getZapierCoursesRequestOpts(requestParameters) {
|
|
90
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
91
|
+
if (requestParameters['xAPIKEY'] == null) {
|
|
92
|
+
throw new runtime.RequiredError('xAPIKEY', 'Required parameter "xAPIKEY" was null or undefined when calling getZapierCourses().');
|
|
93
|
+
}
|
|
94
|
+
if (requestParameters['xPORTALSUBDOMAIN'] == null) {
|
|
95
|
+
throw new runtime.RequiredError('xPORTALSUBDOMAIN', 'Required parameter "xPORTALSUBDOMAIN" was null or undefined when calling getZapierCourses().');
|
|
96
|
+
}
|
|
97
|
+
const queryParameters = {};
|
|
98
|
+
if (requestParameters['page'] != null) {
|
|
99
|
+
queryParameters['page'] = requestParameters['page'];
|
|
100
|
+
}
|
|
101
|
+
if (requestParameters['pageSize'] != null) {
|
|
102
|
+
queryParameters['pageSize'] = requestParameters['pageSize'];
|
|
103
|
+
}
|
|
104
|
+
if (requestParameters['search'] != null) {
|
|
105
|
+
queryParameters['search'] = requestParameters['search'];
|
|
106
|
+
}
|
|
107
|
+
const headerParameters = {};
|
|
108
|
+
if (requestParameters['xAPIKEY'] != null) {
|
|
109
|
+
headerParameters['X-API-KEY'] = String(requestParameters['xAPIKEY']);
|
|
110
|
+
}
|
|
111
|
+
if (requestParameters['xPORTALSUBDOMAIN'] != null) {
|
|
112
|
+
headerParameters['X-PORTAL-SUBDOMAIN'] = String(requestParameters['xPORTALSUBDOMAIN']);
|
|
113
|
+
}
|
|
114
|
+
let urlPath = `/integrations/zapier/courses`;
|
|
115
|
+
return {
|
|
116
|
+
path: urlPath,
|
|
117
|
+
method: 'GET',
|
|
118
|
+
headers: headerParameters,
|
|
119
|
+
query: queryParameters,
|
|
120
|
+
};
|
|
121
|
+
});
|
|
122
|
+
}
|
|
123
|
+
/**
|
|
124
|
+
* List published courses available to a Zapier connection
|
|
125
|
+
*/
|
|
126
|
+
getZapierCoursesRaw(requestParameters, initOverrides) {
|
|
127
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
128
|
+
const requestOptions = yield this.getZapierCoursesRequestOpts(requestParameters);
|
|
129
|
+
const response = yield this.request(requestOptions, initOverrides);
|
|
130
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => (0, GetZapierCourses_1.GetZapierCoursesFromJSON)(jsonValue));
|
|
131
|
+
});
|
|
132
|
+
}
|
|
133
|
+
/**
|
|
134
|
+
* List published courses available to a Zapier connection
|
|
135
|
+
*/
|
|
136
|
+
getZapierCourses(requestParameters, initOverrides) {
|
|
137
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
138
|
+
const response = yield this.getZapierCoursesRaw(requestParameters, initOverrides);
|
|
139
|
+
return yield response.value();
|
|
140
|
+
});
|
|
141
|
+
}
|
|
75
142
|
/**
|
|
76
143
|
* Creates request options for getZapierMe without sending the request
|
|
77
144
|
*/
|
|
@@ -154,6 +221,161 @@ class IntegrationApi extends runtime.BaseAPI {
|
|
|
154
221
|
return yield response.value();
|
|
155
222
|
});
|
|
156
223
|
}
|
|
224
|
+
/**
|
|
225
|
+
* Creates request options for getZapierShopifyCourseMappings without sending the request
|
|
226
|
+
*/
|
|
227
|
+
getZapierShopifyCourseMappingsRequestOpts(requestParameters) {
|
|
228
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
229
|
+
if (requestParameters['xAPIKEY'] == null) {
|
|
230
|
+
throw new runtime.RequiredError('xAPIKEY', 'Required parameter "xAPIKEY" was null or undefined when calling getZapierShopifyCourseMappings().');
|
|
231
|
+
}
|
|
232
|
+
if (requestParameters['xPORTALSUBDOMAIN'] == null) {
|
|
233
|
+
throw new runtime.RequiredError('xPORTALSUBDOMAIN', 'Required parameter "xPORTALSUBDOMAIN" was null or undefined when calling getZapierShopifyCourseMappings().');
|
|
234
|
+
}
|
|
235
|
+
const queryParameters = {};
|
|
236
|
+
if (requestParameters['shopDomain'] != null) {
|
|
237
|
+
queryParameters['shopDomain'] = requestParameters['shopDomain'];
|
|
238
|
+
}
|
|
239
|
+
const headerParameters = {};
|
|
240
|
+
if (requestParameters['xAPIKEY'] != null) {
|
|
241
|
+
headerParameters['X-API-KEY'] = String(requestParameters['xAPIKEY']);
|
|
242
|
+
}
|
|
243
|
+
if (requestParameters['xPORTALSUBDOMAIN'] != null) {
|
|
244
|
+
headerParameters['X-PORTAL-SUBDOMAIN'] = String(requestParameters['xPORTALSUBDOMAIN']);
|
|
245
|
+
}
|
|
246
|
+
let urlPath = `/integrations/zapier/shopify/course-mappings`;
|
|
247
|
+
return {
|
|
248
|
+
path: urlPath,
|
|
249
|
+
method: 'GET',
|
|
250
|
+
headers: headerParameters,
|
|
251
|
+
query: queryParameters,
|
|
252
|
+
};
|
|
253
|
+
});
|
|
254
|
+
}
|
|
255
|
+
/**
|
|
256
|
+
* List Shopify variant-to-course mappings
|
|
257
|
+
*/
|
|
258
|
+
getZapierShopifyCourseMappingsRaw(requestParameters, initOverrides) {
|
|
259
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
260
|
+
const requestOptions = yield this.getZapierShopifyCourseMappingsRequestOpts(requestParameters);
|
|
261
|
+
const response = yield this.request(requestOptions, initOverrides);
|
|
262
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => (0, GetZapierShopifyCourseMappings_1.GetZapierShopifyCourseMappingsFromJSON)(jsonValue));
|
|
263
|
+
});
|
|
264
|
+
}
|
|
265
|
+
/**
|
|
266
|
+
* List Shopify variant-to-course mappings
|
|
267
|
+
*/
|
|
268
|
+
getZapierShopifyCourseMappings(requestParameters, initOverrides) {
|
|
269
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
270
|
+
const response = yield this.getZapierShopifyCourseMappingsRaw(requestParameters, initOverrides);
|
|
271
|
+
return yield response.value();
|
|
272
|
+
});
|
|
273
|
+
}
|
|
274
|
+
/**
|
|
275
|
+
* Creates request options for getZapierUsers without sending the request
|
|
276
|
+
*/
|
|
277
|
+
getZapierUsersRequestOpts(requestParameters) {
|
|
278
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
279
|
+
if (requestParameters['xAPIKEY'] == null) {
|
|
280
|
+
throw new runtime.RequiredError('xAPIKEY', 'Required parameter "xAPIKEY" was null or undefined when calling getZapierUsers().');
|
|
281
|
+
}
|
|
282
|
+
if (requestParameters['xPORTALSUBDOMAIN'] == null) {
|
|
283
|
+
throw new runtime.RequiredError('xPORTALSUBDOMAIN', 'Required parameter "xPORTALSUBDOMAIN" was null or undefined when calling getZapierUsers().');
|
|
284
|
+
}
|
|
285
|
+
if (requestParameters['email'] == null) {
|
|
286
|
+
throw new runtime.RequiredError('email', 'Required parameter "email" was null or undefined when calling getZapierUsers().');
|
|
287
|
+
}
|
|
288
|
+
const queryParameters = {};
|
|
289
|
+
if (requestParameters['email'] != null) {
|
|
290
|
+
queryParameters['email'] = requestParameters['email'];
|
|
291
|
+
}
|
|
292
|
+
const headerParameters = {};
|
|
293
|
+
if (requestParameters['xAPIKEY'] != null) {
|
|
294
|
+
headerParameters['X-API-KEY'] = String(requestParameters['xAPIKEY']);
|
|
295
|
+
}
|
|
296
|
+
if (requestParameters['xPORTALSUBDOMAIN'] != null) {
|
|
297
|
+
headerParameters['X-PORTAL-SUBDOMAIN'] = String(requestParameters['xPORTALSUBDOMAIN']);
|
|
298
|
+
}
|
|
299
|
+
let urlPath = `/integrations/zapier/users`;
|
|
300
|
+
return {
|
|
301
|
+
path: urlPath,
|
|
302
|
+
method: 'GET',
|
|
303
|
+
headers: headerParameters,
|
|
304
|
+
query: queryParameters,
|
|
305
|
+
};
|
|
306
|
+
});
|
|
307
|
+
}
|
|
308
|
+
/**
|
|
309
|
+
* Find a learner by exact email address
|
|
310
|
+
*/
|
|
311
|
+
getZapierUsersRaw(requestParameters, initOverrides) {
|
|
312
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
313
|
+
const requestOptions = yield this.getZapierUsersRequestOpts(requestParameters);
|
|
314
|
+
const response = yield this.request(requestOptions, initOverrides);
|
|
315
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => (0, GetZapierUsers_1.GetZapierUsersFromJSON)(jsonValue));
|
|
316
|
+
});
|
|
317
|
+
}
|
|
318
|
+
/**
|
|
319
|
+
* Find a learner by exact email address
|
|
320
|
+
*/
|
|
321
|
+
getZapierUsers(requestParameters, initOverrides) {
|
|
322
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
323
|
+
const response = yield this.getZapierUsersRaw(requestParameters, initOverrides);
|
|
324
|
+
return yield response.value();
|
|
325
|
+
});
|
|
326
|
+
}
|
|
327
|
+
/**
|
|
328
|
+
* Creates request options for postZapierEnrollment without sending the request
|
|
329
|
+
*/
|
|
330
|
+
postZapierEnrollmentRequestOpts(requestParameters) {
|
|
331
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
332
|
+
if (requestParameters['xAPIKEY'] == null) {
|
|
333
|
+
throw new runtime.RequiredError('xAPIKEY', 'Required parameter "xAPIKEY" was null or undefined when calling postZapierEnrollment().');
|
|
334
|
+
}
|
|
335
|
+
if (requestParameters['xPORTALSUBDOMAIN'] == null) {
|
|
336
|
+
throw new runtime.RequiredError('xPORTALSUBDOMAIN', 'Required parameter "xPORTALSUBDOMAIN" was null or undefined when calling postZapierEnrollment().');
|
|
337
|
+
}
|
|
338
|
+
if (requestParameters['postZapierEnrollment'] == null) {
|
|
339
|
+
throw new runtime.RequiredError('postZapierEnrollment', 'Required parameter "postZapierEnrollment" was null or undefined when calling postZapierEnrollment().');
|
|
340
|
+
}
|
|
341
|
+
const queryParameters = {};
|
|
342
|
+
const headerParameters = {};
|
|
343
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
344
|
+
if (requestParameters['xAPIKEY'] != null) {
|
|
345
|
+
headerParameters['X-API-KEY'] = String(requestParameters['xAPIKEY']);
|
|
346
|
+
}
|
|
347
|
+
if (requestParameters['xPORTALSUBDOMAIN'] != null) {
|
|
348
|
+
headerParameters['X-PORTAL-SUBDOMAIN'] = String(requestParameters['xPORTALSUBDOMAIN']);
|
|
349
|
+
}
|
|
350
|
+
let urlPath = `/integrations/zapier/enrollments`;
|
|
351
|
+
return {
|
|
352
|
+
path: urlPath,
|
|
353
|
+
method: 'POST',
|
|
354
|
+
headers: headerParameters,
|
|
355
|
+
query: queryParameters,
|
|
356
|
+
body: (0, PostZapierEnrollment_1.PostZapierEnrollmentToJSON)(requestParameters['postZapierEnrollment']),
|
|
357
|
+
};
|
|
358
|
+
});
|
|
359
|
+
}
|
|
360
|
+
/**
|
|
361
|
+
* Enroll an existing learner in a course
|
|
362
|
+
*/
|
|
363
|
+
postZapierEnrollmentRaw(requestParameters, initOverrides) {
|
|
364
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
365
|
+
const requestOptions = yield this.postZapierEnrollmentRequestOpts(requestParameters);
|
|
366
|
+
const response = yield this.request(requestOptions, initOverrides);
|
|
367
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => (0, ZapierEnrollment_1.ZapierEnrollmentFromJSON)(jsonValue));
|
|
368
|
+
});
|
|
369
|
+
}
|
|
370
|
+
/**
|
|
371
|
+
* Enroll an existing learner in a course
|
|
372
|
+
*/
|
|
373
|
+
postZapierEnrollment(requestParameters, initOverrides) {
|
|
374
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
375
|
+
const response = yield this.postZapierEnrollmentRaw(requestParameters, initOverrides);
|
|
376
|
+
return yield response.value();
|
|
377
|
+
});
|
|
378
|
+
}
|
|
157
379
|
/**
|
|
158
380
|
* Creates request options for postZapierSetup without sending the request
|
|
159
381
|
*/
|
|
@@ -194,6 +416,162 @@ class IntegrationApi extends runtime.BaseAPI {
|
|
|
194
416
|
return yield response.value();
|
|
195
417
|
});
|
|
196
418
|
}
|
|
419
|
+
/**
|
|
420
|
+
* Creates request options for postZapierShopifyCourseMapping without sending the request
|
|
421
|
+
*/
|
|
422
|
+
postZapierShopifyCourseMappingRequestOpts(requestParameters) {
|
|
423
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
424
|
+
if (requestParameters['xAPIKEY'] == null) {
|
|
425
|
+
throw new runtime.RequiredError('xAPIKEY', 'Required parameter "xAPIKEY" was null or undefined when calling postZapierShopifyCourseMapping().');
|
|
426
|
+
}
|
|
427
|
+
if (requestParameters['xPORTALSUBDOMAIN'] == null) {
|
|
428
|
+
throw new runtime.RequiredError('xPORTALSUBDOMAIN', 'Required parameter "xPORTALSUBDOMAIN" was null or undefined when calling postZapierShopifyCourseMapping().');
|
|
429
|
+
}
|
|
430
|
+
if (requestParameters['postZapierShopifyCourseMapping'] == null) {
|
|
431
|
+
throw new runtime.RequiredError('postZapierShopifyCourseMapping', 'Required parameter "postZapierShopifyCourseMapping" was null or undefined when calling postZapierShopifyCourseMapping().');
|
|
432
|
+
}
|
|
433
|
+
const queryParameters = {};
|
|
434
|
+
const headerParameters = {};
|
|
435
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
436
|
+
if (requestParameters['xAPIKEY'] != null) {
|
|
437
|
+
headerParameters['X-API-KEY'] = String(requestParameters['xAPIKEY']);
|
|
438
|
+
}
|
|
439
|
+
if (requestParameters['xPORTALSUBDOMAIN'] != null) {
|
|
440
|
+
headerParameters['X-PORTAL-SUBDOMAIN'] = String(requestParameters['xPORTALSUBDOMAIN']);
|
|
441
|
+
}
|
|
442
|
+
let urlPath = `/integrations/zapier/shopify/course-mappings`;
|
|
443
|
+
return {
|
|
444
|
+
path: urlPath,
|
|
445
|
+
method: 'POST',
|
|
446
|
+
headers: headerParameters,
|
|
447
|
+
query: queryParameters,
|
|
448
|
+
body: (0, PostZapierShopifyCourseMapping_1.PostZapierShopifyCourseMappingToJSON)(requestParameters['postZapierShopifyCourseMapping']),
|
|
449
|
+
};
|
|
450
|
+
});
|
|
451
|
+
}
|
|
452
|
+
/**
|
|
453
|
+
* Create or update a Shopify variant-to-course mapping
|
|
454
|
+
*/
|
|
455
|
+
postZapierShopifyCourseMappingRaw(requestParameters, initOverrides) {
|
|
456
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
457
|
+
const requestOptions = yield this.postZapierShopifyCourseMappingRequestOpts(requestParameters);
|
|
458
|
+
const response = yield this.request(requestOptions, initOverrides);
|
|
459
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => (0, ZapierShopifyCourseMapping_1.ZapierShopifyCourseMappingFromJSON)(jsonValue));
|
|
460
|
+
});
|
|
461
|
+
}
|
|
462
|
+
/**
|
|
463
|
+
* Create or update a Shopify variant-to-course mapping
|
|
464
|
+
*/
|
|
465
|
+
postZapierShopifyCourseMapping(requestParameters, initOverrides) {
|
|
466
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
467
|
+
const response = yield this.postZapierShopifyCourseMappingRaw(requestParameters, initOverrides);
|
|
468
|
+
return yield response.value();
|
|
469
|
+
});
|
|
470
|
+
}
|
|
471
|
+
/**
|
|
472
|
+
* Creates request options for postZapierShopifyEnrollment without sending the request
|
|
473
|
+
*/
|
|
474
|
+
postZapierShopifyEnrollmentRequestOpts(requestParameters) {
|
|
475
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
476
|
+
if (requestParameters['xAPIKEY'] == null) {
|
|
477
|
+
throw new runtime.RequiredError('xAPIKEY', 'Required parameter "xAPIKEY" was null or undefined when calling postZapierShopifyEnrollment().');
|
|
478
|
+
}
|
|
479
|
+
if (requestParameters['xPORTALSUBDOMAIN'] == null) {
|
|
480
|
+
throw new runtime.RequiredError('xPORTALSUBDOMAIN', 'Required parameter "xPORTALSUBDOMAIN" was null or undefined when calling postZapierShopifyEnrollment().');
|
|
481
|
+
}
|
|
482
|
+
if (requestParameters['postZapierShopifyEnrollment'] == null) {
|
|
483
|
+
throw new runtime.RequiredError('postZapierShopifyEnrollment', 'Required parameter "postZapierShopifyEnrollment" was null or undefined when calling postZapierShopifyEnrollment().');
|
|
484
|
+
}
|
|
485
|
+
const queryParameters = {};
|
|
486
|
+
const headerParameters = {};
|
|
487
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
488
|
+
if (requestParameters['xAPIKEY'] != null) {
|
|
489
|
+
headerParameters['X-API-KEY'] = String(requestParameters['xAPIKEY']);
|
|
490
|
+
}
|
|
491
|
+
if (requestParameters['xPORTALSUBDOMAIN'] != null) {
|
|
492
|
+
headerParameters['X-PORTAL-SUBDOMAIN'] = String(requestParameters['xPORTALSUBDOMAIN']);
|
|
493
|
+
}
|
|
494
|
+
let urlPath = `/integrations/zapier/shopify/enrollments`;
|
|
495
|
+
return {
|
|
496
|
+
path: urlPath,
|
|
497
|
+
method: 'POST',
|
|
498
|
+
headers: headerParameters,
|
|
499
|
+
query: queryParameters,
|
|
500
|
+
body: (0, PostZapierShopifyEnrollment_1.PostZapierShopifyEnrollmentToJSON)(requestParameters['postZapierShopifyEnrollment']),
|
|
501
|
+
};
|
|
502
|
+
});
|
|
503
|
+
}
|
|
504
|
+
/**
|
|
505
|
+
* Find or invite a Shopify customer and enroll them using the purchased variant mapping
|
|
506
|
+
*/
|
|
507
|
+
postZapierShopifyEnrollmentRaw(requestParameters, initOverrides) {
|
|
508
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
509
|
+
const requestOptions = yield this.postZapierShopifyEnrollmentRequestOpts(requestParameters);
|
|
510
|
+
const response = yield this.request(requestOptions, initOverrides);
|
|
511
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => (0, PostZapierShopifyEnrollmentResponse_1.PostZapierShopifyEnrollmentResponseFromJSON)(jsonValue));
|
|
512
|
+
});
|
|
513
|
+
}
|
|
514
|
+
/**
|
|
515
|
+
* Find or invite a Shopify customer and enroll them using the purchased variant mapping
|
|
516
|
+
*/
|
|
517
|
+
postZapierShopifyEnrollment(requestParameters, initOverrides) {
|
|
518
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
519
|
+
const response = yield this.postZapierShopifyEnrollmentRaw(requestParameters, initOverrides);
|
|
520
|
+
return yield response.value();
|
|
521
|
+
});
|
|
522
|
+
}
|
|
523
|
+
/**
|
|
524
|
+
* Creates request options for postZapierUser without sending the request
|
|
525
|
+
*/
|
|
526
|
+
postZapierUserRequestOpts(requestParameters) {
|
|
527
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
528
|
+
if (requestParameters['xAPIKEY'] == null) {
|
|
529
|
+
throw new runtime.RequiredError('xAPIKEY', 'Required parameter "xAPIKEY" was null or undefined when calling postZapierUser().');
|
|
530
|
+
}
|
|
531
|
+
if (requestParameters['xPORTALSUBDOMAIN'] == null) {
|
|
532
|
+
throw new runtime.RequiredError('xPORTALSUBDOMAIN', 'Required parameter "xPORTALSUBDOMAIN" was null or undefined when calling postZapierUser().');
|
|
533
|
+
}
|
|
534
|
+
if (requestParameters['postZapierUser'] == null) {
|
|
535
|
+
throw new runtime.RequiredError('postZapierUser', 'Required parameter "postZapierUser" was null or undefined when calling postZapierUser().');
|
|
536
|
+
}
|
|
537
|
+
const queryParameters = {};
|
|
538
|
+
const headerParameters = {};
|
|
539
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
540
|
+
if (requestParameters['xAPIKEY'] != null) {
|
|
541
|
+
headerParameters['X-API-KEY'] = String(requestParameters['xAPIKEY']);
|
|
542
|
+
}
|
|
543
|
+
if (requestParameters['xPORTALSUBDOMAIN'] != null) {
|
|
544
|
+
headerParameters['X-PORTAL-SUBDOMAIN'] = String(requestParameters['xPORTALSUBDOMAIN']);
|
|
545
|
+
}
|
|
546
|
+
let urlPath = `/integrations/zapier/users`;
|
|
547
|
+
return {
|
|
548
|
+
path: urlPath,
|
|
549
|
+
method: 'POST',
|
|
550
|
+
headers: headerParameters,
|
|
551
|
+
query: queryParameters,
|
|
552
|
+
body: (0, PostZapierUser_1.PostZapierUserToJSON)(requestParameters['postZapierUser']),
|
|
553
|
+
};
|
|
554
|
+
});
|
|
555
|
+
}
|
|
556
|
+
/**
|
|
557
|
+
* Find or invite a learner to the connected portal
|
|
558
|
+
*/
|
|
559
|
+
postZapierUserRaw(requestParameters, initOverrides) {
|
|
560
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
561
|
+
const requestOptions = yield this.postZapierUserRequestOpts(requestParameters);
|
|
562
|
+
const response = yield this.request(requestOptions, initOverrides);
|
|
563
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => (0, ZapierUser_1.ZapierUserFromJSON)(jsonValue));
|
|
564
|
+
});
|
|
565
|
+
}
|
|
566
|
+
/**
|
|
567
|
+
* Find or invite a learner to the connected portal
|
|
568
|
+
*/
|
|
569
|
+
postZapierUser(requestParameters, initOverrides) {
|
|
570
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
571
|
+
const response = yield this.postZapierUserRaw(requestParameters, initOverrides);
|
|
572
|
+
return yield response.value();
|
|
573
|
+
});
|
|
574
|
+
}
|
|
197
575
|
/**
|
|
198
576
|
* Creates request options for putZapierSetup without sending the request
|
|
199
577
|
*/
|
|
@@ -10,22 +10,70 @@
|
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
12
|
import * as runtime from '../runtime';
|
|
13
|
+
import { type GetZapierCourses } from '../models/GetZapierCourses';
|
|
13
14
|
import { type GetZapierMe } from '../models/GetZapierMe';
|
|
14
15
|
import { type GetZapierSetup } from '../models/GetZapierSetup';
|
|
16
|
+
import { type GetZapierShopifyCourseMappings } from '../models/GetZapierShopifyCourseMappings';
|
|
17
|
+
import { type GetZapierUsers } from '../models/GetZapierUsers';
|
|
18
|
+
import { type PostZapierEnrollment } from '../models/PostZapierEnrollment';
|
|
15
19
|
import { type PostZapierSetup } from '../models/PostZapierSetup';
|
|
16
20
|
import { type PostZapierSetupResponse } from '../models/PostZapierSetupResponse';
|
|
21
|
+
import { type PostZapierShopifyCourseMapping } from '../models/PostZapierShopifyCourseMapping';
|
|
22
|
+
import { type PostZapierShopifyEnrollment } from '../models/PostZapierShopifyEnrollment';
|
|
23
|
+
import { type PostZapierShopifyEnrollmentResponse } from '../models/PostZapierShopifyEnrollmentResponse';
|
|
24
|
+
import { type PostZapierUser } from '../models/PostZapierUser';
|
|
17
25
|
import { type PutZapierSetup } from '../models/PutZapierSetup';
|
|
26
|
+
import { type ZapierEnrollment } from '../models/ZapierEnrollment';
|
|
18
27
|
import { type ZapierIntegration } from '../models/ZapierIntegration';
|
|
28
|
+
import { type ZapierShopifyCourseMapping } from '../models/ZapierShopifyCourseMapping';
|
|
29
|
+
import { type ZapierUser } from '../models/ZapierUser';
|
|
19
30
|
export interface DeleteZapierSetupRequest {
|
|
20
31
|
zapierIntegrationId: string;
|
|
21
32
|
}
|
|
33
|
+
export interface GetZapierCoursesRequest {
|
|
34
|
+
xAPIKEY: string;
|
|
35
|
+
xPORTALSUBDOMAIN: string;
|
|
36
|
+
page?: number;
|
|
37
|
+
pageSize?: number;
|
|
38
|
+
search?: string;
|
|
39
|
+
}
|
|
22
40
|
export interface GetZapierMeRequest {
|
|
23
41
|
xAPIKEY: string;
|
|
24
42
|
xPORTALSUBDOMAIN: string;
|
|
25
43
|
}
|
|
44
|
+
export interface GetZapierShopifyCourseMappingsRequest {
|
|
45
|
+
xAPIKEY: string;
|
|
46
|
+
xPORTALSUBDOMAIN: string;
|
|
47
|
+
shopDomain?: string;
|
|
48
|
+
}
|
|
49
|
+
export interface GetZapierUsersRequest {
|
|
50
|
+
xAPIKEY: string;
|
|
51
|
+
xPORTALSUBDOMAIN: string;
|
|
52
|
+
email: string;
|
|
53
|
+
}
|
|
54
|
+
export interface PostZapierEnrollmentRequest {
|
|
55
|
+
xAPIKEY: string;
|
|
56
|
+
xPORTALSUBDOMAIN: string;
|
|
57
|
+
postZapierEnrollment: PostZapierEnrollment;
|
|
58
|
+
}
|
|
26
59
|
export interface PostZapierSetupRequest {
|
|
27
60
|
postZapierSetup: PostZapierSetup;
|
|
28
61
|
}
|
|
62
|
+
export interface PostZapierShopifyCourseMappingRequest {
|
|
63
|
+
xAPIKEY: string;
|
|
64
|
+
xPORTALSUBDOMAIN: string;
|
|
65
|
+
postZapierShopifyCourseMapping: PostZapierShopifyCourseMapping;
|
|
66
|
+
}
|
|
67
|
+
export interface PostZapierShopifyEnrollmentRequest {
|
|
68
|
+
xAPIKEY: string;
|
|
69
|
+
xPORTALSUBDOMAIN: string;
|
|
70
|
+
postZapierShopifyEnrollment: PostZapierShopifyEnrollment;
|
|
71
|
+
}
|
|
72
|
+
export interface PostZapierUserRequest {
|
|
73
|
+
xAPIKEY: string;
|
|
74
|
+
xPORTALSUBDOMAIN: string;
|
|
75
|
+
postZapierUser: PostZapierUser;
|
|
76
|
+
}
|
|
29
77
|
export interface PutZapierSetupRequest {
|
|
30
78
|
zapierIntegrationId: string;
|
|
31
79
|
putZapierSetup: PutZapierSetup;
|
|
@@ -46,6 +94,18 @@ export declare class IntegrationApi extends runtime.BaseAPI {
|
|
|
46
94
|
* Revoke a Zapier connection and its API key
|
|
47
95
|
*/
|
|
48
96
|
deleteZapierSetup(requestParameters: DeleteZapierSetupRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
|
|
97
|
+
/**
|
|
98
|
+
* Creates request options for getZapierCourses without sending the request
|
|
99
|
+
*/
|
|
100
|
+
getZapierCoursesRequestOpts(requestParameters: GetZapierCoursesRequest): Promise<runtime.RequestOpts>;
|
|
101
|
+
/**
|
|
102
|
+
* List published courses available to a Zapier connection
|
|
103
|
+
*/
|
|
104
|
+
getZapierCoursesRaw(requestParameters: GetZapierCoursesRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<GetZapierCourses>>;
|
|
105
|
+
/**
|
|
106
|
+
* List published courses available to a Zapier connection
|
|
107
|
+
*/
|
|
108
|
+
getZapierCourses(requestParameters: GetZapierCoursesRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GetZapierCourses>;
|
|
49
109
|
/**
|
|
50
110
|
* Creates request options for getZapierMe without sending the request
|
|
51
111
|
*/
|
|
@@ -70,6 +130,42 @@ export declare class IntegrationApi extends runtime.BaseAPI {
|
|
|
70
130
|
* List Zapier connections and permissions available to the selected portal
|
|
71
131
|
*/
|
|
72
132
|
getZapierSetup(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GetZapierSetup>;
|
|
133
|
+
/**
|
|
134
|
+
* Creates request options for getZapierShopifyCourseMappings without sending the request
|
|
135
|
+
*/
|
|
136
|
+
getZapierShopifyCourseMappingsRequestOpts(requestParameters: GetZapierShopifyCourseMappingsRequest): Promise<runtime.RequestOpts>;
|
|
137
|
+
/**
|
|
138
|
+
* List Shopify variant-to-course mappings
|
|
139
|
+
*/
|
|
140
|
+
getZapierShopifyCourseMappingsRaw(requestParameters: GetZapierShopifyCourseMappingsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<GetZapierShopifyCourseMappings>>;
|
|
141
|
+
/**
|
|
142
|
+
* List Shopify variant-to-course mappings
|
|
143
|
+
*/
|
|
144
|
+
getZapierShopifyCourseMappings(requestParameters: GetZapierShopifyCourseMappingsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GetZapierShopifyCourseMappings>;
|
|
145
|
+
/**
|
|
146
|
+
* Creates request options for getZapierUsers without sending the request
|
|
147
|
+
*/
|
|
148
|
+
getZapierUsersRequestOpts(requestParameters: GetZapierUsersRequest): Promise<runtime.RequestOpts>;
|
|
149
|
+
/**
|
|
150
|
+
* Find a learner by exact email address
|
|
151
|
+
*/
|
|
152
|
+
getZapierUsersRaw(requestParameters: GetZapierUsersRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<GetZapierUsers>>;
|
|
153
|
+
/**
|
|
154
|
+
* Find a learner by exact email address
|
|
155
|
+
*/
|
|
156
|
+
getZapierUsers(requestParameters: GetZapierUsersRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GetZapierUsers>;
|
|
157
|
+
/**
|
|
158
|
+
* Creates request options for postZapierEnrollment without sending the request
|
|
159
|
+
*/
|
|
160
|
+
postZapierEnrollmentRequestOpts(requestParameters: PostZapierEnrollmentRequest): Promise<runtime.RequestOpts>;
|
|
161
|
+
/**
|
|
162
|
+
* Enroll an existing learner in a course
|
|
163
|
+
*/
|
|
164
|
+
postZapierEnrollmentRaw(requestParameters: PostZapierEnrollmentRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ZapierEnrollment>>;
|
|
165
|
+
/**
|
|
166
|
+
* Enroll an existing learner in a course
|
|
167
|
+
*/
|
|
168
|
+
postZapierEnrollment(requestParameters: PostZapierEnrollmentRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ZapierEnrollment>;
|
|
73
169
|
/**
|
|
74
170
|
* Creates request options for postZapierSetup without sending the request
|
|
75
171
|
*/
|
|
@@ -82,6 +178,42 @@ export declare class IntegrationApi extends runtime.BaseAPI {
|
|
|
82
178
|
* Create a Zapier connection and API key for the selected portal
|
|
83
179
|
*/
|
|
84
180
|
postZapierSetup(requestParameters: PostZapierSetupRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<PostZapierSetupResponse>;
|
|
181
|
+
/**
|
|
182
|
+
* Creates request options for postZapierShopifyCourseMapping without sending the request
|
|
183
|
+
*/
|
|
184
|
+
postZapierShopifyCourseMappingRequestOpts(requestParameters: PostZapierShopifyCourseMappingRequest): Promise<runtime.RequestOpts>;
|
|
185
|
+
/**
|
|
186
|
+
* Create or update a Shopify variant-to-course mapping
|
|
187
|
+
*/
|
|
188
|
+
postZapierShopifyCourseMappingRaw(requestParameters: PostZapierShopifyCourseMappingRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ZapierShopifyCourseMapping>>;
|
|
189
|
+
/**
|
|
190
|
+
* Create or update a Shopify variant-to-course mapping
|
|
191
|
+
*/
|
|
192
|
+
postZapierShopifyCourseMapping(requestParameters: PostZapierShopifyCourseMappingRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ZapierShopifyCourseMapping>;
|
|
193
|
+
/**
|
|
194
|
+
* Creates request options for postZapierShopifyEnrollment without sending the request
|
|
195
|
+
*/
|
|
196
|
+
postZapierShopifyEnrollmentRequestOpts(requestParameters: PostZapierShopifyEnrollmentRequest): Promise<runtime.RequestOpts>;
|
|
197
|
+
/**
|
|
198
|
+
* Find or invite a Shopify customer and enroll them using the purchased variant mapping
|
|
199
|
+
*/
|
|
200
|
+
postZapierShopifyEnrollmentRaw(requestParameters: PostZapierShopifyEnrollmentRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<PostZapierShopifyEnrollmentResponse>>;
|
|
201
|
+
/**
|
|
202
|
+
* Find or invite a Shopify customer and enroll them using the purchased variant mapping
|
|
203
|
+
*/
|
|
204
|
+
postZapierShopifyEnrollment(requestParameters: PostZapierShopifyEnrollmentRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<PostZapierShopifyEnrollmentResponse>;
|
|
205
|
+
/**
|
|
206
|
+
* Creates request options for postZapierUser without sending the request
|
|
207
|
+
*/
|
|
208
|
+
postZapierUserRequestOpts(requestParameters: PostZapierUserRequest): Promise<runtime.RequestOpts>;
|
|
209
|
+
/**
|
|
210
|
+
* Find or invite a learner to the connected portal
|
|
211
|
+
*/
|
|
212
|
+
postZapierUserRaw(requestParameters: PostZapierUserRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ZapierUser>>;
|
|
213
|
+
/**
|
|
214
|
+
* Find or invite a learner to the connected portal
|
|
215
|
+
*/
|
|
216
|
+
postZapierUser(requestParameters: PostZapierUserRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ZapierUser>;
|
|
85
217
|
/**
|
|
86
218
|
* Creates request options for putZapierSetup without sending the request
|
|
87
219
|
*/
|