gs2 1.3.160 → 1.3.162
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/inventory/model/BigInventory.d.ts +36 -0
- package/inventory/model/BigInventory.js +191 -0
- package/inventory/model/BigInventory.js.map +1 -0
- package/inventory/model/BigInventory.ts +207 -0
- package/inventory/model/BigInventoryModel.d.ts +32 -0
- package/inventory/model/BigInventoryModel.js +165 -0
- package/inventory/model/BigInventoryModel.js.map +1 -0
- package/inventory/model/BigInventoryModel.ts +179 -0
- package/inventory/model/BigInventoryModelMaster.d.ts +43 -0
- package/inventory/model/BigInventoryModelMaster.js +199 -0
- package/inventory/model/BigInventoryModelMaster.js.map +1 -0
- package/inventory/model/BigInventoryModelMaster.ts +212 -0
- package/inventory/model/BigItem.d.ts +45 -0
- package/inventory/model/BigItem.js +241 -0
- package/inventory/model/BigItem.js.map +1 -0
- package/inventory/model/BigItem.ts +260 -0
- package/inventory/model/BigItemModel.d.ts +28 -0
- package/inventory/model/BigItemModel.js +163 -0
- package/inventory/model/BigItemModel.js.map +1 -0
- package/inventory/model/BigItemModel.ts +179 -0
- package/inventory/model/BigItemModelMaster.d.ts +44 -0
- package/inventory/model/BigItemModelMaster.js +219 -0
- package/inventory/model/BigItemModelMaster.js.map +1 -0
- package/inventory/model/BigItemModelMaster.ts +235 -0
- package/inventory/model/InventoryModelMaster.d.ts +4 -0
- package/inventory/model/InventoryModelMaster.js +15 -1
- package/inventory/model/InventoryModelMaster.js.map +1 -1
- package/inventory/model/InventoryModelMaster.ts +15 -1
- package/inventory/model/ItemModelMaster.d.ts +4 -0
- package/inventory/model/ItemModelMaster.js +15 -1
- package/inventory/model/ItemModelMaster.js.map +1 -1
- package/inventory/model/ItemModelMaster.ts +15 -1
- package/inventory/model/Namespace.d.ts +4 -0
- package/inventory/model/Namespace.js +15 -1
- package/inventory/model/Namespace.js.map +1 -1
- package/inventory/model/Namespace.ts +15 -1
- package/inventory/model/SimpleInventory.d.ts +9 -0
- package/inventory/model/SimpleInventory.js +37 -1
- package/inventory/model/SimpleInventory.js.map +1 -1
- package/inventory/model/SimpleInventory.ts +38 -1
- package/inventory/model/SimpleInventoryModelMaster.d.ts +4 -0
- package/inventory/model/SimpleInventoryModelMaster.js +15 -1
- package/inventory/model/SimpleInventoryModelMaster.js.map +1 -1
- package/inventory/model/SimpleInventoryModelMaster.ts +15 -1
- package/inventory/model/SimpleItem.d.ts +4 -0
- package/inventory/model/SimpleItem.js +15 -1
- package/inventory/model/SimpleItem.js.map +1 -1
- package/inventory/model/SimpleItem.ts +15 -1
- package/inventory/model/SimpleItemModelMaster.d.ts +4 -0
- package/inventory/model/SimpleItemModelMaster.js +15 -1
- package/inventory/model/SimpleItemModelMaster.js.map +1 -1
- package/inventory/model/SimpleItemModelMaster.ts +15 -1
- package/inventory/model/index.d.ts +7 -1
- package/inventory/model/index.js +13 -1
- package/inventory/model/index.js.map +1 -1
- package/inventory/model/index.ts +12 -0
- package/inventory/request/AcquireBigItemByStampSheetRequest.d.ts +25 -0
- package/inventory/request/AcquireBigItemByStampSheetRequest.js +83 -0
- package/inventory/request/AcquireBigItemByStampSheetRequest.js.map +1 -0
- package/inventory/request/AcquireBigItemByStampSheetRequest.ts +90 -0
- package/inventory/request/AcquireBigItemByUserIdRequest.d.ts +41 -0
- package/inventory/request/AcquireBigItemByUserIdRequest.js +137 -0
- package/inventory/request/AcquireBigItemByUserIdRequest.js.map +1 -0
- package/inventory/request/AcquireBigItemByUserIdRequest.ts +147 -0
- package/inventory/request/ConsumeBigItemByStampTaskRequest.d.ts +25 -0
- package/inventory/request/ConsumeBigItemByStampTaskRequest.js +83 -0
- package/inventory/request/ConsumeBigItemByStampTaskRequest.js.map +1 -0
- package/inventory/request/ConsumeBigItemByStampTaskRequest.ts +90 -0
- package/inventory/request/ConsumeBigItemByUserIdRequest.d.ts +41 -0
- package/inventory/request/ConsumeBigItemByUserIdRequest.js +137 -0
- package/inventory/request/ConsumeBigItemByUserIdRequest.js.map +1 -0
- package/inventory/request/ConsumeBigItemByUserIdRequest.ts +147 -0
- package/inventory/request/ConsumeBigItemRequest.d.ts +41 -0
- package/inventory/request/ConsumeBigItemRequest.js +137 -0
- package/inventory/request/ConsumeBigItemRequest.js.map +1 -0
- package/inventory/request/ConsumeBigItemRequest.ts +147 -0
- package/inventory/request/CreateBigInventoryModelMasterRequest.d.ts +33 -0
- package/inventory/request/CreateBigInventoryModelMasterRequest.js +111 -0
- package/inventory/request/CreateBigInventoryModelMasterRequest.js.map +1 -0
- package/inventory/request/CreateBigInventoryModelMasterRequest.ts +118 -0
- package/inventory/request/CreateBigItemModelMasterRequest.d.ts +37 -0
- package/inventory/request/CreateBigItemModelMasterRequest.js +125 -0
- package/inventory/request/CreateBigItemModelMasterRequest.js.map +1 -0
- package/inventory/request/CreateBigItemModelMasterRequest.ts +132 -0
- package/inventory/request/DeleteBigInventoryModelMasterRequest.d.ts +25 -0
- package/inventory/request/DeleteBigInventoryModelMasterRequest.js +83 -0
- package/inventory/request/DeleteBigInventoryModelMasterRequest.js.map +1 -0
- package/inventory/request/DeleteBigInventoryModelMasterRequest.ts +90 -0
- package/inventory/request/DeleteBigItemByUserIdRequest.d.ts +37 -0
- package/inventory/request/DeleteBigItemByUserIdRequest.js +123 -0
- package/inventory/request/DeleteBigItemByUserIdRequest.js.map +1 -0
- package/inventory/request/DeleteBigItemByUserIdRequest.ts +133 -0
- package/inventory/request/DeleteBigItemModelMasterRequest.d.ts +29 -0
- package/inventory/request/DeleteBigItemModelMasterRequest.js +97 -0
- package/inventory/request/DeleteBigItemModelMasterRequest.js.map +1 -0
- package/inventory/request/DeleteBigItemModelMasterRequest.ts +104 -0
- package/inventory/request/DescribeBigInventoryModelMastersRequest.d.ts +29 -0
- package/inventory/request/DescribeBigInventoryModelMastersRequest.js +97 -0
- package/inventory/request/DescribeBigInventoryModelMastersRequest.js.map +1 -0
- package/inventory/request/DescribeBigInventoryModelMastersRequest.ts +104 -0
- package/inventory/request/DescribeBigInventoryModelsRequest.d.ts +21 -0
- package/inventory/request/DescribeBigInventoryModelsRequest.js +69 -0
- package/inventory/request/DescribeBigInventoryModelsRequest.js.map +1 -0
- package/inventory/request/DescribeBigInventoryModelsRequest.ts +76 -0
- package/inventory/request/DescribeBigItemModelMastersRequest.d.ts +33 -0
- package/inventory/request/DescribeBigItemModelMastersRequest.js +111 -0
- package/inventory/request/DescribeBigItemModelMastersRequest.js.map +1 -0
- package/inventory/request/DescribeBigItemModelMastersRequest.ts +118 -0
- package/inventory/request/DescribeBigItemModelsRequest.d.ts +25 -0
- package/inventory/request/DescribeBigItemModelsRequest.js +83 -0
- package/inventory/request/DescribeBigItemModelsRequest.js.map +1 -0
- package/inventory/request/DescribeBigItemModelsRequest.ts +90 -0
- package/inventory/request/DescribeBigItemsByUserIdRequest.d.ts +37 -0
- package/inventory/request/DescribeBigItemsByUserIdRequest.js +125 -0
- package/inventory/request/DescribeBigItemsByUserIdRequest.js.map +1 -0
- package/inventory/request/DescribeBigItemsByUserIdRequest.ts +132 -0
- package/inventory/request/DescribeBigItemsRequest.d.ts +37 -0
- package/inventory/request/DescribeBigItemsRequest.js +125 -0
- package/inventory/request/DescribeBigItemsRequest.js.map +1 -0
- package/inventory/request/DescribeBigItemsRequest.ts +132 -0
- package/inventory/request/GetBigInventoryModelMasterRequest.d.ts +25 -0
- package/inventory/request/GetBigInventoryModelMasterRequest.js +83 -0
- package/inventory/request/GetBigInventoryModelMasterRequest.js.map +1 -0
- package/inventory/request/GetBigInventoryModelMasterRequest.ts +90 -0
- package/inventory/request/GetBigInventoryModelRequest.d.ts +25 -0
- package/inventory/request/GetBigInventoryModelRequest.js +83 -0
- package/inventory/request/GetBigInventoryModelRequest.js.map +1 -0
- package/inventory/request/GetBigInventoryModelRequest.ts +90 -0
- package/inventory/request/GetBigItemByUserIdRequest.d.ts +33 -0
- package/inventory/request/GetBigItemByUserIdRequest.js +111 -0
- package/inventory/request/GetBigItemByUserIdRequest.js.map +1 -0
- package/inventory/request/GetBigItemByUserIdRequest.ts +118 -0
- package/inventory/request/GetBigItemModelMasterRequest.d.ts +29 -0
- package/inventory/request/GetBigItemModelMasterRequest.js +97 -0
- package/inventory/request/GetBigItemModelMasterRequest.js.map +1 -0
- package/inventory/request/GetBigItemModelMasterRequest.ts +104 -0
- package/inventory/request/GetBigItemModelRequest.d.ts +29 -0
- package/inventory/request/GetBigItemModelRequest.js +97 -0
- package/inventory/request/GetBigItemModelRequest.js.map +1 -0
- package/inventory/request/GetBigItemModelRequest.ts +104 -0
- package/inventory/request/GetBigItemRequest.d.ts +33 -0
- package/inventory/request/GetBigItemRequest.js +111 -0
- package/inventory/request/GetBigItemRequest.js.map +1 -0
- package/inventory/request/GetBigItemRequest.ts +118 -0
- package/inventory/request/UpdateBigInventoryModelMasterRequest.d.ts +33 -0
- package/inventory/request/UpdateBigInventoryModelMasterRequest.js +111 -0
- package/inventory/request/UpdateBigInventoryModelMasterRequest.js.map +1 -0
- package/inventory/request/UpdateBigInventoryModelMasterRequest.ts +118 -0
- package/inventory/request/UpdateBigItemModelMasterRequest.d.ts +37 -0
- package/inventory/request/UpdateBigItemModelMasterRequest.js +125 -0
- package/inventory/request/UpdateBigItemModelMasterRequest.js.map +1 -0
- package/inventory/request/UpdateBigItemModelMasterRequest.ts +132 -0
- package/inventory/request/index.d.ts +25 -1
- package/inventory/request/index.js +51 -2
- package/inventory/request/index.js.map +1 -1
- package/inventory/request/index.ts +48 -0
- package/inventory/rest.d.ts +24 -0
- package/inventory/rest.js +1154 -512
- package/inventory/rest.js.map +1 -1
- package/inventory/rest.ts +1117 -379
- package/inventory/result/AcquireBigItemByStampSheetResult.d.ts +14 -0
- package/inventory/result/AcquireBigItemByStampSheetResult.js +48 -0
- package/inventory/result/AcquireBigItemByStampSheetResult.js.map +1 -0
- package/inventory/result/AcquireBigItemByStampSheetResult.ts +48 -0
- package/inventory/result/AcquireBigItemByUserIdResult.d.ts +14 -0
- package/inventory/result/AcquireBigItemByUserIdResult.js +48 -0
- package/inventory/result/AcquireBigItemByUserIdResult.js.map +1 -0
- package/inventory/result/AcquireBigItemByUserIdResult.ts +48 -0
- package/inventory/result/ConsumeBigItemByStampTaskResult.d.ts +18 -0
- package/inventory/result/ConsumeBigItemByStampTaskResult.js +62 -0
- package/inventory/result/ConsumeBigItemByStampTaskResult.js.map +1 -0
- package/inventory/result/ConsumeBigItemByStampTaskResult.ts +65 -0
- package/inventory/result/ConsumeBigItemByUserIdResult.d.ts +14 -0
- package/inventory/result/ConsumeBigItemByUserIdResult.js +48 -0
- package/inventory/result/ConsumeBigItemByUserIdResult.js.map +1 -0
- package/inventory/result/ConsumeBigItemByUserIdResult.ts +48 -0
- package/inventory/result/ConsumeBigItemResult.d.ts +14 -0
- package/inventory/result/ConsumeBigItemResult.js +48 -0
- package/inventory/result/ConsumeBigItemResult.js.map +1 -0
- package/inventory/result/ConsumeBigItemResult.ts +48 -0
- package/inventory/result/CreateBigInventoryModelMasterResult.d.ts +14 -0
- package/inventory/result/CreateBigInventoryModelMasterResult.js +48 -0
- package/inventory/result/CreateBigInventoryModelMasterResult.js.map +1 -0
- package/inventory/result/CreateBigInventoryModelMasterResult.ts +48 -0
- package/inventory/result/CreateBigItemModelMasterResult.d.ts +14 -0
- package/inventory/result/CreateBigItemModelMasterResult.js +48 -0
- package/inventory/result/CreateBigItemModelMasterResult.js.map +1 -0
- package/inventory/result/CreateBigItemModelMasterResult.ts +48 -0
- package/inventory/result/DeleteBigInventoryModelMasterResult.d.ts +14 -0
- package/inventory/result/DeleteBigInventoryModelMasterResult.js +48 -0
- package/inventory/result/DeleteBigInventoryModelMasterResult.js.map +1 -0
- package/inventory/result/DeleteBigInventoryModelMasterResult.ts +48 -0
- package/inventory/result/DeleteBigItemByUserIdResult.d.ts +14 -0
- package/inventory/result/DeleteBigItemByUserIdResult.js +48 -0
- package/inventory/result/DeleteBigItemByUserIdResult.js.map +1 -0
- package/inventory/result/DeleteBigItemByUserIdResult.ts +48 -0
- package/inventory/result/DeleteBigItemModelMasterResult.d.ts +14 -0
- package/inventory/result/DeleteBigItemModelMasterResult.js +48 -0
- package/inventory/result/DeleteBigItemModelMasterResult.js.map +1 -0
- package/inventory/result/DeleteBigItemModelMasterResult.ts +48 -0
- package/inventory/result/DescribeBigInventoryModelMastersResult.d.ts +18 -0
- package/inventory/result/DescribeBigInventoryModelMastersResult.js +67 -0
- package/inventory/result/DescribeBigInventoryModelMastersResult.js.map +1 -0
- package/inventory/result/DescribeBigInventoryModelMastersResult.ts +73 -0
- package/inventory/result/DescribeBigInventoryModelsResult.d.ts +14 -0
- package/inventory/result/DescribeBigInventoryModelsResult.js +53 -0
- package/inventory/result/DescribeBigInventoryModelsResult.js.map +1 -0
- package/inventory/result/DescribeBigInventoryModelsResult.ts +56 -0
- package/inventory/result/DescribeBigItemModelMastersResult.d.ts +18 -0
- package/inventory/result/DescribeBigItemModelMastersResult.js +67 -0
- package/inventory/result/DescribeBigItemModelMastersResult.js.map +1 -0
- package/inventory/result/DescribeBigItemModelMastersResult.ts +73 -0
- package/inventory/result/DescribeBigItemModelsResult.d.ts +14 -0
- package/inventory/result/DescribeBigItemModelsResult.js +53 -0
- package/inventory/result/DescribeBigItemModelsResult.js.map +1 -0
- package/inventory/result/DescribeBigItemModelsResult.ts +56 -0
- package/inventory/result/DescribeBigItemsByUserIdResult.d.ts +18 -0
- package/inventory/result/DescribeBigItemsByUserIdResult.js +67 -0
- package/inventory/result/DescribeBigItemsByUserIdResult.js.map +1 -0
- package/inventory/result/DescribeBigItemsByUserIdResult.ts +73 -0
- package/inventory/result/DescribeBigItemsResult.d.ts +18 -0
- package/inventory/result/DescribeBigItemsResult.js +67 -0
- package/inventory/result/DescribeBigItemsResult.js.map +1 -0
- package/inventory/result/DescribeBigItemsResult.ts +73 -0
- package/inventory/result/GetBigInventoryModelMasterResult.d.ts +14 -0
- package/inventory/result/GetBigInventoryModelMasterResult.js +48 -0
- package/inventory/result/GetBigInventoryModelMasterResult.js.map +1 -0
- package/inventory/result/GetBigInventoryModelMasterResult.ts +48 -0
- package/inventory/result/GetBigInventoryModelResult.d.ts +14 -0
- package/inventory/result/GetBigInventoryModelResult.js +48 -0
- package/inventory/result/GetBigInventoryModelResult.js.map +1 -0
- package/inventory/result/GetBigInventoryModelResult.ts +48 -0
- package/inventory/result/GetBigItemByUserIdResult.d.ts +18 -0
- package/inventory/result/GetBigItemByUserIdResult.js +62 -0
- package/inventory/result/GetBigItemByUserIdResult.js.map +1 -0
- package/inventory/result/GetBigItemByUserIdResult.ts +65 -0
- package/inventory/result/GetBigItemModelMasterResult.d.ts +14 -0
- package/inventory/result/GetBigItemModelMasterResult.js +48 -0
- package/inventory/result/GetBigItemModelMasterResult.js.map +1 -0
- package/inventory/result/GetBigItemModelMasterResult.ts +48 -0
- package/inventory/result/GetBigItemModelResult.d.ts +14 -0
- package/inventory/result/GetBigItemModelResult.js +48 -0
- package/inventory/result/GetBigItemModelResult.js.map +1 -0
- package/inventory/result/GetBigItemModelResult.ts +48 -0
- package/inventory/result/GetBigItemResult.d.ts +18 -0
- package/inventory/result/GetBigItemResult.js +62 -0
- package/inventory/result/GetBigItemResult.js.map +1 -0
- package/inventory/result/GetBigItemResult.ts +65 -0
- package/inventory/result/UpdateBigInventoryModelMasterResult.d.ts +14 -0
- package/inventory/result/UpdateBigInventoryModelMasterResult.js +48 -0
- package/inventory/result/UpdateBigInventoryModelMasterResult.js.map +1 -0
- package/inventory/result/UpdateBigInventoryModelMasterResult.ts +48 -0
- package/inventory/result/UpdateBigItemModelMasterResult.d.ts +14 -0
- package/inventory/result/UpdateBigItemModelMasterResult.js +48 -0
- package/inventory/result/UpdateBigItemModelMasterResult.js.map +1 -0
- package/inventory/result/UpdateBigItemModelMasterResult.ts +48 -0
- package/inventory/result/index.d.ts +25 -1
- package/inventory/result/index.js +51 -2
- package/inventory/result/index.js.map +1 -1
- package/inventory/result/index.ts +48 -0
- package/package.json +1 -1
- package/project/request/WaitActivateRegionRequest.d.ts +25 -0
- package/project/request/WaitActivateRegionRequest.js +83 -0
- package/project/request/WaitActivateRegionRequest.js.map +1 -0
- package/project/request/WaitActivateRegionRequest.ts +90 -0
- package/project/request/index.d.ts +2 -1
- package/project/request/index.js +3 -1
- package/project/request/index.js.map +1 -1
- package/project/request/index.ts +2 -0
- package/project/rest.d.ts +1 -0
- package/project/rest.js +27 -0
- package/project/rest.js.map +1 -1
- package/project/rest.ts +31 -0
- package/project/result/WaitActivateRegionResult.d.ts +14 -0
- package/project/result/WaitActivateRegionResult.js +48 -0
- package/project/result/WaitActivateRegionResult.js.map +1 -0
- package/project/result/WaitActivateRegionResult.ts +48 -0
- package/project/result/index.d.ts +2 -1
- package/project/result/index.js +3 -1
- package/project/result/index.js.map +1 -1
- package/project/result/index.ts +2 -0
- package/stamina/model/MaxStaminaTable.d.ts +0 -10
- package/stamina/model/MaxStaminaTable.js +0 -81
- package/stamina/model/MaxStaminaTable.js.map +1 -1
- package/stamina/model/MaxStaminaTable.ts +0 -96
- package/stamina/model/RecoverIntervalTable.d.ts +0 -10
- package/stamina/model/RecoverIntervalTable.js +0 -81
- package/stamina/model/RecoverIntervalTable.js.map +1 -1
- package/stamina/model/RecoverIntervalTable.ts +0 -96
- package/stamina/model/RecoverValueTable.d.ts +0 -10
- package/stamina/model/RecoverValueTable.js +0 -81
- package/stamina/model/RecoverValueTable.js.map +1 -1
- package/stamina/model/RecoverValueTable.ts +0 -96
package/inventory/rest.js
CHANGED
|
@@ -894,9 +894,9 @@ var Gs2InventoryRestClient = /** @class */ (function (_super) {
|
|
|
894
894
|
throw JSON.parse(error.response.data.message);
|
|
895
895
|
});
|
|
896
896
|
};
|
|
897
|
-
Gs2InventoryRestClient.prototype.
|
|
898
|
-
var _a, _b, _c;
|
|
899
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/master/
|
|
897
|
+
Gs2InventoryRestClient.prototype.describeBigInventoryModelMasters = function (request) {
|
|
898
|
+
var _a, _b, _c, _d, _e;
|
|
899
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/master/big/inventory')
|
|
900
900
|
.replace('{service}', 'inventory')
|
|
901
901
|
.replace('{region}', this.session.region)
|
|
902
902
|
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'));
|
|
@@ -906,19 +906,21 @@ var Gs2InventoryRestClient = /** @class */ (function (_super) {
|
|
|
906
906
|
}
|
|
907
907
|
var params = {
|
|
908
908
|
'contextStack': (_c = request.getContextStack()) !== null && _c !== void 0 ? _c : null,
|
|
909
|
+
'pageToken': String((_d = request.getPageToken()) !== null && _d !== void 0 ? _d : null),
|
|
910
|
+
'limit': String((_e = request.getLimit()) !== null && _e !== void 0 ? _e : null),
|
|
909
911
|
};
|
|
910
912
|
return axios_1.default.get(url, {
|
|
911
913
|
params: params,
|
|
912
914
|
headers: headers,
|
|
913
915
|
}).then(function (response) {
|
|
914
|
-
return Result.
|
|
916
|
+
return Result.DescribeBigInventoryModelMastersResult.fromDict(response.data);
|
|
915
917
|
}).catch(function (error) {
|
|
916
918
|
throw JSON.parse(error.response.data.message);
|
|
917
919
|
});
|
|
918
920
|
};
|
|
919
|
-
Gs2InventoryRestClient.prototype.
|
|
920
|
-
var _a, _b, _c;
|
|
921
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/master')
|
|
921
|
+
Gs2InventoryRestClient.prototype.createBigInventoryModelMaster = function (request) {
|
|
922
|
+
var _a, _b, _c, _d, _e, _f;
|
|
923
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/master/big/inventory')
|
|
922
924
|
.replace('{service}', 'inventory')
|
|
923
925
|
.replace('{region}', this.session.region)
|
|
924
926
|
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'));
|
|
@@ -926,63 +928,68 @@ var Gs2InventoryRestClient = /** @class */ (function (_super) {
|
|
|
926
928
|
if (request.getRequestId()) {
|
|
927
929
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
928
930
|
}
|
|
929
|
-
var
|
|
931
|
+
var body = {
|
|
930
932
|
'contextStack': (_c = request.getContextStack()) !== null && _c !== void 0 ? _c : null,
|
|
933
|
+
'name': (_d = request.getName()) !== null && _d !== void 0 ? _d : null,
|
|
934
|
+
'description': (_e = request.getDescription()) !== null && _e !== void 0 ? _e : null,
|
|
935
|
+
'metadata': (_f = request.getMetadata()) !== null && _f !== void 0 ? _f : null,
|
|
931
936
|
};
|
|
932
|
-
return axios_1.default.
|
|
933
|
-
params: params,
|
|
937
|
+
return axios_1.default.post(url, body, {
|
|
934
938
|
headers: headers,
|
|
935
939
|
}).then(function (response) {
|
|
936
|
-
return Result.
|
|
940
|
+
return Result.CreateBigInventoryModelMasterResult.fromDict(response.data);
|
|
937
941
|
}).catch(function (error) {
|
|
938
|
-
|
|
942
|
+
if (error.response) {
|
|
943
|
+
throw JSON.parse(error.response.data.message);
|
|
944
|
+
}
|
|
945
|
+
else {
|
|
946
|
+
throw [];
|
|
947
|
+
}
|
|
939
948
|
});
|
|
940
949
|
};
|
|
941
|
-
Gs2InventoryRestClient.prototype.
|
|
942
|
-
var _a, _b, _c, _d;
|
|
943
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/master')
|
|
950
|
+
Gs2InventoryRestClient.prototype.getBigInventoryModelMaster = function (request) {
|
|
951
|
+
var _a, _b, _c, _d, _e;
|
|
952
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/master/big/inventory/{inventoryName}')
|
|
944
953
|
.replace('{service}', 'inventory')
|
|
945
954
|
.replace('{region}', this.session.region)
|
|
946
|
-
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
955
|
+
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
956
|
+
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'));
|
|
947
957
|
var headers = this.createAuthorizedHeaders();
|
|
948
958
|
if (request.getRequestId()) {
|
|
949
959
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
950
960
|
}
|
|
951
|
-
var
|
|
952
|
-
'contextStack': (
|
|
953
|
-
'settings': (_d = request.getSettings()) !== null && _d !== void 0 ? _d : null,
|
|
961
|
+
var params = {
|
|
962
|
+
'contextStack': (_e = request.getContextStack()) !== null && _e !== void 0 ? _e : null,
|
|
954
963
|
};
|
|
955
|
-
return axios_1.default.
|
|
964
|
+
return axios_1.default.get(url, {
|
|
965
|
+
params: params,
|
|
956
966
|
headers: headers,
|
|
957
967
|
}).then(function (response) {
|
|
958
|
-
return Result.
|
|
968
|
+
return Result.GetBigInventoryModelMasterResult.fromDict(response.data);
|
|
959
969
|
}).catch(function (error) {
|
|
960
|
-
|
|
961
|
-
throw JSON.parse(error.response.data.message);
|
|
962
|
-
}
|
|
963
|
-
else {
|
|
964
|
-
throw [];
|
|
965
|
-
}
|
|
970
|
+
throw JSON.parse(error.response.data.message);
|
|
966
971
|
});
|
|
967
972
|
};
|
|
968
|
-
Gs2InventoryRestClient.prototype.
|
|
969
|
-
var _a, _b, _c, _d, _e;
|
|
970
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/master/
|
|
973
|
+
Gs2InventoryRestClient.prototype.updateBigInventoryModelMaster = function (request) {
|
|
974
|
+
var _a, _b, _c, _d, _e, _f, _g;
|
|
975
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/master/big/inventory/{inventoryName}')
|
|
971
976
|
.replace('{service}', 'inventory')
|
|
972
977
|
.replace('{region}', this.session.region)
|
|
973
|
-
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
978
|
+
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
979
|
+
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'));
|
|
974
980
|
var headers = this.createAuthorizedHeaders();
|
|
975
981
|
if (request.getRequestId()) {
|
|
976
982
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
977
983
|
}
|
|
978
984
|
var body = {
|
|
979
|
-
'contextStack': (
|
|
980
|
-
'
|
|
985
|
+
'contextStack': (_e = request.getContextStack()) !== null && _e !== void 0 ? _e : null,
|
|
986
|
+
'description': (_f = request.getDescription()) !== null && _f !== void 0 ? _f : null,
|
|
987
|
+
'metadata': (_g = request.getMetadata()) !== null && _g !== void 0 ? _g : null,
|
|
981
988
|
};
|
|
982
989
|
return axios_1.default.put(url, body, {
|
|
983
990
|
headers: headers,
|
|
984
991
|
}).then(function (response) {
|
|
985
|
-
return Result.
|
|
992
|
+
return Result.UpdateBigInventoryModelMasterResult.fromDict(response.data);
|
|
986
993
|
}).catch(function (error) {
|
|
987
994
|
if (error.response) {
|
|
988
995
|
throw JSON.parse(error.response.data.message);
|
|
@@ -992,61 +999,54 @@ var Gs2InventoryRestClient = /** @class */ (function (_super) {
|
|
|
992
999
|
}
|
|
993
1000
|
});
|
|
994
1001
|
};
|
|
995
|
-
Gs2InventoryRestClient.prototype.
|
|
996
|
-
var _a, _b, _c, _d, _e
|
|
997
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/
|
|
1002
|
+
Gs2InventoryRestClient.prototype.deleteBigInventoryModelMaster = function (request) {
|
|
1003
|
+
var _a, _b, _c, _d, _e;
|
|
1004
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/master/big/inventory/{inventoryName}')
|
|
998
1005
|
.replace('{service}', 'inventory')
|
|
999
1006
|
.replace('{region}', this.session.region)
|
|
1000
|
-
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1007
|
+
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1008
|
+
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'));
|
|
1001
1009
|
var headers = this.createAuthorizedHeaders();
|
|
1002
1010
|
if (request.getRequestId()) {
|
|
1003
1011
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1004
1012
|
}
|
|
1005
|
-
if (request.getAccessToken()) {
|
|
1006
|
-
headers['X-GS2-ACCESS-TOKEN'] = (_c = request.getAccessToken()) !== null && _c !== void 0 ? _c : null;
|
|
1007
|
-
}
|
|
1008
1013
|
var params = {
|
|
1009
|
-
'contextStack': (
|
|
1010
|
-
'pageToken': String((_e = request.getPageToken()) !== null && _e !== void 0 ? _e : null),
|
|
1011
|
-
'limit': String((_f = request.getLimit()) !== null && _f !== void 0 ? _f : null),
|
|
1014
|
+
'contextStack': (_e = request.getContextStack()) !== null && _e !== void 0 ? _e : null,
|
|
1012
1015
|
};
|
|
1013
|
-
return axios_1.default.
|
|
1016
|
+
return axios_1.default.delete(url, {
|
|
1014
1017
|
params: params,
|
|
1015
1018
|
headers: headers,
|
|
1016
1019
|
}).then(function (response) {
|
|
1017
|
-
return Result.
|
|
1020
|
+
return Result.DeleteBigInventoryModelMasterResult.fromDict(response.data);
|
|
1018
1021
|
}).catch(function (error) {
|
|
1019
1022
|
throw JSON.parse(error.response.data.message);
|
|
1020
1023
|
});
|
|
1021
1024
|
};
|
|
1022
|
-
Gs2InventoryRestClient.prototype.
|
|
1023
|
-
var _a, _b, _c
|
|
1024
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/
|
|
1025
|
+
Gs2InventoryRestClient.prototype.describeBigInventoryModels = function (request) {
|
|
1026
|
+
var _a, _b, _c;
|
|
1027
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/big/inventory')
|
|
1025
1028
|
.replace('{service}', 'inventory')
|
|
1026
1029
|
.replace('{region}', this.session.region)
|
|
1027
|
-
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1028
|
-
.replace('{userId}', String((_c = request.getUserId()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getUserId()) !== null && _d !== void 0 ? _d : 'null'));
|
|
1030
|
+
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'));
|
|
1029
1031
|
var headers = this.createAuthorizedHeaders();
|
|
1030
1032
|
if (request.getRequestId()) {
|
|
1031
1033
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1032
1034
|
}
|
|
1033
1035
|
var params = {
|
|
1034
|
-
'contextStack': (
|
|
1035
|
-
'pageToken': String((_f = request.getPageToken()) !== null && _f !== void 0 ? _f : null),
|
|
1036
|
-
'limit': String((_g = request.getLimit()) !== null && _g !== void 0 ? _g : null),
|
|
1036
|
+
'contextStack': (_c = request.getContextStack()) !== null && _c !== void 0 ? _c : null,
|
|
1037
1037
|
};
|
|
1038
1038
|
return axios_1.default.get(url, {
|
|
1039
1039
|
params: params,
|
|
1040
1040
|
headers: headers,
|
|
1041
1041
|
}).then(function (response) {
|
|
1042
|
-
return Result.
|
|
1042
|
+
return Result.DescribeBigInventoryModelsResult.fromDict(response.data);
|
|
1043
1043
|
}).catch(function (error) {
|
|
1044
1044
|
throw JSON.parse(error.response.data.message);
|
|
1045
1045
|
});
|
|
1046
1046
|
};
|
|
1047
|
-
Gs2InventoryRestClient.prototype.
|
|
1048
|
-
var _a, _b, _c, _d, _e
|
|
1049
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/
|
|
1047
|
+
Gs2InventoryRestClient.prototype.getBigInventoryModel = function (request) {
|
|
1048
|
+
var _a, _b, _c, _d, _e;
|
|
1049
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/big/inventory/{inventoryName}')
|
|
1050
1050
|
.replace('{service}', 'inventory')
|
|
1051
1051
|
.replace('{region}', this.session.region)
|
|
1052
1052
|
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
@@ -1055,100 +1055,64 @@ var Gs2InventoryRestClient = /** @class */ (function (_super) {
|
|
|
1055
1055
|
if (request.getRequestId()) {
|
|
1056
1056
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1057
1057
|
}
|
|
1058
|
-
if (request.getAccessToken()) {
|
|
1059
|
-
headers['X-GS2-ACCESS-TOKEN'] = (_e = request.getAccessToken()) !== null && _e !== void 0 ? _e : null;
|
|
1060
|
-
}
|
|
1061
1058
|
var params = {
|
|
1062
|
-
'contextStack': (
|
|
1059
|
+
'contextStack': (_e = request.getContextStack()) !== null && _e !== void 0 ? _e : null,
|
|
1063
1060
|
};
|
|
1064
1061
|
return axios_1.default.get(url, {
|
|
1065
1062
|
params: params,
|
|
1066
1063
|
headers: headers,
|
|
1067
1064
|
}).then(function (response) {
|
|
1068
|
-
return Result.
|
|
1065
|
+
return Result.GetBigInventoryModelResult.fromDict(response.data);
|
|
1069
1066
|
}).catch(function (error) {
|
|
1070
1067
|
throw JSON.parse(error.response.data.message);
|
|
1071
1068
|
});
|
|
1072
1069
|
};
|
|
1073
|
-
Gs2InventoryRestClient.prototype.
|
|
1070
|
+
Gs2InventoryRestClient.prototype.describeBigItemModelMasters = function (request) {
|
|
1074
1071
|
var _a, _b, _c, _d, _e, _f, _g;
|
|
1075
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/
|
|
1072
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/master/big/inventory/{inventoryName}/item')
|
|
1076
1073
|
.replace('{service}', 'inventory')
|
|
1077
1074
|
.replace('{region}', this.session.region)
|
|
1078
1075
|
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1079
|
-
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1080
|
-
.replace('{userId}', String((_e = request.getUserId()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getUserId()) !== null && _f !== void 0 ? _f : 'null'));
|
|
1076
|
+
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'));
|
|
1081
1077
|
var headers = this.createAuthorizedHeaders();
|
|
1082
1078
|
if (request.getRequestId()) {
|
|
1083
1079
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1084
1080
|
}
|
|
1085
1081
|
var params = {
|
|
1086
|
-
'contextStack': (
|
|
1082
|
+
'contextStack': (_e = request.getContextStack()) !== null && _e !== void 0 ? _e : null,
|
|
1083
|
+
'pageToken': String((_f = request.getPageToken()) !== null && _f !== void 0 ? _f : null),
|
|
1084
|
+
'limit': String((_g = request.getLimit()) !== null && _g !== void 0 ? _g : null),
|
|
1087
1085
|
};
|
|
1088
1086
|
return axios_1.default.get(url, {
|
|
1089
1087
|
params: params,
|
|
1090
1088
|
headers: headers,
|
|
1091
1089
|
}).then(function (response) {
|
|
1092
|
-
return Result.
|
|
1090
|
+
return Result.DescribeBigItemModelMastersResult.fromDict(response.data);
|
|
1093
1091
|
}).catch(function (error) {
|
|
1094
1092
|
throw JSON.parse(error.response.data.message);
|
|
1095
1093
|
});
|
|
1096
1094
|
};
|
|
1097
|
-
Gs2InventoryRestClient.prototype.
|
|
1098
|
-
var _a, _b, _c, _d, _e, _f, _g, _h
|
|
1099
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/
|
|
1095
|
+
Gs2InventoryRestClient.prototype.createBigItemModelMaster = function (request) {
|
|
1096
|
+
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
1097
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/master/big/inventory/{inventoryName}/item')
|
|
1100
1098
|
.replace('{service}', 'inventory')
|
|
1101
1099
|
.replace('{region}', this.session.region)
|
|
1102
1100
|
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1103
|
-
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1104
|
-
.replace('{userId}', String((_e = request.getUserId()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getUserId()) !== null && _f !== void 0 ? _f : 'null'));
|
|
1101
|
+
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'));
|
|
1105
1102
|
var headers = this.createAuthorizedHeaders();
|
|
1106
1103
|
if (request.getRequestId()) {
|
|
1107
1104
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1108
1105
|
}
|
|
1109
|
-
if (request.getDuplicationAvoider()) {
|
|
1110
|
-
headers['X-GS2-DUPLICATION-AVOIDER'] = (_g = request.getDuplicationAvoider()) !== null && _g !== void 0 ? _g : null;
|
|
1111
|
-
}
|
|
1112
1106
|
var body = {
|
|
1113
|
-
'contextStack': (
|
|
1114
|
-
'
|
|
1107
|
+
'contextStack': (_e = request.getContextStack()) !== null && _e !== void 0 ? _e : null,
|
|
1108
|
+
'name': (_f = request.getName()) !== null && _f !== void 0 ? _f : null,
|
|
1109
|
+
'description': (_g = request.getDescription()) !== null && _g !== void 0 ? _g : null,
|
|
1110
|
+
'metadata': (_h = request.getMetadata()) !== null && _h !== void 0 ? _h : null,
|
|
1115
1111
|
};
|
|
1116
1112
|
return axios_1.default.post(url, body, {
|
|
1117
1113
|
headers: headers,
|
|
1118
1114
|
}).then(function (response) {
|
|
1119
|
-
return Result.
|
|
1120
|
-
}).catch(function (error) {
|
|
1121
|
-
if (error.response) {
|
|
1122
|
-
throw JSON.parse(error.response.data.message);
|
|
1123
|
-
}
|
|
1124
|
-
else {
|
|
1125
|
-
throw [];
|
|
1126
|
-
}
|
|
1127
|
-
});
|
|
1128
|
-
};
|
|
1129
|
-
Gs2InventoryRestClient.prototype.setCapacityByUserId = function (request) {
|
|
1130
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
1131
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/inventory/{inventoryName}/capacity')
|
|
1132
|
-
.replace('{service}', 'inventory')
|
|
1133
|
-
.replace('{region}', this.session.region)
|
|
1134
|
-
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1135
|
-
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1136
|
-
.replace('{userId}', String((_e = request.getUserId()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getUserId()) !== null && _f !== void 0 ? _f : 'null'));
|
|
1137
|
-
var headers = this.createAuthorizedHeaders();
|
|
1138
|
-
if (request.getRequestId()) {
|
|
1139
|
-
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1140
|
-
}
|
|
1141
|
-
if (request.getDuplicationAvoider()) {
|
|
1142
|
-
headers['X-GS2-DUPLICATION-AVOIDER'] = (_g = request.getDuplicationAvoider()) !== null && _g !== void 0 ? _g : null;
|
|
1143
|
-
}
|
|
1144
|
-
var body = {
|
|
1145
|
-
'contextStack': (_h = request.getContextStack()) !== null && _h !== void 0 ? _h : null,
|
|
1146
|
-
'newCapacityValue': (_j = request.getNewCapacityValue()) !== null && _j !== void 0 ? _j : null,
|
|
1147
|
-
};
|
|
1148
|
-
return axios_1.default.put(url, body, {
|
|
1149
|
-
headers: headers,
|
|
1150
|
-
}).then(function (response) {
|
|
1151
|
-
return Result.SetCapacityByUserIdResult.fromDict(response.data);
|
|
1115
|
+
return Result.CreateBigItemModelMasterResult.fromDict(response.data);
|
|
1152
1116
|
}).catch(function (error) {
|
|
1153
1117
|
if (error.response) {
|
|
1154
1118
|
throw JSON.parse(error.response.data.message);
|
|
@@ -1158,51 +1122,51 @@ var Gs2InventoryRestClient = /** @class */ (function (_super) {
|
|
|
1158
1122
|
}
|
|
1159
1123
|
});
|
|
1160
1124
|
};
|
|
1161
|
-
Gs2InventoryRestClient.prototype.
|
|
1162
|
-
var _a, _b, _c, _d, _e, _f, _g
|
|
1163
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/
|
|
1125
|
+
Gs2InventoryRestClient.prototype.getBigItemModelMaster = function (request) {
|
|
1126
|
+
var _a, _b, _c, _d, _e, _f, _g;
|
|
1127
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/master/big/inventory/{inventoryName}/item/{itemName}')
|
|
1164
1128
|
.replace('{service}', 'inventory')
|
|
1165
1129
|
.replace('{region}', this.session.region)
|
|
1166
1130
|
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1167
1131
|
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1168
|
-
.replace('{
|
|
1132
|
+
.replace('{itemName}', String((_e = request.getItemName()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getItemName()) !== null && _f !== void 0 ? _f : 'null'));
|
|
1169
1133
|
var headers = this.createAuthorizedHeaders();
|
|
1170
1134
|
if (request.getRequestId()) {
|
|
1171
1135
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1172
1136
|
}
|
|
1173
|
-
if (request.getDuplicationAvoider()) {
|
|
1174
|
-
headers['X-GS2-DUPLICATION-AVOIDER'] = (_g = request.getDuplicationAvoider()) !== null && _g !== void 0 ? _g : null;
|
|
1175
|
-
}
|
|
1176
1137
|
var params = {
|
|
1177
|
-
'contextStack': (
|
|
1138
|
+
'contextStack': (_g = request.getContextStack()) !== null && _g !== void 0 ? _g : null,
|
|
1178
1139
|
};
|
|
1179
|
-
return axios_1.default.
|
|
1140
|
+
return axios_1.default.get(url, {
|
|
1180
1141
|
params: params,
|
|
1181
1142
|
headers: headers,
|
|
1182
1143
|
}).then(function (response) {
|
|
1183
|
-
return Result.
|
|
1144
|
+
return Result.GetBigItemModelMasterResult.fromDict(response.data);
|
|
1184
1145
|
}).catch(function (error) {
|
|
1185
1146
|
throw JSON.parse(error.response.data.message);
|
|
1186
1147
|
});
|
|
1187
1148
|
};
|
|
1188
|
-
Gs2InventoryRestClient.prototype.
|
|
1189
|
-
var _a, _b, _c;
|
|
1190
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/
|
|
1149
|
+
Gs2InventoryRestClient.prototype.updateBigItemModelMaster = function (request) {
|
|
1150
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
1151
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/master/big/inventory/{inventoryName}/item/{itemName}')
|
|
1191
1152
|
.replace('{service}', 'inventory')
|
|
1192
|
-
.replace('{region}', this.session.region)
|
|
1153
|
+
.replace('{region}', this.session.region)
|
|
1154
|
+
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1155
|
+
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1156
|
+
.replace('{itemName}', String((_e = request.getItemName()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getItemName()) !== null && _f !== void 0 ? _f : 'null'));
|
|
1193
1157
|
var headers = this.createAuthorizedHeaders();
|
|
1194
1158
|
if (request.getRequestId()) {
|
|
1195
1159
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1196
1160
|
}
|
|
1197
1161
|
var body = {
|
|
1198
|
-
'contextStack': (
|
|
1199
|
-
'
|
|
1200
|
-
'
|
|
1162
|
+
'contextStack': (_g = request.getContextStack()) !== null && _g !== void 0 ? _g : null,
|
|
1163
|
+
'description': (_h = request.getDescription()) !== null && _h !== void 0 ? _h : null,
|
|
1164
|
+
'metadata': (_j = request.getMetadata()) !== null && _j !== void 0 ? _j : null,
|
|
1201
1165
|
};
|
|
1202
|
-
return axios_1.default.
|
|
1166
|
+
return axios_1.default.put(url, body, {
|
|
1203
1167
|
headers: headers,
|
|
1204
1168
|
}).then(function (response) {
|
|
1205
|
-
return Result.
|
|
1169
|
+
return Result.UpdateBigItemModelMasterResult.fromDict(response.data);
|
|
1206
1170
|
}).catch(function (error) {
|
|
1207
1171
|
if (error.response) {
|
|
1208
1172
|
throw JSON.parse(error.response.data.message);
|
|
@@ -1212,36 +1176,33 @@ var Gs2InventoryRestClient = /** @class */ (function (_super) {
|
|
|
1212
1176
|
}
|
|
1213
1177
|
});
|
|
1214
1178
|
};
|
|
1215
|
-
Gs2InventoryRestClient.prototype.
|
|
1216
|
-
var _a, _b, _c;
|
|
1217
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/
|
|
1179
|
+
Gs2InventoryRestClient.prototype.deleteBigItemModelMaster = function (request) {
|
|
1180
|
+
var _a, _b, _c, _d, _e, _f, _g;
|
|
1181
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/master/big/inventory/{inventoryName}/item/{itemName}')
|
|
1218
1182
|
.replace('{service}', 'inventory')
|
|
1219
|
-
.replace('{region}', this.session.region)
|
|
1183
|
+
.replace('{region}', this.session.region)
|
|
1184
|
+
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1185
|
+
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1186
|
+
.replace('{itemName}', String((_e = request.getItemName()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getItemName()) !== null && _f !== void 0 ? _f : 'null'));
|
|
1220
1187
|
var headers = this.createAuthorizedHeaders();
|
|
1221
1188
|
if (request.getRequestId()) {
|
|
1222
1189
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1223
1190
|
}
|
|
1224
|
-
var
|
|
1225
|
-
'contextStack': (
|
|
1226
|
-
'stampSheet': (_b = request.getStampSheet()) !== null && _b !== void 0 ? _b : null,
|
|
1227
|
-
'keyId': (_c = request.getKeyId()) !== null && _c !== void 0 ? _c : null,
|
|
1191
|
+
var params = {
|
|
1192
|
+
'contextStack': (_g = request.getContextStack()) !== null && _g !== void 0 ? _g : null,
|
|
1228
1193
|
};
|
|
1229
|
-
return axios_1.default.
|
|
1194
|
+
return axios_1.default.delete(url, {
|
|
1195
|
+
params: params,
|
|
1230
1196
|
headers: headers,
|
|
1231
1197
|
}).then(function (response) {
|
|
1232
|
-
return Result.
|
|
1198
|
+
return Result.DeleteBigItemModelMasterResult.fromDict(response.data);
|
|
1233
1199
|
}).catch(function (error) {
|
|
1234
|
-
|
|
1235
|
-
throw JSON.parse(error.response.data.message);
|
|
1236
|
-
}
|
|
1237
|
-
else {
|
|
1238
|
-
throw [];
|
|
1239
|
-
}
|
|
1200
|
+
throw JSON.parse(error.response.data.message);
|
|
1240
1201
|
});
|
|
1241
1202
|
};
|
|
1242
|
-
Gs2InventoryRestClient.prototype.
|
|
1243
|
-
var _a, _b, _c, _d, _e
|
|
1244
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/
|
|
1203
|
+
Gs2InventoryRestClient.prototype.describeBigItemModels = function (request) {
|
|
1204
|
+
var _a, _b, _c, _d, _e;
|
|
1205
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/big/inventory/{inventoryName}/item')
|
|
1245
1206
|
.replace('{service}', 'inventory')
|
|
1246
1207
|
.replace('{region}', this.session.region)
|
|
1247
1208
|
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
@@ -1250,67 +1211,459 @@ var Gs2InventoryRestClient = /** @class */ (function (_super) {
|
|
|
1250
1211
|
if (request.getRequestId()) {
|
|
1251
1212
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1252
1213
|
}
|
|
1253
|
-
if (request.getAccessToken()) {
|
|
1254
|
-
headers['X-GS2-ACCESS-TOKEN'] = (_e = request.getAccessToken()) !== null && _e !== void 0 ? _e : null;
|
|
1255
|
-
}
|
|
1256
1214
|
var params = {
|
|
1257
|
-
'contextStack': (
|
|
1258
|
-
'pageToken': String((_g = request.getPageToken()) !== null && _g !== void 0 ? _g : null),
|
|
1259
|
-
'limit': String((_h = request.getLimit()) !== null && _h !== void 0 ? _h : null),
|
|
1215
|
+
'contextStack': (_e = request.getContextStack()) !== null && _e !== void 0 ? _e : null,
|
|
1260
1216
|
};
|
|
1261
1217
|
return axios_1.default.get(url, {
|
|
1262
1218
|
params: params,
|
|
1263
1219
|
headers: headers,
|
|
1264
1220
|
}).then(function (response) {
|
|
1265
|
-
return Result.
|
|
1221
|
+
return Result.DescribeBigItemModelsResult.fromDict(response.data);
|
|
1266
1222
|
}).catch(function (error) {
|
|
1267
1223
|
throw JSON.parse(error.response.data.message);
|
|
1268
1224
|
});
|
|
1269
1225
|
};
|
|
1270
|
-
Gs2InventoryRestClient.prototype.
|
|
1271
|
-
var _a, _b, _c, _d, _e, _f, _g
|
|
1272
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/
|
|
1226
|
+
Gs2InventoryRestClient.prototype.getBigItemModel = function (request) {
|
|
1227
|
+
var _a, _b, _c, _d, _e, _f, _g;
|
|
1228
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/big/inventory/{inventoryName}/item/{itemName}')
|
|
1273
1229
|
.replace('{service}', 'inventory')
|
|
1274
1230
|
.replace('{region}', this.session.region)
|
|
1275
1231
|
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1276
1232
|
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1277
|
-
.replace('{
|
|
1233
|
+
.replace('{itemName}', String((_e = request.getItemName()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getItemName()) !== null && _f !== void 0 ? _f : 'null'));
|
|
1278
1234
|
var headers = this.createAuthorizedHeaders();
|
|
1279
1235
|
if (request.getRequestId()) {
|
|
1280
1236
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1281
1237
|
}
|
|
1282
1238
|
var params = {
|
|
1283
1239
|
'contextStack': (_g = request.getContextStack()) !== null && _g !== void 0 ? _g : null,
|
|
1284
|
-
'pageToken': String((_h = request.getPageToken()) !== null && _h !== void 0 ? _h : null),
|
|
1285
|
-
'limit': String((_j = request.getLimit()) !== null && _j !== void 0 ? _j : null),
|
|
1286
1240
|
};
|
|
1287
1241
|
return axios_1.default.get(url, {
|
|
1288
1242
|
params: params,
|
|
1289
1243
|
headers: headers,
|
|
1290
1244
|
}).then(function (response) {
|
|
1291
|
-
return Result.
|
|
1245
|
+
return Result.GetBigItemModelResult.fromDict(response.data);
|
|
1292
1246
|
}).catch(function (error) {
|
|
1293
1247
|
throw JSON.parse(error.response.data.message);
|
|
1294
1248
|
});
|
|
1295
1249
|
};
|
|
1296
|
-
Gs2InventoryRestClient.prototype.
|
|
1297
|
-
var _a, _b, _c
|
|
1298
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/
|
|
1250
|
+
Gs2InventoryRestClient.prototype.exportMaster = function (request) {
|
|
1251
|
+
var _a, _b, _c;
|
|
1252
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/master/export')
|
|
1299
1253
|
.replace('{service}', 'inventory')
|
|
1300
1254
|
.replace('{region}', this.session.region)
|
|
1301
|
-
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1302
|
-
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1303
|
-
.replace('{itemName}', String((_e = request.getItemName()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getItemName()) !== null && _f !== void 0 ? _f : 'null'));
|
|
1255
|
+
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'));
|
|
1304
1256
|
var headers = this.createAuthorizedHeaders();
|
|
1305
1257
|
if (request.getRequestId()) {
|
|
1306
1258
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1307
1259
|
}
|
|
1308
|
-
if (request.getAccessToken()) {
|
|
1309
|
-
headers['X-GS2-ACCESS-TOKEN'] = (_g = request.getAccessToken()) !== null && _g !== void 0 ? _g : null;
|
|
1310
|
-
}
|
|
1311
1260
|
var params = {
|
|
1312
|
-
'contextStack': (
|
|
1313
|
-
|
|
1261
|
+
'contextStack': (_c = request.getContextStack()) !== null && _c !== void 0 ? _c : null,
|
|
1262
|
+
};
|
|
1263
|
+
return axios_1.default.get(url, {
|
|
1264
|
+
params: params,
|
|
1265
|
+
headers: headers,
|
|
1266
|
+
}).then(function (response) {
|
|
1267
|
+
return Result.ExportMasterResult.fromDict(response.data);
|
|
1268
|
+
}).catch(function (error) {
|
|
1269
|
+
throw JSON.parse(error.response.data.message);
|
|
1270
|
+
});
|
|
1271
|
+
};
|
|
1272
|
+
Gs2InventoryRestClient.prototype.getCurrentItemModelMaster = function (request) {
|
|
1273
|
+
var _a, _b, _c;
|
|
1274
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/master')
|
|
1275
|
+
.replace('{service}', 'inventory')
|
|
1276
|
+
.replace('{region}', this.session.region)
|
|
1277
|
+
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'));
|
|
1278
|
+
var headers = this.createAuthorizedHeaders();
|
|
1279
|
+
if (request.getRequestId()) {
|
|
1280
|
+
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1281
|
+
}
|
|
1282
|
+
var params = {
|
|
1283
|
+
'contextStack': (_c = request.getContextStack()) !== null && _c !== void 0 ? _c : null,
|
|
1284
|
+
};
|
|
1285
|
+
return axios_1.default.get(url, {
|
|
1286
|
+
params: params,
|
|
1287
|
+
headers: headers,
|
|
1288
|
+
}).then(function (response) {
|
|
1289
|
+
return Result.GetCurrentItemModelMasterResult.fromDict(response.data);
|
|
1290
|
+
}).catch(function (error) {
|
|
1291
|
+
throw JSON.parse(error.response.data.message);
|
|
1292
|
+
});
|
|
1293
|
+
};
|
|
1294
|
+
Gs2InventoryRestClient.prototype.updateCurrentItemModelMaster = function (request) {
|
|
1295
|
+
var _a, _b, _c, _d;
|
|
1296
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/master')
|
|
1297
|
+
.replace('{service}', 'inventory')
|
|
1298
|
+
.replace('{region}', this.session.region)
|
|
1299
|
+
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'));
|
|
1300
|
+
var headers = this.createAuthorizedHeaders();
|
|
1301
|
+
if (request.getRequestId()) {
|
|
1302
|
+
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1303
|
+
}
|
|
1304
|
+
var body = {
|
|
1305
|
+
'contextStack': (_c = request.getContextStack()) !== null && _c !== void 0 ? _c : null,
|
|
1306
|
+
'settings': (_d = request.getSettings()) !== null && _d !== void 0 ? _d : null,
|
|
1307
|
+
};
|
|
1308
|
+
return axios_1.default.put(url, body, {
|
|
1309
|
+
headers: headers,
|
|
1310
|
+
}).then(function (response) {
|
|
1311
|
+
return Result.UpdateCurrentItemModelMasterResult.fromDict(response.data);
|
|
1312
|
+
}).catch(function (error) {
|
|
1313
|
+
if (error.response) {
|
|
1314
|
+
throw JSON.parse(error.response.data.message);
|
|
1315
|
+
}
|
|
1316
|
+
else {
|
|
1317
|
+
throw [];
|
|
1318
|
+
}
|
|
1319
|
+
});
|
|
1320
|
+
};
|
|
1321
|
+
Gs2InventoryRestClient.prototype.updateCurrentItemModelMasterFromGitHub = function (request) {
|
|
1322
|
+
var _a, _b, _c, _d, _e;
|
|
1323
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/master/from_git_hub')
|
|
1324
|
+
.replace('{service}', 'inventory')
|
|
1325
|
+
.replace('{region}', this.session.region)
|
|
1326
|
+
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'));
|
|
1327
|
+
var headers = this.createAuthorizedHeaders();
|
|
1328
|
+
if (request.getRequestId()) {
|
|
1329
|
+
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1330
|
+
}
|
|
1331
|
+
var body = {
|
|
1332
|
+
'contextStack': (_c = request.getContextStack()) !== null && _c !== void 0 ? _c : null,
|
|
1333
|
+
'checkoutSetting': (_e = (_d = request.getCheckoutSetting()) === null || _d === void 0 ? void 0 : _d.toDict()) !== null && _e !== void 0 ? _e : null,
|
|
1334
|
+
};
|
|
1335
|
+
return axios_1.default.put(url, body, {
|
|
1336
|
+
headers: headers,
|
|
1337
|
+
}).then(function (response) {
|
|
1338
|
+
return Result.UpdateCurrentItemModelMasterFromGitHubResult.fromDict(response.data);
|
|
1339
|
+
}).catch(function (error) {
|
|
1340
|
+
if (error.response) {
|
|
1341
|
+
throw JSON.parse(error.response.data.message);
|
|
1342
|
+
}
|
|
1343
|
+
else {
|
|
1344
|
+
throw [];
|
|
1345
|
+
}
|
|
1346
|
+
});
|
|
1347
|
+
};
|
|
1348
|
+
Gs2InventoryRestClient.prototype.describeInventories = function (request) {
|
|
1349
|
+
var _a, _b, _c, _d, _e, _f;
|
|
1350
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/me/inventory')
|
|
1351
|
+
.replace('{service}', 'inventory')
|
|
1352
|
+
.replace('{region}', this.session.region)
|
|
1353
|
+
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'));
|
|
1354
|
+
var headers = this.createAuthorizedHeaders();
|
|
1355
|
+
if (request.getRequestId()) {
|
|
1356
|
+
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1357
|
+
}
|
|
1358
|
+
if (request.getAccessToken()) {
|
|
1359
|
+
headers['X-GS2-ACCESS-TOKEN'] = (_c = request.getAccessToken()) !== null && _c !== void 0 ? _c : null;
|
|
1360
|
+
}
|
|
1361
|
+
var params = {
|
|
1362
|
+
'contextStack': (_d = request.getContextStack()) !== null && _d !== void 0 ? _d : null,
|
|
1363
|
+
'pageToken': String((_e = request.getPageToken()) !== null && _e !== void 0 ? _e : null),
|
|
1364
|
+
'limit': String((_f = request.getLimit()) !== null && _f !== void 0 ? _f : null),
|
|
1365
|
+
};
|
|
1366
|
+
return axios_1.default.get(url, {
|
|
1367
|
+
params: params,
|
|
1368
|
+
headers: headers,
|
|
1369
|
+
}).then(function (response) {
|
|
1370
|
+
return Result.DescribeInventoriesResult.fromDict(response.data);
|
|
1371
|
+
}).catch(function (error) {
|
|
1372
|
+
throw JSON.parse(error.response.data.message);
|
|
1373
|
+
});
|
|
1374
|
+
};
|
|
1375
|
+
Gs2InventoryRestClient.prototype.describeInventoriesByUserId = function (request) {
|
|
1376
|
+
var _a, _b, _c, _d, _e, _f, _g;
|
|
1377
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/inventory')
|
|
1378
|
+
.replace('{service}', 'inventory')
|
|
1379
|
+
.replace('{region}', this.session.region)
|
|
1380
|
+
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1381
|
+
.replace('{userId}', String((_c = request.getUserId()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getUserId()) !== null && _d !== void 0 ? _d : 'null'));
|
|
1382
|
+
var headers = this.createAuthorizedHeaders();
|
|
1383
|
+
if (request.getRequestId()) {
|
|
1384
|
+
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1385
|
+
}
|
|
1386
|
+
var params = {
|
|
1387
|
+
'contextStack': (_e = request.getContextStack()) !== null && _e !== void 0 ? _e : null,
|
|
1388
|
+
'pageToken': String((_f = request.getPageToken()) !== null && _f !== void 0 ? _f : null),
|
|
1389
|
+
'limit': String((_g = request.getLimit()) !== null && _g !== void 0 ? _g : null),
|
|
1390
|
+
};
|
|
1391
|
+
return axios_1.default.get(url, {
|
|
1392
|
+
params: params,
|
|
1393
|
+
headers: headers,
|
|
1394
|
+
}).then(function (response) {
|
|
1395
|
+
return Result.DescribeInventoriesByUserIdResult.fromDict(response.data);
|
|
1396
|
+
}).catch(function (error) {
|
|
1397
|
+
throw JSON.parse(error.response.data.message);
|
|
1398
|
+
});
|
|
1399
|
+
};
|
|
1400
|
+
Gs2InventoryRestClient.prototype.getInventory = function (request) {
|
|
1401
|
+
var _a, _b, _c, _d, _e, _f;
|
|
1402
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/me/inventory/{inventoryName}')
|
|
1403
|
+
.replace('{service}', 'inventory')
|
|
1404
|
+
.replace('{region}', this.session.region)
|
|
1405
|
+
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1406
|
+
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'));
|
|
1407
|
+
var headers = this.createAuthorizedHeaders();
|
|
1408
|
+
if (request.getRequestId()) {
|
|
1409
|
+
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1410
|
+
}
|
|
1411
|
+
if (request.getAccessToken()) {
|
|
1412
|
+
headers['X-GS2-ACCESS-TOKEN'] = (_e = request.getAccessToken()) !== null && _e !== void 0 ? _e : null;
|
|
1413
|
+
}
|
|
1414
|
+
var params = {
|
|
1415
|
+
'contextStack': (_f = request.getContextStack()) !== null && _f !== void 0 ? _f : null,
|
|
1416
|
+
};
|
|
1417
|
+
return axios_1.default.get(url, {
|
|
1418
|
+
params: params,
|
|
1419
|
+
headers: headers,
|
|
1420
|
+
}).then(function (response) {
|
|
1421
|
+
return Result.GetInventoryResult.fromDict(response.data);
|
|
1422
|
+
}).catch(function (error) {
|
|
1423
|
+
throw JSON.parse(error.response.data.message);
|
|
1424
|
+
});
|
|
1425
|
+
};
|
|
1426
|
+
Gs2InventoryRestClient.prototype.getInventoryByUserId = function (request) {
|
|
1427
|
+
var _a, _b, _c, _d, _e, _f, _g;
|
|
1428
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/inventory/{inventoryName}')
|
|
1429
|
+
.replace('{service}', 'inventory')
|
|
1430
|
+
.replace('{region}', this.session.region)
|
|
1431
|
+
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1432
|
+
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1433
|
+
.replace('{userId}', String((_e = request.getUserId()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getUserId()) !== null && _f !== void 0 ? _f : 'null'));
|
|
1434
|
+
var headers = this.createAuthorizedHeaders();
|
|
1435
|
+
if (request.getRequestId()) {
|
|
1436
|
+
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1437
|
+
}
|
|
1438
|
+
var params = {
|
|
1439
|
+
'contextStack': (_g = request.getContextStack()) !== null && _g !== void 0 ? _g : null,
|
|
1440
|
+
};
|
|
1441
|
+
return axios_1.default.get(url, {
|
|
1442
|
+
params: params,
|
|
1443
|
+
headers: headers,
|
|
1444
|
+
}).then(function (response) {
|
|
1445
|
+
return Result.GetInventoryByUserIdResult.fromDict(response.data);
|
|
1446
|
+
}).catch(function (error) {
|
|
1447
|
+
throw JSON.parse(error.response.data.message);
|
|
1448
|
+
});
|
|
1449
|
+
};
|
|
1450
|
+
Gs2InventoryRestClient.prototype.addCapacityByUserId = function (request) {
|
|
1451
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
1452
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/inventory/{inventoryName}/capacity')
|
|
1453
|
+
.replace('{service}', 'inventory')
|
|
1454
|
+
.replace('{region}', this.session.region)
|
|
1455
|
+
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1456
|
+
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1457
|
+
.replace('{userId}', String((_e = request.getUserId()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getUserId()) !== null && _f !== void 0 ? _f : 'null'));
|
|
1458
|
+
var headers = this.createAuthorizedHeaders();
|
|
1459
|
+
if (request.getRequestId()) {
|
|
1460
|
+
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1461
|
+
}
|
|
1462
|
+
if (request.getDuplicationAvoider()) {
|
|
1463
|
+
headers['X-GS2-DUPLICATION-AVOIDER'] = (_g = request.getDuplicationAvoider()) !== null && _g !== void 0 ? _g : null;
|
|
1464
|
+
}
|
|
1465
|
+
var body = {
|
|
1466
|
+
'contextStack': (_h = request.getContextStack()) !== null && _h !== void 0 ? _h : null,
|
|
1467
|
+
'addCapacityValue': (_j = request.getAddCapacityValue()) !== null && _j !== void 0 ? _j : null,
|
|
1468
|
+
};
|
|
1469
|
+
return axios_1.default.post(url, body, {
|
|
1470
|
+
headers: headers,
|
|
1471
|
+
}).then(function (response) {
|
|
1472
|
+
return Result.AddCapacityByUserIdResult.fromDict(response.data);
|
|
1473
|
+
}).catch(function (error) {
|
|
1474
|
+
if (error.response) {
|
|
1475
|
+
throw JSON.parse(error.response.data.message);
|
|
1476
|
+
}
|
|
1477
|
+
else {
|
|
1478
|
+
throw [];
|
|
1479
|
+
}
|
|
1480
|
+
});
|
|
1481
|
+
};
|
|
1482
|
+
Gs2InventoryRestClient.prototype.setCapacityByUserId = function (request) {
|
|
1483
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
1484
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/inventory/{inventoryName}/capacity')
|
|
1485
|
+
.replace('{service}', 'inventory')
|
|
1486
|
+
.replace('{region}', this.session.region)
|
|
1487
|
+
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1488
|
+
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1489
|
+
.replace('{userId}', String((_e = request.getUserId()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getUserId()) !== null && _f !== void 0 ? _f : 'null'));
|
|
1490
|
+
var headers = this.createAuthorizedHeaders();
|
|
1491
|
+
if (request.getRequestId()) {
|
|
1492
|
+
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1493
|
+
}
|
|
1494
|
+
if (request.getDuplicationAvoider()) {
|
|
1495
|
+
headers['X-GS2-DUPLICATION-AVOIDER'] = (_g = request.getDuplicationAvoider()) !== null && _g !== void 0 ? _g : null;
|
|
1496
|
+
}
|
|
1497
|
+
var body = {
|
|
1498
|
+
'contextStack': (_h = request.getContextStack()) !== null && _h !== void 0 ? _h : null,
|
|
1499
|
+
'newCapacityValue': (_j = request.getNewCapacityValue()) !== null && _j !== void 0 ? _j : null,
|
|
1500
|
+
};
|
|
1501
|
+
return axios_1.default.put(url, body, {
|
|
1502
|
+
headers: headers,
|
|
1503
|
+
}).then(function (response) {
|
|
1504
|
+
return Result.SetCapacityByUserIdResult.fromDict(response.data);
|
|
1505
|
+
}).catch(function (error) {
|
|
1506
|
+
if (error.response) {
|
|
1507
|
+
throw JSON.parse(error.response.data.message);
|
|
1508
|
+
}
|
|
1509
|
+
else {
|
|
1510
|
+
throw [];
|
|
1511
|
+
}
|
|
1512
|
+
});
|
|
1513
|
+
};
|
|
1514
|
+
Gs2InventoryRestClient.prototype.deleteInventoryByUserId = function (request) {
|
|
1515
|
+
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
1516
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/inventory/{inventoryName}')
|
|
1517
|
+
.replace('{service}', 'inventory')
|
|
1518
|
+
.replace('{region}', this.session.region)
|
|
1519
|
+
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1520
|
+
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1521
|
+
.replace('{userId}', String((_e = request.getUserId()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getUserId()) !== null && _f !== void 0 ? _f : 'null'));
|
|
1522
|
+
var headers = this.createAuthorizedHeaders();
|
|
1523
|
+
if (request.getRequestId()) {
|
|
1524
|
+
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1525
|
+
}
|
|
1526
|
+
if (request.getDuplicationAvoider()) {
|
|
1527
|
+
headers['X-GS2-DUPLICATION-AVOIDER'] = (_g = request.getDuplicationAvoider()) !== null && _g !== void 0 ? _g : null;
|
|
1528
|
+
}
|
|
1529
|
+
var params = {
|
|
1530
|
+
'contextStack': (_h = request.getContextStack()) !== null && _h !== void 0 ? _h : null,
|
|
1531
|
+
};
|
|
1532
|
+
return axios_1.default.delete(url, {
|
|
1533
|
+
params: params,
|
|
1534
|
+
headers: headers,
|
|
1535
|
+
}).then(function (response) {
|
|
1536
|
+
return Result.DeleteInventoryByUserIdResult.fromDict(response.data);
|
|
1537
|
+
}).catch(function (error) {
|
|
1538
|
+
throw JSON.parse(error.response.data.message);
|
|
1539
|
+
});
|
|
1540
|
+
};
|
|
1541
|
+
Gs2InventoryRestClient.prototype.addCapacityByStampSheet = function (request) {
|
|
1542
|
+
var _a, _b, _c;
|
|
1543
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/stamp/inventory/capacity/add')
|
|
1544
|
+
.replace('{service}', 'inventory')
|
|
1545
|
+
.replace('{region}', this.session.region);
|
|
1546
|
+
var headers = this.createAuthorizedHeaders();
|
|
1547
|
+
if (request.getRequestId()) {
|
|
1548
|
+
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1549
|
+
}
|
|
1550
|
+
var body = {
|
|
1551
|
+
'contextStack': (_a = request.getContextStack()) !== null && _a !== void 0 ? _a : null,
|
|
1552
|
+
'stampSheet': (_b = request.getStampSheet()) !== null && _b !== void 0 ? _b : null,
|
|
1553
|
+
'keyId': (_c = request.getKeyId()) !== null && _c !== void 0 ? _c : null,
|
|
1554
|
+
};
|
|
1555
|
+
return axios_1.default.post(url, body, {
|
|
1556
|
+
headers: headers,
|
|
1557
|
+
}).then(function (response) {
|
|
1558
|
+
return Result.AddCapacityByStampSheetResult.fromDict(response.data);
|
|
1559
|
+
}).catch(function (error) {
|
|
1560
|
+
if (error.response) {
|
|
1561
|
+
throw JSON.parse(error.response.data.message);
|
|
1562
|
+
}
|
|
1563
|
+
else {
|
|
1564
|
+
throw [];
|
|
1565
|
+
}
|
|
1566
|
+
});
|
|
1567
|
+
};
|
|
1568
|
+
Gs2InventoryRestClient.prototype.setCapacityByStampSheet = function (request) {
|
|
1569
|
+
var _a, _b, _c;
|
|
1570
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/stamp/inventory/capacity/set')
|
|
1571
|
+
.replace('{service}', 'inventory')
|
|
1572
|
+
.replace('{region}', this.session.region);
|
|
1573
|
+
var headers = this.createAuthorizedHeaders();
|
|
1574
|
+
if (request.getRequestId()) {
|
|
1575
|
+
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1576
|
+
}
|
|
1577
|
+
var body = {
|
|
1578
|
+
'contextStack': (_a = request.getContextStack()) !== null && _a !== void 0 ? _a : null,
|
|
1579
|
+
'stampSheet': (_b = request.getStampSheet()) !== null && _b !== void 0 ? _b : null,
|
|
1580
|
+
'keyId': (_c = request.getKeyId()) !== null && _c !== void 0 ? _c : null,
|
|
1581
|
+
};
|
|
1582
|
+
return axios_1.default.post(url, body, {
|
|
1583
|
+
headers: headers,
|
|
1584
|
+
}).then(function (response) {
|
|
1585
|
+
return Result.SetCapacityByStampSheetResult.fromDict(response.data);
|
|
1586
|
+
}).catch(function (error) {
|
|
1587
|
+
if (error.response) {
|
|
1588
|
+
throw JSON.parse(error.response.data.message);
|
|
1589
|
+
}
|
|
1590
|
+
else {
|
|
1591
|
+
throw [];
|
|
1592
|
+
}
|
|
1593
|
+
});
|
|
1594
|
+
};
|
|
1595
|
+
Gs2InventoryRestClient.prototype.describeItemSets = function (request) {
|
|
1596
|
+
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
1597
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/me/inventory/{inventoryName}/item')
|
|
1598
|
+
.replace('{service}', 'inventory')
|
|
1599
|
+
.replace('{region}', this.session.region)
|
|
1600
|
+
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1601
|
+
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'));
|
|
1602
|
+
var headers = this.createAuthorizedHeaders();
|
|
1603
|
+
if (request.getRequestId()) {
|
|
1604
|
+
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1605
|
+
}
|
|
1606
|
+
if (request.getAccessToken()) {
|
|
1607
|
+
headers['X-GS2-ACCESS-TOKEN'] = (_e = request.getAccessToken()) !== null && _e !== void 0 ? _e : null;
|
|
1608
|
+
}
|
|
1609
|
+
var params = {
|
|
1610
|
+
'contextStack': (_f = request.getContextStack()) !== null && _f !== void 0 ? _f : null,
|
|
1611
|
+
'pageToken': String((_g = request.getPageToken()) !== null && _g !== void 0 ? _g : null),
|
|
1612
|
+
'limit': String((_h = request.getLimit()) !== null && _h !== void 0 ? _h : null),
|
|
1613
|
+
};
|
|
1614
|
+
return axios_1.default.get(url, {
|
|
1615
|
+
params: params,
|
|
1616
|
+
headers: headers,
|
|
1617
|
+
}).then(function (response) {
|
|
1618
|
+
return Result.DescribeItemSetsResult.fromDict(response.data);
|
|
1619
|
+
}).catch(function (error) {
|
|
1620
|
+
throw JSON.parse(error.response.data.message);
|
|
1621
|
+
});
|
|
1622
|
+
};
|
|
1623
|
+
Gs2InventoryRestClient.prototype.describeItemSetsByUserId = function (request) {
|
|
1624
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
1625
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/inventory/{inventoryName}/item')
|
|
1626
|
+
.replace('{service}', 'inventory')
|
|
1627
|
+
.replace('{region}', this.session.region)
|
|
1628
|
+
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1629
|
+
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1630
|
+
.replace('{userId}', String((_e = request.getUserId()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getUserId()) !== null && _f !== void 0 ? _f : 'null'));
|
|
1631
|
+
var headers = this.createAuthorizedHeaders();
|
|
1632
|
+
if (request.getRequestId()) {
|
|
1633
|
+
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1634
|
+
}
|
|
1635
|
+
var params = {
|
|
1636
|
+
'contextStack': (_g = request.getContextStack()) !== null && _g !== void 0 ? _g : null,
|
|
1637
|
+
'pageToken': String((_h = request.getPageToken()) !== null && _h !== void 0 ? _h : null),
|
|
1638
|
+
'limit': String((_j = request.getLimit()) !== null && _j !== void 0 ? _j : null),
|
|
1639
|
+
};
|
|
1640
|
+
return axios_1.default.get(url, {
|
|
1641
|
+
params: params,
|
|
1642
|
+
headers: headers,
|
|
1643
|
+
}).then(function (response) {
|
|
1644
|
+
return Result.DescribeItemSetsByUserIdResult.fromDict(response.data);
|
|
1645
|
+
}).catch(function (error) {
|
|
1646
|
+
throw JSON.parse(error.response.data.message);
|
|
1647
|
+
});
|
|
1648
|
+
};
|
|
1649
|
+
Gs2InventoryRestClient.prototype.getItemSet = function (request) {
|
|
1650
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
1651
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/me/inventory/{inventoryName}/item/{itemName}')
|
|
1652
|
+
.replace('{service}', 'inventory')
|
|
1653
|
+
.replace('{region}', this.session.region)
|
|
1654
|
+
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1655
|
+
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1656
|
+
.replace('{itemName}', String((_e = request.getItemName()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getItemName()) !== null && _f !== void 0 ? _f : 'null'));
|
|
1657
|
+
var headers = this.createAuthorizedHeaders();
|
|
1658
|
+
if (request.getRequestId()) {
|
|
1659
|
+
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1660
|
+
}
|
|
1661
|
+
if (request.getAccessToken()) {
|
|
1662
|
+
headers['X-GS2-ACCESS-TOKEN'] = (_g = request.getAccessToken()) !== null && _g !== void 0 ? _g : null;
|
|
1663
|
+
}
|
|
1664
|
+
var params = {
|
|
1665
|
+
'contextStack': (_h = request.getContextStack()) !== null && _h !== void 0 ? _h : null,
|
|
1666
|
+
'itemSetName': String((_j = request.getItemSetName()) !== null && _j !== void 0 ? _j : null),
|
|
1314
1667
|
};
|
|
1315
1668
|
return axios_1.default.get(url, {
|
|
1316
1669
|
params: params,
|
|
@@ -1318,11 +1671,199 @@ var Gs2InventoryRestClient = /** @class */ (function (_super) {
|
|
|
1318
1671
|
}).then(function (response) {
|
|
1319
1672
|
return Result.GetItemSetResult.fromDict(response.data);
|
|
1320
1673
|
}).catch(function (error) {
|
|
1321
|
-
throw JSON.parse(error.response.data.message);
|
|
1674
|
+
throw JSON.parse(error.response.data.message);
|
|
1675
|
+
});
|
|
1676
|
+
};
|
|
1677
|
+
Gs2InventoryRestClient.prototype.getItemSetByUserId = function (request) {
|
|
1678
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
1679
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/inventory/{inventoryName}/item/{itemName}')
|
|
1680
|
+
.replace('{service}', 'inventory')
|
|
1681
|
+
.replace('{region}', this.session.region)
|
|
1682
|
+
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1683
|
+
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1684
|
+
.replace('{userId}', String((_e = request.getUserId()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getUserId()) !== null && _f !== void 0 ? _f : 'null'))
|
|
1685
|
+
.replace('{itemName}', String((_g = request.getItemName()) !== null && _g !== void 0 ? _g : 'null') === "" ? "null" : String((_h = request.getItemName()) !== null && _h !== void 0 ? _h : 'null'));
|
|
1686
|
+
var headers = this.createAuthorizedHeaders();
|
|
1687
|
+
if (request.getRequestId()) {
|
|
1688
|
+
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1689
|
+
}
|
|
1690
|
+
var params = {
|
|
1691
|
+
'contextStack': (_j = request.getContextStack()) !== null && _j !== void 0 ? _j : null,
|
|
1692
|
+
'itemSetName': String((_k = request.getItemSetName()) !== null && _k !== void 0 ? _k : null),
|
|
1693
|
+
};
|
|
1694
|
+
return axios_1.default.get(url, {
|
|
1695
|
+
params: params,
|
|
1696
|
+
headers: headers,
|
|
1697
|
+
}).then(function (response) {
|
|
1698
|
+
return Result.GetItemSetByUserIdResult.fromDict(response.data);
|
|
1699
|
+
}).catch(function (error) {
|
|
1700
|
+
throw JSON.parse(error.response.data.message);
|
|
1701
|
+
});
|
|
1702
|
+
};
|
|
1703
|
+
Gs2InventoryRestClient.prototype.getItemWithSignature = function (request) {
|
|
1704
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
1705
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/me/inventory/{inventoryName}/item/{itemName}/signature')
|
|
1706
|
+
.replace('{service}', 'inventory')
|
|
1707
|
+
.replace('{region}', this.session.region)
|
|
1708
|
+
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1709
|
+
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1710
|
+
.replace('{itemName}', String((_e = request.getItemName()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getItemName()) !== null && _f !== void 0 ? _f : 'null'));
|
|
1711
|
+
var headers = this.createAuthorizedHeaders();
|
|
1712
|
+
if (request.getRequestId()) {
|
|
1713
|
+
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1714
|
+
}
|
|
1715
|
+
if (request.getAccessToken()) {
|
|
1716
|
+
headers['X-GS2-ACCESS-TOKEN'] = (_g = request.getAccessToken()) !== null && _g !== void 0 ? _g : null;
|
|
1717
|
+
}
|
|
1718
|
+
var params = {
|
|
1719
|
+
'contextStack': (_h = request.getContextStack()) !== null && _h !== void 0 ? _h : null,
|
|
1720
|
+
'itemSetName': String((_j = request.getItemSetName()) !== null && _j !== void 0 ? _j : null),
|
|
1721
|
+
'keyId': String((_k = request.getKeyId()) !== null && _k !== void 0 ? _k : null),
|
|
1722
|
+
};
|
|
1723
|
+
return axios_1.default.get(url, {
|
|
1724
|
+
params: params,
|
|
1725
|
+
headers: headers,
|
|
1726
|
+
}).then(function (response) {
|
|
1727
|
+
return Result.GetItemWithSignatureResult.fromDict(response.data);
|
|
1728
|
+
}).catch(function (error) {
|
|
1729
|
+
throw JSON.parse(error.response.data.message);
|
|
1730
|
+
});
|
|
1731
|
+
};
|
|
1732
|
+
Gs2InventoryRestClient.prototype.getItemWithSignatureByUserId = function (request) {
|
|
1733
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l;
|
|
1734
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/inventory/{inventoryName}/item/{itemName}/signature')
|
|
1735
|
+
.replace('{service}', 'inventory')
|
|
1736
|
+
.replace('{region}', this.session.region)
|
|
1737
|
+
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1738
|
+
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1739
|
+
.replace('{userId}', String((_e = request.getUserId()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getUserId()) !== null && _f !== void 0 ? _f : 'null'))
|
|
1740
|
+
.replace('{itemName}', String((_g = request.getItemName()) !== null && _g !== void 0 ? _g : 'null') === "" ? "null" : String((_h = request.getItemName()) !== null && _h !== void 0 ? _h : 'null'));
|
|
1741
|
+
var headers = this.createAuthorizedHeaders();
|
|
1742
|
+
if (request.getRequestId()) {
|
|
1743
|
+
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1744
|
+
}
|
|
1745
|
+
var params = {
|
|
1746
|
+
'contextStack': (_j = request.getContextStack()) !== null && _j !== void 0 ? _j : null,
|
|
1747
|
+
'itemSetName': String((_k = request.getItemSetName()) !== null && _k !== void 0 ? _k : null),
|
|
1748
|
+
'keyId': String((_l = request.getKeyId()) !== null && _l !== void 0 ? _l : null),
|
|
1749
|
+
};
|
|
1750
|
+
return axios_1.default.get(url, {
|
|
1751
|
+
params: params,
|
|
1752
|
+
headers: headers,
|
|
1753
|
+
}).then(function (response) {
|
|
1754
|
+
return Result.GetItemWithSignatureByUserIdResult.fromDict(response.data);
|
|
1755
|
+
}).catch(function (error) {
|
|
1756
|
+
throw JSON.parse(error.response.data.message);
|
|
1757
|
+
});
|
|
1758
|
+
};
|
|
1759
|
+
Gs2InventoryRestClient.prototype.acquireItemSetByUserId = function (request) {
|
|
1760
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
|
|
1761
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/inventory/{inventoryName}/item/{itemName}/acquire')
|
|
1762
|
+
.replace('{service}', 'inventory')
|
|
1763
|
+
.replace('{region}', this.session.region)
|
|
1764
|
+
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1765
|
+
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1766
|
+
.replace('{itemName}', String((_e = request.getItemName()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getItemName()) !== null && _f !== void 0 ? _f : 'null'))
|
|
1767
|
+
.replace('{userId}', String((_g = request.getUserId()) !== null && _g !== void 0 ? _g : 'null') === "" ? "null" : String((_h = request.getUserId()) !== null && _h !== void 0 ? _h : 'null'));
|
|
1768
|
+
var headers = this.createAuthorizedHeaders();
|
|
1769
|
+
if (request.getRequestId()) {
|
|
1770
|
+
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1771
|
+
}
|
|
1772
|
+
if (request.getDuplicationAvoider()) {
|
|
1773
|
+
headers['X-GS2-DUPLICATION-AVOIDER'] = (_j = request.getDuplicationAvoider()) !== null && _j !== void 0 ? _j : null;
|
|
1774
|
+
}
|
|
1775
|
+
var body = {
|
|
1776
|
+
'contextStack': (_k = request.getContextStack()) !== null && _k !== void 0 ? _k : null,
|
|
1777
|
+
'acquireCount': (_l = request.getAcquireCount()) !== null && _l !== void 0 ? _l : null,
|
|
1778
|
+
'expiresAt': (_m = request.getExpiresAt()) !== null && _m !== void 0 ? _m : null,
|
|
1779
|
+
'createNewItemSet': (_o = request.getCreateNewItemSet()) !== null && _o !== void 0 ? _o : null,
|
|
1780
|
+
'itemSetName': (_p = request.getItemSetName()) !== null && _p !== void 0 ? _p : null,
|
|
1781
|
+
};
|
|
1782
|
+
return axios_1.default.post(url, body, {
|
|
1783
|
+
headers: headers,
|
|
1784
|
+
}).then(function (response) {
|
|
1785
|
+
return Result.AcquireItemSetByUserIdResult.fromDict(response.data);
|
|
1786
|
+
}).catch(function (error) {
|
|
1787
|
+
if (error.response) {
|
|
1788
|
+
throw JSON.parse(error.response.data.message);
|
|
1789
|
+
}
|
|
1790
|
+
else {
|
|
1791
|
+
throw [];
|
|
1792
|
+
}
|
|
1793
|
+
});
|
|
1794
|
+
};
|
|
1795
|
+
Gs2InventoryRestClient.prototype.consumeItemSet = function (request) {
|
|
1796
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l;
|
|
1797
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/me/inventory/{inventoryName}/item/{itemName}/consume')
|
|
1798
|
+
.replace('{service}', 'inventory')
|
|
1799
|
+
.replace('{region}', this.session.region)
|
|
1800
|
+
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1801
|
+
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1802
|
+
.replace('{itemName}', String((_e = request.getItemName()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getItemName()) !== null && _f !== void 0 ? _f : 'null'));
|
|
1803
|
+
var headers = this.createAuthorizedHeaders();
|
|
1804
|
+
if (request.getRequestId()) {
|
|
1805
|
+
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1806
|
+
}
|
|
1807
|
+
if (request.getAccessToken()) {
|
|
1808
|
+
headers['X-GS2-ACCESS-TOKEN'] = (_g = request.getAccessToken()) !== null && _g !== void 0 ? _g : null;
|
|
1809
|
+
}
|
|
1810
|
+
if (request.getDuplicationAvoider()) {
|
|
1811
|
+
headers['X-GS2-DUPLICATION-AVOIDER'] = (_h = request.getDuplicationAvoider()) !== null && _h !== void 0 ? _h : null;
|
|
1812
|
+
}
|
|
1813
|
+
var body = {
|
|
1814
|
+
'contextStack': (_j = request.getContextStack()) !== null && _j !== void 0 ? _j : null,
|
|
1815
|
+
'consumeCount': (_k = request.getConsumeCount()) !== null && _k !== void 0 ? _k : null,
|
|
1816
|
+
'itemSetName': (_l = request.getItemSetName()) !== null && _l !== void 0 ? _l : null,
|
|
1817
|
+
};
|
|
1818
|
+
return axios_1.default.post(url, body, {
|
|
1819
|
+
headers: headers,
|
|
1820
|
+
}).then(function (response) {
|
|
1821
|
+
return Result.ConsumeItemSetResult.fromDict(response.data);
|
|
1822
|
+
}).catch(function (error) {
|
|
1823
|
+
if (error.response) {
|
|
1824
|
+
throw JSON.parse(error.response.data.message);
|
|
1825
|
+
}
|
|
1826
|
+
else {
|
|
1827
|
+
throw [];
|
|
1828
|
+
}
|
|
1829
|
+
});
|
|
1830
|
+
};
|
|
1831
|
+
Gs2InventoryRestClient.prototype.consumeItemSetByUserId = function (request) {
|
|
1832
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m;
|
|
1833
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/inventory/{inventoryName}/item/{itemName}/consume')
|
|
1834
|
+
.replace('{service}', 'inventory')
|
|
1835
|
+
.replace('{region}', this.session.region)
|
|
1836
|
+
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1837
|
+
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1838
|
+
.replace('{userId}', String((_e = request.getUserId()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getUserId()) !== null && _f !== void 0 ? _f : 'null'))
|
|
1839
|
+
.replace('{itemName}', String((_g = request.getItemName()) !== null && _g !== void 0 ? _g : 'null') === "" ? "null" : String((_h = request.getItemName()) !== null && _h !== void 0 ? _h : 'null'));
|
|
1840
|
+
var headers = this.createAuthorizedHeaders();
|
|
1841
|
+
if (request.getRequestId()) {
|
|
1842
|
+
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1843
|
+
}
|
|
1844
|
+
if (request.getDuplicationAvoider()) {
|
|
1845
|
+
headers['X-GS2-DUPLICATION-AVOIDER'] = (_j = request.getDuplicationAvoider()) !== null && _j !== void 0 ? _j : null;
|
|
1846
|
+
}
|
|
1847
|
+
var body = {
|
|
1848
|
+
'contextStack': (_k = request.getContextStack()) !== null && _k !== void 0 ? _k : null,
|
|
1849
|
+
'consumeCount': (_l = request.getConsumeCount()) !== null && _l !== void 0 ? _l : null,
|
|
1850
|
+
'itemSetName': (_m = request.getItemSetName()) !== null && _m !== void 0 ? _m : null,
|
|
1851
|
+
};
|
|
1852
|
+
return axios_1.default.post(url, body, {
|
|
1853
|
+
headers: headers,
|
|
1854
|
+
}).then(function (response) {
|
|
1855
|
+
return Result.ConsumeItemSetByUserIdResult.fromDict(response.data);
|
|
1856
|
+
}).catch(function (error) {
|
|
1857
|
+
if (error.response) {
|
|
1858
|
+
throw JSON.parse(error.response.data.message);
|
|
1859
|
+
}
|
|
1860
|
+
else {
|
|
1861
|
+
throw [];
|
|
1862
|
+
}
|
|
1322
1863
|
});
|
|
1323
1864
|
};
|
|
1324
|
-
Gs2InventoryRestClient.prototype.
|
|
1325
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
1865
|
+
Gs2InventoryRestClient.prototype.deleteItemSetByUserId = function (request) {
|
|
1866
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l;
|
|
1326
1867
|
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/inventory/{inventoryName}/item/{itemName}')
|
|
1327
1868
|
.replace('{service}', 'inventory')
|
|
1328
1869
|
.replace('{region}', this.session.region)
|
|
@@ -1334,102 +1875,285 @@ var Gs2InventoryRestClient = /** @class */ (function (_super) {
|
|
|
1334
1875
|
if (request.getRequestId()) {
|
|
1335
1876
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1336
1877
|
}
|
|
1878
|
+
if (request.getDuplicationAvoider()) {
|
|
1879
|
+
headers['X-GS2-DUPLICATION-AVOIDER'] = (_j = request.getDuplicationAvoider()) !== null && _j !== void 0 ? _j : null;
|
|
1880
|
+
}
|
|
1337
1881
|
var params = {
|
|
1338
|
-
'contextStack': (
|
|
1339
|
-
'itemSetName': String((
|
|
1882
|
+
'contextStack': (_k = request.getContextStack()) !== null && _k !== void 0 ? _k : null,
|
|
1883
|
+
'itemSetName': String((_l = request.getItemSetName()) !== null && _l !== void 0 ? _l : null),
|
|
1340
1884
|
};
|
|
1341
|
-
return axios_1.default.
|
|
1885
|
+
return axios_1.default.delete(url, {
|
|
1342
1886
|
params: params,
|
|
1343
1887
|
headers: headers,
|
|
1344
1888
|
}).then(function (response) {
|
|
1345
|
-
return Result.
|
|
1889
|
+
return Result.DeleteItemSetByUserIdResult.fromDict(response.data);
|
|
1346
1890
|
}).catch(function (error) {
|
|
1347
1891
|
throw JSON.parse(error.response.data.message);
|
|
1348
1892
|
});
|
|
1349
1893
|
};
|
|
1350
|
-
Gs2InventoryRestClient.prototype.
|
|
1894
|
+
Gs2InventoryRestClient.prototype.acquireItemSetByStampSheet = function (request) {
|
|
1895
|
+
var _a, _b, _c;
|
|
1896
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/stamp/item/acquire')
|
|
1897
|
+
.replace('{service}', 'inventory')
|
|
1898
|
+
.replace('{region}', this.session.region);
|
|
1899
|
+
var headers = this.createAuthorizedHeaders();
|
|
1900
|
+
if (request.getRequestId()) {
|
|
1901
|
+
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1902
|
+
}
|
|
1903
|
+
var body = {
|
|
1904
|
+
'contextStack': (_a = request.getContextStack()) !== null && _a !== void 0 ? _a : null,
|
|
1905
|
+
'stampSheet': (_b = request.getStampSheet()) !== null && _b !== void 0 ? _b : null,
|
|
1906
|
+
'keyId': (_c = request.getKeyId()) !== null && _c !== void 0 ? _c : null,
|
|
1907
|
+
};
|
|
1908
|
+
return axios_1.default.post(url, body, {
|
|
1909
|
+
headers: headers,
|
|
1910
|
+
}).then(function (response) {
|
|
1911
|
+
return Result.AcquireItemSetByStampSheetResult.fromDict(response.data);
|
|
1912
|
+
}).catch(function (error) {
|
|
1913
|
+
if (error.response) {
|
|
1914
|
+
throw JSON.parse(error.response.data.message);
|
|
1915
|
+
}
|
|
1916
|
+
else {
|
|
1917
|
+
throw [];
|
|
1918
|
+
}
|
|
1919
|
+
});
|
|
1920
|
+
};
|
|
1921
|
+
Gs2InventoryRestClient.prototype.consumeItemSetByStampTask = function (request) {
|
|
1922
|
+
var _a, _b, _c;
|
|
1923
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/stamp/item/consume')
|
|
1924
|
+
.replace('{service}', 'inventory')
|
|
1925
|
+
.replace('{region}', this.session.region);
|
|
1926
|
+
var headers = this.createAuthorizedHeaders();
|
|
1927
|
+
if (request.getRequestId()) {
|
|
1928
|
+
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1929
|
+
}
|
|
1930
|
+
var body = {
|
|
1931
|
+
'contextStack': (_a = request.getContextStack()) !== null && _a !== void 0 ? _a : null,
|
|
1932
|
+
'stampTask': (_b = request.getStampTask()) !== null && _b !== void 0 ? _b : null,
|
|
1933
|
+
'keyId': (_c = request.getKeyId()) !== null && _c !== void 0 ? _c : null,
|
|
1934
|
+
};
|
|
1935
|
+
return axios_1.default.post(url, body, {
|
|
1936
|
+
headers: headers,
|
|
1937
|
+
}).then(function (response) {
|
|
1938
|
+
return Result.ConsumeItemSetByStampTaskResult.fromDict(response.data);
|
|
1939
|
+
}).catch(function (error) {
|
|
1940
|
+
if (error.response) {
|
|
1941
|
+
throw JSON.parse(error.response.data.message);
|
|
1942
|
+
}
|
|
1943
|
+
else {
|
|
1944
|
+
throw [];
|
|
1945
|
+
}
|
|
1946
|
+
});
|
|
1947
|
+
};
|
|
1948
|
+
Gs2InventoryRestClient.prototype.describeReferenceOf = function (request) {
|
|
1351
1949
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
1352
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/me/inventory/{inventoryName}/item/{itemName}/
|
|
1950
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/me/inventory/{inventoryName}/item/{itemName}/{itemSetName}/reference')
|
|
1353
1951
|
.replace('{service}', 'inventory')
|
|
1354
1952
|
.replace('{region}', this.session.region)
|
|
1355
1953
|
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1356
1954
|
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1357
|
-
.replace('{itemName}', String((_e = request.getItemName()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getItemName()) !== null && _f !== void 0 ? _f : 'null'))
|
|
1955
|
+
.replace('{itemName}', String((_e = request.getItemName()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getItemName()) !== null && _f !== void 0 ? _f : 'null'))
|
|
1956
|
+
.replace('{itemSetName}', String((_g = request.getItemSetName()) !== null && _g !== void 0 ? _g : 'null') === "" ? "null" : String((_h = request.getItemSetName()) !== null && _h !== void 0 ? _h : 'null'));
|
|
1358
1957
|
var headers = this.createAuthorizedHeaders();
|
|
1359
1958
|
if (request.getRequestId()) {
|
|
1360
1959
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1361
1960
|
}
|
|
1362
1961
|
if (request.getAccessToken()) {
|
|
1363
|
-
headers['X-GS2-ACCESS-TOKEN'] = (
|
|
1962
|
+
headers['X-GS2-ACCESS-TOKEN'] = (_j = request.getAccessToken()) !== null && _j !== void 0 ? _j : null;
|
|
1364
1963
|
}
|
|
1365
1964
|
var params = {
|
|
1366
|
-
'contextStack': (
|
|
1367
|
-
'itemSetName': String((_j = request.getItemSetName()) !== null && _j !== void 0 ? _j : null),
|
|
1368
|
-
'keyId': String((_k = request.getKeyId()) !== null && _k !== void 0 ? _k : null),
|
|
1965
|
+
'contextStack': (_k = request.getContextStack()) !== null && _k !== void 0 ? _k : null,
|
|
1369
1966
|
};
|
|
1370
1967
|
return axios_1.default.get(url, {
|
|
1371
1968
|
params: params,
|
|
1372
1969
|
headers: headers,
|
|
1373
1970
|
}).then(function (response) {
|
|
1374
|
-
return Result.
|
|
1971
|
+
return Result.DescribeReferenceOfResult.fromDict(response.data);
|
|
1375
1972
|
}).catch(function (error) {
|
|
1376
1973
|
throw JSON.parse(error.response.data.message);
|
|
1377
1974
|
});
|
|
1378
1975
|
};
|
|
1379
|
-
Gs2InventoryRestClient.prototype.
|
|
1976
|
+
Gs2InventoryRestClient.prototype.describeReferenceOfByUserId = function (request) {
|
|
1380
1977
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l;
|
|
1381
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/inventory/{inventoryName}/item/{itemName}/
|
|
1978
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/inventory/{inventoryName}/item/{itemName}/{itemSetName}/reference')
|
|
1382
1979
|
.replace('{service}', 'inventory')
|
|
1383
1980
|
.replace('{region}', this.session.region)
|
|
1384
1981
|
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1385
1982
|
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1386
1983
|
.replace('{userId}', String((_e = request.getUserId()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getUserId()) !== null && _f !== void 0 ? _f : 'null'))
|
|
1387
|
-
.replace('{itemName}', String((_g = request.getItemName()) !== null && _g !== void 0 ? _g : 'null') === "" ? "null" : String((_h = request.getItemName()) !== null && _h !== void 0 ? _h : 'null'))
|
|
1984
|
+
.replace('{itemName}', String((_g = request.getItemName()) !== null && _g !== void 0 ? _g : 'null') === "" ? "null" : String((_h = request.getItemName()) !== null && _h !== void 0 ? _h : 'null'))
|
|
1985
|
+
.replace('{itemSetName}', String((_j = request.getItemSetName()) !== null && _j !== void 0 ? _j : 'null') === "" ? "null" : String((_k = request.getItemSetName()) !== null && _k !== void 0 ? _k : 'null'));
|
|
1388
1986
|
var headers = this.createAuthorizedHeaders();
|
|
1389
1987
|
if (request.getRequestId()) {
|
|
1390
1988
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1391
1989
|
}
|
|
1392
1990
|
var params = {
|
|
1393
|
-
'contextStack': (
|
|
1394
|
-
'itemSetName': String((_k = request.getItemSetName()) !== null && _k !== void 0 ? _k : null),
|
|
1395
|
-
'keyId': String((_l = request.getKeyId()) !== null && _l !== void 0 ? _l : null),
|
|
1991
|
+
'contextStack': (_l = request.getContextStack()) !== null && _l !== void 0 ? _l : null,
|
|
1396
1992
|
};
|
|
1397
1993
|
return axios_1.default.get(url, {
|
|
1398
1994
|
params: params,
|
|
1399
1995
|
headers: headers,
|
|
1400
1996
|
}).then(function (response) {
|
|
1401
|
-
return Result.
|
|
1997
|
+
return Result.DescribeReferenceOfByUserIdResult.fromDict(response.data);
|
|
1402
1998
|
}).catch(function (error) {
|
|
1403
1999
|
throw JSON.parse(error.response.data.message);
|
|
1404
2000
|
});
|
|
1405
2001
|
};
|
|
1406
|
-
Gs2InventoryRestClient.prototype.
|
|
1407
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m
|
|
1408
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/
|
|
2002
|
+
Gs2InventoryRestClient.prototype.getReferenceOf = function (request) {
|
|
2003
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m;
|
|
2004
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/me/inventory/{inventoryName}/item/{itemName}/{itemSetName}/reference/{referenceOf}')
|
|
2005
|
+
.replace('{service}', 'inventory')
|
|
2006
|
+
.replace('{region}', this.session.region)
|
|
2007
|
+
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
2008
|
+
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
2009
|
+
.replace('{itemName}', String((_e = request.getItemName()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getItemName()) !== null && _f !== void 0 ? _f : 'null'))
|
|
2010
|
+
.replace('{itemSetName}', String((_g = request.getItemSetName()) !== null && _g !== void 0 ? _g : 'null') === "" ? "null" : String((_h = request.getItemSetName()) !== null && _h !== void 0 ? _h : 'null'))
|
|
2011
|
+
.replace('{referenceOf}', String((_j = request.getReferenceOf()) !== null && _j !== void 0 ? _j : 'null') === "" ? "null" : String((_k = request.getReferenceOf()) !== null && _k !== void 0 ? _k : 'null'));
|
|
2012
|
+
var headers = this.createAuthorizedHeaders();
|
|
2013
|
+
if (request.getRequestId()) {
|
|
2014
|
+
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
2015
|
+
}
|
|
2016
|
+
if (request.getAccessToken()) {
|
|
2017
|
+
headers['X-GS2-ACCESS-TOKEN'] = (_l = request.getAccessToken()) !== null && _l !== void 0 ? _l : null;
|
|
2018
|
+
}
|
|
2019
|
+
var params = {
|
|
2020
|
+
'contextStack': (_m = request.getContextStack()) !== null && _m !== void 0 ? _m : null,
|
|
2021
|
+
};
|
|
2022
|
+
return axios_1.default.get(url, {
|
|
2023
|
+
params: params,
|
|
2024
|
+
headers: headers,
|
|
2025
|
+
}).then(function (response) {
|
|
2026
|
+
return Result.GetReferenceOfResult.fromDict(response.data);
|
|
2027
|
+
}).catch(function (error) {
|
|
2028
|
+
throw JSON.parse(error.response.data.message);
|
|
2029
|
+
});
|
|
2030
|
+
};
|
|
2031
|
+
Gs2InventoryRestClient.prototype.getReferenceOfByUserId = function (request) {
|
|
2032
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o;
|
|
2033
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/inventory/{inventoryName}/item/{itemName}/{itemSetName}/reference/{referenceOf}')
|
|
2034
|
+
.replace('{service}', 'inventory')
|
|
2035
|
+
.replace('{region}', this.session.region)
|
|
2036
|
+
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
2037
|
+
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
2038
|
+
.replace('{userId}', String((_e = request.getUserId()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getUserId()) !== null && _f !== void 0 ? _f : 'null'))
|
|
2039
|
+
.replace('{itemName}', String((_g = request.getItemName()) !== null && _g !== void 0 ? _g : 'null') === "" ? "null" : String((_h = request.getItemName()) !== null && _h !== void 0 ? _h : 'null'))
|
|
2040
|
+
.replace('{itemSetName}', String((_j = request.getItemSetName()) !== null && _j !== void 0 ? _j : 'null') === "" ? "null" : String((_k = request.getItemSetName()) !== null && _k !== void 0 ? _k : 'null'))
|
|
2041
|
+
.replace('{referenceOf}', String((_l = request.getReferenceOf()) !== null && _l !== void 0 ? _l : 'null') === "" ? "null" : String((_m = request.getReferenceOf()) !== null && _m !== void 0 ? _m : 'null'));
|
|
2042
|
+
var headers = this.createAuthorizedHeaders();
|
|
2043
|
+
if (request.getRequestId()) {
|
|
2044
|
+
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
2045
|
+
}
|
|
2046
|
+
var params = {
|
|
2047
|
+
'contextStack': (_o = request.getContextStack()) !== null && _o !== void 0 ? _o : null,
|
|
2048
|
+
};
|
|
2049
|
+
return axios_1.default.get(url, {
|
|
2050
|
+
params: params,
|
|
2051
|
+
headers: headers,
|
|
2052
|
+
}).then(function (response) {
|
|
2053
|
+
return Result.GetReferenceOfByUserIdResult.fromDict(response.data);
|
|
2054
|
+
}).catch(function (error) {
|
|
2055
|
+
throw JSON.parse(error.response.data.message);
|
|
2056
|
+
});
|
|
2057
|
+
};
|
|
2058
|
+
Gs2InventoryRestClient.prototype.verifyReferenceOf = function (request) {
|
|
2059
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q;
|
|
2060
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/me/inventory/{inventoryName}/item/{itemName}/{itemSetName}/reference/{referenceOf}/verify/{verifyType}')
|
|
2061
|
+
.replace('{service}', 'inventory')
|
|
2062
|
+
.replace('{region}', this.session.region)
|
|
2063
|
+
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
2064
|
+
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
2065
|
+
.replace('{itemName}', String((_e = request.getItemName()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getItemName()) !== null && _f !== void 0 ? _f : 'null'))
|
|
2066
|
+
.replace('{itemSetName}', String((_g = request.getItemSetName()) !== null && _g !== void 0 ? _g : 'null') === "" ? "null" : String((_h = request.getItemSetName()) !== null && _h !== void 0 ? _h : 'null'))
|
|
2067
|
+
.replace('{referenceOf}', String((_j = request.getReferenceOf()) !== null && _j !== void 0 ? _j : 'null') === "" ? "null" : String((_k = request.getReferenceOf()) !== null && _k !== void 0 ? _k : 'null'))
|
|
2068
|
+
.replace('{verifyType}', String((_l = request.getVerifyType()) !== null && _l !== void 0 ? _l : 'null') === "" ? "null" : String((_m = request.getVerifyType()) !== null && _m !== void 0 ? _m : 'null'));
|
|
2069
|
+
var headers = this.createAuthorizedHeaders();
|
|
2070
|
+
if (request.getRequestId()) {
|
|
2071
|
+
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
2072
|
+
}
|
|
2073
|
+
if (request.getAccessToken()) {
|
|
2074
|
+
headers['X-GS2-ACCESS-TOKEN'] = (_o = request.getAccessToken()) !== null && _o !== void 0 ? _o : null;
|
|
2075
|
+
}
|
|
2076
|
+
if (request.getDuplicationAvoider()) {
|
|
2077
|
+
headers['X-GS2-DUPLICATION-AVOIDER'] = (_p = request.getDuplicationAvoider()) !== null && _p !== void 0 ? _p : null;
|
|
2078
|
+
}
|
|
2079
|
+
var body = {
|
|
2080
|
+
'contextStack': (_q = request.getContextStack()) !== null && _q !== void 0 ? _q : null,
|
|
2081
|
+
};
|
|
2082
|
+
return axios_1.default.post(url, body, {
|
|
2083
|
+
headers: headers,
|
|
2084
|
+
}).then(function (response) {
|
|
2085
|
+
return Result.VerifyReferenceOfResult.fromDict(response.data);
|
|
2086
|
+
}).catch(function (error) {
|
|
2087
|
+
if (error.response) {
|
|
2088
|
+
throw JSON.parse(error.response.data.message);
|
|
2089
|
+
}
|
|
2090
|
+
else {
|
|
2091
|
+
throw [];
|
|
2092
|
+
}
|
|
2093
|
+
});
|
|
2094
|
+
};
|
|
2095
|
+
Gs2InventoryRestClient.prototype.verifyReferenceOfByUserId = function (request) {
|
|
2096
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r;
|
|
2097
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/inventory/{inventoryName}/item/{itemName}/{itemSetName}/reference/{referenceOf}/verify/{verifyType}')
|
|
2098
|
+
.replace('{service}', 'inventory')
|
|
2099
|
+
.replace('{region}', this.session.region)
|
|
2100
|
+
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
2101
|
+
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
2102
|
+
.replace('{userId}', String((_e = request.getUserId()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getUserId()) !== null && _f !== void 0 ? _f : 'null'))
|
|
2103
|
+
.replace('{itemName}', String((_g = request.getItemName()) !== null && _g !== void 0 ? _g : 'null') === "" ? "null" : String((_h = request.getItemName()) !== null && _h !== void 0 ? _h : 'null'))
|
|
2104
|
+
.replace('{itemSetName}', String((_j = request.getItemSetName()) !== null && _j !== void 0 ? _j : 'null') === "" ? "null" : String((_k = request.getItemSetName()) !== null && _k !== void 0 ? _k : 'null'))
|
|
2105
|
+
.replace('{referenceOf}', String((_l = request.getReferenceOf()) !== null && _l !== void 0 ? _l : 'null') === "" ? "null" : String((_m = request.getReferenceOf()) !== null && _m !== void 0 ? _m : 'null'))
|
|
2106
|
+
.replace('{verifyType}', String((_o = request.getVerifyType()) !== null && _o !== void 0 ? _o : 'null') === "" ? "null" : String((_p = request.getVerifyType()) !== null && _p !== void 0 ? _p : 'null'));
|
|
2107
|
+
var headers = this.createAuthorizedHeaders();
|
|
2108
|
+
if (request.getRequestId()) {
|
|
2109
|
+
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
2110
|
+
}
|
|
2111
|
+
if (request.getDuplicationAvoider()) {
|
|
2112
|
+
headers['X-GS2-DUPLICATION-AVOIDER'] = (_q = request.getDuplicationAvoider()) !== null && _q !== void 0 ? _q : null;
|
|
2113
|
+
}
|
|
2114
|
+
var body = {
|
|
2115
|
+
'contextStack': (_r = request.getContextStack()) !== null && _r !== void 0 ? _r : null,
|
|
2116
|
+
};
|
|
2117
|
+
return axios_1.default.post(url, body, {
|
|
2118
|
+
headers: headers,
|
|
2119
|
+
}).then(function (response) {
|
|
2120
|
+
return Result.VerifyReferenceOfByUserIdResult.fromDict(response.data);
|
|
2121
|
+
}).catch(function (error) {
|
|
2122
|
+
if (error.response) {
|
|
2123
|
+
throw JSON.parse(error.response.data.message);
|
|
2124
|
+
}
|
|
2125
|
+
else {
|
|
2126
|
+
throw [];
|
|
2127
|
+
}
|
|
2128
|
+
});
|
|
2129
|
+
};
|
|
2130
|
+
Gs2InventoryRestClient.prototype.addReferenceOf = function (request) {
|
|
2131
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m;
|
|
2132
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/me/inventory/{inventoryName}/item/{itemName}/{itemSetName}/reference')
|
|
1409
2133
|
.replace('{service}', 'inventory')
|
|
1410
2134
|
.replace('{region}', this.session.region)
|
|
1411
2135
|
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1412
2136
|
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1413
2137
|
.replace('{itemName}', String((_e = request.getItemName()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getItemName()) !== null && _f !== void 0 ? _f : 'null'))
|
|
1414
|
-
.replace('{
|
|
2138
|
+
.replace('{itemSetName}', String((_g = request.getItemSetName()) !== null && _g !== void 0 ? _g : 'null') === "" ? "null" : String((_h = request.getItemSetName()) !== null && _h !== void 0 ? _h : 'null'));
|
|
1415
2139
|
var headers = this.createAuthorizedHeaders();
|
|
1416
2140
|
if (request.getRequestId()) {
|
|
1417
2141
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1418
2142
|
}
|
|
2143
|
+
if (request.getAccessToken()) {
|
|
2144
|
+
headers['X-GS2-ACCESS-TOKEN'] = (_j = request.getAccessToken()) !== null && _j !== void 0 ? _j : null;
|
|
2145
|
+
}
|
|
1419
2146
|
if (request.getDuplicationAvoider()) {
|
|
1420
|
-
headers['X-GS2-DUPLICATION-AVOIDER'] = (
|
|
2147
|
+
headers['X-GS2-DUPLICATION-AVOIDER'] = (_k = request.getDuplicationAvoider()) !== null && _k !== void 0 ? _k : null;
|
|
1421
2148
|
}
|
|
1422
2149
|
var body = {
|
|
1423
|
-
'contextStack': (
|
|
1424
|
-
'
|
|
1425
|
-
'expiresAt': (_m = request.getExpiresAt()) !== null && _m !== void 0 ? _m : null,
|
|
1426
|
-
'createNewItemSet': (_o = request.getCreateNewItemSet()) !== null && _o !== void 0 ? _o : null,
|
|
1427
|
-
'itemSetName': (_p = request.getItemSetName()) !== null && _p !== void 0 ? _p : null,
|
|
2150
|
+
'contextStack': (_l = request.getContextStack()) !== null && _l !== void 0 ? _l : null,
|
|
2151
|
+
'referenceOf': (_m = request.getReferenceOf()) !== null && _m !== void 0 ? _m : null,
|
|
1428
2152
|
};
|
|
1429
2153
|
return axios_1.default.post(url, body, {
|
|
1430
2154
|
headers: headers,
|
|
1431
2155
|
}).then(function (response) {
|
|
1432
|
-
return Result.
|
|
2156
|
+
return Result.AddReferenceOfResult.fromDict(response.data);
|
|
1433
2157
|
}).catch(function (error) {
|
|
1434
2158
|
if (error.response) {
|
|
1435
2159
|
throw JSON.parse(error.response.data.message);
|
|
@@ -1439,33 +2163,31 @@ var Gs2InventoryRestClient = /** @class */ (function (_super) {
|
|
|
1439
2163
|
}
|
|
1440
2164
|
});
|
|
1441
2165
|
};
|
|
1442
|
-
Gs2InventoryRestClient.prototype.
|
|
1443
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l;
|
|
1444
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/
|
|
2166
|
+
Gs2InventoryRestClient.prototype.addReferenceOfByUserId = function (request) {
|
|
2167
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o;
|
|
2168
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/inventory/{inventoryName}/item/{itemName}/{itemSetName}/reference')
|
|
1445
2169
|
.replace('{service}', 'inventory')
|
|
1446
2170
|
.replace('{region}', this.session.region)
|
|
1447
2171
|
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1448
2172
|
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1449
|
-
.replace('{
|
|
2173
|
+
.replace('{userId}', String((_e = request.getUserId()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getUserId()) !== null && _f !== void 0 ? _f : 'null'))
|
|
2174
|
+
.replace('{itemName}', String((_g = request.getItemName()) !== null && _g !== void 0 ? _g : 'null') === "" ? "null" : String((_h = request.getItemName()) !== null && _h !== void 0 ? _h : 'null'))
|
|
2175
|
+
.replace('{itemSetName}', String((_j = request.getItemSetName()) !== null && _j !== void 0 ? _j : 'null') === "" ? "null" : String((_k = request.getItemSetName()) !== null && _k !== void 0 ? _k : 'null'));
|
|
1450
2176
|
var headers = this.createAuthorizedHeaders();
|
|
1451
2177
|
if (request.getRequestId()) {
|
|
1452
2178
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1453
2179
|
}
|
|
1454
|
-
if (request.getAccessToken()) {
|
|
1455
|
-
headers['X-GS2-ACCESS-TOKEN'] = (_g = request.getAccessToken()) !== null && _g !== void 0 ? _g : null;
|
|
1456
|
-
}
|
|
1457
2180
|
if (request.getDuplicationAvoider()) {
|
|
1458
|
-
headers['X-GS2-DUPLICATION-AVOIDER'] = (
|
|
2181
|
+
headers['X-GS2-DUPLICATION-AVOIDER'] = (_l = request.getDuplicationAvoider()) !== null && _l !== void 0 ? _l : null;
|
|
1459
2182
|
}
|
|
1460
2183
|
var body = {
|
|
1461
|
-
'contextStack': (
|
|
1462
|
-
'
|
|
1463
|
-
'itemSetName': (_l = request.getItemSetName()) !== null && _l !== void 0 ? _l : null,
|
|
2184
|
+
'contextStack': (_m = request.getContextStack()) !== null && _m !== void 0 ? _m : null,
|
|
2185
|
+
'referenceOf': (_o = request.getReferenceOf()) !== null && _o !== void 0 ? _o : null,
|
|
1464
2186
|
};
|
|
1465
2187
|
return axios_1.default.post(url, body, {
|
|
1466
2188
|
headers: headers,
|
|
1467
2189
|
}).then(function (response) {
|
|
1468
|
-
return Result.
|
|
2190
|
+
return Result.AddReferenceOfByUserIdResult.fromDict(response.data);
|
|
1469
2191
|
}).catch(function (error) {
|
|
1470
2192
|
if (error.response) {
|
|
1471
2193
|
throw JSON.parse(error.response.data.message);
|
|
@@ -1475,72 +2197,71 @@ var Gs2InventoryRestClient = /** @class */ (function (_super) {
|
|
|
1475
2197
|
}
|
|
1476
2198
|
});
|
|
1477
2199
|
};
|
|
1478
|
-
Gs2InventoryRestClient.prototype.
|
|
1479
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m;
|
|
1480
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/
|
|
2200
|
+
Gs2InventoryRestClient.prototype.deleteReferenceOf = function (request) {
|
|
2201
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o;
|
|
2202
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/me/inventory/{inventoryName}/item/{itemName}/{itemSetName}/reference/{referenceOf}')
|
|
1481
2203
|
.replace('{service}', 'inventory')
|
|
1482
2204
|
.replace('{region}', this.session.region)
|
|
1483
2205
|
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1484
2206
|
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1485
|
-
.replace('{
|
|
1486
|
-
.replace('{
|
|
2207
|
+
.replace('{itemName}', String((_e = request.getItemName()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getItemName()) !== null && _f !== void 0 ? _f : 'null'))
|
|
2208
|
+
.replace('{itemSetName}', String((_g = request.getItemSetName()) !== null && _g !== void 0 ? _g : 'null') === "" ? "null" : String((_h = request.getItemSetName()) !== null && _h !== void 0 ? _h : 'null'))
|
|
2209
|
+
.replace('{referenceOf}', String((_j = request.getReferenceOf()) !== null && _j !== void 0 ? _j : 'null') === "" ? "null" : String((_k = request.getReferenceOf()) !== null && _k !== void 0 ? _k : 'null'));
|
|
1487
2210
|
var headers = this.createAuthorizedHeaders();
|
|
1488
2211
|
if (request.getRequestId()) {
|
|
1489
2212
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1490
2213
|
}
|
|
2214
|
+
if (request.getAccessToken()) {
|
|
2215
|
+
headers['X-GS2-ACCESS-TOKEN'] = (_l = request.getAccessToken()) !== null && _l !== void 0 ? _l : null;
|
|
2216
|
+
}
|
|
1491
2217
|
if (request.getDuplicationAvoider()) {
|
|
1492
|
-
headers['X-GS2-DUPLICATION-AVOIDER'] = (
|
|
2218
|
+
headers['X-GS2-DUPLICATION-AVOIDER'] = (_m = request.getDuplicationAvoider()) !== null && _m !== void 0 ? _m : null;
|
|
1493
2219
|
}
|
|
1494
|
-
var
|
|
1495
|
-
'contextStack': (
|
|
1496
|
-
'consumeCount': (_l = request.getConsumeCount()) !== null && _l !== void 0 ? _l : null,
|
|
1497
|
-
'itemSetName': (_m = request.getItemSetName()) !== null && _m !== void 0 ? _m : null,
|
|
2220
|
+
var params = {
|
|
2221
|
+
'contextStack': (_o = request.getContextStack()) !== null && _o !== void 0 ? _o : null,
|
|
1498
2222
|
};
|
|
1499
|
-
return axios_1.default.
|
|
2223
|
+
return axios_1.default.delete(url, {
|
|
2224
|
+
params: params,
|
|
1500
2225
|
headers: headers,
|
|
1501
2226
|
}).then(function (response) {
|
|
1502
|
-
return Result.
|
|
2227
|
+
return Result.DeleteReferenceOfResult.fromDict(response.data);
|
|
1503
2228
|
}).catch(function (error) {
|
|
1504
|
-
|
|
1505
|
-
throw JSON.parse(error.response.data.message);
|
|
1506
|
-
}
|
|
1507
|
-
else {
|
|
1508
|
-
throw [];
|
|
1509
|
-
}
|
|
2229
|
+
throw JSON.parse(error.response.data.message);
|
|
1510
2230
|
});
|
|
1511
2231
|
};
|
|
1512
|
-
Gs2InventoryRestClient.prototype.
|
|
1513
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l;
|
|
1514
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/inventory/{inventoryName}/item/{itemName}')
|
|
2232
|
+
Gs2InventoryRestClient.prototype.deleteReferenceOfByUserId = function (request) {
|
|
2233
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
|
|
2234
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/inventory/{inventoryName}/item/{itemName}/{itemSetName}/reference/{referenceOf}')
|
|
1515
2235
|
.replace('{service}', 'inventory')
|
|
1516
2236
|
.replace('{region}', this.session.region)
|
|
1517
2237
|
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1518
2238
|
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1519
2239
|
.replace('{userId}', String((_e = request.getUserId()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getUserId()) !== null && _f !== void 0 ? _f : 'null'))
|
|
1520
|
-
.replace('{itemName}', String((_g = request.getItemName()) !== null && _g !== void 0 ? _g : 'null') === "" ? "null" : String((_h = request.getItemName()) !== null && _h !== void 0 ? _h : 'null'))
|
|
2240
|
+
.replace('{itemName}', String((_g = request.getItemName()) !== null && _g !== void 0 ? _g : 'null') === "" ? "null" : String((_h = request.getItemName()) !== null && _h !== void 0 ? _h : 'null'))
|
|
2241
|
+
.replace('{itemSetName}', String((_j = request.getItemSetName()) !== null && _j !== void 0 ? _j : 'null') === "" ? "null" : String((_k = request.getItemSetName()) !== null && _k !== void 0 ? _k : 'null'))
|
|
2242
|
+
.replace('{referenceOf}', String((_l = request.getReferenceOf()) !== null && _l !== void 0 ? _l : 'null') === "" ? "null" : String((_m = request.getReferenceOf()) !== null && _m !== void 0 ? _m : 'null'));
|
|
1521
2243
|
var headers = this.createAuthorizedHeaders();
|
|
1522
2244
|
if (request.getRequestId()) {
|
|
1523
2245
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1524
2246
|
}
|
|
1525
2247
|
if (request.getDuplicationAvoider()) {
|
|
1526
|
-
headers['X-GS2-DUPLICATION-AVOIDER'] = (
|
|
2248
|
+
headers['X-GS2-DUPLICATION-AVOIDER'] = (_o = request.getDuplicationAvoider()) !== null && _o !== void 0 ? _o : null;
|
|
1527
2249
|
}
|
|
1528
2250
|
var params = {
|
|
1529
|
-
'contextStack': (
|
|
1530
|
-
'itemSetName': String((_l = request.getItemSetName()) !== null && _l !== void 0 ? _l : null),
|
|
2251
|
+
'contextStack': (_p = request.getContextStack()) !== null && _p !== void 0 ? _p : null,
|
|
1531
2252
|
};
|
|
1532
2253
|
return axios_1.default.delete(url, {
|
|
1533
2254
|
params: params,
|
|
1534
2255
|
headers: headers,
|
|
1535
2256
|
}).then(function (response) {
|
|
1536
|
-
return Result.
|
|
2257
|
+
return Result.DeleteReferenceOfByUserIdResult.fromDict(response.data);
|
|
1537
2258
|
}).catch(function (error) {
|
|
1538
2259
|
throw JSON.parse(error.response.data.message);
|
|
1539
2260
|
});
|
|
1540
2261
|
};
|
|
1541
|
-
Gs2InventoryRestClient.prototype.
|
|
2262
|
+
Gs2InventoryRestClient.prototype.addReferenceOfItemSetByStampSheet = function (request) {
|
|
1542
2263
|
var _a, _b, _c;
|
|
1543
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/stamp/item/
|
|
2264
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/stamp/item/reference/add')
|
|
1544
2265
|
.replace('{service}', 'inventory')
|
|
1545
2266
|
.replace('{region}', this.session.region);
|
|
1546
2267
|
var headers = this.createAuthorizedHeaders();
|
|
@@ -1555,7 +2276,7 @@ var Gs2InventoryRestClient = /** @class */ (function (_super) {
|
|
|
1555
2276
|
return axios_1.default.post(url, body, {
|
|
1556
2277
|
headers: headers,
|
|
1557
2278
|
}).then(function (response) {
|
|
1558
|
-
return Result.
|
|
2279
|
+
return Result.AddReferenceOfItemSetByStampSheetResult.fromDict(response.data);
|
|
1559
2280
|
}).catch(function (error) {
|
|
1560
2281
|
if (error.response) {
|
|
1561
2282
|
throw JSON.parse(error.response.data.message);
|
|
@@ -1565,9 +2286,36 @@ var Gs2InventoryRestClient = /** @class */ (function (_super) {
|
|
|
1565
2286
|
}
|
|
1566
2287
|
});
|
|
1567
2288
|
};
|
|
1568
|
-
Gs2InventoryRestClient.prototype.
|
|
2289
|
+
Gs2InventoryRestClient.prototype.deleteReferenceOfItemSetByStampSheet = function (request) {
|
|
1569
2290
|
var _a, _b, _c;
|
|
1570
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/stamp/item/
|
|
2291
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/stamp/item/reference/delete')
|
|
2292
|
+
.replace('{service}', 'inventory')
|
|
2293
|
+
.replace('{region}', this.session.region);
|
|
2294
|
+
var headers = this.createAuthorizedHeaders();
|
|
2295
|
+
if (request.getRequestId()) {
|
|
2296
|
+
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
2297
|
+
}
|
|
2298
|
+
var body = {
|
|
2299
|
+
'contextStack': (_a = request.getContextStack()) !== null && _a !== void 0 ? _a : null,
|
|
2300
|
+
'stampSheet': (_b = request.getStampSheet()) !== null && _b !== void 0 ? _b : null,
|
|
2301
|
+
'keyId': (_c = request.getKeyId()) !== null && _c !== void 0 ? _c : null,
|
|
2302
|
+
};
|
|
2303
|
+
return axios_1.default.post(url, body, {
|
|
2304
|
+
headers: headers,
|
|
2305
|
+
}).then(function (response) {
|
|
2306
|
+
return Result.DeleteReferenceOfItemSetByStampSheetResult.fromDict(response.data);
|
|
2307
|
+
}).catch(function (error) {
|
|
2308
|
+
if (error.response) {
|
|
2309
|
+
throw JSON.parse(error.response.data.message);
|
|
2310
|
+
}
|
|
2311
|
+
else {
|
|
2312
|
+
throw [];
|
|
2313
|
+
}
|
|
2314
|
+
});
|
|
2315
|
+
};
|
|
2316
|
+
Gs2InventoryRestClient.prototype.verifyReferenceOfByStampTask = function (request) {
|
|
2317
|
+
var _a, _b, _c;
|
|
2318
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/stamp/item/verify')
|
|
1571
2319
|
.replace('{service}', 'inventory')
|
|
1572
2320
|
.replace('{region}', this.session.region);
|
|
1573
2321
|
var headers = this.createAuthorizedHeaders();
|
|
@@ -1582,7 +2330,7 @@ var Gs2InventoryRestClient = /** @class */ (function (_super) {
|
|
|
1582
2330
|
return axios_1.default.post(url, body, {
|
|
1583
2331
|
headers: headers,
|
|
1584
2332
|
}).then(function (response) {
|
|
1585
|
-
return Result.
|
|
2333
|
+
return Result.VerifyReferenceOfByStampTaskResult.fromDict(response.data);
|
|
1586
2334
|
}).catch(function (error) {
|
|
1587
2335
|
if (error.response) {
|
|
1588
2336
|
throw JSON.parse(error.response.data.message);
|
|
@@ -1592,215 +2340,189 @@ var Gs2InventoryRestClient = /** @class */ (function (_super) {
|
|
|
1592
2340
|
}
|
|
1593
2341
|
});
|
|
1594
2342
|
};
|
|
1595
|
-
Gs2InventoryRestClient.prototype.
|
|
1596
|
-
var _a, _b, _c, _d, _e, _f, _g, _h
|
|
1597
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/me/inventory/{inventoryName}/item
|
|
2343
|
+
Gs2InventoryRestClient.prototype.describeSimpleItems = function (request) {
|
|
2344
|
+
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
2345
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/me/simple/inventory/{inventoryName}/item')
|
|
1598
2346
|
.replace('{service}', 'inventory')
|
|
1599
2347
|
.replace('{region}', this.session.region)
|
|
1600
2348
|
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1601
|
-
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1602
|
-
.replace('{itemName}', String((_e = request.getItemName()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getItemName()) !== null && _f !== void 0 ? _f : 'null'))
|
|
1603
|
-
.replace('{itemSetName}', String((_g = request.getItemSetName()) !== null && _g !== void 0 ? _g : 'null') === "" ? "null" : String((_h = request.getItemSetName()) !== null && _h !== void 0 ? _h : 'null'));
|
|
2349
|
+
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'));
|
|
1604
2350
|
var headers = this.createAuthorizedHeaders();
|
|
1605
2351
|
if (request.getRequestId()) {
|
|
1606
2352
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1607
2353
|
}
|
|
1608
2354
|
if (request.getAccessToken()) {
|
|
1609
|
-
headers['X-GS2-ACCESS-TOKEN'] = (
|
|
2355
|
+
headers['X-GS2-ACCESS-TOKEN'] = (_e = request.getAccessToken()) !== null && _e !== void 0 ? _e : null;
|
|
1610
2356
|
}
|
|
1611
2357
|
var params = {
|
|
1612
|
-
'contextStack': (
|
|
2358
|
+
'contextStack': (_f = request.getContextStack()) !== null && _f !== void 0 ? _f : null,
|
|
2359
|
+
'pageToken': String((_g = request.getPageToken()) !== null && _g !== void 0 ? _g : null),
|
|
2360
|
+
'limit': String((_h = request.getLimit()) !== null && _h !== void 0 ? _h : null),
|
|
1613
2361
|
};
|
|
1614
2362
|
return axios_1.default.get(url, {
|
|
1615
2363
|
params: params,
|
|
1616
2364
|
headers: headers,
|
|
1617
2365
|
}).then(function (response) {
|
|
1618
|
-
return Result.
|
|
2366
|
+
return Result.DescribeSimpleItemsResult.fromDict(response.data);
|
|
1619
2367
|
}).catch(function (error) {
|
|
1620
2368
|
throw JSON.parse(error.response.data.message);
|
|
1621
2369
|
});
|
|
1622
2370
|
};
|
|
1623
|
-
Gs2InventoryRestClient.prototype.
|
|
1624
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j
|
|
1625
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/inventory/{inventoryName}/item
|
|
2371
|
+
Gs2InventoryRestClient.prototype.describeSimpleItemsByUserId = function (request) {
|
|
2372
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
2373
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/simple/inventory/{inventoryName}/item')
|
|
1626
2374
|
.replace('{service}', 'inventory')
|
|
1627
2375
|
.replace('{region}', this.session.region)
|
|
1628
2376
|
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1629
2377
|
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1630
|
-
.replace('{userId}', String((_e = request.getUserId()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getUserId()) !== null && _f !== void 0 ? _f : 'null'))
|
|
1631
|
-
.replace('{itemName}', String((_g = request.getItemName()) !== null && _g !== void 0 ? _g : 'null') === "" ? "null" : String((_h = request.getItemName()) !== null && _h !== void 0 ? _h : 'null'))
|
|
1632
|
-
.replace('{itemSetName}', String((_j = request.getItemSetName()) !== null && _j !== void 0 ? _j : 'null') === "" ? "null" : String((_k = request.getItemSetName()) !== null && _k !== void 0 ? _k : 'null'));
|
|
2378
|
+
.replace('{userId}', String((_e = request.getUserId()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getUserId()) !== null && _f !== void 0 ? _f : 'null'));
|
|
1633
2379
|
var headers = this.createAuthorizedHeaders();
|
|
1634
2380
|
if (request.getRequestId()) {
|
|
1635
2381
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1636
2382
|
}
|
|
1637
2383
|
var params = {
|
|
1638
|
-
'contextStack': (
|
|
2384
|
+
'contextStack': (_g = request.getContextStack()) !== null && _g !== void 0 ? _g : null,
|
|
2385
|
+
'pageToken': String((_h = request.getPageToken()) !== null && _h !== void 0 ? _h : null),
|
|
2386
|
+
'limit': String((_j = request.getLimit()) !== null && _j !== void 0 ? _j : null),
|
|
1639
2387
|
};
|
|
1640
2388
|
return axios_1.default.get(url, {
|
|
1641
2389
|
params: params,
|
|
1642
2390
|
headers: headers,
|
|
1643
2391
|
}).then(function (response) {
|
|
1644
|
-
return Result.
|
|
2392
|
+
return Result.DescribeSimpleItemsByUserIdResult.fromDict(response.data);
|
|
1645
2393
|
}).catch(function (error) {
|
|
1646
2394
|
throw JSON.parse(error.response.data.message);
|
|
1647
2395
|
});
|
|
1648
2396
|
};
|
|
1649
|
-
Gs2InventoryRestClient.prototype.
|
|
1650
|
-
var _a, _b, _c, _d, _e, _f, _g, _h
|
|
1651
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/me/inventory/{inventoryName}/item/{itemName}
|
|
2397
|
+
Gs2InventoryRestClient.prototype.getSimpleItem = function (request) {
|
|
2398
|
+
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
2399
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/me/simple/inventory/{inventoryName}/item/{itemName}')
|
|
1652
2400
|
.replace('{service}', 'inventory')
|
|
1653
2401
|
.replace('{region}', this.session.region)
|
|
1654
2402
|
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1655
2403
|
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1656
|
-
.replace('{itemName}', String((_e = request.getItemName()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getItemName()) !== null && _f !== void 0 ? _f : 'null'))
|
|
1657
|
-
.replace('{itemSetName}', String((_g = request.getItemSetName()) !== null && _g !== void 0 ? _g : 'null') === "" ? "null" : String((_h = request.getItemSetName()) !== null && _h !== void 0 ? _h : 'null'))
|
|
1658
|
-
.replace('{referenceOf}', String((_j = request.getReferenceOf()) !== null && _j !== void 0 ? _j : 'null') === "" ? "null" : String((_k = request.getReferenceOf()) !== null && _k !== void 0 ? _k : 'null'));
|
|
2404
|
+
.replace('{itemName}', String((_e = request.getItemName()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getItemName()) !== null && _f !== void 0 ? _f : 'null'));
|
|
1659
2405
|
var headers = this.createAuthorizedHeaders();
|
|
1660
2406
|
if (request.getRequestId()) {
|
|
1661
2407
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1662
2408
|
}
|
|
1663
2409
|
if (request.getAccessToken()) {
|
|
1664
|
-
headers['X-GS2-ACCESS-TOKEN'] = (
|
|
2410
|
+
headers['X-GS2-ACCESS-TOKEN'] = (_g = request.getAccessToken()) !== null && _g !== void 0 ? _g : null;
|
|
1665
2411
|
}
|
|
1666
2412
|
var params = {
|
|
1667
|
-
'contextStack': (
|
|
2413
|
+
'contextStack': (_h = request.getContextStack()) !== null && _h !== void 0 ? _h : null,
|
|
1668
2414
|
};
|
|
1669
2415
|
return axios_1.default.get(url, {
|
|
1670
2416
|
params: params,
|
|
1671
2417
|
headers: headers,
|
|
1672
2418
|
}).then(function (response) {
|
|
1673
|
-
return Result.
|
|
2419
|
+
return Result.GetSimpleItemResult.fromDict(response.data);
|
|
1674
2420
|
}).catch(function (error) {
|
|
1675
2421
|
throw JSON.parse(error.response.data.message);
|
|
1676
2422
|
});
|
|
1677
2423
|
};
|
|
1678
|
-
Gs2InventoryRestClient.prototype.
|
|
1679
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j
|
|
1680
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/inventory/{inventoryName}/item/{itemName}
|
|
2424
|
+
Gs2InventoryRestClient.prototype.getSimpleItemByUserId = function (request) {
|
|
2425
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
2426
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/simple/inventory/{inventoryName}/item/{itemName}')
|
|
1681
2427
|
.replace('{service}', 'inventory')
|
|
1682
2428
|
.replace('{region}', this.session.region)
|
|
1683
2429
|
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1684
2430
|
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1685
2431
|
.replace('{userId}', String((_e = request.getUserId()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getUserId()) !== null && _f !== void 0 ? _f : 'null'))
|
|
1686
|
-
.replace('{itemName}', String((_g = request.getItemName()) !== null && _g !== void 0 ? _g : 'null') === "" ? "null" : String((_h = request.getItemName()) !== null && _h !== void 0 ? _h : 'null'))
|
|
1687
|
-
.replace('{itemSetName}', String((_j = request.getItemSetName()) !== null && _j !== void 0 ? _j : 'null') === "" ? "null" : String((_k = request.getItemSetName()) !== null && _k !== void 0 ? _k : 'null'))
|
|
1688
|
-
.replace('{referenceOf}', String((_l = request.getReferenceOf()) !== null && _l !== void 0 ? _l : 'null') === "" ? "null" : String((_m = request.getReferenceOf()) !== null && _m !== void 0 ? _m : 'null'));
|
|
2432
|
+
.replace('{itemName}', String((_g = request.getItemName()) !== null && _g !== void 0 ? _g : 'null') === "" ? "null" : String((_h = request.getItemName()) !== null && _h !== void 0 ? _h : 'null'));
|
|
1689
2433
|
var headers = this.createAuthorizedHeaders();
|
|
1690
2434
|
if (request.getRequestId()) {
|
|
1691
2435
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1692
2436
|
}
|
|
1693
2437
|
var params = {
|
|
1694
|
-
'contextStack': (
|
|
2438
|
+
'contextStack': (_j = request.getContextStack()) !== null && _j !== void 0 ? _j : null,
|
|
1695
2439
|
};
|
|
1696
2440
|
return axios_1.default.get(url, {
|
|
1697
2441
|
params: params,
|
|
1698
2442
|
headers: headers,
|
|
1699
2443
|
}).then(function (response) {
|
|
1700
|
-
return Result.
|
|
2444
|
+
return Result.GetSimpleItemByUserIdResult.fromDict(response.data);
|
|
1701
2445
|
}).catch(function (error) {
|
|
1702
2446
|
throw JSON.parse(error.response.data.message);
|
|
1703
2447
|
});
|
|
1704
2448
|
};
|
|
1705
|
-
Gs2InventoryRestClient.prototype.
|
|
1706
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j
|
|
1707
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/me/inventory/{inventoryName}/item/{itemName}/
|
|
2449
|
+
Gs2InventoryRestClient.prototype.getSimpleItemWithSignature = function (request) {
|
|
2450
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
2451
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/me/simple/inventory/{inventoryName}/item/{itemName}/signature')
|
|
1708
2452
|
.replace('{service}', 'inventory')
|
|
1709
2453
|
.replace('{region}', this.session.region)
|
|
1710
2454
|
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1711
2455
|
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1712
|
-
.replace('{itemName}', String((_e = request.getItemName()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getItemName()) !== null && _f !== void 0 ? _f : 'null'))
|
|
1713
|
-
.replace('{itemSetName}', String((_g = request.getItemSetName()) !== null && _g !== void 0 ? _g : 'null') === "" ? "null" : String((_h = request.getItemSetName()) !== null && _h !== void 0 ? _h : 'null'))
|
|
1714
|
-
.replace('{referenceOf}', String((_j = request.getReferenceOf()) !== null && _j !== void 0 ? _j : 'null') === "" ? "null" : String((_k = request.getReferenceOf()) !== null && _k !== void 0 ? _k : 'null'))
|
|
1715
|
-
.replace('{verifyType}', String((_l = request.getVerifyType()) !== null && _l !== void 0 ? _l : 'null') === "" ? "null" : String((_m = request.getVerifyType()) !== null && _m !== void 0 ? _m : 'null'));
|
|
2456
|
+
.replace('{itemName}', String((_e = request.getItemName()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getItemName()) !== null && _f !== void 0 ? _f : 'null'));
|
|
1716
2457
|
var headers = this.createAuthorizedHeaders();
|
|
1717
2458
|
if (request.getRequestId()) {
|
|
1718
2459
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1719
2460
|
}
|
|
1720
2461
|
if (request.getAccessToken()) {
|
|
1721
|
-
headers['X-GS2-ACCESS-TOKEN'] = (
|
|
1722
|
-
}
|
|
1723
|
-
if (request.getDuplicationAvoider()) {
|
|
1724
|
-
headers['X-GS2-DUPLICATION-AVOIDER'] = (_p = request.getDuplicationAvoider()) !== null && _p !== void 0 ? _p : null;
|
|
2462
|
+
headers['X-GS2-ACCESS-TOKEN'] = (_g = request.getAccessToken()) !== null && _g !== void 0 ? _g : null;
|
|
1725
2463
|
}
|
|
1726
|
-
var
|
|
1727
|
-
'contextStack': (
|
|
2464
|
+
var params = {
|
|
2465
|
+
'contextStack': (_h = request.getContextStack()) !== null && _h !== void 0 ? _h : null,
|
|
2466
|
+
'keyId': String((_j = request.getKeyId()) !== null && _j !== void 0 ? _j : null),
|
|
1728
2467
|
};
|
|
1729
|
-
return axios_1.default.
|
|
2468
|
+
return axios_1.default.get(url, {
|
|
2469
|
+
params: params,
|
|
1730
2470
|
headers: headers,
|
|
1731
2471
|
}).then(function (response) {
|
|
1732
|
-
return Result.
|
|
2472
|
+
return Result.GetSimpleItemWithSignatureResult.fromDict(response.data);
|
|
1733
2473
|
}).catch(function (error) {
|
|
1734
|
-
|
|
1735
|
-
throw JSON.parse(error.response.data.message);
|
|
1736
|
-
}
|
|
1737
|
-
else {
|
|
1738
|
-
throw [];
|
|
1739
|
-
}
|
|
2474
|
+
throw JSON.parse(error.response.data.message);
|
|
1740
2475
|
});
|
|
1741
2476
|
};
|
|
1742
|
-
Gs2InventoryRestClient.prototype.
|
|
1743
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k
|
|
1744
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/inventory/{inventoryName}/item/{itemName}/
|
|
2477
|
+
Gs2InventoryRestClient.prototype.getSimpleItemWithSignatureByUserId = function (request) {
|
|
2478
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
2479
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/simple/inventory/{inventoryName}/item/{itemName}/signature')
|
|
1745
2480
|
.replace('{service}', 'inventory')
|
|
1746
2481
|
.replace('{region}', this.session.region)
|
|
1747
2482
|
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1748
2483
|
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1749
2484
|
.replace('{userId}', String((_e = request.getUserId()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getUserId()) !== null && _f !== void 0 ? _f : 'null'))
|
|
1750
|
-
.replace('{itemName}', String((_g = request.getItemName()) !== null && _g !== void 0 ? _g : 'null') === "" ? "null" : String((_h = request.getItemName()) !== null && _h !== void 0 ? _h : 'null'))
|
|
1751
|
-
.replace('{itemSetName}', String((_j = request.getItemSetName()) !== null && _j !== void 0 ? _j : 'null') === "" ? "null" : String((_k = request.getItemSetName()) !== null && _k !== void 0 ? _k : 'null'))
|
|
1752
|
-
.replace('{referenceOf}', String((_l = request.getReferenceOf()) !== null && _l !== void 0 ? _l : 'null') === "" ? "null" : String((_m = request.getReferenceOf()) !== null && _m !== void 0 ? _m : 'null'))
|
|
1753
|
-
.replace('{verifyType}', String((_o = request.getVerifyType()) !== null && _o !== void 0 ? _o : 'null') === "" ? "null" : String((_p = request.getVerifyType()) !== null && _p !== void 0 ? _p : 'null'));
|
|
2485
|
+
.replace('{itemName}', String((_g = request.getItemName()) !== null && _g !== void 0 ? _g : 'null') === "" ? "null" : String((_h = request.getItemName()) !== null && _h !== void 0 ? _h : 'null'));
|
|
1754
2486
|
var headers = this.createAuthorizedHeaders();
|
|
1755
2487
|
if (request.getRequestId()) {
|
|
1756
2488
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1757
2489
|
}
|
|
1758
|
-
|
|
1759
|
-
|
|
1760
|
-
|
|
1761
|
-
var body = {
|
|
1762
|
-
'contextStack': (_r = request.getContextStack()) !== null && _r !== void 0 ? _r : null,
|
|
2490
|
+
var params = {
|
|
2491
|
+
'contextStack': (_j = request.getContextStack()) !== null && _j !== void 0 ? _j : null,
|
|
2492
|
+
'keyId': String((_k = request.getKeyId()) !== null && _k !== void 0 ? _k : null),
|
|
1763
2493
|
};
|
|
1764
|
-
return axios_1.default.
|
|
2494
|
+
return axios_1.default.get(url, {
|
|
2495
|
+
params: params,
|
|
1765
2496
|
headers: headers,
|
|
1766
2497
|
}).then(function (response) {
|
|
1767
|
-
return Result.
|
|
1768
|
-
}).catch(function (error) {
|
|
1769
|
-
|
|
1770
|
-
throw JSON.parse(error.response.data.message);
|
|
1771
|
-
}
|
|
1772
|
-
else {
|
|
1773
|
-
throw [];
|
|
1774
|
-
}
|
|
2498
|
+
return Result.GetSimpleItemWithSignatureByUserIdResult.fromDict(response.data);
|
|
2499
|
+
}).catch(function (error) {
|
|
2500
|
+
throw JSON.parse(error.response.data.message);
|
|
1775
2501
|
});
|
|
1776
2502
|
};
|
|
1777
|
-
Gs2InventoryRestClient.prototype.
|
|
1778
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k
|
|
1779
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/
|
|
2503
|
+
Gs2InventoryRestClient.prototype.acquireSimpleItemsByUserId = function (request) {
|
|
2504
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
2505
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/simple/inventory/{inventoryName}/acquire')
|
|
1780
2506
|
.replace('{service}', 'inventory')
|
|
1781
2507
|
.replace('{region}', this.session.region)
|
|
1782
2508
|
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1783
2509
|
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1784
|
-
.replace('{
|
|
1785
|
-
.replace('{itemSetName}', String((_g = request.getItemSetName()) !== null && _g !== void 0 ? _g : 'null') === "" ? "null" : String((_h = request.getItemSetName()) !== null && _h !== void 0 ? _h : 'null'));
|
|
2510
|
+
.replace('{userId}', String((_e = request.getUserId()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getUserId()) !== null && _f !== void 0 ? _f : 'null'));
|
|
1786
2511
|
var headers = this.createAuthorizedHeaders();
|
|
1787
2512
|
if (request.getRequestId()) {
|
|
1788
2513
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1789
2514
|
}
|
|
1790
|
-
if (request.getAccessToken()) {
|
|
1791
|
-
headers['X-GS2-ACCESS-TOKEN'] = (_j = request.getAccessToken()) !== null && _j !== void 0 ? _j : null;
|
|
1792
|
-
}
|
|
1793
2515
|
if (request.getDuplicationAvoider()) {
|
|
1794
|
-
headers['X-GS2-DUPLICATION-AVOIDER'] = (
|
|
2516
|
+
headers['X-GS2-DUPLICATION-AVOIDER'] = (_g = request.getDuplicationAvoider()) !== null && _g !== void 0 ? _g : null;
|
|
1795
2517
|
}
|
|
1796
2518
|
var body = {
|
|
1797
|
-
'contextStack': (
|
|
1798
|
-
'
|
|
2519
|
+
'contextStack': (_h = request.getContextStack()) !== null && _h !== void 0 ? _h : null,
|
|
2520
|
+
'acquireCounts': (_k = (_j = request.getAcquireCounts()) === null || _j === void 0 ? void 0 : _j.map(function (item) { return item.toDict(); })) !== null && _k !== void 0 ? _k : null,
|
|
1799
2521
|
};
|
|
1800
2522
|
return axios_1.default.post(url, body, {
|
|
1801
2523
|
headers: headers,
|
|
1802
2524
|
}).then(function (response) {
|
|
1803
|
-
return Result.
|
|
2525
|
+
return Result.AcquireSimpleItemsByUserIdResult.fromDict(response.data);
|
|
1804
2526
|
}).catch(function (error) {
|
|
1805
2527
|
if (error.response) {
|
|
1806
2528
|
throw JSON.parse(error.response.data.message);
|
|
@@ -1810,31 +2532,31 @@ var Gs2InventoryRestClient = /** @class */ (function (_super) {
|
|
|
1810
2532
|
}
|
|
1811
2533
|
});
|
|
1812
2534
|
};
|
|
1813
|
-
Gs2InventoryRestClient.prototype.
|
|
1814
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j
|
|
1815
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/
|
|
2535
|
+
Gs2InventoryRestClient.prototype.consumeSimpleItems = function (request) {
|
|
2536
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
2537
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/me/simple/inventory/{inventoryName}/consume')
|
|
1816
2538
|
.replace('{service}', 'inventory')
|
|
1817
2539
|
.replace('{region}', this.session.region)
|
|
1818
2540
|
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1819
|
-
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1820
|
-
.replace('{userId}', String((_e = request.getUserId()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getUserId()) !== null && _f !== void 0 ? _f : 'null'))
|
|
1821
|
-
.replace('{itemName}', String((_g = request.getItemName()) !== null && _g !== void 0 ? _g : 'null') === "" ? "null" : String((_h = request.getItemName()) !== null && _h !== void 0 ? _h : 'null'))
|
|
1822
|
-
.replace('{itemSetName}', String((_j = request.getItemSetName()) !== null && _j !== void 0 ? _j : 'null') === "" ? "null" : String((_k = request.getItemSetName()) !== null && _k !== void 0 ? _k : 'null'));
|
|
2541
|
+
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'));
|
|
1823
2542
|
var headers = this.createAuthorizedHeaders();
|
|
1824
2543
|
if (request.getRequestId()) {
|
|
1825
2544
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1826
2545
|
}
|
|
2546
|
+
if (request.getAccessToken()) {
|
|
2547
|
+
headers['X-GS2-ACCESS-TOKEN'] = (_e = request.getAccessToken()) !== null && _e !== void 0 ? _e : null;
|
|
2548
|
+
}
|
|
1827
2549
|
if (request.getDuplicationAvoider()) {
|
|
1828
|
-
headers['X-GS2-DUPLICATION-AVOIDER'] = (
|
|
2550
|
+
headers['X-GS2-DUPLICATION-AVOIDER'] = (_f = request.getDuplicationAvoider()) !== null && _f !== void 0 ? _f : null;
|
|
1829
2551
|
}
|
|
1830
2552
|
var body = {
|
|
1831
|
-
'contextStack': (
|
|
1832
|
-
'
|
|
2553
|
+
'contextStack': (_g = request.getContextStack()) !== null && _g !== void 0 ? _g : null,
|
|
2554
|
+
'consumeCounts': (_j = (_h = request.getConsumeCounts()) === null || _h === void 0 ? void 0 : _h.map(function (item) { return item.toDict(); })) !== null && _j !== void 0 ? _j : null,
|
|
1833
2555
|
};
|
|
1834
2556
|
return axios_1.default.post(url, body, {
|
|
1835
2557
|
headers: headers,
|
|
1836
2558
|
}).then(function (response) {
|
|
1837
|
-
return Result.
|
|
2559
|
+
return Result.ConsumeSimpleItemsResult.fromDict(response.data);
|
|
1838
2560
|
}).catch(function (error) {
|
|
1839
2561
|
if (error.response) {
|
|
1840
2562
|
throw JSON.parse(error.response.data.message);
|
|
@@ -1844,98 +2566,68 @@ var Gs2InventoryRestClient = /** @class */ (function (_super) {
|
|
|
1844
2566
|
}
|
|
1845
2567
|
});
|
|
1846
2568
|
};
|
|
1847
|
-
Gs2InventoryRestClient.prototype.
|
|
1848
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k
|
|
1849
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/
|
|
2569
|
+
Gs2InventoryRestClient.prototype.consumeSimpleItemsByUserId = function (request) {
|
|
2570
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
2571
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/simple/inventory/{inventoryName}/consume')
|
|
1850
2572
|
.replace('{service}', 'inventory')
|
|
1851
2573
|
.replace('{region}', this.session.region)
|
|
1852
2574
|
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1853
2575
|
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1854
|
-
.replace('{
|
|
1855
|
-
.replace('{itemSetName}', String((_g = request.getItemSetName()) !== null && _g !== void 0 ? _g : 'null') === "" ? "null" : String((_h = request.getItemSetName()) !== null && _h !== void 0 ? _h : 'null'))
|
|
1856
|
-
.replace('{referenceOf}', String((_j = request.getReferenceOf()) !== null && _j !== void 0 ? _j : 'null') === "" ? "null" : String((_k = request.getReferenceOf()) !== null && _k !== void 0 ? _k : 'null'));
|
|
2576
|
+
.replace('{userId}', String((_e = request.getUserId()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getUserId()) !== null && _f !== void 0 ? _f : 'null'));
|
|
1857
2577
|
var headers = this.createAuthorizedHeaders();
|
|
1858
2578
|
if (request.getRequestId()) {
|
|
1859
2579
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1860
2580
|
}
|
|
1861
|
-
if (request.getAccessToken()) {
|
|
1862
|
-
headers['X-GS2-ACCESS-TOKEN'] = (_l = request.getAccessToken()) !== null && _l !== void 0 ? _l : null;
|
|
1863
|
-
}
|
|
1864
2581
|
if (request.getDuplicationAvoider()) {
|
|
1865
|
-
headers['X-GS2-DUPLICATION-AVOIDER'] = (
|
|
2582
|
+
headers['X-GS2-DUPLICATION-AVOIDER'] = (_g = request.getDuplicationAvoider()) !== null && _g !== void 0 ? _g : null;
|
|
1866
2583
|
}
|
|
1867
|
-
var
|
|
1868
|
-
'contextStack': (
|
|
2584
|
+
var body = {
|
|
2585
|
+
'contextStack': (_h = request.getContextStack()) !== null && _h !== void 0 ? _h : null,
|
|
2586
|
+
'consumeCounts': (_k = (_j = request.getConsumeCounts()) === null || _j === void 0 ? void 0 : _j.map(function (item) { return item.toDict(); })) !== null && _k !== void 0 ? _k : null,
|
|
1869
2587
|
};
|
|
1870
|
-
return axios_1.default.
|
|
1871
|
-
params: params,
|
|
2588
|
+
return axios_1.default.post(url, body, {
|
|
1872
2589
|
headers: headers,
|
|
1873
2590
|
}).then(function (response) {
|
|
1874
|
-
return Result.
|
|
2591
|
+
return Result.ConsumeSimpleItemsByUserIdResult.fromDict(response.data);
|
|
1875
2592
|
}).catch(function (error) {
|
|
1876
|
-
|
|
2593
|
+
if (error.response) {
|
|
2594
|
+
throw JSON.parse(error.response.data.message);
|
|
2595
|
+
}
|
|
2596
|
+
else {
|
|
2597
|
+
throw [];
|
|
2598
|
+
}
|
|
1877
2599
|
});
|
|
1878
2600
|
};
|
|
1879
|
-
Gs2InventoryRestClient.prototype.
|
|
1880
|
-
var _a, _b, _c, _d, _e, _f, _g, _h
|
|
1881
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/inventory/{inventoryName}
|
|
2601
|
+
Gs2InventoryRestClient.prototype.deleteSimpleItemsByUserId = function (request) {
|
|
2602
|
+
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
2603
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/simple/inventory/{inventoryName}')
|
|
1882
2604
|
.replace('{service}', 'inventory')
|
|
1883
2605
|
.replace('{region}', this.session.region)
|
|
1884
2606
|
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
1885
2607
|
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
1886
|
-
.replace('{userId}', String((_e = request.getUserId()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getUserId()) !== null && _f !== void 0 ? _f : 'null'))
|
|
1887
|
-
.replace('{itemName}', String((_g = request.getItemName()) !== null && _g !== void 0 ? _g : 'null') === "" ? "null" : String((_h = request.getItemName()) !== null && _h !== void 0 ? _h : 'null'))
|
|
1888
|
-
.replace('{itemSetName}', String((_j = request.getItemSetName()) !== null && _j !== void 0 ? _j : 'null') === "" ? "null" : String((_k = request.getItemSetName()) !== null && _k !== void 0 ? _k : 'null'))
|
|
1889
|
-
.replace('{referenceOf}', String((_l = request.getReferenceOf()) !== null && _l !== void 0 ? _l : 'null') === "" ? "null" : String((_m = request.getReferenceOf()) !== null && _m !== void 0 ? _m : 'null'));
|
|
2608
|
+
.replace('{userId}', String((_e = request.getUserId()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getUserId()) !== null && _f !== void 0 ? _f : 'null'));
|
|
1890
2609
|
var headers = this.createAuthorizedHeaders();
|
|
1891
2610
|
if (request.getRequestId()) {
|
|
1892
2611
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1893
2612
|
}
|
|
1894
2613
|
if (request.getDuplicationAvoider()) {
|
|
1895
|
-
headers['X-GS2-DUPLICATION-AVOIDER'] = (
|
|
2614
|
+
headers['X-GS2-DUPLICATION-AVOIDER'] = (_g = request.getDuplicationAvoider()) !== null && _g !== void 0 ? _g : null;
|
|
1896
2615
|
}
|
|
1897
2616
|
var params = {
|
|
1898
|
-
'contextStack': (
|
|
2617
|
+
'contextStack': (_h = request.getContextStack()) !== null && _h !== void 0 ? _h : null,
|
|
1899
2618
|
};
|
|
1900
2619
|
return axios_1.default.delete(url, {
|
|
1901
2620
|
params: params,
|
|
1902
2621
|
headers: headers,
|
|
1903
2622
|
}).then(function (response) {
|
|
1904
|
-
return Result.
|
|
2623
|
+
return Result.DeleteSimpleItemsByUserIdResult.fromDict(response.data);
|
|
1905
2624
|
}).catch(function (error) {
|
|
1906
2625
|
throw JSON.parse(error.response.data.message);
|
|
1907
2626
|
});
|
|
1908
2627
|
};
|
|
1909
|
-
Gs2InventoryRestClient.prototype.
|
|
1910
|
-
var _a, _b, _c;
|
|
1911
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/stamp/item/reference/add')
|
|
1912
|
-
.replace('{service}', 'inventory')
|
|
1913
|
-
.replace('{region}', this.session.region);
|
|
1914
|
-
var headers = this.createAuthorizedHeaders();
|
|
1915
|
-
if (request.getRequestId()) {
|
|
1916
|
-
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
1917
|
-
}
|
|
1918
|
-
var body = {
|
|
1919
|
-
'contextStack': (_a = request.getContextStack()) !== null && _a !== void 0 ? _a : null,
|
|
1920
|
-
'stampSheet': (_b = request.getStampSheet()) !== null && _b !== void 0 ? _b : null,
|
|
1921
|
-
'keyId': (_c = request.getKeyId()) !== null && _c !== void 0 ? _c : null,
|
|
1922
|
-
};
|
|
1923
|
-
return axios_1.default.post(url, body, {
|
|
1924
|
-
headers: headers,
|
|
1925
|
-
}).then(function (response) {
|
|
1926
|
-
return Result.AddReferenceOfItemSetByStampSheetResult.fromDict(response.data);
|
|
1927
|
-
}).catch(function (error) {
|
|
1928
|
-
if (error.response) {
|
|
1929
|
-
throw JSON.parse(error.response.data.message);
|
|
1930
|
-
}
|
|
1931
|
-
else {
|
|
1932
|
-
throw [];
|
|
1933
|
-
}
|
|
1934
|
-
});
|
|
1935
|
-
};
|
|
1936
|
-
Gs2InventoryRestClient.prototype.deleteReferenceOfItemSetByStampSheet = function (request) {
|
|
2628
|
+
Gs2InventoryRestClient.prototype.acquireSimpleItemsByStampSheet = function (request) {
|
|
1937
2629
|
var _a, _b, _c;
|
|
1938
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/stamp/item/
|
|
2630
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/stamp/simple/item/acquire')
|
|
1939
2631
|
.replace('{service}', 'inventory')
|
|
1940
2632
|
.replace('{region}', this.session.region);
|
|
1941
2633
|
var headers = this.createAuthorizedHeaders();
|
|
@@ -1950,7 +2642,7 @@ var Gs2InventoryRestClient = /** @class */ (function (_super) {
|
|
|
1950
2642
|
return axios_1.default.post(url, body, {
|
|
1951
2643
|
headers: headers,
|
|
1952
2644
|
}).then(function (response) {
|
|
1953
|
-
return Result.
|
|
2645
|
+
return Result.AcquireSimpleItemsByStampSheetResult.fromDict(response.data);
|
|
1954
2646
|
}).catch(function (error) {
|
|
1955
2647
|
if (error.response) {
|
|
1956
2648
|
throw JSON.parse(error.response.data.message);
|
|
@@ -1960,9 +2652,9 @@ var Gs2InventoryRestClient = /** @class */ (function (_super) {
|
|
|
1960
2652
|
}
|
|
1961
2653
|
});
|
|
1962
2654
|
};
|
|
1963
|
-
Gs2InventoryRestClient.prototype.
|
|
2655
|
+
Gs2InventoryRestClient.prototype.consumeSimpleItemsByStampTask = function (request) {
|
|
1964
2656
|
var _a, _b, _c;
|
|
1965
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/stamp/item/
|
|
2657
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/stamp/simple/item/consume')
|
|
1966
2658
|
.replace('{service}', 'inventory')
|
|
1967
2659
|
.replace('{region}', this.session.region);
|
|
1968
2660
|
var headers = this.createAuthorizedHeaders();
|
|
@@ -1977,7 +2669,7 @@ var Gs2InventoryRestClient = /** @class */ (function (_super) {
|
|
|
1977
2669
|
return axios_1.default.post(url, body, {
|
|
1978
2670
|
headers: headers,
|
|
1979
2671
|
}).then(function (response) {
|
|
1980
|
-
return Result.
|
|
2672
|
+
return Result.ConsumeSimpleItemsByStampTaskResult.fromDict(response.data);
|
|
1981
2673
|
}).catch(function (error) {
|
|
1982
2674
|
if (error.response) {
|
|
1983
2675
|
throw JSON.parse(error.response.data.message);
|
|
@@ -1987,9 +2679,9 @@ var Gs2InventoryRestClient = /** @class */ (function (_super) {
|
|
|
1987
2679
|
}
|
|
1988
2680
|
});
|
|
1989
2681
|
};
|
|
1990
|
-
Gs2InventoryRestClient.prototype.
|
|
2682
|
+
Gs2InventoryRestClient.prototype.describeBigItems = function (request) {
|
|
1991
2683
|
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
1992
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/me/
|
|
2684
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/me/big/inventory/{inventoryName}/item')
|
|
1993
2685
|
.replace('{service}', 'inventory')
|
|
1994
2686
|
.replace('{region}', this.session.region)
|
|
1995
2687
|
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
@@ -2010,14 +2702,14 @@ var Gs2InventoryRestClient = /** @class */ (function (_super) {
|
|
|
2010
2702
|
params: params,
|
|
2011
2703
|
headers: headers,
|
|
2012
2704
|
}).then(function (response) {
|
|
2013
|
-
return Result.
|
|
2705
|
+
return Result.DescribeBigItemsResult.fromDict(response.data);
|
|
2014
2706
|
}).catch(function (error) {
|
|
2015
2707
|
throw JSON.parse(error.response.data.message);
|
|
2016
2708
|
});
|
|
2017
2709
|
};
|
|
2018
|
-
Gs2InventoryRestClient.prototype.
|
|
2710
|
+
Gs2InventoryRestClient.prototype.describeBigItemsByUserId = function (request) {
|
|
2019
2711
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
2020
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/
|
|
2712
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/big/inventory/{inventoryName}/item')
|
|
2021
2713
|
.replace('{service}', 'inventory')
|
|
2022
2714
|
.replace('{region}', this.session.region)
|
|
2023
2715
|
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
@@ -2036,14 +2728,14 @@ var Gs2InventoryRestClient = /** @class */ (function (_super) {
|
|
|
2036
2728
|
params: params,
|
|
2037
2729
|
headers: headers,
|
|
2038
2730
|
}).then(function (response) {
|
|
2039
|
-
return Result.
|
|
2731
|
+
return Result.DescribeBigItemsByUserIdResult.fromDict(response.data);
|
|
2040
2732
|
}).catch(function (error) {
|
|
2041
2733
|
throw JSON.parse(error.response.data.message);
|
|
2042
2734
|
});
|
|
2043
2735
|
};
|
|
2044
|
-
Gs2InventoryRestClient.prototype.
|
|
2736
|
+
Gs2InventoryRestClient.prototype.getBigItem = function (request) {
|
|
2045
2737
|
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
2046
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/me/
|
|
2738
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/me/big/inventory/{inventoryName}/item/{itemName}')
|
|
2047
2739
|
.replace('{service}', 'inventory')
|
|
2048
2740
|
.replace('{region}', this.session.region)
|
|
2049
2741
|
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
@@ -2063,14 +2755,14 @@ var Gs2InventoryRestClient = /** @class */ (function (_super) {
|
|
|
2063
2755
|
params: params,
|
|
2064
2756
|
headers: headers,
|
|
2065
2757
|
}).then(function (response) {
|
|
2066
|
-
return Result.
|
|
2758
|
+
return Result.GetBigItemResult.fromDict(response.data);
|
|
2067
2759
|
}).catch(function (error) {
|
|
2068
2760
|
throw JSON.parse(error.response.data.message);
|
|
2069
2761
|
});
|
|
2070
2762
|
};
|
|
2071
|
-
Gs2InventoryRestClient.prototype.
|
|
2763
|
+
Gs2InventoryRestClient.prototype.getBigItemByUserId = function (request) {
|
|
2072
2764
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
2073
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/
|
|
2765
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/big/inventory/{inventoryName}/item/{itemName}')
|
|
2074
2766
|
.replace('{service}', 'inventory')
|
|
2075
2767
|
.replace('{region}', this.session.region)
|
|
2076
2768
|
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
@@ -2088,42 +2780,14 @@ var Gs2InventoryRestClient = /** @class */ (function (_super) {
|
|
|
2088
2780
|
params: params,
|
|
2089
2781
|
headers: headers,
|
|
2090
2782
|
}).then(function (response) {
|
|
2091
|
-
return Result.
|
|
2092
|
-
}).catch(function (error) {
|
|
2093
|
-
throw JSON.parse(error.response.data.message);
|
|
2094
|
-
});
|
|
2095
|
-
};
|
|
2096
|
-
Gs2InventoryRestClient.prototype.getSimpleItemWithSignature = function (request) {
|
|
2097
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
2098
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/me/simple/inventory/{inventoryName}/item/{itemName}/signature')
|
|
2099
|
-
.replace('{service}', 'inventory')
|
|
2100
|
-
.replace('{region}', this.session.region)
|
|
2101
|
-
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
2102
|
-
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
2103
|
-
.replace('{itemName}', String((_e = request.getItemName()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getItemName()) !== null && _f !== void 0 ? _f : 'null'));
|
|
2104
|
-
var headers = this.createAuthorizedHeaders();
|
|
2105
|
-
if (request.getRequestId()) {
|
|
2106
|
-
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
2107
|
-
}
|
|
2108
|
-
if (request.getAccessToken()) {
|
|
2109
|
-
headers['X-GS2-ACCESS-TOKEN'] = (_g = request.getAccessToken()) !== null && _g !== void 0 ? _g : null;
|
|
2110
|
-
}
|
|
2111
|
-
var params = {
|
|
2112
|
-
'contextStack': (_h = request.getContextStack()) !== null && _h !== void 0 ? _h : null,
|
|
2113
|
-
'keyId': String((_j = request.getKeyId()) !== null && _j !== void 0 ? _j : null),
|
|
2114
|
-
};
|
|
2115
|
-
return axios_1.default.get(url, {
|
|
2116
|
-
params: params,
|
|
2117
|
-
headers: headers,
|
|
2118
|
-
}).then(function (response) {
|
|
2119
|
-
return Result.GetSimpleItemWithSignatureResult.fromDict(response.data);
|
|
2783
|
+
return Result.GetBigItemByUserIdResult.fromDict(response.data);
|
|
2120
2784
|
}).catch(function (error) {
|
|
2121
2785
|
throw JSON.parse(error.response.data.message);
|
|
2122
2786
|
});
|
|
2123
2787
|
};
|
|
2124
|
-
Gs2InventoryRestClient.prototype.
|
|
2125
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
2126
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/
|
|
2788
|
+
Gs2InventoryRestClient.prototype.acquireBigItemByUserId = function (request) {
|
|
2789
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l;
|
|
2790
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/big/inventory/{inventoryName}/{itemName}/acquire')
|
|
2127
2791
|
.replace('{service}', 'inventory')
|
|
2128
2792
|
.replace('{region}', this.session.region)
|
|
2129
2793
|
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
@@ -2134,42 +2798,17 @@ var Gs2InventoryRestClient = /** @class */ (function (_super) {
|
|
|
2134
2798
|
if (request.getRequestId()) {
|
|
2135
2799
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
2136
2800
|
}
|
|
2137
|
-
var params = {
|
|
2138
|
-
'contextStack': (_j = request.getContextStack()) !== null && _j !== void 0 ? _j : null,
|
|
2139
|
-
'keyId': String((_k = request.getKeyId()) !== null && _k !== void 0 ? _k : null),
|
|
2140
|
-
};
|
|
2141
|
-
return axios_1.default.get(url, {
|
|
2142
|
-
params: params,
|
|
2143
|
-
headers: headers,
|
|
2144
|
-
}).then(function (response) {
|
|
2145
|
-
return Result.GetSimpleItemWithSignatureByUserIdResult.fromDict(response.data);
|
|
2146
|
-
}).catch(function (error) {
|
|
2147
|
-
throw JSON.parse(error.response.data.message);
|
|
2148
|
-
});
|
|
2149
|
-
};
|
|
2150
|
-
Gs2InventoryRestClient.prototype.acquireSimpleItemsByUserId = function (request) {
|
|
2151
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
2152
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/simple/inventory/{inventoryName}/acquire')
|
|
2153
|
-
.replace('{service}', 'inventory')
|
|
2154
|
-
.replace('{region}', this.session.region)
|
|
2155
|
-
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
2156
|
-
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
2157
|
-
.replace('{userId}', String((_e = request.getUserId()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getUserId()) !== null && _f !== void 0 ? _f : 'null'));
|
|
2158
|
-
var headers = this.createAuthorizedHeaders();
|
|
2159
|
-
if (request.getRequestId()) {
|
|
2160
|
-
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
2161
|
-
}
|
|
2162
2801
|
if (request.getDuplicationAvoider()) {
|
|
2163
|
-
headers['X-GS2-DUPLICATION-AVOIDER'] = (
|
|
2802
|
+
headers['X-GS2-DUPLICATION-AVOIDER'] = (_j = request.getDuplicationAvoider()) !== null && _j !== void 0 ? _j : null;
|
|
2164
2803
|
}
|
|
2165
2804
|
var body = {
|
|
2166
|
-
'contextStack': (
|
|
2167
|
-
'
|
|
2805
|
+
'contextStack': (_k = request.getContextStack()) !== null && _k !== void 0 ? _k : null,
|
|
2806
|
+
'acquireCount': (_l = request.getAcquireCount()) !== null && _l !== void 0 ? _l : null,
|
|
2168
2807
|
};
|
|
2169
2808
|
return axios_1.default.post(url, body, {
|
|
2170
2809
|
headers: headers,
|
|
2171
2810
|
}).then(function (response) {
|
|
2172
|
-
return Result.
|
|
2811
|
+
return Result.AcquireBigItemByUserIdResult.fromDict(response.data);
|
|
2173
2812
|
}).catch(function (error) {
|
|
2174
2813
|
if (error.response) {
|
|
2175
2814
|
throw JSON.parse(error.response.data.message);
|
|
@@ -2179,31 +2818,32 @@ var Gs2InventoryRestClient = /** @class */ (function (_super) {
|
|
|
2179
2818
|
}
|
|
2180
2819
|
});
|
|
2181
2820
|
};
|
|
2182
|
-
Gs2InventoryRestClient.prototype.
|
|
2183
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
2184
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/me/
|
|
2821
|
+
Gs2InventoryRestClient.prototype.consumeBigItem = function (request) {
|
|
2822
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
2823
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/me/big/inventory/{inventoryName}/{itemName}/consume')
|
|
2185
2824
|
.replace('{service}', 'inventory')
|
|
2186
2825
|
.replace('{region}', this.session.region)
|
|
2187
2826
|
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
2188
|
-
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
2827
|
+
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
2828
|
+
.replace('{itemName}', String((_e = request.getItemName()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getItemName()) !== null && _f !== void 0 ? _f : 'null'));
|
|
2189
2829
|
var headers = this.createAuthorizedHeaders();
|
|
2190
2830
|
if (request.getRequestId()) {
|
|
2191
2831
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
2192
2832
|
}
|
|
2193
2833
|
if (request.getAccessToken()) {
|
|
2194
|
-
headers['X-GS2-ACCESS-TOKEN'] = (
|
|
2834
|
+
headers['X-GS2-ACCESS-TOKEN'] = (_g = request.getAccessToken()) !== null && _g !== void 0 ? _g : null;
|
|
2195
2835
|
}
|
|
2196
2836
|
if (request.getDuplicationAvoider()) {
|
|
2197
|
-
headers['X-GS2-DUPLICATION-AVOIDER'] = (
|
|
2837
|
+
headers['X-GS2-DUPLICATION-AVOIDER'] = (_h = request.getDuplicationAvoider()) !== null && _h !== void 0 ? _h : null;
|
|
2198
2838
|
}
|
|
2199
2839
|
var body = {
|
|
2200
|
-
'contextStack': (
|
|
2201
|
-
'
|
|
2840
|
+
'contextStack': (_j = request.getContextStack()) !== null && _j !== void 0 ? _j : null,
|
|
2841
|
+
'consumeCount': (_k = request.getConsumeCount()) !== null && _k !== void 0 ? _k : null,
|
|
2202
2842
|
};
|
|
2203
2843
|
return axios_1.default.post(url, body, {
|
|
2204
2844
|
headers: headers,
|
|
2205
2845
|
}).then(function (response) {
|
|
2206
|
-
return Result.
|
|
2846
|
+
return Result.ConsumeBigItemResult.fromDict(response.data);
|
|
2207
2847
|
}).catch(function (error) {
|
|
2208
2848
|
if (error.response) {
|
|
2209
2849
|
throw JSON.parse(error.response.data.message);
|
|
@@ -2213,29 +2853,30 @@ var Gs2InventoryRestClient = /** @class */ (function (_super) {
|
|
|
2213
2853
|
}
|
|
2214
2854
|
});
|
|
2215
2855
|
};
|
|
2216
|
-
Gs2InventoryRestClient.prototype.
|
|
2217
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
2218
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/
|
|
2856
|
+
Gs2InventoryRestClient.prototype.consumeBigItemByUserId = function (request) {
|
|
2857
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l;
|
|
2858
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/big/inventory/{inventoryName}/{itemName}/consume')
|
|
2219
2859
|
.replace('{service}', 'inventory')
|
|
2220
2860
|
.replace('{region}', this.session.region)
|
|
2221
2861
|
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
2222
2862
|
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
2223
|
-
.replace('{userId}', String((_e = request.getUserId()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getUserId()) !== null && _f !== void 0 ? _f : 'null'))
|
|
2863
|
+
.replace('{userId}', String((_e = request.getUserId()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getUserId()) !== null && _f !== void 0 ? _f : 'null'))
|
|
2864
|
+
.replace('{itemName}', String((_g = request.getItemName()) !== null && _g !== void 0 ? _g : 'null') === "" ? "null" : String((_h = request.getItemName()) !== null && _h !== void 0 ? _h : 'null'));
|
|
2224
2865
|
var headers = this.createAuthorizedHeaders();
|
|
2225
2866
|
if (request.getRequestId()) {
|
|
2226
2867
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
2227
2868
|
}
|
|
2228
2869
|
if (request.getDuplicationAvoider()) {
|
|
2229
|
-
headers['X-GS2-DUPLICATION-AVOIDER'] = (
|
|
2870
|
+
headers['X-GS2-DUPLICATION-AVOIDER'] = (_j = request.getDuplicationAvoider()) !== null && _j !== void 0 ? _j : null;
|
|
2230
2871
|
}
|
|
2231
2872
|
var body = {
|
|
2232
|
-
'contextStack': (
|
|
2233
|
-
'
|
|
2873
|
+
'contextStack': (_k = request.getContextStack()) !== null && _k !== void 0 ? _k : null,
|
|
2874
|
+
'consumeCount': (_l = request.getConsumeCount()) !== null && _l !== void 0 ? _l : null,
|
|
2234
2875
|
};
|
|
2235
2876
|
return axios_1.default.post(url, body, {
|
|
2236
2877
|
headers: headers,
|
|
2237
2878
|
}).then(function (response) {
|
|
2238
|
-
return Result.
|
|
2879
|
+
return Result.ConsumeBigItemByUserIdResult.fromDict(response.data);
|
|
2239
2880
|
}).catch(function (error) {
|
|
2240
2881
|
if (error.response) {
|
|
2241
2882
|
throw JSON.parse(error.response.data.message);
|
|
@@ -2245,36 +2886,37 @@ var Gs2InventoryRestClient = /** @class */ (function (_super) {
|
|
|
2245
2886
|
}
|
|
2246
2887
|
});
|
|
2247
2888
|
};
|
|
2248
|
-
Gs2InventoryRestClient.prototype.
|
|
2249
|
-
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
2250
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/
|
|
2889
|
+
Gs2InventoryRestClient.prototype.deleteBigItemByUserId = function (request) {
|
|
2890
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
2891
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/{namespaceName}/user/{userId}/big/inventory/{inventoryName}')
|
|
2251
2892
|
.replace('{service}', 'inventory')
|
|
2252
2893
|
.replace('{region}', this.session.region)
|
|
2253
2894
|
.replace('{namespaceName}', String((_a = request.getNamespaceName()) !== null && _a !== void 0 ? _a : 'null') === "" ? "null" : String((_b = request.getNamespaceName()) !== null && _b !== void 0 ? _b : 'null'))
|
|
2254
2895
|
.replace('{inventoryName}', String((_c = request.getInventoryName()) !== null && _c !== void 0 ? _c : 'null') === "" ? "null" : String((_d = request.getInventoryName()) !== null && _d !== void 0 ? _d : 'null'))
|
|
2255
|
-
.replace('{userId}', String((_e = request.getUserId()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getUserId()) !== null && _f !== void 0 ? _f : 'null'))
|
|
2896
|
+
.replace('{userId}', String((_e = request.getUserId()) !== null && _e !== void 0 ? _e : 'null') === "" ? "null" : String((_f = request.getUserId()) !== null && _f !== void 0 ? _f : 'null'))
|
|
2897
|
+
.replace('{itemName}', String((_g = request.getItemName()) !== null && _g !== void 0 ? _g : 'null') === "" ? "null" : String((_h = request.getItemName()) !== null && _h !== void 0 ? _h : 'null'));
|
|
2256
2898
|
var headers = this.createAuthorizedHeaders();
|
|
2257
2899
|
if (request.getRequestId()) {
|
|
2258
2900
|
headers['X-GS2-REQUEST-ID'] = request.getRequestId();
|
|
2259
2901
|
}
|
|
2260
2902
|
if (request.getDuplicationAvoider()) {
|
|
2261
|
-
headers['X-GS2-DUPLICATION-AVOIDER'] = (
|
|
2903
|
+
headers['X-GS2-DUPLICATION-AVOIDER'] = (_j = request.getDuplicationAvoider()) !== null && _j !== void 0 ? _j : null;
|
|
2262
2904
|
}
|
|
2263
2905
|
var params = {
|
|
2264
|
-
'contextStack': (
|
|
2906
|
+
'contextStack': (_k = request.getContextStack()) !== null && _k !== void 0 ? _k : null,
|
|
2265
2907
|
};
|
|
2266
2908
|
return axios_1.default.delete(url, {
|
|
2267
2909
|
params: params,
|
|
2268
2910
|
headers: headers,
|
|
2269
2911
|
}).then(function (response) {
|
|
2270
|
-
return Result.
|
|
2912
|
+
return Result.DeleteBigItemByUserIdResult.fromDict(response.data);
|
|
2271
2913
|
}).catch(function (error) {
|
|
2272
2914
|
throw JSON.parse(error.response.data.message);
|
|
2273
2915
|
});
|
|
2274
2916
|
};
|
|
2275
|
-
Gs2InventoryRestClient.prototype.
|
|
2917
|
+
Gs2InventoryRestClient.prototype.acquireBigItemByStampSheet = function (request) {
|
|
2276
2918
|
var _a, _b, _c;
|
|
2277
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/stamp/
|
|
2919
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/stamp/big/item/acquire')
|
|
2278
2920
|
.replace('{service}', 'inventory')
|
|
2279
2921
|
.replace('{region}', this.session.region);
|
|
2280
2922
|
var headers = this.createAuthorizedHeaders();
|
|
@@ -2289,7 +2931,7 @@ var Gs2InventoryRestClient = /** @class */ (function (_super) {
|
|
|
2289
2931
|
return axios_1.default.post(url, body, {
|
|
2290
2932
|
headers: headers,
|
|
2291
2933
|
}).then(function (response) {
|
|
2292
|
-
return Result.
|
|
2934
|
+
return Result.AcquireBigItemByStampSheetResult.fromDict(response.data);
|
|
2293
2935
|
}).catch(function (error) {
|
|
2294
2936
|
if (error.response) {
|
|
2295
2937
|
throw JSON.parse(error.response.data.message);
|
|
@@ -2299,9 +2941,9 @@ var Gs2InventoryRestClient = /** @class */ (function (_super) {
|
|
|
2299
2941
|
}
|
|
2300
2942
|
});
|
|
2301
2943
|
};
|
|
2302
|
-
Gs2InventoryRestClient.prototype.
|
|
2944
|
+
Gs2InventoryRestClient.prototype.consumeBigItemByStampTask = function (request) {
|
|
2303
2945
|
var _a, _b, _c;
|
|
2304
|
-
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/stamp/
|
|
2946
|
+
var url = (model_1.Gs2Constant.ENDPOINT_HOST + '/stamp/big/item/consume')
|
|
2305
2947
|
.replace('{service}', 'inventory')
|
|
2306
2948
|
.replace('{region}', this.session.region);
|
|
2307
2949
|
var headers = this.createAuthorizedHeaders();
|
|
@@ -2316,7 +2958,7 @@ var Gs2InventoryRestClient = /** @class */ (function (_super) {
|
|
|
2316
2958
|
return axios_1.default.post(url, body, {
|
|
2317
2959
|
headers: headers,
|
|
2318
2960
|
}).then(function (response) {
|
|
2319
|
-
return Result.
|
|
2961
|
+
return Result.ConsumeBigItemByStampTaskResult.fromDict(response.data);
|
|
2320
2962
|
}).catch(function (error) {
|
|
2321
2963
|
if (error.response) {
|
|
2322
2964
|
throw JSON.parse(error.response.data.message);
|