@emilgroup/translation-sdk-node 1.1.0 → 1.1.1-beta.5
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 +3 -0
- package/README.md +20 -4
- package/api/default-api.ts +128 -0
- package/api/translation-api.ts +141 -112
- package/api.ts +2 -0
- package/base.ts +50 -6
- package/common.ts +2 -2
- package/configuration.ts +9 -0
- package/dist/api/default-api.d.ts +70 -0
- package/dist/api/default-api.js +204 -0
- package/dist/api/translation-api.d.ts +124 -106
- package/dist/api/translation-api.js +92 -80
- package/dist/api.d.ts +1 -0
- package/dist/api.js +1 -0
- package/dist/base.d.ts +15 -4
- package/dist/base.js +45 -4
- package/dist/common.js +2 -2
- package/dist/configuration.d.ts +6 -0
- package/dist/configuration.js +8 -0
- package/dist/models/create-product-language-request-dto.d.ts +1 -1
- package/dist/models/index.d.ts +2 -0
- package/dist/models/index.js +2 -0
- package/dist/models/inline-response200.d.ts +54 -0
- package/dist/models/inline-response200.js +15 -0
- package/dist/models/inline-response503.d.ts +54 -0
- package/dist/models/inline-response503.js +15 -0
- package/dist/models/product-language-class.d.ts +4 -4
- package/models/create-product-language-request-dto.ts +1 -1
- package/models/index.ts +2 -0
- package/models/inline-response200.ts +48 -0
- package/models/inline-response503.ts +48 -0
- package/models/product-language-class.ts +4 -4
- package/package.json +2 -2
- package/tsconfig.json +1 -0
|
@@ -97,7 +97,7 @@ var TranslationApiAxiosParamCreator = function (configuration) {
|
|
|
97
97
|
var _this = this;
|
|
98
98
|
return {
|
|
99
99
|
/**
|
|
100
|
-
* This creates a product language.
|
|
100
|
+
* This creates a product language. **Required Permissions** \"translation-management.translations.create\"
|
|
101
101
|
* @summary Create the product language
|
|
102
102
|
* @param {CreateProductLanguageRequestDto} createProductLanguageRequestDto
|
|
103
103
|
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
@@ -146,7 +146,7 @@ var TranslationApiAxiosParamCreator = function (configuration) {
|
|
|
146
146
|
});
|
|
147
147
|
},
|
|
148
148
|
/**
|
|
149
|
-
* Permanently deletes the product language. Supply the unique id that was returned when you created the product language and this will delete it.
|
|
149
|
+
* Permanently deletes the product language. Supply the unique id that was returned when you created the product language and this will delete it. **Required Permissions** \"translation-management.translations.delete\"
|
|
150
150
|
* @summary Delete the product language
|
|
151
151
|
* @param {number} id Id of the product language.
|
|
152
152
|
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
@@ -194,7 +194,7 @@ var TranslationApiAxiosParamCreator = function (configuration) {
|
|
|
194
194
|
});
|
|
195
195
|
},
|
|
196
196
|
/**
|
|
197
|
-
* This downloads the list of translatable fields for a given product.
|
|
197
|
+
* This downloads the list of translatable fields for a given product. **Required Permissions** \"translation-management.translations.view\"
|
|
198
198
|
* @summary Retrieve the product translations
|
|
199
199
|
* @param {string} productSlug
|
|
200
200
|
* @param {'German' | 'English' | 'Polish' | 'French' | 'Italian' | 'Spanish' | 'Portuguese' | 'Russian' | 'Japanese' | 'Chinese' | 'Korean' | 'Turkish' | 'Arabic' | 'Hindi' | 'Indonesian' | 'Thai' | 'Vietnamese' | 'Persian' | 'Romanian'} language
|
|
@@ -248,7 +248,7 @@ var TranslationApiAxiosParamCreator = function (configuration) {
|
|
|
248
248
|
});
|
|
249
249
|
},
|
|
250
250
|
/**
|
|
251
|
-
* This gets a product language.
|
|
251
|
+
* This gets a product language. **Required Permissions** \"translation-management.translations.view\"
|
|
252
252
|
* @summary Retrieve the product language
|
|
253
253
|
* @param {number} id Id of the product language.
|
|
254
254
|
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
@@ -296,19 +296,20 @@ var TranslationApiAxiosParamCreator = function (configuration) {
|
|
|
296
296
|
});
|
|
297
297
|
},
|
|
298
298
|
/**
|
|
299
|
-
*
|
|
299
|
+
* Returns a list of product languages you have previously created. The product languages are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation. **Required Permissions** \"translation-management.translations.view\"
|
|
300
300
|
* @summary List product languages
|
|
301
301
|
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
302
|
-
* @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and
|
|
303
|
-
* @param {string} [pageToken] A cursor for use in pagination. pageToken is an ID that defines your place in the list. For instance, if you make a list request and receive 100 objects and pageToken=1,
|
|
304
|
-
* @param {
|
|
305
|
-
* @param {
|
|
306
|
-
* @param {
|
|
307
|
-
* @param {
|
|
302
|
+
* @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
|
|
303
|
+
* @param {string} [pageToken] A cursor for use in pagination. pageToken is an ID that defines your place in the list. For instance, if you make a list request and receive 100 objects and pageToken=1, your subsequent call can include pageToken=2 in order to fetch the next page of the list.
|
|
304
|
+
* @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.<br/> <br/> <i>Allowed values: id, productSlug, language, isActive, translationStatus, createdAt, updateAt</i>
|
|
305
|
+
* @param {string} [search] Search the response for matches in any searchable field. Use filter instead where possible for improved performance.<br/> <br/> <i>Searchable fields: id, language</i>
|
|
306
|
+
* @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.<br/> <br/> <i>Allowed values: id, language, isActive, translationStatus, createdAt, updatedAt</i>
|
|
307
|
+
* @param {string} [expand] Expand to fetch additional information about the list items. Expanding resources can reduce the number of API calls required to accomplish a task. Use with discretion as some expanded fields can drastically increase payload size.<br/> <br/>
|
|
308
|
+
* @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.<br/> <br/> <i>Allowed values: id, productSlug, language, isActive, translationStatus, createdAt, updateAt</i>
|
|
308
309
|
* @param {*} [options] Override http request option.
|
|
309
310
|
* @throws {RequiredError}
|
|
310
311
|
*/
|
|
311
|
-
listProductLanguages: function (authorization, pageSize, pageToken, filter, search, order, expand, options) {
|
|
312
|
+
listProductLanguages: function (authorization, pageSize, pageToken, filter, search, order, expand, filters, options) {
|
|
312
313
|
if (options === void 0) { options = {}; }
|
|
313
314
|
return __awaiter(_this, void 0, void 0, function () {
|
|
314
315
|
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
@@ -349,6 +350,9 @@ var TranslationApiAxiosParamCreator = function (configuration) {
|
|
|
349
350
|
if (expand !== undefined) {
|
|
350
351
|
localVarQueryParameter['expand'] = expand;
|
|
351
352
|
}
|
|
353
|
+
if (filters !== undefined) {
|
|
354
|
+
localVarQueryParameter['filters'] = filters;
|
|
355
|
+
}
|
|
352
356
|
if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
|
|
353
357
|
localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
|
|
354
358
|
}
|
|
@@ -364,19 +368,20 @@ var TranslationApiAxiosParamCreator = function (configuration) {
|
|
|
364
368
|
});
|
|
365
369
|
},
|
|
366
370
|
/**
|
|
367
|
-
* Returns a list of translations you have previously created.
|
|
371
|
+
* Returns a list of translations you have previously created. The translations are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation. **Required Permissions** \"translation-management.translations.view\"
|
|
368
372
|
* @summary List translations
|
|
369
373
|
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
370
|
-
* @param {
|
|
371
|
-
* @param {
|
|
372
|
-
* @param {
|
|
373
|
-
* @param {
|
|
374
|
-
* @param {
|
|
375
|
-
* @param {
|
|
374
|
+
* @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
|
|
375
|
+
* @param {string} [pageToken] A cursor for use in pagination. pageToken is an ID that defines your place in the list. For instance, if you make a list request and receive 100 objects and pageToken=1, your subsequent call can include pageToken=2 in order to fetch the next page of the list.
|
|
376
|
+
* @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.<br/> <br/> <i>Allowed values: key</i>
|
|
377
|
+
* @param {string} [search] Search the response for matches in any searchable field. Use filter instead where possible for improved performance.<br/> <br/> <i>Searchable fields: key</i>
|
|
378
|
+
* @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.<br/> <br/> <i>Allowed values: id, createdAt, key</i>
|
|
379
|
+
* @param {string} [expand] Expand to fetch additional information about the list items. Expanding resources can reduce the number of API calls required to accomplish a task. Use with discretion as some expanded fields can drastically increase payload size.<br/> <br/>
|
|
380
|
+
* @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.<br/> <br/> <i>Allowed values: key</i>
|
|
376
381
|
* @param {*} [options] Override http request option.
|
|
377
382
|
* @throws {RequiredError}
|
|
378
383
|
*/
|
|
379
|
-
listTranslations: function (authorization, pageSize, pageToken, filter, search, order, expand, options) {
|
|
384
|
+
listTranslations: function (authorization, pageSize, pageToken, filter, search, order, expand, filters, options) {
|
|
380
385
|
if (options === void 0) { options = {}; }
|
|
381
386
|
return __awaiter(_this, void 0, void 0, function () {
|
|
382
387
|
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
@@ -417,6 +422,9 @@ var TranslationApiAxiosParamCreator = function (configuration) {
|
|
|
417
422
|
if (expand !== undefined) {
|
|
418
423
|
localVarQueryParameter['expand'] = expand;
|
|
419
424
|
}
|
|
425
|
+
if (filters !== undefined) {
|
|
426
|
+
localVarQueryParameter['filters'] = filters;
|
|
427
|
+
}
|
|
420
428
|
if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
|
|
421
429
|
localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
|
|
422
430
|
}
|
|
@@ -432,7 +440,7 @@ var TranslationApiAxiosParamCreator = function (configuration) {
|
|
|
432
440
|
});
|
|
433
441
|
},
|
|
434
442
|
/**
|
|
435
|
-
* This updates the product language with the specified id.
|
|
443
|
+
* This updates the product language with the specified id. **Required Permissions** \"translation-management.translations.update\"
|
|
436
444
|
* @summary Update the product language
|
|
437
445
|
* @param {UpdateProductLanguageRequestDto} updateProductLanguageRequestDto
|
|
438
446
|
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
@@ -481,7 +489,7 @@ var TranslationApiAxiosParamCreator = function (configuration) {
|
|
|
481
489
|
});
|
|
482
490
|
},
|
|
483
491
|
/**
|
|
484
|
-
* This uploads the translations for a given product.
|
|
492
|
+
* This uploads the translations for a given product. **Required Permissions** \"translation-management.translations.create\"
|
|
485
493
|
* @summary Create the product translations
|
|
486
494
|
* @param {string} productSlug
|
|
487
495
|
* @param {'German' | 'English' | 'Polish' | 'French' | 'Italian' | 'Spanish' | 'Portuguese' | 'Russian' | 'Japanese' | 'Chinese' | 'Korean' | 'Turkish' | 'Arabic' | 'Hindi' | 'Indonesian' | 'Thai' | 'Vietnamese' | 'Persian' | 'Romanian'} language
|
|
@@ -552,7 +560,7 @@ var TranslationApiFp = function (configuration) {
|
|
|
552
560
|
var localVarAxiosParamCreator = (0, exports.TranslationApiAxiosParamCreator)(configuration);
|
|
553
561
|
return {
|
|
554
562
|
/**
|
|
555
|
-
* This creates a product language.
|
|
563
|
+
* This creates a product language. **Required Permissions** \"translation-management.translations.create\"
|
|
556
564
|
* @summary Create the product language
|
|
557
565
|
* @param {CreateProductLanguageRequestDto} createProductLanguageRequestDto
|
|
558
566
|
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
@@ -573,7 +581,7 @@ var TranslationApiFp = function (configuration) {
|
|
|
573
581
|
});
|
|
574
582
|
},
|
|
575
583
|
/**
|
|
576
|
-
* Permanently deletes the product language. Supply the unique id that was returned when you created the product language and this will delete it.
|
|
584
|
+
* Permanently deletes the product language. Supply the unique id that was returned when you created the product language and this will delete it. **Required Permissions** \"translation-management.translations.delete\"
|
|
577
585
|
* @summary Delete the product language
|
|
578
586
|
* @param {number} id Id of the product language.
|
|
579
587
|
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
@@ -594,7 +602,7 @@ var TranslationApiFp = function (configuration) {
|
|
|
594
602
|
});
|
|
595
603
|
},
|
|
596
604
|
/**
|
|
597
|
-
* This downloads the list of translatable fields for a given product.
|
|
605
|
+
* This downloads the list of translatable fields for a given product. **Required Permissions** \"translation-management.translations.view\"
|
|
598
606
|
* @summary Retrieve the product translations
|
|
599
607
|
* @param {string} productSlug
|
|
600
608
|
* @param {'German' | 'English' | 'Polish' | 'French' | 'Italian' | 'Spanish' | 'Portuguese' | 'Russian' | 'Japanese' | 'Chinese' | 'Korean' | 'Turkish' | 'Arabic' | 'Hindi' | 'Indonesian' | 'Thai' | 'Vietnamese' | 'Persian' | 'Romanian'} language
|
|
@@ -616,7 +624,7 @@ var TranslationApiFp = function (configuration) {
|
|
|
616
624
|
});
|
|
617
625
|
},
|
|
618
626
|
/**
|
|
619
|
-
* This gets a product language.
|
|
627
|
+
* This gets a product language. **Required Permissions** \"translation-management.translations.view\"
|
|
620
628
|
* @summary Retrieve the product language
|
|
621
629
|
* @param {number} id Id of the product language.
|
|
622
630
|
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
@@ -637,24 +645,25 @@ var TranslationApiFp = function (configuration) {
|
|
|
637
645
|
});
|
|
638
646
|
},
|
|
639
647
|
/**
|
|
640
|
-
*
|
|
648
|
+
* Returns a list of product languages you have previously created. The product languages are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation. **Required Permissions** \"translation-management.translations.view\"
|
|
641
649
|
* @summary List product languages
|
|
642
650
|
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
643
|
-
* @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and
|
|
644
|
-
* @param {string} [pageToken] A cursor for use in pagination. pageToken is an ID that defines your place in the list. For instance, if you make a list request and receive 100 objects and pageToken=1,
|
|
645
|
-
* @param {
|
|
646
|
-
* @param {
|
|
647
|
-
* @param {
|
|
648
|
-
* @param {
|
|
651
|
+
* @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
|
|
652
|
+
* @param {string} [pageToken] A cursor for use in pagination. pageToken is an ID that defines your place in the list. For instance, if you make a list request and receive 100 objects and pageToken=1, your subsequent call can include pageToken=2 in order to fetch the next page of the list.
|
|
653
|
+
* @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.<br/> <br/> <i>Allowed values: id, productSlug, language, isActive, translationStatus, createdAt, updateAt</i>
|
|
654
|
+
* @param {string} [search] Search the response for matches in any searchable field. Use filter instead where possible for improved performance.<br/> <br/> <i>Searchable fields: id, language</i>
|
|
655
|
+
* @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.<br/> <br/> <i>Allowed values: id, language, isActive, translationStatus, createdAt, updatedAt</i>
|
|
656
|
+
* @param {string} [expand] Expand to fetch additional information about the list items. Expanding resources can reduce the number of API calls required to accomplish a task. Use with discretion as some expanded fields can drastically increase payload size.<br/> <br/>
|
|
657
|
+
* @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.<br/> <br/> <i>Allowed values: id, productSlug, language, isActive, translationStatus, createdAt, updateAt</i>
|
|
649
658
|
* @param {*} [options] Override http request option.
|
|
650
659
|
* @throws {RequiredError}
|
|
651
660
|
*/
|
|
652
|
-
listProductLanguages: function (authorization, pageSize, pageToken, filter, search, order, expand, options) {
|
|
661
|
+
listProductLanguages: function (authorization, pageSize, pageToken, filter, search, order, expand, filters, options) {
|
|
653
662
|
return __awaiter(this, void 0, void 0, function () {
|
|
654
663
|
var localVarAxiosArgs;
|
|
655
664
|
return __generator(this, function (_a) {
|
|
656
665
|
switch (_a.label) {
|
|
657
|
-
case 0: return [4 /*yield*/, localVarAxiosParamCreator.listProductLanguages(authorization, pageSize, pageToken, filter, search, order, expand, options)];
|
|
666
|
+
case 0: return [4 /*yield*/, localVarAxiosParamCreator.listProductLanguages(authorization, pageSize, pageToken, filter, search, order, expand, filters, options)];
|
|
658
667
|
case 1:
|
|
659
668
|
localVarAxiosArgs = _a.sent();
|
|
660
669
|
return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
|
|
@@ -663,24 +672,25 @@ var TranslationApiFp = function (configuration) {
|
|
|
663
672
|
});
|
|
664
673
|
},
|
|
665
674
|
/**
|
|
666
|
-
* Returns a list of translations you have previously created.
|
|
675
|
+
* Returns a list of translations you have previously created. The translations are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation. **Required Permissions** \"translation-management.translations.view\"
|
|
667
676
|
* @summary List translations
|
|
668
677
|
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
669
|
-
* @param {
|
|
670
|
-
* @param {
|
|
671
|
-
* @param {
|
|
672
|
-
* @param {
|
|
673
|
-
* @param {
|
|
674
|
-
* @param {
|
|
678
|
+
* @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
|
|
679
|
+
* @param {string} [pageToken] A cursor for use in pagination. pageToken is an ID that defines your place in the list. For instance, if you make a list request and receive 100 objects and pageToken=1, your subsequent call can include pageToken=2 in order to fetch the next page of the list.
|
|
680
|
+
* @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.<br/> <br/> <i>Allowed values: key</i>
|
|
681
|
+
* @param {string} [search] Search the response for matches in any searchable field. Use filter instead where possible for improved performance.<br/> <br/> <i>Searchable fields: key</i>
|
|
682
|
+
* @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.<br/> <br/> <i>Allowed values: id, createdAt, key</i>
|
|
683
|
+
* @param {string} [expand] Expand to fetch additional information about the list items. Expanding resources can reduce the number of API calls required to accomplish a task. Use with discretion as some expanded fields can drastically increase payload size.<br/> <br/>
|
|
684
|
+
* @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.<br/> <br/> <i>Allowed values: key</i>
|
|
675
685
|
* @param {*} [options] Override http request option.
|
|
676
686
|
* @throws {RequiredError}
|
|
677
687
|
*/
|
|
678
|
-
listTranslations: function (authorization, pageSize, pageToken, filter, search, order, expand, options) {
|
|
688
|
+
listTranslations: function (authorization, pageSize, pageToken, filter, search, order, expand, filters, options) {
|
|
679
689
|
return __awaiter(this, void 0, void 0, function () {
|
|
680
690
|
var localVarAxiosArgs;
|
|
681
691
|
return __generator(this, function (_a) {
|
|
682
692
|
switch (_a.label) {
|
|
683
|
-
case 0: return [4 /*yield*/, localVarAxiosParamCreator.listTranslations(authorization, pageSize, pageToken, filter, search, order, expand, options)];
|
|
693
|
+
case 0: return [4 /*yield*/, localVarAxiosParamCreator.listTranslations(authorization, pageSize, pageToken, filter, search, order, expand, filters, options)];
|
|
684
694
|
case 1:
|
|
685
695
|
localVarAxiosArgs = _a.sent();
|
|
686
696
|
return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
|
|
@@ -689,7 +699,7 @@ var TranslationApiFp = function (configuration) {
|
|
|
689
699
|
});
|
|
690
700
|
},
|
|
691
701
|
/**
|
|
692
|
-
* This updates the product language with the specified id.
|
|
702
|
+
* This updates the product language with the specified id. **Required Permissions** \"translation-management.translations.update\"
|
|
693
703
|
* @summary Update the product language
|
|
694
704
|
* @param {UpdateProductLanguageRequestDto} updateProductLanguageRequestDto
|
|
695
705
|
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
@@ -710,7 +720,7 @@ var TranslationApiFp = function (configuration) {
|
|
|
710
720
|
});
|
|
711
721
|
},
|
|
712
722
|
/**
|
|
713
|
-
* This uploads the translations for a given product.
|
|
723
|
+
* This uploads the translations for a given product. **Required Permissions** \"translation-management.translations.create\"
|
|
714
724
|
* @summary Create the product translations
|
|
715
725
|
* @param {string} productSlug
|
|
716
726
|
* @param {'German' | 'English' | 'Polish' | 'French' | 'Italian' | 'Spanish' | 'Portuguese' | 'Russian' | 'Japanese' | 'Chinese' | 'Korean' | 'Turkish' | 'Arabic' | 'Hindi' | 'Indonesian' | 'Thai' | 'Vietnamese' | 'Persian' | 'Romanian'} language
|
|
@@ -743,7 +753,7 @@ var TranslationApiFactory = function (configuration, basePath, axios) {
|
|
|
743
753
|
var localVarFp = (0, exports.TranslationApiFp)(configuration);
|
|
744
754
|
return {
|
|
745
755
|
/**
|
|
746
|
-
* This creates a product language.
|
|
756
|
+
* This creates a product language. **Required Permissions** \"translation-management.translations.create\"
|
|
747
757
|
* @summary Create the product language
|
|
748
758
|
* @param {CreateProductLanguageRequestDto} createProductLanguageRequestDto
|
|
749
759
|
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
@@ -754,7 +764,7 @@ var TranslationApiFactory = function (configuration, basePath, axios) {
|
|
|
754
764
|
return localVarFp.createProductLanguage(createProductLanguageRequestDto, authorization, options).then(function (request) { return request(axios, basePath); });
|
|
755
765
|
},
|
|
756
766
|
/**
|
|
757
|
-
* Permanently deletes the product language. Supply the unique id that was returned when you created the product language and this will delete it.
|
|
767
|
+
* Permanently deletes the product language. Supply the unique id that was returned when you created the product language and this will delete it. **Required Permissions** \"translation-management.translations.delete\"
|
|
758
768
|
* @summary Delete the product language
|
|
759
769
|
* @param {number} id Id of the product language.
|
|
760
770
|
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
@@ -765,7 +775,7 @@ var TranslationApiFactory = function (configuration, basePath, axios) {
|
|
|
765
775
|
return localVarFp.deleteProductLanguage(id, authorization, options).then(function (request) { return request(axios, basePath); });
|
|
766
776
|
},
|
|
767
777
|
/**
|
|
768
|
-
* This downloads the list of translatable fields for a given product.
|
|
778
|
+
* This downloads the list of translatable fields for a given product. **Required Permissions** \"translation-management.translations.view\"
|
|
769
779
|
* @summary Retrieve the product translations
|
|
770
780
|
* @param {string} productSlug
|
|
771
781
|
* @param {'German' | 'English' | 'Polish' | 'French' | 'Italian' | 'Spanish' | 'Portuguese' | 'Russian' | 'Japanese' | 'Chinese' | 'Korean' | 'Turkish' | 'Arabic' | 'Hindi' | 'Indonesian' | 'Thai' | 'Vietnamese' | 'Persian' | 'Romanian'} language
|
|
@@ -777,7 +787,7 @@ var TranslationApiFactory = function (configuration, basePath, axios) {
|
|
|
777
787
|
return localVarFp.downloadProductTranslations(productSlug, language, authorization, options).then(function (request) { return request(axios, basePath); });
|
|
778
788
|
},
|
|
779
789
|
/**
|
|
780
|
-
* This gets a product language.
|
|
790
|
+
* This gets a product language. **Required Permissions** \"translation-management.translations.view\"
|
|
781
791
|
* @summary Retrieve the product language
|
|
782
792
|
* @param {number} id Id of the product language.
|
|
783
793
|
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
@@ -788,39 +798,41 @@ var TranslationApiFactory = function (configuration, basePath, axios) {
|
|
|
788
798
|
return localVarFp.getProductLanguage(id, authorization, options).then(function (request) { return request(axios, basePath); });
|
|
789
799
|
},
|
|
790
800
|
/**
|
|
791
|
-
*
|
|
801
|
+
* Returns a list of product languages you have previously created. The product languages are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation. **Required Permissions** \"translation-management.translations.view\"
|
|
792
802
|
* @summary List product languages
|
|
793
803
|
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
794
|
-
* @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and
|
|
795
|
-
* @param {string} [pageToken] A cursor for use in pagination. pageToken is an ID that defines your place in the list. For instance, if you make a list request and receive 100 objects and pageToken=1,
|
|
796
|
-
* @param {
|
|
797
|
-
* @param {
|
|
798
|
-
* @param {
|
|
799
|
-
* @param {
|
|
804
|
+
* @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
|
|
805
|
+
* @param {string} [pageToken] A cursor for use in pagination. pageToken is an ID that defines your place in the list. For instance, if you make a list request and receive 100 objects and pageToken=1, your subsequent call can include pageToken=2 in order to fetch the next page of the list.
|
|
806
|
+
* @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.<br/> <br/> <i>Allowed values: id, productSlug, language, isActive, translationStatus, createdAt, updateAt</i>
|
|
807
|
+
* @param {string} [search] Search the response for matches in any searchable field. Use filter instead where possible for improved performance.<br/> <br/> <i>Searchable fields: id, language</i>
|
|
808
|
+
* @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.<br/> <br/> <i>Allowed values: id, language, isActive, translationStatus, createdAt, updatedAt</i>
|
|
809
|
+
* @param {string} [expand] Expand to fetch additional information about the list items. Expanding resources can reduce the number of API calls required to accomplish a task. Use with discretion as some expanded fields can drastically increase payload size.<br/> <br/>
|
|
810
|
+
* @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.<br/> <br/> <i>Allowed values: id, productSlug, language, isActive, translationStatus, createdAt, updateAt</i>
|
|
800
811
|
* @param {*} [options] Override http request option.
|
|
801
812
|
* @throws {RequiredError}
|
|
802
813
|
*/
|
|
803
|
-
listProductLanguages: function (authorization, pageSize, pageToken, filter, search, order, expand, options) {
|
|
804
|
-
return localVarFp.listProductLanguages(authorization, pageSize, pageToken, filter, search, order, expand, options).then(function (request) { return request(axios, basePath); });
|
|
814
|
+
listProductLanguages: function (authorization, pageSize, pageToken, filter, search, order, expand, filters, options) {
|
|
815
|
+
return localVarFp.listProductLanguages(authorization, pageSize, pageToken, filter, search, order, expand, filters, options).then(function (request) { return request(axios, basePath); });
|
|
805
816
|
},
|
|
806
817
|
/**
|
|
807
|
-
* Returns a list of translations you have previously created.
|
|
818
|
+
* Returns a list of translations you have previously created. The translations are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation. **Required Permissions** \"translation-management.translations.view\"
|
|
808
819
|
* @summary List translations
|
|
809
820
|
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
810
|
-
* @param {
|
|
811
|
-
* @param {
|
|
812
|
-
* @param {
|
|
813
|
-
* @param {
|
|
814
|
-
* @param {
|
|
815
|
-
* @param {
|
|
821
|
+
* @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
|
|
822
|
+
* @param {string} [pageToken] A cursor for use in pagination. pageToken is an ID that defines your place in the list. For instance, if you make a list request and receive 100 objects and pageToken=1, your subsequent call can include pageToken=2 in order to fetch the next page of the list.
|
|
823
|
+
* @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.<br/> <br/> <i>Allowed values: key</i>
|
|
824
|
+
* @param {string} [search] Search the response for matches in any searchable field. Use filter instead where possible for improved performance.<br/> <br/> <i>Searchable fields: key</i>
|
|
825
|
+
* @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.<br/> <br/> <i>Allowed values: id, createdAt, key</i>
|
|
826
|
+
* @param {string} [expand] Expand to fetch additional information about the list items. Expanding resources can reduce the number of API calls required to accomplish a task. Use with discretion as some expanded fields can drastically increase payload size.<br/> <br/>
|
|
827
|
+
* @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.<br/> <br/> <i>Allowed values: key</i>
|
|
816
828
|
* @param {*} [options] Override http request option.
|
|
817
829
|
* @throws {RequiredError}
|
|
818
830
|
*/
|
|
819
|
-
listTranslations: function (authorization, pageSize, pageToken, filter, search, order, expand, options) {
|
|
820
|
-
return localVarFp.listTranslations(authorization, pageSize, pageToken, filter, search, order, expand, options).then(function (request) { return request(axios, basePath); });
|
|
831
|
+
listTranslations: function (authorization, pageSize, pageToken, filter, search, order, expand, filters, options) {
|
|
832
|
+
return localVarFp.listTranslations(authorization, pageSize, pageToken, filter, search, order, expand, filters, options).then(function (request) { return request(axios, basePath); });
|
|
821
833
|
},
|
|
822
834
|
/**
|
|
823
|
-
* This updates the product language with the specified id.
|
|
835
|
+
* This updates the product language with the specified id. **Required Permissions** \"translation-management.translations.update\"
|
|
824
836
|
* @summary Update the product language
|
|
825
837
|
* @param {UpdateProductLanguageRequestDto} updateProductLanguageRequestDto
|
|
826
838
|
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
@@ -831,7 +843,7 @@ var TranslationApiFactory = function (configuration, basePath, axios) {
|
|
|
831
843
|
return localVarFp.updateProductLanguage(updateProductLanguageRequestDto, authorization, options).then(function (request) { return request(axios, basePath); });
|
|
832
844
|
},
|
|
833
845
|
/**
|
|
834
|
-
* This uploads the translations for a given product.
|
|
846
|
+
* This uploads the translations for a given product. **Required Permissions** \"translation-management.translations.create\"
|
|
835
847
|
* @summary Create the product translations
|
|
836
848
|
* @param {string} productSlug
|
|
837
849
|
* @param {'German' | 'English' | 'Polish' | 'French' | 'Italian' | 'Spanish' | 'Portuguese' | 'Russian' | 'Japanese' | 'Chinese' | 'Korean' | 'Turkish' | 'Arabic' | 'Hindi' | 'Indonesian' | 'Thai' | 'Vietnamese' | 'Persian' | 'Romanian'} language
|
|
@@ -858,7 +870,7 @@ var TranslationApi = /** @class */ (function (_super) {
|
|
|
858
870
|
return _super !== null && _super.apply(this, arguments) || this;
|
|
859
871
|
}
|
|
860
872
|
/**
|
|
861
|
-
* This creates a product language.
|
|
873
|
+
* This creates a product language. **Required Permissions** \"translation-management.translations.create\"
|
|
862
874
|
* @summary Create the product language
|
|
863
875
|
* @param {TranslationApiCreateProductLanguageRequest} requestParameters Request parameters.
|
|
864
876
|
* @param {*} [options] Override http request option.
|
|
@@ -870,7 +882,7 @@ var TranslationApi = /** @class */ (function (_super) {
|
|
|
870
882
|
return (0, exports.TranslationApiFp)(this.configuration).createProductLanguage(requestParameters.createProductLanguageRequestDto, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
871
883
|
};
|
|
872
884
|
/**
|
|
873
|
-
* Permanently deletes the product language. Supply the unique id that was returned when you created the product language and this will delete it.
|
|
885
|
+
* Permanently deletes the product language. Supply the unique id that was returned when you created the product language and this will delete it. **Required Permissions** \"translation-management.translations.delete\"
|
|
874
886
|
* @summary Delete the product language
|
|
875
887
|
* @param {TranslationApiDeleteProductLanguageRequest} requestParameters Request parameters.
|
|
876
888
|
* @param {*} [options] Override http request option.
|
|
@@ -882,7 +894,7 @@ var TranslationApi = /** @class */ (function (_super) {
|
|
|
882
894
|
return (0, exports.TranslationApiFp)(this.configuration).deleteProductLanguage(requestParameters.id, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
883
895
|
};
|
|
884
896
|
/**
|
|
885
|
-
* This downloads the list of translatable fields for a given product.
|
|
897
|
+
* This downloads the list of translatable fields for a given product. **Required Permissions** \"translation-management.translations.view\"
|
|
886
898
|
* @summary Retrieve the product translations
|
|
887
899
|
* @param {TranslationApiDownloadProductTranslationsRequest} requestParameters Request parameters.
|
|
888
900
|
* @param {*} [options] Override http request option.
|
|
@@ -894,7 +906,7 @@ var TranslationApi = /** @class */ (function (_super) {
|
|
|
894
906
|
return (0, exports.TranslationApiFp)(this.configuration).downloadProductTranslations(requestParameters.productSlug, requestParameters.language, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
895
907
|
};
|
|
896
908
|
/**
|
|
897
|
-
* This gets a product language.
|
|
909
|
+
* This gets a product language. **Required Permissions** \"translation-management.translations.view\"
|
|
898
910
|
* @summary Retrieve the product language
|
|
899
911
|
* @param {TranslationApiGetProductLanguageRequest} requestParameters Request parameters.
|
|
900
912
|
* @param {*} [options] Override http request option.
|
|
@@ -906,7 +918,7 @@ var TranslationApi = /** @class */ (function (_super) {
|
|
|
906
918
|
return (0, exports.TranslationApiFp)(this.configuration).getProductLanguage(requestParameters.id, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
907
919
|
};
|
|
908
920
|
/**
|
|
909
|
-
*
|
|
921
|
+
* Returns a list of product languages you have previously created. The product languages are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation. **Required Permissions** \"translation-management.translations.view\"
|
|
910
922
|
* @summary List product languages
|
|
911
923
|
* @param {TranslationApiListProductLanguagesRequest} requestParameters Request parameters.
|
|
912
924
|
* @param {*} [options] Override http request option.
|
|
@@ -916,10 +928,10 @@ var TranslationApi = /** @class */ (function (_super) {
|
|
|
916
928
|
TranslationApi.prototype.listProductLanguages = function (requestParameters, options) {
|
|
917
929
|
var _this = this;
|
|
918
930
|
if (requestParameters === void 0) { requestParameters = {}; }
|
|
919
|
-
return (0, exports.TranslationApiFp)(this.configuration).listProductLanguages(requestParameters.authorization, requestParameters.pageSize, requestParameters.pageToken, requestParameters.filter, requestParameters.search, requestParameters.order, requestParameters.expand, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
931
|
+
return (0, exports.TranslationApiFp)(this.configuration).listProductLanguages(requestParameters.authorization, requestParameters.pageSize, requestParameters.pageToken, requestParameters.filter, requestParameters.search, requestParameters.order, requestParameters.expand, requestParameters.filters, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
920
932
|
};
|
|
921
933
|
/**
|
|
922
|
-
* Returns a list of translations you have previously created.
|
|
934
|
+
* Returns a list of translations you have previously created. The translations are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation. **Required Permissions** \"translation-management.translations.view\"
|
|
923
935
|
* @summary List translations
|
|
924
936
|
* @param {TranslationApiListTranslationsRequest} requestParameters Request parameters.
|
|
925
937
|
* @param {*} [options] Override http request option.
|
|
@@ -929,10 +941,10 @@ var TranslationApi = /** @class */ (function (_super) {
|
|
|
929
941
|
TranslationApi.prototype.listTranslations = function (requestParameters, options) {
|
|
930
942
|
var _this = this;
|
|
931
943
|
if (requestParameters === void 0) { requestParameters = {}; }
|
|
932
|
-
return (0, exports.TranslationApiFp)(this.configuration).listTranslations(requestParameters.authorization, requestParameters.pageSize, requestParameters.pageToken, requestParameters.filter, requestParameters.search, requestParameters.order, requestParameters.expand, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
944
|
+
return (0, exports.TranslationApiFp)(this.configuration).listTranslations(requestParameters.authorization, requestParameters.pageSize, requestParameters.pageToken, requestParameters.filter, requestParameters.search, requestParameters.order, requestParameters.expand, requestParameters.filters, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
933
945
|
};
|
|
934
946
|
/**
|
|
935
|
-
* This updates the product language with the specified id.
|
|
947
|
+
* This updates the product language with the specified id. **Required Permissions** \"translation-management.translations.update\"
|
|
936
948
|
* @summary Update the product language
|
|
937
949
|
* @param {TranslationApiUpdateProductLanguageRequest} requestParameters Request parameters.
|
|
938
950
|
* @param {*} [options] Override http request option.
|
|
@@ -944,7 +956,7 @@ var TranslationApi = /** @class */ (function (_super) {
|
|
|
944
956
|
return (0, exports.TranslationApiFp)(this.configuration).updateProductLanguage(requestParameters.updateProductLanguageRequestDto, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
945
957
|
};
|
|
946
958
|
/**
|
|
947
|
-
* This uploads the translations for a given product.
|
|
959
|
+
* This uploads the translations for a given product. **Required Permissions** \"translation-management.translations.create\"
|
|
948
960
|
* @summary Create the product translations
|
|
949
961
|
* @param {TranslationApiUploadProductTranslationsRequest} requestParameters Request parameters.
|
|
950
962
|
* @param {*} [options] Override http request option.
|
package/dist/api.d.ts
CHANGED
package/dist/api.js
CHANGED
|
@@ -27,4 +27,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
27
27
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
28
28
|
};
|
|
29
29
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
30
|
+
__exportStar(require("./api/default-api"), exports);
|
|
30
31
|
__exportStar(require("./api/translation-api"), exports);
|
package/dist/base.d.ts
CHANGED
|
@@ -24,12 +24,22 @@ export declare const COLLECTION_FORMATS: {
|
|
|
24
24
|
};
|
|
25
25
|
export interface LoginClass {
|
|
26
26
|
accessToken: string;
|
|
27
|
-
permissions:
|
|
27
|
+
permissions: string;
|
|
28
|
+
}
|
|
29
|
+
export interface SwitchWorkspaceRequest {
|
|
30
|
+
username: string;
|
|
31
|
+
targetWorkspace: string;
|
|
32
|
+
}
|
|
33
|
+
export interface SwitchWorkspaceResponseClass {
|
|
34
|
+
accessToken: string;
|
|
35
|
+
permissions: string;
|
|
28
36
|
}
|
|
29
37
|
export declare enum Environment {
|
|
30
38
|
Production = "https://apiv2.emil.de",
|
|
31
39
|
Test = "https://apiv2-test.emil.de",
|
|
32
|
-
|
|
40
|
+
Staging = "https://apiv2-staging.emil.de",
|
|
41
|
+
Development = "https://apiv2-dev.emil.de",
|
|
42
|
+
ProductionZurich = "https://eu-central-2.apiv2.emil.de"
|
|
33
43
|
}
|
|
34
44
|
export declare function resetRetry(): void;
|
|
35
45
|
/**
|
|
@@ -53,12 +63,13 @@ export declare class BaseAPI {
|
|
|
53
63
|
private username?;
|
|
54
64
|
private password?;
|
|
55
65
|
constructor(configuration?: Configuration, basePath?: string, axios?: AxiosInstance);
|
|
56
|
-
initialize(env?: Environment): Promise<void>;
|
|
66
|
+
initialize(env?: Environment, targetWorkspace?: string): Promise<void>;
|
|
57
67
|
private loadCredentials;
|
|
58
68
|
private readConfigFile;
|
|
59
69
|
private readEnvVariables;
|
|
60
70
|
selectEnvironment(env: Environment): void;
|
|
61
|
-
authorize(username: string, password: string): Promise<void>;
|
|
71
|
+
authorize(username: string, password: string, targetWorkspace?: string): Promise<void>;
|
|
72
|
+
switchWorkspace(targetWorkspace: string): Promise<void>;
|
|
62
73
|
refreshTokenInternal(): Promise<string>;
|
|
63
74
|
private extractRefreshToken;
|
|
64
75
|
getConfiguration(): Configuration;
|