@handsondigital/idplugger-admin 2.6.2 → 2.7.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.openapi-generator/FILES +14 -0
- package/README.md +21 -2
- package/api.ts +2867 -1728
- package/dist/api.d.ts +820 -0
- package/dist/api.js +706 -1
- package/docs/AdminPromotionConfigsIndex200Response.md +26 -0
- package/docs/AdminPromotionConfigsIndex200ResponseConfigsInner.md +28 -0
- package/docs/AdminPromotionConfigsIndex500Response.md +24 -0
- package/docs/AdminPromotionConfigsShow200Response.md +26 -0
- package/docs/AdminPromotionConfigsShow200ResponseConfig.md +28 -0
- package/docs/AdminPromotionConfigsShow404Response.md +24 -0
- package/docs/AdminPromotionConfigsStore201Response.md +26 -0
- package/docs/AdminPromotionConfigsStoreRequest.md +26 -0
- package/docs/AdminPromotionConfigsUpdate200Response.md +26 -0
- package/docs/AdminPromotionConfigsUpdateRequest.md +24 -0
- package/docs/AdminPromotionConfigsUpsert200Response.md +26 -0
- package/docs/AdminPromotionConfigsValidKeys200Response.md +24 -0
- package/docs/AdminPromotionConfigsValidKeys200ResponseValidKeysInner.md +22 -0
- package/docs/ConfigsApi.md +351 -0
- package/package.json +1 -1
package/dist/api.js
CHANGED
|
@@ -84,13 +84,53 @@ var __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {
|
|
|
84
84
|
return to.concat(ar || Array.prototype.slice.call(from));
|
|
85
85
|
};
|
|
86
86
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
87
|
-
exports.
|
|
87
|
+
exports.RolesApi = exports.RolesApiFactory = exports.RolesApiFp = exports.RolesApiAxiosParamCreator = exports.PromotionApi = exports.PromotionApiFactory = exports.PromotionApiFp = exports.PromotionApiAxiosParamCreator = exports.PermissionsApi = exports.PermissionsApiFactory = exports.PermissionsApiFp = exports.PermissionsApiAxiosParamCreator = exports.MetricsApi = exports.MetricsApiFactory = exports.MetricsApiFp = exports.MetricsApiAxiosParamCreator = exports.LogsApi = exports.LogsApiFactory = exports.LogsApiFp = exports.LogsApiAxiosParamCreator = exports.ErrorsApi = exports.ErrorsApiFactory = exports.ErrorsApiFp = exports.ErrorsApiAxiosParamCreator = exports.ErrorReportsApi = exports.ErrorReportsApiFactory = exports.ErrorReportsApiFp = exports.ErrorReportsApiAxiosParamCreator = exports.CustomerServiceApi = exports.CustomerServiceApiFactory = exports.CustomerServiceApiFp = exports.CustomerServiceApiAxiosParamCreator = exports.AdminPromotionConfigsIndexTypeEnum = exports.ConfigsApi = exports.ConfigsApiFactory = exports.ConfigsApiFp = exports.ConfigsApiAxiosParamCreator = exports.AuthApi = exports.AuthApiFactory = exports.AuthApiFp = exports.AuthApiAxiosParamCreator = exports.ApiLogsApi = exports.ApiLogsApiFactory = exports.ApiLogsApiFp = exports.ApiLogsApiAxiosParamCreator = exports.PromotionStartRequestPermissionsEnum = exports.PromotionStart200ResponseUserPermissionsEnum = exports.AdminPromotionConfigsUpdateRequestTypeEnum = exports.AdminPromotionConfigsStoreRequestTypeEnum = exports.AdminPromotionConfigsIndex200ResponseConfigsInnerTypeEnum = void 0;
|
|
88
|
+
exports.UserApi = exports.UserApiFactory = exports.UserApiFp = exports.UserApiAxiosParamCreator = exports.StepsApi = exports.StepsApiFactory = exports.StepsApiFp = exports.StepsApiAxiosParamCreator = void 0;
|
|
88
89
|
var axios_1 = require("axios");
|
|
89
90
|
// Some imports not used depending on template conditions
|
|
90
91
|
// @ts-ignore
|
|
91
92
|
var common_1 = require("./common");
|
|
92
93
|
// @ts-ignore
|
|
93
94
|
var base_1 = require("./base");
|
|
95
|
+
exports.AdminPromotionConfigsIndex200ResponseConfigsInnerTypeEnum = {
|
|
96
|
+
Text: 'text',
|
|
97
|
+
Uuid: 'uuid',
|
|
98
|
+
Html: 'html',
|
|
99
|
+
Url: 'url',
|
|
100
|
+
PathUrl: 'path_url',
|
|
101
|
+
Integer: 'integer',
|
|
102
|
+
Double: 'double',
|
|
103
|
+
File: 'file',
|
|
104
|
+
Json: 'json',
|
|
105
|
+
Date: 'date',
|
|
106
|
+
Datetime: 'datetime'
|
|
107
|
+
};
|
|
108
|
+
exports.AdminPromotionConfigsStoreRequestTypeEnum = {
|
|
109
|
+
Text: 'text',
|
|
110
|
+
Uuid: 'uuid',
|
|
111
|
+
Html: 'html',
|
|
112
|
+
Url: 'url',
|
|
113
|
+
PathUrl: 'path_url',
|
|
114
|
+
Integer: 'integer',
|
|
115
|
+
Double: 'double',
|
|
116
|
+
File: 'file',
|
|
117
|
+
Json: 'json',
|
|
118
|
+
Date: 'date',
|
|
119
|
+
Datetime: 'datetime'
|
|
120
|
+
};
|
|
121
|
+
exports.AdminPromotionConfigsUpdateRequestTypeEnum = {
|
|
122
|
+
Text: 'text',
|
|
123
|
+
Uuid: 'uuid',
|
|
124
|
+
Html: 'html',
|
|
125
|
+
Url: 'url',
|
|
126
|
+
PathUrl: 'path_url',
|
|
127
|
+
Integer: 'integer',
|
|
128
|
+
Double: 'double',
|
|
129
|
+
File: 'file',
|
|
130
|
+
Json: 'json',
|
|
131
|
+
Date: 'date',
|
|
132
|
+
Datetime: 'datetime'
|
|
133
|
+
};
|
|
94
134
|
exports.PromotionStart200ResponseUserPermissionsEnum = {
|
|
95
135
|
PromotionUsersIndex: 'promotion.users.index',
|
|
96
136
|
PromotionUsersCreate: 'promotion.users.create',
|
|
@@ -891,6 +931,671 @@ var AuthApi = /** @class */ (function (_super) {
|
|
|
891
931
|
return AuthApi;
|
|
892
932
|
}(base_1.BaseAPI));
|
|
893
933
|
exports.AuthApi = AuthApi;
|
|
934
|
+
/**
|
|
935
|
+
* ConfigsApi - axios parameter creator
|
|
936
|
+
* @export
|
|
937
|
+
*/
|
|
938
|
+
var ConfigsApiAxiosParamCreator = function (configuration) {
|
|
939
|
+
var _this = this;
|
|
940
|
+
return {
|
|
941
|
+
/**
|
|
942
|
+
*
|
|
943
|
+
* @summary Listar configurações de uma promoção
|
|
944
|
+
* @param {string} promotionId UUID da promoção
|
|
945
|
+
* @param {string} [key] Filtrar por chave (busca parcial)
|
|
946
|
+
* @param {string} [grupo] Filtrar por grupo
|
|
947
|
+
* @param {AdminPromotionConfigsIndexTypeEnum} [type] Filtrar por tipo
|
|
948
|
+
* @param {number} [perPage] Itens por página
|
|
949
|
+
* @param {number} [page] Número da página
|
|
950
|
+
* @param {*} [options] Override http request option.
|
|
951
|
+
* @throws {RequiredError}
|
|
952
|
+
*/
|
|
953
|
+
adminPromotionConfigsIndex: function (promotionId_1, key_1, grupo_1, type_1, perPage_1, page_1) {
|
|
954
|
+
var args_1 = [];
|
|
955
|
+
for (var _i = 6; _i < arguments.length; _i++) {
|
|
956
|
+
args_1[_i - 6] = arguments[_i];
|
|
957
|
+
}
|
|
958
|
+
return __awaiter(_this, __spreadArray([promotionId_1, key_1, grupo_1, type_1, perPage_1, page_1], args_1, true), void 0, function (promotionId, key, grupo, type, perPage, page, options) {
|
|
959
|
+
var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
960
|
+
if (options === void 0) { options = {}; }
|
|
961
|
+
return __generator(this, function (_a) {
|
|
962
|
+
switch (_a.label) {
|
|
963
|
+
case 0:
|
|
964
|
+
// verify required parameter 'promotionId' is not null or undefined
|
|
965
|
+
(0, common_1.assertParamExists)('adminPromotionConfigsIndex', 'promotionId', promotionId);
|
|
966
|
+
localVarPath = "/v3/admin/promotion/{promotion_id}/configs"
|
|
967
|
+
.replace("{".concat("promotion_id", "}"), encodeURIComponent(String(promotionId)));
|
|
968
|
+
localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
969
|
+
if (configuration) {
|
|
970
|
+
baseOptions = configuration.baseOptions;
|
|
971
|
+
}
|
|
972
|
+
localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
|
|
973
|
+
localVarHeaderParameter = {};
|
|
974
|
+
localVarQueryParameter = {};
|
|
975
|
+
// authentication bearerAuth required
|
|
976
|
+
// http bearer authentication required
|
|
977
|
+
return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
|
|
978
|
+
case 1:
|
|
979
|
+
// authentication bearerAuth required
|
|
980
|
+
// http bearer authentication required
|
|
981
|
+
_a.sent();
|
|
982
|
+
if (key !== undefined) {
|
|
983
|
+
localVarQueryParameter['key'] = key;
|
|
984
|
+
}
|
|
985
|
+
if (grupo !== undefined) {
|
|
986
|
+
localVarQueryParameter['grupo'] = grupo;
|
|
987
|
+
}
|
|
988
|
+
if (type !== undefined) {
|
|
989
|
+
localVarQueryParameter['type'] = type;
|
|
990
|
+
}
|
|
991
|
+
if (perPage !== undefined) {
|
|
992
|
+
localVarQueryParameter['_per_page'] = perPage;
|
|
993
|
+
}
|
|
994
|
+
if (page !== undefined) {
|
|
995
|
+
localVarQueryParameter['page'] = page;
|
|
996
|
+
}
|
|
997
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
998
|
+
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
999
|
+
localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
1000
|
+
return [2 /*return*/, {
|
|
1001
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
1002
|
+
options: localVarRequestOptions,
|
|
1003
|
+
}];
|
|
1004
|
+
}
|
|
1005
|
+
});
|
|
1006
|
+
});
|
|
1007
|
+
},
|
|
1008
|
+
/**
|
|
1009
|
+
*
|
|
1010
|
+
* @summary Buscar configuração por chave
|
|
1011
|
+
* @param {string} promotionId UUID da promoção
|
|
1012
|
+
* @param {string} key Chave da configuração
|
|
1013
|
+
* @param {*} [options] Override http request option.
|
|
1014
|
+
* @throws {RequiredError}
|
|
1015
|
+
*/
|
|
1016
|
+
adminPromotionConfigsShow: function (promotionId_1, key_1) {
|
|
1017
|
+
var args_1 = [];
|
|
1018
|
+
for (var _i = 2; _i < arguments.length; _i++) {
|
|
1019
|
+
args_1[_i - 2] = arguments[_i];
|
|
1020
|
+
}
|
|
1021
|
+
return __awaiter(_this, __spreadArray([promotionId_1, key_1], args_1, true), void 0, function (promotionId, key, options) {
|
|
1022
|
+
var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
1023
|
+
if (options === void 0) { options = {}; }
|
|
1024
|
+
return __generator(this, function (_a) {
|
|
1025
|
+
switch (_a.label) {
|
|
1026
|
+
case 0:
|
|
1027
|
+
// verify required parameter 'promotionId' is not null or undefined
|
|
1028
|
+
(0, common_1.assertParamExists)('adminPromotionConfigsShow', 'promotionId', promotionId);
|
|
1029
|
+
// verify required parameter 'key' is not null or undefined
|
|
1030
|
+
(0, common_1.assertParamExists)('adminPromotionConfigsShow', 'key', key);
|
|
1031
|
+
localVarPath = "/v3/admin/promotion/{promotion_id}/configs/{key}"
|
|
1032
|
+
.replace("{".concat("promotion_id", "}"), encodeURIComponent(String(promotionId)))
|
|
1033
|
+
.replace("{".concat("key", "}"), encodeURIComponent(String(key)));
|
|
1034
|
+
localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
1035
|
+
if (configuration) {
|
|
1036
|
+
baseOptions = configuration.baseOptions;
|
|
1037
|
+
}
|
|
1038
|
+
localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
|
|
1039
|
+
localVarHeaderParameter = {};
|
|
1040
|
+
localVarQueryParameter = {};
|
|
1041
|
+
// authentication bearerAuth required
|
|
1042
|
+
// http bearer authentication required
|
|
1043
|
+
return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
|
|
1044
|
+
case 1:
|
|
1045
|
+
// authentication bearerAuth required
|
|
1046
|
+
// http bearer authentication required
|
|
1047
|
+
_a.sent();
|
|
1048
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
1049
|
+
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
1050
|
+
localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
1051
|
+
return [2 /*return*/, {
|
|
1052
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
1053
|
+
options: localVarRequestOptions,
|
|
1054
|
+
}];
|
|
1055
|
+
}
|
|
1056
|
+
});
|
|
1057
|
+
});
|
|
1058
|
+
},
|
|
1059
|
+
/**
|
|
1060
|
+
*
|
|
1061
|
+
* @summary Criar nova configuração
|
|
1062
|
+
* @param {string} promotionId UUID da promoção
|
|
1063
|
+
* @param {AdminPromotionConfigsStoreRequest} adminPromotionConfigsStoreRequest
|
|
1064
|
+
* @param {*} [options] Override http request option.
|
|
1065
|
+
* @throws {RequiredError}
|
|
1066
|
+
*/
|
|
1067
|
+
adminPromotionConfigsStore: function (promotionId_1, adminPromotionConfigsStoreRequest_1) {
|
|
1068
|
+
var args_1 = [];
|
|
1069
|
+
for (var _i = 2; _i < arguments.length; _i++) {
|
|
1070
|
+
args_1[_i - 2] = arguments[_i];
|
|
1071
|
+
}
|
|
1072
|
+
return __awaiter(_this, __spreadArray([promotionId_1, adminPromotionConfigsStoreRequest_1], args_1, true), void 0, function (promotionId, adminPromotionConfigsStoreRequest, options) {
|
|
1073
|
+
var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
1074
|
+
if (options === void 0) { options = {}; }
|
|
1075
|
+
return __generator(this, function (_a) {
|
|
1076
|
+
switch (_a.label) {
|
|
1077
|
+
case 0:
|
|
1078
|
+
// verify required parameter 'promotionId' is not null or undefined
|
|
1079
|
+
(0, common_1.assertParamExists)('adminPromotionConfigsStore', 'promotionId', promotionId);
|
|
1080
|
+
// verify required parameter 'adminPromotionConfigsStoreRequest' is not null or undefined
|
|
1081
|
+
(0, common_1.assertParamExists)('adminPromotionConfigsStore', 'adminPromotionConfigsStoreRequest', adminPromotionConfigsStoreRequest);
|
|
1082
|
+
localVarPath = "/v3/admin/promotion/{promotion_id}/configs"
|
|
1083
|
+
.replace("{".concat("promotion_id", "}"), encodeURIComponent(String(promotionId)));
|
|
1084
|
+
localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
1085
|
+
if (configuration) {
|
|
1086
|
+
baseOptions = configuration.baseOptions;
|
|
1087
|
+
}
|
|
1088
|
+
localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
|
|
1089
|
+
localVarHeaderParameter = {};
|
|
1090
|
+
localVarQueryParameter = {};
|
|
1091
|
+
// authentication bearerAuth required
|
|
1092
|
+
// http bearer authentication required
|
|
1093
|
+
return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
|
|
1094
|
+
case 1:
|
|
1095
|
+
// authentication bearerAuth required
|
|
1096
|
+
// http bearer authentication required
|
|
1097
|
+
_a.sent();
|
|
1098
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
1099
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
1100
|
+
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
1101
|
+
localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
1102
|
+
localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(adminPromotionConfigsStoreRequest, localVarRequestOptions, configuration);
|
|
1103
|
+
return [2 /*return*/, {
|
|
1104
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
1105
|
+
options: localVarRequestOptions,
|
|
1106
|
+
}];
|
|
1107
|
+
}
|
|
1108
|
+
});
|
|
1109
|
+
});
|
|
1110
|
+
},
|
|
1111
|
+
/**
|
|
1112
|
+
*
|
|
1113
|
+
* @summary Atualizar configuração por chave
|
|
1114
|
+
* @param {string} promotionId UUID da promoção
|
|
1115
|
+
* @param {string} key Chave da configuração
|
|
1116
|
+
* @param {AdminPromotionConfigsUpdateRequest} adminPromotionConfigsUpdateRequest
|
|
1117
|
+
* @param {*} [options] Override http request option.
|
|
1118
|
+
* @throws {RequiredError}
|
|
1119
|
+
*/
|
|
1120
|
+
adminPromotionConfigsUpdate: function (promotionId_1, key_1, adminPromotionConfigsUpdateRequest_1) {
|
|
1121
|
+
var args_1 = [];
|
|
1122
|
+
for (var _i = 3; _i < arguments.length; _i++) {
|
|
1123
|
+
args_1[_i - 3] = arguments[_i];
|
|
1124
|
+
}
|
|
1125
|
+
return __awaiter(_this, __spreadArray([promotionId_1, key_1, adminPromotionConfigsUpdateRequest_1], args_1, true), void 0, function (promotionId, key, adminPromotionConfigsUpdateRequest, options) {
|
|
1126
|
+
var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
1127
|
+
if (options === void 0) { options = {}; }
|
|
1128
|
+
return __generator(this, function (_a) {
|
|
1129
|
+
switch (_a.label) {
|
|
1130
|
+
case 0:
|
|
1131
|
+
// verify required parameter 'promotionId' is not null or undefined
|
|
1132
|
+
(0, common_1.assertParamExists)('adminPromotionConfigsUpdate', 'promotionId', promotionId);
|
|
1133
|
+
// verify required parameter 'key' is not null or undefined
|
|
1134
|
+
(0, common_1.assertParamExists)('adminPromotionConfigsUpdate', 'key', key);
|
|
1135
|
+
// verify required parameter 'adminPromotionConfigsUpdateRequest' is not null or undefined
|
|
1136
|
+
(0, common_1.assertParamExists)('adminPromotionConfigsUpdate', 'adminPromotionConfigsUpdateRequest', adminPromotionConfigsUpdateRequest);
|
|
1137
|
+
localVarPath = "/v3/admin/promotion/{promotion_id}/configs/{key}"
|
|
1138
|
+
.replace("{".concat("promotion_id", "}"), encodeURIComponent(String(promotionId)))
|
|
1139
|
+
.replace("{".concat("key", "}"), encodeURIComponent(String(key)));
|
|
1140
|
+
localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
1141
|
+
if (configuration) {
|
|
1142
|
+
baseOptions = configuration.baseOptions;
|
|
1143
|
+
}
|
|
1144
|
+
localVarRequestOptions = __assign(__assign({ method: 'PUT' }, baseOptions), options);
|
|
1145
|
+
localVarHeaderParameter = {};
|
|
1146
|
+
localVarQueryParameter = {};
|
|
1147
|
+
// authentication bearerAuth required
|
|
1148
|
+
// http bearer authentication required
|
|
1149
|
+
return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
|
|
1150
|
+
case 1:
|
|
1151
|
+
// authentication bearerAuth required
|
|
1152
|
+
// http bearer authentication required
|
|
1153
|
+
_a.sent();
|
|
1154
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
1155
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
1156
|
+
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
1157
|
+
localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
1158
|
+
localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(adminPromotionConfigsUpdateRequest, localVarRequestOptions, configuration);
|
|
1159
|
+
return [2 /*return*/, {
|
|
1160
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
1161
|
+
options: localVarRequestOptions,
|
|
1162
|
+
}];
|
|
1163
|
+
}
|
|
1164
|
+
});
|
|
1165
|
+
});
|
|
1166
|
+
},
|
|
1167
|
+
/**
|
|
1168
|
+
*
|
|
1169
|
+
* @summary Criar ou atualizar configuração por chave (upsert)
|
|
1170
|
+
* @param {string} promotionId UUID da promoção
|
|
1171
|
+
* @param {AdminPromotionConfigsStoreRequest} adminPromotionConfigsStoreRequest
|
|
1172
|
+
* @param {*} [options] Override http request option.
|
|
1173
|
+
* @throws {RequiredError}
|
|
1174
|
+
*/
|
|
1175
|
+
adminPromotionConfigsUpsert: function (promotionId_1, adminPromotionConfigsStoreRequest_1) {
|
|
1176
|
+
var args_1 = [];
|
|
1177
|
+
for (var _i = 2; _i < arguments.length; _i++) {
|
|
1178
|
+
args_1[_i - 2] = arguments[_i];
|
|
1179
|
+
}
|
|
1180
|
+
return __awaiter(_this, __spreadArray([promotionId_1, adminPromotionConfigsStoreRequest_1], args_1, true), void 0, function (promotionId, adminPromotionConfigsStoreRequest, options) {
|
|
1181
|
+
var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
1182
|
+
if (options === void 0) { options = {}; }
|
|
1183
|
+
return __generator(this, function (_a) {
|
|
1184
|
+
switch (_a.label) {
|
|
1185
|
+
case 0:
|
|
1186
|
+
// verify required parameter 'promotionId' is not null or undefined
|
|
1187
|
+
(0, common_1.assertParamExists)('adminPromotionConfigsUpsert', 'promotionId', promotionId);
|
|
1188
|
+
// verify required parameter 'adminPromotionConfigsStoreRequest' is not null or undefined
|
|
1189
|
+
(0, common_1.assertParamExists)('adminPromotionConfigsUpsert', 'adminPromotionConfigsStoreRequest', adminPromotionConfigsStoreRequest);
|
|
1190
|
+
localVarPath = "/v3/admin/promotion/{promotion_id}/configs/upsert"
|
|
1191
|
+
.replace("{".concat("promotion_id", "}"), encodeURIComponent(String(promotionId)));
|
|
1192
|
+
localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
1193
|
+
if (configuration) {
|
|
1194
|
+
baseOptions = configuration.baseOptions;
|
|
1195
|
+
}
|
|
1196
|
+
localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
|
|
1197
|
+
localVarHeaderParameter = {};
|
|
1198
|
+
localVarQueryParameter = {};
|
|
1199
|
+
// authentication bearerAuth required
|
|
1200
|
+
// http bearer authentication required
|
|
1201
|
+
return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
|
|
1202
|
+
case 1:
|
|
1203
|
+
// authentication bearerAuth required
|
|
1204
|
+
// http bearer authentication required
|
|
1205
|
+
_a.sent();
|
|
1206
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
1207
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
1208
|
+
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
1209
|
+
localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
1210
|
+
localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(adminPromotionConfigsStoreRequest, localVarRequestOptions, configuration);
|
|
1211
|
+
return [2 /*return*/, {
|
|
1212
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
1213
|
+
options: localVarRequestOptions,
|
|
1214
|
+
}];
|
|
1215
|
+
}
|
|
1216
|
+
});
|
|
1217
|
+
});
|
|
1218
|
+
},
|
|
1219
|
+
/**
|
|
1220
|
+
*
|
|
1221
|
+
* @summary Listar chaves válidas do ConfigKeyEnum
|
|
1222
|
+
* @param {string} promotionId UUID da promoção
|
|
1223
|
+
* @param {*} [options] Override http request option.
|
|
1224
|
+
* @throws {RequiredError}
|
|
1225
|
+
*/
|
|
1226
|
+
adminPromotionConfigsValidKeys: function (promotionId_1) {
|
|
1227
|
+
var args_1 = [];
|
|
1228
|
+
for (var _i = 1; _i < arguments.length; _i++) {
|
|
1229
|
+
args_1[_i - 1] = arguments[_i];
|
|
1230
|
+
}
|
|
1231
|
+
return __awaiter(_this, __spreadArray([promotionId_1], args_1, true), void 0, function (promotionId, options) {
|
|
1232
|
+
var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
1233
|
+
if (options === void 0) { options = {}; }
|
|
1234
|
+
return __generator(this, function (_a) {
|
|
1235
|
+
switch (_a.label) {
|
|
1236
|
+
case 0:
|
|
1237
|
+
// verify required parameter 'promotionId' is not null or undefined
|
|
1238
|
+
(0, common_1.assertParamExists)('adminPromotionConfigsValidKeys', 'promotionId', promotionId);
|
|
1239
|
+
localVarPath = "/v3/admin/promotion/{promotion_id}/configs/valid-keys"
|
|
1240
|
+
.replace("{".concat("promotion_id", "}"), encodeURIComponent(String(promotionId)));
|
|
1241
|
+
localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
1242
|
+
if (configuration) {
|
|
1243
|
+
baseOptions = configuration.baseOptions;
|
|
1244
|
+
}
|
|
1245
|
+
localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
|
|
1246
|
+
localVarHeaderParameter = {};
|
|
1247
|
+
localVarQueryParameter = {};
|
|
1248
|
+
// authentication bearerAuth required
|
|
1249
|
+
// http bearer authentication required
|
|
1250
|
+
return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
|
|
1251
|
+
case 1:
|
|
1252
|
+
// authentication bearerAuth required
|
|
1253
|
+
// http bearer authentication required
|
|
1254
|
+
_a.sent();
|
|
1255
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
1256
|
+
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
1257
|
+
localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
1258
|
+
return [2 /*return*/, {
|
|
1259
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
1260
|
+
options: localVarRequestOptions,
|
|
1261
|
+
}];
|
|
1262
|
+
}
|
|
1263
|
+
});
|
|
1264
|
+
});
|
|
1265
|
+
},
|
|
1266
|
+
};
|
|
1267
|
+
};
|
|
1268
|
+
exports.ConfigsApiAxiosParamCreator = ConfigsApiAxiosParamCreator;
|
|
1269
|
+
/**
|
|
1270
|
+
* ConfigsApi - functional programming interface
|
|
1271
|
+
* @export
|
|
1272
|
+
*/
|
|
1273
|
+
var ConfigsApiFp = function (configuration) {
|
|
1274
|
+
var localVarAxiosParamCreator = (0, exports.ConfigsApiAxiosParamCreator)(configuration);
|
|
1275
|
+
return {
|
|
1276
|
+
/**
|
|
1277
|
+
*
|
|
1278
|
+
* @summary Listar configurações de uma promoção
|
|
1279
|
+
* @param {string} promotionId UUID da promoção
|
|
1280
|
+
* @param {string} [key] Filtrar por chave (busca parcial)
|
|
1281
|
+
* @param {string} [grupo] Filtrar por grupo
|
|
1282
|
+
* @param {AdminPromotionConfigsIndexTypeEnum} [type] Filtrar por tipo
|
|
1283
|
+
* @param {number} [perPage] Itens por página
|
|
1284
|
+
* @param {number} [page] Número da página
|
|
1285
|
+
* @param {*} [options] Override http request option.
|
|
1286
|
+
* @throws {RequiredError}
|
|
1287
|
+
*/
|
|
1288
|
+
adminPromotionConfigsIndex: function (promotionId, key, grupo, type, perPage, page, options) {
|
|
1289
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
1290
|
+
var localVarAxiosArgs, localVarOperationServerIndex, localVarOperationServerBasePath;
|
|
1291
|
+
var _a, _b, _c;
|
|
1292
|
+
return __generator(this, function (_d) {
|
|
1293
|
+
switch (_d.label) {
|
|
1294
|
+
case 0: return [4 /*yield*/, localVarAxiosParamCreator.adminPromotionConfigsIndex(promotionId, key, grupo, type, perPage, page, options)];
|
|
1295
|
+
case 1:
|
|
1296
|
+
localVarAxiosArgs = _d.sent();
|
|
1297
|
+
localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
1298
|
+
localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['ConfigsApi.adminPromotionConfigsIndex']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
1299
|
+
return [2 /*return*/, function (axios, basePath) { return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }];
|
|
1300
|
+
}
|
|
1301
|
+
});
|
|
1302
|
+
});
|
|
1303
|
+
},
|
|
1304
|
+
/**
|
|
1305
|
+
*
|
|
1306
|
+
* @summary Buscar configuração por chave
|
|
1307
|
+
* @param {string} promotionId UUID da promoção
|
|
1308
|
+
* @param {string} key Chave da configuração
|
|
1309
|
+
* @param {*} [options] Override http request option.
|
|
1310
|
+
* @throws {RequiredError}
|
|
1311
|
+
*/
|
|
1312
|
+
adminPromotionConfigsShow: function (promotionId, key, options) {
|
|
1313
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
1314
|
+
var localVarAxiosArgs, localVarOperationServerIndex, localVarOperationServerBasePath;
|
|
1315
|
+
var _a, _b, _c;
|
|
1316
|
+
return __generator(this, function (_d) {
|
|
1317
|
+
switch (_d.label) {
|
|
1318
|
+
case 0: return [4 /*yield*/, localVarAxiosParamCreator.adminPromotionConfigsShow(promotionId, key, options)];
|
|
1319
|
+
case 1:
|
|
1320
|
+
localVarAxiosArgs = _d.sent();
|
|
1321
|
+
localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
1322
|
+
localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['ConfigsApi.adminPromotionConfigsShow']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
1323
|
+
return [2 /*return*/, function (axios, basePath) { return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }];
|
|
1324
|
+
}
|
|
1325
|
+
});
|
|
1326
|
+
});
|
|
1327
|
+
},
|
|
1328
|
+
/**
|
|
1329
|
+
*
|
|
1330
|
+
* @summary Criar nova configuração
|
|
1331
|
+
* @param {string} promotionId UUID da promoção
|
|
1332
|
+
* @param {AdminPromotionConfigsStoreRequest} adminPromotionConfigsStoreRequest
|
|
1333
|
+
* @param {*} [options] Override http request option.
|
|
1334
|
+
* @throws {RequiredError}
|
|
1335
|
+
*/
|
|
1336
|
+
adminPromotionConfigsStore: function (promotionId, adminPromotionConfigsStoreRequest, options) {
|
|
1337
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
1338
|
+
var localVarAxiosArgs, localVarOperationServerIndex, localVarOperationServerBasePath;
|
|
1339
|
+
var _a, _b, _c;
|
|
1340
|
+
return __generator(this, function (_d) {
|
|
1341
|
+
switch (_d.label) {
|
|
1342
|
+
case 0: return [4 /*yield*/, localVarAxiosParamCreator.adminPromotionConfigsStore(promotionId, adminPromotionConfigsStoreRequest, options)];
|
|
1343
|
+
case 1:
|
|
1344
|
+
localVarAxiosArgs = _d.sent();
|
|
1345
|
+
localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
1346
|
+
localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['ConfigsApi.adminPromotionConfigsStore']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
1347
|
+
return [2 /*return*/, function (axios, basePath) { return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }];
|
|
1348
|
+
}
|
|
1349
|
+
});
|
|
1350
|
+
});
|
|
1351
|
+
},
|
|
1352
|
+
/**
|
|
1353
|
+
*
|
|
1354
|
+
* @summary Atualizar configuração por chave
|
|
1355
|
+
* @param {string} promotionId UUID da promoção
|
|
1356
|
+
* @param {string} key Chave da configuração
|
|
1357
|
+
* @param {AdminPromotionConfigsUpdateRequest} adminPromotionConfigsUpdateRequest
|
|
1358
|
+
* @param {*} [options] Override http request option.
|
|
1359
|
+
* @throws {RequiredError}
|
|
1360
|
+
*/
|
|
1361
|
+
adminPromotionConfigsUpdate: function (promotionId, key, adminPromotionConfigsUpdateRequest, options) {
|
|
1362
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
1363
|
+
var localVarAxiosArgs, localVarOperationServerIndex, localVarOperationServerBasePath;
|
|
1364
|
+
var _a, _b, _c;
|
|
1365
|
+
return __generator(this, function (_d) {
|
|
1366
|
+
switch (_d.label) {
|
|
1367
|
+
case 0: return [4 /*yield*/, localVarAxiosParamCreator.adminPromotionConfigsUpdate(promotionId, key, adminPromotionConfigsUpdateRequest, options)];
|
|
1368
|
+
case 1:
|
|
1369
|
+
localVarAxiosArgs = _d.sent();
|
|
1370
|
+
localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
1371
|
+
localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['ConfigsApi.adminPromotionConfigsUpdate']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
1372
|
+
return [2 /*return*/, function (axios, basePath) { return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }];
|
|
1373
|
+
}
|
|
1374
|
+
});
|
|
1375
|
+
});
|
|
1376
|
+
},
|
|
1377
|
+
/**
|
|
1378
|
+
*
|
|
1379
|
+
* @summary Criar ou atualizar configuração por chave (upsert)
|
|
1380
|
+
* @param {string} promotionId UUID da promoção
|
|
1381
|
+
* @param {AdminPromotionConfigsStoreRequest} adminPromotionConfigsStoreRequest
|
|
1382
|
+
* @param {*} [options] Override http request option.
|
|
1383
|
+
* @throws {RequiredError}
|
|
1384
|
+
*/
|
|
1385
|
+
adminPromotionConfigsUpsert: function (promotionId, adminPromotionConfigsStoreRequest, options) {
|
|
1386
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
1387
|
+
var localVarAxiosArgs, localVarOperationServerIndex, localVarOperationServerBasePath;
|
|
1388
|
+
var _a, _b, _c;
|
|
1389
|
+
return __generator(this, function (_d) {
|
|
1390
|
+
switch (_d.label) {
|
|
1391
|
+
case 0: return [4 /*yield*/, localVarAxiosParamCreator.adminPromotionConfigsUpsert(promotionId, adminPromotionConfigsStoreRequest, options)];
|
|
1392
|
+
case 1:
|
|
1393
|
+
localVarAxiosArgs = _d.sent();
|
|
1394
|
+
localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
1395
|
+
localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['ConfigsApi.adminPromotionConfigsUpsert']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
1396
|
+
return [2 /*return*/, function (axios, basePath) { return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }];
|
|
1397
|
+
}
|
|
1398
|
+
});
|
|
1399
|
+
});
|
|
1400
|
+
},
|
|
1401
|
+
/**
|
|
1402
|
+
*
|
|
1403
|
+
* @summary Listar chaves válidas do ConfigKeyEnum
|
|
1404
|
+
* @param {string} promotionId UUID da promoção
|
|
1405
|
+
* @param {*} [options] Override http request option.
|
|
1406
|
+
* @throws {RequiredError}
|
|
1407
|
+
*/
|
|
1408
|
+
adminPromotionConfigsValidKeys: function (promotionId, options) {
|
|
1409
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
1410
|
+
var localVarAxiosArgs, localVarOperationServerIndex, localVarOperationServerBasePath;
|
|
1411
|
+
var _a, _b, _c;
|
|
1412
|
+
return __generator(this, function (_d) {
|
|
1413
|
+
switch (_d.label) {
|
|
1414
|
+
case 0: return [4 /*yield*/, localVarAxiosParamCreator.adminPromotionConfigsValidKeys(promotionId, options)];
|
|
1415
|
+
case 1:
|
|
1416
|
+
localVarAxiosArgs = _d.sent();
|
|
1417
|
+
localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
1418
|
+
localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['ConfigsApi.adminPromotionConfigsValidKeys']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
1419
|
+
return [2 /*return*/, function (axios, basePath) { return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }];
|
|
1420
|
+
}
|
|
1421
|
+
});
|
|
1422
|
+
});
|
|
1423
|
+
},
|
|
1424
|
+
};
|
|
1425
|
+
};
|
|
1426
|
+
exports.ConfigsApiFp = ConfigsApiFp;
|
|
1427
|
+
/**
|
|
1428
|
+
* ConfigsApi - factory interface
|
|
1429
|
+
* @export
|
|
1430
|
+
*/
|
|
1431
|
+
var ConfigsApiFactory = function (configuration, basePath, axios) {
|
|
1432
|
+
var localVarFp = (0, exports.ConfigsApiFp)(configuration);
|
|
1433
|
+
return {
|
|
1434
|
+
/**
|
|
1435
|
+
*
|
|
1436
|
+
* @summary Listar configurações de uma promoção
|
|
1437
|
+
* @param {ConfigsApiAdminPromotionConfigsIndexRequest} requestParameters Request parameters.
|
|
1438
|
+
* @param {*} [options] Override http request option.
|
|
1439
|
+
* @throws {RequiredError}
|
|
1440
|
+
*/
|
|
1441
|
+
adminPromotionConfigsIndex: function (requestParameters, options) {
|
|
1442
|
+
return localVarFp.adminPromotionConfigsIndex(requestParameters.promotionId, requestParameters.key, requestParameters.grupo, requestParameters.type, requestParameters.perPage, requestParameters.page, options).then(function (request) { return request(axios, basePath); });
|
|
1443
|
+
},
|
|
1444
|
+
/**
|
|
1445
|
+
*
|
|
1446
|
+
* @summary Buscar configuração por chave
|
|
1447
|
+
* @param {ConfigsApiAdminPromotionConfigsShowRequest} requestParameters Request parameters.
|
|
1448
|
+
* @param {*} [options] Override http request option.
|
|
1449
|
+
* @throws {RequiredError}
|
|
1450
|
+
*/
|
|
1451
|
+
adminPromotionConfigsShow: function (requestParameters, options) {
|
|
1452
|
+
return localVarFp.adminPromotionConfigsShow(requestParameters.promotionId, requestParameters.key, options).then(function (request) { return request(axios, basePath); });
|
|
1453
|
+
},
|
|
1454
|
+
/**
|
|
1455
|
+
*
|
|
1456
|
+
* @summary Criar nova configuração
|
|
1457
|
+
* @param {ConfigsApiAdminPromotionConfigsStoreRequest} requestParameters Request parameters.
|
|
1458
|
+
* @param {*} [options] Override http request option.
|
|
1459
|
+
* @throws {RequiredError}
|
|
1460
|
+
*/
|
|
1461
|
+
adminPromotionConfigsStore: function (requestParameters, options) {
|
|
1462
|
+
return localVarFp.adminPromotionConfigsStore(requestParameters.promotionId, requestParameters.adminPromotionConfigsStoreRequest, options).then(function (request) { return request(axios, basePath); });
|
|
1463
|
+
},
|
|
1464
|
+
/**
|
|
1465
|
+
*
|
|
1466
|
+
* @summary Atualizar configuração por chave
|
|
1467
|
+
* @param {ConfigsApiAdminPromotionConfigsUpdateRequest} requestParameters Request parameters.
|
|
1468
|
+
* @param {*} [options] Override http request option.
|
|
1469
|
+
* @throws {RequiredError}
|
|
1470
|
+
*/
|
|
1471
|
+
adminPromotionConfigsUpdate: function (requestParameters, options) {
|
|
1472
|
+
return localVarFp.adminPromotionConfigsUpdate(requestParameters.promotionId, requestParameters.key, requestParameters.adminPromotionConfigsUpdateRequest, options).then(function (request) { return request(axios, basePath); });
|
|
1473
|
+
},
|
|
1474
|
+
/**
|
|
1475
|
+
*
|
|
1476
|
+
* @summary Criar ou atualizar configuração por chave (upsert)
|
|
1477
|
+
* @param {ConfigsApiAdminPromotionConfigsUpsertRequest} requestParameters Request parameters.
|
|
1478
|
+
* @param {*} [options] Override http request option.
|
|
1479
|
+
* @throws {RequiredError}
|
|
1480
|
+
*/
|
|
1481
|
+
adminPromotionConfigsUpsert: function (requestParameters, options) {
|
|
1482
|
+
return localVarFp.adminPromotionConfigsUpsert(requestParameters.promotionId, requestParameters.adminPromotionConfigsStoreRequest, options).then(function (request) { return request(axios, basePath); });
|
|
1483
|
+
},
|
|
1484
|
+
/**
|
|
1485
|
+
*
|
|
1486
|
+
* @summary Listar chaves válidas do ConfigKeyEnum
|
|
1487
|
+
* @param {ConfigsApiAdminPromotionConfigsValidKeysRequest} requestParameters Request parameters.
|
|
1488
|
+
* @param {*} [options] Override http request option.
|
|
1489
|
+
* @throws {RequiredError}
|
|
1490
|
+
*/
|
|
1491
|
+
adminPromotionConfigsValidKeys: function (requestParameters, options) {
|
|
1492
|
+
return localVarFp.adminPromotionConfigsValidKeys(requestParameters.promotionId, options).then(function (request) { return request(axios, basePath); });
|
|
1493
|
+
},
|
|
1494
|
+
};
|
|
1495
|
+
};
|
|
1496
|
+
exports.ConfigsApiFactory = ConfigsApiFactory;
|
|
1497
|
+
/**
|
|
1498
|
+
* ConfigsApi - object-oriented interface
|
|
1499
|
+
* @export
|
|
1500
|
+
* @class ConfigsApi
|
|
1501
|
+
* @extends {BaseAPI}
|
|
1502
|
+
*/
|
|
1503
|
+
var ConfigsApi = /** @class */ (function (_super) {
|
|
1504
|
+
__extends(ConfigsApi, _super);
|
|
1505
|
+
function ConfigsApi() {
|
|
1506
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
1507
|
+
}
|
|
1508
|
+
/**
|
|
1509
|
+
*
|
|
1510
|
+
* @summary Listar configurações de uma promoção
|
|
1511
|
+
* @param {ConfigsApiAdminPromotionConfigsIndexRequest} requestParameters Request parameters.
|
|
1512
|
+
* @param {*} [options] Override http request option.
|
|
1513
|
+
* @throws {RequiredError}
|
|
1514
|
+
* @memberof ConfigsApi
|
|
1515
|
+
*/
|
|
1516
|
+
ConfigsApi.prototype.adminPromotionConfigsIndex = function (requestParameters, options) {
|
|
1517
|
+
var _this = this;
|
|
1518
|
+
return (0, exports.ConfigsApiFp)(this.configuration).adminPromotionConfigsIndex(requestParameters.promotionId, requestParameters.key, requestParameters.grupo, requestParameters.type, requestParameters.perPage, requestParameters.page, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
1519
|
+
};
|
|
1520
|
+
/**
|
|
1521
|
+
*
|
|
1522
|
+
* @summary Buscar configuração por chave
|
|
1523
|
+
* @param {ConfigsApiAdminPromotionConfigsShowRequest} requestParameters Request parameters.
|
|
1524
|
+
* @param {*} [options] Override http request option.
|
|
1525
|
+
* @throws {RequiredError}
|
|
1526
|
+
* @memberof ConfigsApi
|
|
1527
|
+
*/
|
|
1528
|
+
ConfigsApi.prototype.adminPromotionConfigsShow = function (requestParameters, options) {
|
|
1529
|
+
var _this = this;
|
|
1530
|
+
return (0, exports.ConfigsApiFp)(this.configuration).adminPromotionConfigsShow(requestParameters.promotionId, requestParameters.key, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
1531
|
+
};
|
|
1532
|
+
/**
|
|
1533
|
+
*
|
|
1534
|
+
* @summary Criar nova configuração
|
|
1535
|
+
* @param {ConfigsApiAdminPromotionConfigsStoreRequest} requestParameters Request parameters.
|
|
1536
|
+
* @param {*} [options] Override http request option.
|
|
1537
|
+
* @throws {RequiredError}
|
|
1538
|
+
* @memberof ConfigsApi
|
|
1539
|
+
*/
|
|
1540
|
+
ConfigsApi.prototype.adminPromotionConfigsStore = function (requestParameters, options) {
|
|
1541
|
+
var _this = this;
|
|
1542
|
+
return (0, exports.ConfigsApiFp)(this.configuration).adminPromotionConfigsStore(requestParameters.promotionId, requestParameters.adminPromotionConfigsStoreRequest, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
1543
|
+
};
|
|
1544
|
+
/**
|
|
1545
|
+
*
|
|
1546
|
+
* @summary Atualizar configuração por chave
|
|
1547
|
+
* @param {ConfigsApiAdminPromotionConfigsUpdateRequest} requestParameters Request parameters.
|
|
1548
|
+
* @param {*} [options] Override http request option.
|
|
1549
|
+
* @throws {RequiredError}
|
|
1550
|
+
* @memberof ConfigsApi
|
|
1551
|
+
*/
|
|
1552
|
+
ConfigsApi.prototype.adminPromotionConfigsUpdate = function (requestParameters, options) {
|
|
1553
|
+
var _this = this;
|
|
1554
|
+
return (0, exports.ConfigsApiFp)(this.configuration).adminPromotionConfigsUpdate(requestParameters.promotionId, requestParameters.key, requestParameters.adminPromotionConfigsUpdateRequest, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
1555
|
+
};
|
|
1556
|
+
/**
|
|
1557
|
+
*
|
|
1558
|
+
* @summary Criar ou atualizar configuração por chave (upsert)
|
|
1559
|
+
* @param {ConfigsApiAdminPromotionConfigsUpsertRequest} requestParameters Request parameters.
|
|
1560
|
+
* @param {*} [options] Override http request option.
|
|
1561
|
+
* @throws {RequiredError}
|
|
1562
|
+
* @memberof ConfigsApi
|
|
1563
|
+
*/
|
|
1564
|
+
ConfigsApi.prototype.adminPromotionConfigsUpsert = function (requestParameters, options) {
|
|
1565
|
+
var _this = this;
|
|
1566
|
+
return (0, exports.ConfigsApiFp)(this.configuration).adminPromotionConfigsUpsert(requestParameters.promotionId, requestParameters.adminPromotionConfigsStoreRequest, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
1567
|
+
};
|
|
1568
|
+
/**
|
|
1569
|
+
*
|
|
1570
|
+
* @summary Listar chaves válidas do ConfigKeyEnum
|
|
1571
|
+
* @param {ConfigsApiAdminPromotionConfigsValidKeysRequest} requestParameters Request parameters.
|
|
1572
|
+
* @param {*} [options] Override http request option.
|
|
1573
|
+
* @throws {RequiredError}
|
|
1574
|
+
* @memberof ConfigsApi
|
|
1575
|
+
*/
|
|
1576
|
+
ConfigsApi.prototype.adminPromotionConfigsValidKeys = function (requestParameters, options) {
|
|
1577
|
+
var _this = this;
|
|
1578
|
+
return (0, exports.ConfigsApiFp)(this.configuration).adminPromotionConfigsValidKeys(requestParameters.promotionId, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
1579
|
+
};
|
|
1580
|
+
return ConfigsApi;
|
|
1581
|
+
}(base_1.BaseAPI));
|
|
1582
|
+
exports.ConfigsApi = ConfigsApi;
|
|
1583
|
+
/**
|
|
1584
|
+
* @export
|
|
1585
|
+
*/
|
|
1586
|
+
exports.AdminPromotionConfigsIndexTypeEnum = {
|
|
1587
|
+
Text: 'text',
|
|
1588
|
+
Uuid: 'uuid',
|
|
1589
|
+
Html: 'html',
|
|
1590
|
+
Url: 'url',
|
|
1591
|
+
PathUrl: 'path_url',
|
|
1592
|
+
Integer: 'integer',
|
|
1593
|
+
Double: 'double',
|
|
1594
|
+
File: 'file',
|
|
1595
|
+
Json: 'json',
|
|
1596
|
+
Date: 'date',
|
|
1597
|
+
Datetime: 'datetime'
|
|
1598
|
+
};
|
|
894
1599
|
/**
|
|
895
1600
|
* CustomerServiceApi - axios parameter creator
|
|
896
1601
|
* @export
|