@seekora-ai/admin-api 1.0.71 → 1.0.72
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/README.md +54 -2
- package/api.ts +4290 -952
- package/dist/api.d.ts +3278 -830
- package/dist/api.js +1813 -180
- package/dist/esm/api.d.ts +3278 -830
- package/dist/esm/api.js +1799 -174
- package/package.json +1 -1
- package/seekora-ai-admin-api-1.0.72.tgz +0 -0
- package/seekora-ai-admin-api-1.0.71.tgz +0 -0
package/dist/esm/api.js
CHANGED
|
@@ -122,10 +122,20 @@ export const DataTypesCreditTransactionTransactionTypeEnum = {
|
|
|
122
122
|
Bonus: 'bonus',
|
|
123
123
|
Expire: 'expire'
|
|
124
124
|
};
|
|
125
|
+
export const DataTypesProcessRefundRequestDtoRefundTypeEnum = {
|
|
126
|
+
Full: 'full',
|
|
127
|
+
Partial: 'partial',
|
|
128
|
+
RemainingCredits: 'remaining_credits'
|
|
129
|
+
};
|
|
125
130
|
export const DataTypesRefundApprovalDtoActionEnum = {
|
|
126
131
|
Approve: 'approve',
|
|
127
132
|
Reject: 'reject'
|
|
128
133
|
};
|
|
134
|
+
export const DataTypesRefundCalculationRequestDtoRefundTypeEnum = {
|
|
135
|
+
Full: 'full',
|
|
136
|
+
Partial: 'partial',
|
|
137
|
+
RemainingCredits: 'remaining_credits'
|
|
138
|
+
};
|
|
129
139
|
export const DataTypesUpdatePluralDeclensionRequestTypeEnum = {
|
|
130
140
|
Custom: 'custom',
|
|
131
141
|
Default: 'default'
|
|
@@ -135,6 +145,11 @@ export const DataTypesUpdateWordStatusRequestWordTypeEnum = {
|
|
|
135
145
|
StoreLanguage: 'store_language',
|
|
136
146
|
Custom: 'custom'
|
|
137
147
|
};
|
|
148
|
+
export const RefundRefundPreviewRequestDtoRefundTypeEnum = {
|
|
149
|
+
Full: 'full',
|
|
150
|
+
Partial: 'partial',
|
|
151
|
+
RemainingCredits: 'remaining_credits'
|
|
152
|
+
};
|
|
138
153
|
/**
|
|
139
154
|
* APICallsApi - axios parameter creator
|
|
140
155
|
* @export
|
|
@@ -4898,34 +4913,74 @@ export class AnalyticsEventsApi extends BaseAPI {
|
|
|
4898
4913
|
}
|
|
4899
4914
|
}
|
|
4900
4915
|
/**
|
|
4901
|
-
*
|
|
4916
|
+
* AnalyticsRulesApi - axios parameter creator
|
|
4902
4917
|
* @export
|
|
4903
4918
|
*/
|
|
4904
|
-
export const
|
|
4919
|
+
export const AnalyticsRulesApiAxiosParamCreator = function (configuration) {
|
|
4905
4920
|
return {
|
|
4906
4921
|
/**
|
|
4907
|
-
*
|
|
4908
|
-
* @summary
|
|
4909
|
-
* @param {string}
|
|
4922
|
+
* Retrieve a paginated list of analytics rules with optional filtering by store, collection, and active status. Supports both page-based and offset-based pagination.
|
|
4923
|
+
* @summary List Analytics Rules
|
|
4924
|
+
* @param {string} authorization Bearer JWT token
|
|
4925
|
+
* @param {number} [storeId] Filter by store ID (for general routes)
|
|
4926
|
+
* @param {string} [collectionName] Filter by collection name
|
|
4927
|
+
* @param {boolean} [isActive] Filter by active status
|
|
4928
|
+
* @param {number} [page] Page number (1-based, alternative to limit/offset)
|
|
4929
|
+
* @param {number} [pageSize] Number of results per page (alternative to limit)
|
|
4930
|
+
* @param {number} [limit] Maximum number of results (default: 50)
|
|
4931
|
+
* @param {number} [offset] Offset for pagination (default: 0)
|
|
4932
|
+
* @param {string} [sortBy] Sort field (name, created_at, modified_at, rule_id)
|
|
4933
|
+
* @param {string} [sortOrder] Sort order (asc, desc, default: desc)
|
|
4934
|
+
* @param {string} [searchQuery] Search in rule names, descriptions, and rule_ids
|
|
4910
4935
|
* @param {*} [options] Override http request option.
|
|
4911
4936
|
* @throws {RequiredError}
|
|
4912
4937
|
*/
|
|
4913
|
-
|
|
4914
|
-
// verify required parameter '
|
|
4915
|
-
assertParamExists('
|
|
4916
|
-
const localVarPath = `/admin/
|
|
4917
|
-
.replace(`{${"articleID"}}`, encodeURIComponent(String(articleID)));
|
|
4938
|
+
apiAdminV1AnalyticsRulesGet: (authorization_1, storeId_1, collectionName_1, isActive_1, page_1, pageSize_1, limit_1, offset_1, sortBy_1, sortOrder_1, searchQuery_1, ...args_1) => __awaiter(this, [authorization_1, storeId_1, collectionName_1, isActive_1, page_1, pageSize_1, limit_1, offset_1, sortBy_1, sortOrder_1, searchQuery_1, ...args_1], void 0, function* (authorization, storeId, collectionName, isActive, page, pageSize, limit, offset, sortBy, sortOrder, searchQuery, options = {}) {
|
|
4939
|
+
// verify required parameter 'authorization' is not null or undefined
|
|
4940
|
+
assertParamExists('apiAdminV1AnalyticsRulesGet', 'authorization', authorization);
|
|
4941
|
+
const localVarPath = `/api/admin/v1/analytics/rules`;
|
|
4918
4942
|
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
4919
4943
|
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
4920
4944
|
let baseOptions;
|
|
4921
4945
|
if (configuration) {
|
|
4922
4946
|
baseOptions = configuration.baseOptions;
|
|
4923
4947
|
}
|
|
4924
|
-
const localVarRequestOptions = Object.assign(Object.assign({ method: '
|
|
4948
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
|
|
4925
4949
|
const localVarHeaderParameter = {};
|
|
4926
4950
|
const localVarQueryParameter = {};
|
|
4927
|
-
|
|
4928
|
-
|
|
4951
|
+
if (storeId !== undefined) {
|
|
4952
|
+
localVarQueryParameter['store_id'] = storeId;
|
|
4953
|
+
}
|
|
4954
|
+
if (collectionName !== undefined) {
|
|
4955
|
+
localVarQueryParameter['collection_name'] = collectionName;
|
|
4956
|
+
}
|
|
4957
|
+
if (isActive !== undefined) {
|
|
4958
|
+
localVarQueryParameter['is_active'] = isActive;
|
|
4959
|
+
}
|
|
4960
|
+
if (page !== undefined) {
|
|
4961
|
+
localVarQueryParameter['page'] = page;
|
|
4962
|
+
}
|
|
4963
|
+
if (pageSize !== undefined) {
|
|
4964
|
+
localVarQueryParameter['page_size'] = pageSize;
|
|
4965
|
+
}
|
|
4966
|
+
if (limit !== undefined) {
|
|
4967
|
+
localVarQueryParameter['limit'] = limit;
|
|
4968
|
+
}
|
|
4969
|
+
if (offset !== undefined) {
|
|
4970
|
+
localVarQueryParameter['offset'] = offset;
|
|
4971
|
+
}
|
|
4972
|
+
if (sortBy !== undefined) {
|
|
4973
|
+
localVarQueryParameter['sort_by'] = sortBy;
|
|
4974
|
+
}
|
|
4975
|
+
if (sortOrder !== undefined) {
|
|
4976
|
+
localVarQueryParameter['sort_order'] = sortOrder;
|
|
4977
|
+
}
|
|
4978
|
+
if (searchQuery !== undefined) {
|
|
4979
|
+
localVarQueryParameter['search_query'] = searchQuery;
|
|
4980
|
+
}
|
|
4981
|
+
if (authorization != null) {
|
|
4982
|
+
localVarHeaderParameter['Authorization'] = String(authorization);
|
|
4983
|
+
}
|
|
4929
4984
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
4930
4985
|
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
4931
4986
|
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
@@ -4935,80 +4990,91 @@ export const ArticlesApiAxiosParamCreator = function (configuration) {
|
|
|
4935
4990
|
};
|
|
4936
4991
|
}),
|
|
4937
4992
|
/**
|
|
4938
|
-
*
|
|
4939
|
-
* @summary
|
|
4940
|
-
* @param {
|
|
4993
|
+
* Create a new analytics rule for Typesense curation. Rules define how search results should be modified (promoted, hidden, filtered, sorted) based on query conditions.
|
|
4994
|
+
* @summary Create Analytics Rule
|
|
4995
|
+
* @param {string} authorization Bearer JWT token
|
|
4996
|
+
* @param {DataTypesCreateAnalyticsRuleRequest} dataTypesCreateAnalyticsRuleRequest Analytics rule configuration
|
|
4941
4997
|
* @param {*} [options] Override http request option.
|
|
4942
4998
|
* @throws {RequiredError}
|
|
4943
4999
|
*/
|
|
4944
|
-
|
|
4945
|
-
// verify required parameter '
|
|
4946
|
-
assertParamExists('
|
|
4947
|
-
|
|
4948
|
-
|
|
5000
|
+
apiAdminV1AnalyticsRulesPost: (authorization_1, dataTypesCreateAnalyticsRuleRequest_1, ...args_1) => __awaiter(this, [authorization_1, dataTypesCreateAnalyticsRuleRequest_1, ...args_1], void 0, function* (authorization, dataTypesCreateAnalyticsRuleRequest, options = {}) {
|
|
5001
|
+
// verify required parameter 'authorization' is not null or undefined
|
|
5002
|
+
assertParamExists('apiAdminV1AnalyticsRulesPost', 'authorization', authorization);
|
|
5003
|
+
// verify required parameter 'dataTypesCreateAnalyticsRuleRequest' is not null or undefined
|
|
5004
|
+
assertParamExists('apiAdminV1AnalyticsRulesPost', 'dataTypesCreateAnalyticsRuleRequest', dataTypesCreateAnalyticsRuleRequest);
|
|
5005
|
+
const localVarPath = `/api/admin/v1/analytics/rules`;
|
|
4949
5006
|
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
4950
5007
|
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
4951
5008
|
let baseOptions;
|
|
4952
5009
|
if (configuration) {
|
|
4953
5010
|
baseOptions = configuration.baseOptions;
|
|
4954
5011
|
}
|
|
4955
|
-
const localVarRequestOptions = Object.assign(Object.assign({ method: '
|
|
5012
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
|
|
4956
5013
|
const localVarHeaderParameter = {};
|
|
4957
5014
|
const localVarQueryParameter = {};
|
|
4958
|
-
|
|
4959
|
-
|
|
5015
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
5016
|
+
if (authorization != null) {
|
|
5017
|
+
localVarHeaderParameter['Authorization'] = String(authorization);
|
|
5018
|
+
}
|
|
4960
5019
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
4961
5020
|
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
4962
5021
|
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
5022
|
+
localVarRequestOptions.data = serializeDataIfNeeded(dataTypesCreateAnalyticsRuleRequest, localVarRequestOptions, configuration);
|
|
4963
5023
|
return {
|
|
4964
5024
|
url: toPathString(localVarUrlObj),
|
|
4965
5025
|
options: localVarRequestOptions,
|
|
4966
5026
|
};
|
|
4967
5027
|
}),
|
|
4968
5028
|
/**
|
|
4969
|
-
*
|
|
4970
|
-
* @summary
|
|
4971
|
-
* @param {
|
|
4972
|
-
* @param {
|
|
5029
|
+
* Permanently delete an analytics rule from both the database and Typesense. This operation cannot be undone.
|
|
5030
|
+
* @summary Delete Analytics Rule
|
|
5031
|
+
* @param {string} authorization Bearer JWT token
|
|
5032
|
+
* @param {string} ruleId Rule ID
|
|
4973
5033
|
* @param {*} [options] Override http request option.
|
|
4974
5034
|
* @throws {RequiredError}
|
|
4975
5035
|
*/
|
|
4976
|
-
|
|
4977
|
-
// verify required parameter '
|
|
4978
|
-
assertParamExists('
|
|
4979
|
-
// verify required parameter '
|
|
4980
|
-
assertParamExists('
|
|
4981
|
-
const localVarPath = `/admin/
|
|
4982
|
-
.replace(`{${"
|
|
5036
|
+
apiAdminV1AnalyticsRulesRuleIdDelete: (authorization_1, ruleId_1, ...args_1) => __awaiter(this, [authorization_1, ruleId_1, ...args_1], void 0, function* (authorization, ruleId, options = {}) {
|
|
5037
|
+
// verify required parameter 'authorization' is not null or undefined
|
|
5038
|
+
assertParamExists('apiAdminV1AnalyticsRulesRuleIdDelete', 'authorization', authorization);
|
|
5039
|
+
// verify required parameter 'ruleId' is not null or undefined
|
|
5040
|
+
assertParamExists('apiAdminV1AnalyticsRulesRuleIdDelete', 'ruleId', ruleId);
|
|
5041
|
+
const localVarPath = `/api/admin/v1/analytics/rules/{ruleId}`
|
|
5042
|
+
.replace(`{${"ruleId"}}`, encodeURIComponent(String(ruleId)));
|
|
4983
5043
|
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
4984
5044
|
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
4985
5045
|
let baseOptions;
|
|
4986
5046
|
if (configuration) {
|
|
4987
5047
|
baseOptions = configuration.baseOptions;
|
|
4988
5048
|
}
|
|
4989
|
-
const localVarRequestOptions = Object.assign(Object.assign({ method: '
|
|
5049
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'DELETE' }, baseOptions), options);
|
|
4990
5050
|
const localVarHeaderParameter = {};
|
|
4991
5051
|
const localVarQueryParameter = {};
|
|
4992
|
-
|
|
4993
|
-
|
|
4994
|
-
|
|
5052
|
+
if (authorization != null) {
|
|
5053
|
+
localVarHeaderParameter['Authorization'] = String(authorization);
|
|
5054
|
+
}
|
|
4995
5055
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
4996
5056
|
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
4997
5057
|
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
4998
|
-
localVarRequestOptions.data = serializeDataIfNeeded(mgDocumentTypesCreateArticleRequestDto, localVarRequestOptions, configuration);
|
|
4999
5058
|
return {
|
|
5000
5059
|
url: toPathString(localVarUrlObj),
|
|
5001
5060
|
options: localVarRequestOptions,
|
|
5002
5061
|
};
|
|
5003
5062
|
}),
|
|
5004
5063
|
/**
|
|
5005
|
-
*
|
|
5006
|
-
* @summary
|
|
5064
|
+
* Retrieve a specific analytics rule by its ID. Returns the complete rule configuration including Typesense override actions.
|
|
5065
|
+
* @summary Get Analytics Rule
|
|
5066
|
+
* @param {string} authorization Bearer JWT token
|
|
5067
|
+
* @param {string} ruleId Rule ID
|
|
5007
5068
|
* @param {*} [options] Override http request option.
|
|
5008
5069
|
* @throws {RequiredError}
|
|
5009
5070
|
*/
|
|
5010
|
-
|
|
5011
|
-
|
|
5071
|
+
apiAdminV1AnalyticsRulesRuleIdGet: (authorization_1, ruleId_1, ...args_1) => __awaiter(this, [authorization_1, ruleId_1, ...args_1], void 0, function* (authorization, ruleId, options = {}) {
|
|
5072
|
+
// verify required parameter 'authorization' is not null or undefined
|
|
5073
|
+
assertParamExists('apiAdminV1AnalyticsRulesRuleIdGet', 'authorization', authorization);
|
|
5074
|
+
// verify required parameter 'ruleId' is not null or undefined
|
|
5075
|
+
assertParamExists('apiAdminV1AnalyticsRulesRuleIdGet', 'ruleId', ruleId);
|
|
5076
|
+
const localVarPath = `/api/admin/v1/analytics/rules/{ruleId}`
|
|
5077
|
+
.replace(`{${"ruleId"}}`, encodeURIComponent(String(ruleId)));
|
|
5012
5078
|
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
5013
5079
|
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
5014
5080
|
let baseOptions;
|
|
@@ -5018,8 +5084,9 @@ export const ArticlesApiAxiosParamCreator = function (configuration) {
|
|
|
5018
5084
|
const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
|
|
5019
5085
|
const localVarHeaderParameter = {};
|
|
5020
5086
|
const localVarQueryParameter = {};
|
|
5021
|
-
|
|
5022
|
-
|
|
5087
|
+
if (authorization != null) {
|
|
5088
|
+
localVarHeaderParameter['Authorization'] = String(authorization);
|
|
5089
|
+
}
|
|
5023
5090
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
5024
5091
|
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
5025
5092
|
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
@@ -5029,119 +5096,1189 @@ export const ArticlesApiAxiosParamCreator = function (configuration) {
|
|
|
5029
5096
|
};
|
|
5030
5097
|
}),
|
|
5031
5098
|
/**
|
|
5032
|
-
*
|
|
5033
|
-
* @summary
|
|
5034
|
-
* @param {
|
|
5099
|
+
* Update an existing analytics rule. Supports partial updates. When is_active is set to false, the rule is removed from Typesense. When is_active is set to true, the rule is synced to Typesense.
|
|
5100
|
+
* @summary Update Analytics Rule
|
|
5101
|
+
* @param {string} authorization Bearer JWT token
|
|
5102
|
+
* @param {string} ruleId Rule ID
|
|
5103
|
+
* @param {DataTypesUpdateAnalyticsRuleRequest} dataTypesUpdateAnalyticsRuleRequest Updated rule configuration (partial update supported)
|
|
5035
5104
|
* @param {*} [options] Override http request option.
|
|
5036
5105
|
* @throws {RequiredError}
|
|
5037
5106
|
*/
|
|
5038
|
-
|
|
5039
|
-
// verify required parameter '
|
|
5040
|
-
assertParamExists('
|
|
5041
|
-
|
|
5107
|
+
apiAdminV1AnalyticsRulesRuleIdPut: (authorization_1, ruleId_1, dataTypesUpdateAnalyticsRuleRequest_1, ...args_1) => __awaiter(this, [authorization_1, ruleId_1, dataTypesUpdateAnalyticsRuleRequest_1, ...args_1], void 0, function* (authorization, ruleId, dataTypesUpdateAnalyticsRuleRequest, options = {}) {
|
|
5108
|
+
// verify required parameter 'authorization' is not null or undefined
|
|
5109
|
+
assertParamExists('apiAdminV1AnalyticsRulesRuleIdPut', 'authorization', authorization);
|
|
5110
|
+
// verify required parameter 'ruleId' is not null or undefined
|
|
5111
|
+
assertParamExists('apiAdminV1AnalyticsRulesRuleIdPut', 'ruleId', ruleId);
|
|
5112
|
+
// verify required parameter 'dataTypesUpdateAnalyticsRuleRequest' is not null or undefined
|
|
5113
|
+
assertParamExists('apiAdminV1AnalyticsRulesRuleIdPut', 'dataTypesUpdateAnalyticsRuleRequest', dataTypesUpdateAnalyticsRuleRequest);
|
|
5114
|
+
const localVarPath = `/api/admin/v1/analytics/rules/{ruleId}`
|
|
5115
|
+
.replace(`{${"ruleId"}}`, encodeURIComponent(String(ruleId)));
|
|
5042
5116
|
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
5043
5117
|
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
5044
5118
|
let baseOptions;
|
|
5045
5119
|
if (configuration) {
|
|
5046
5120
|
baseOptions = configuration.baseOptions;
|
|
5047
5121
|
}
|
|
5048
|
-
const localVarRequestOptions = Object.assign(Object.assign({ method: '
|
|
5122
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'PUT' }, baseOptions), options);
|
|
5049
5123
|
const localVarHeaderParameter = {};
|
|
5050
5124
|
const localVarQueryParameter = {};
|
|
5051
|
-
// authentication BearerAuth required
|
|
5052
|
-
yield setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration);
|
|
5053
5125
|
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
5126
|
+
if (authorization != null) {
|
|
5127
|
+
localVarHeaderParameter['Authorization'] = String(authorization);
|
|
5128
|
+
}
|
|
5054
5129
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
5055
5130
|
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
5056
5131
|
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
5057
|
-
localVarRequestOptions.data = serializeDataIfNeeded(
|
|
5132
|
+
localVarRequestOptions.data = serializeDataIfNeeded(dataTypesUpdateAnalyticsRuleRequest, localVarRequestOptions, configuration);
|
|
5058
5133
|
return {
|
|
5059
5134
|
url: toPathString(localVarUrlObj),
|
|
5060
5135
|
options: localVarRequestOptions,
|
|
5061
5136
|
};
|
|
5062
5137
|
}),
|
|
5063
|
-
};
|
|
5064
|
-
};
|
|
5065
|
-
/**
|
|
5066
|
-
* ArticlesApi - functional programming interface
|
|
5067
|
-
* @export
|
|
5068
|
-
*/
|
|
5069
|
-
export const ArticlesApiFp = function (configuration) {
|
|
5070
|
-
const localVarAxiosParamCreator = ArticlesApiAxiosParamCreator(configuration);
|
|
5071
|
-
return {
|
|
5072
5138
|
/**
|
|
5073
|
-
*
|
|
5074
|
-
* @summary
|
|
5075
|
-
* @param {string}
|
|
5139
|
+
* Manually synchronize analytics rules to Typesense. This endpoint can be used to force a sync of all active rules or specific rules to Typesense collections.
|
|
5140
|
+
* @summary Sync Rules to Typesense
|
|
5141
|
+
* @param {string} authorization Bearer JWT token
|
|
5142
|
+
* @param {DataTypesAnalyticsRuleSyncRequest} dataTypesAnalyticsRuleSyncRequest Sync configuration (optional filters)
|
|
5076
5143
|
* @param {*} [options] Override http request option.
|
|
5077
5144
|
* @throws {RequiredError}
|
|
5078
5145
|
*/
|
|
5079
|
-
|
|
5080
|
-
|
|
5081
|
-
|
|
5082
|
-
|
|
5083
|
-
|
|
5084
|
-
|
|
5085
|
-
|
|
5086
|
-
|
|
5087
|
-
|
|
5146
|
+
apiAdminV1AnalyticsRulesSyncPost: (authorization_1, dataTypesAnalyticsRuleSyncRequest_1, ...args_1) => __awaiter(this, [authorization_1, dataTypesAnalyticsRuleSyncRequest_1, ...args_1], void 0, function* (authorization, dataTypesAnalyticsRuleSyncRequest, options = {}) {
|
|
5147
|
+
// verify required parameter 'authorization' is not null or undefined
|
|
5148
|
+
assertParamExists('apiAdminV1AnalyticsRulesSyncPost', 'authorization', authorization);
|
|
5149
|
+
// verify required parameter 'dataTypesAnalyticsRuleSyncRequest' is not null or undefined
|
|
5150
|
+
assertParamExists('apiAdminV1AnalyticsRulesSyncPost', 'dataTypesAnalyticsRuleSyncRequest', dataTypesAnalyticsRuleSyncRequest);
|
|
5151
|
+
const localVarPath = `/api/admin/v1/analytics/rules/sync`;
|
|
5152
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
5153
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
5154
|
+
let baseOptions;
|
|
5155
|
+
if (configuration) {
|
|
5156
|
+
baseOptions = configuration.baseOptions;
|
|
5157
|
+
}
|
|
5158
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
|
|
5159
|
+
const localVarHeaderParameter = {};
|
|
5160
|
+
const localVarQueryParameter = {};
|
|
5161
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
5162
|
+
if (authorization != null) {
|
|
5163
|
+
localVarHeaderParameter['Authorization'] = String(authorization);
|
|
5164
|
+
}
|
|
5165
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
5166
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
5167
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
5168
|
+
localVarRequestOptions.data = serializeDataIfNeeded(dataTypesAnalyticsRuleSyncRequest, localVarRequestOptions, configuration);
|
|
5169
|
+
return {
|
|
5170
|
+
url: toPathString(localVarUrlObj),
|
|
5171
|
+
options: localVarRequestOptions,
|
|
5172
|
+
};
|
|
5173
|
+
}),
|
|
5088
5174
|
/**
|
|
5089
|
-
*
|
|
5090
|
-
* @summary
|
|
5091
|
-
* @param {
|
|
5175
|
+
* Retrieve a paginated list of analytics rules with optional filtering by store, collection, and active status. Supports both page-based and offset-based pagination.
|
|
5176
|
+
* @summary List Analytics Rules
|
|
5177
|
+
* @param {string} authorization Bearer JWT token
|
|
5178
|
+
* @param {string} xstoreid Store ID (for store-specific routes)
|
|
5179
|
+
* @param {number} [storeId] Filter by store ID (for general routes)
|
|
5180
|
+
* @param {string} [collectionName] Filter by collection name
|
|
5181
|
+
* @param {boolean} [isActive] Filter by active status
|
|
5182
|
+
* @param {number} [page] Page number (1-based, alternative to limit/offset)
|
|
5183
|
+
* @param {number} [pageSize] Number of results per page (alternative to limit)
|
|
5184
|
+
* @param {number} [limit] Maximum number of results (default: 50)
|
|
5185
|
+
* @param {number} [offset] Offset for pagination (default: 0)
|
|
5186
|
+
* @param {string} [sortBy] Sort field (name, created_at, modified_at, rule_id)
|
|
5187
|
+
* @param {string} [sortOrder] Sort order (asc, desc, default: desc)
|
|
5188
|
+
* @param {string} [searchQuery] Search in rule names, descriptions, and rule_ids
|
|
5092
5189
|
* @param {*} [options] Override http request option.
|
|
5093
5190
|
* @throws {RequiredError}
|
|
5094
5191
|
*/
|
|
5095
|
-
|
|
5096
|
-
|
|
5097
|
-
|
|
5098
|
-
|
|
5099
|
-
|
|
5100
|
-
|
|
5101
|
-
|
|
5102
|
-
|
|
5103
|
-
|
|
5192
|
+
apiAdminV1StoresXstoreidAnalyticsRulesGet: (authorization_1, xstoreid_1, storeId_1, collectionName_1, isActive_1, page_1, pageSize_1, limit_1, offset_1, sortBy_1, sortOrder_1, searchQuery_1, ...args_1) => __awaiter(this, [authorization_1, xstoreid_1, storeId_1, collectionName_1, isActive_1, page_1, pageSize_1, limit_1, offset_1, sortBy_1, sortOrder_1, searchQuery_1, ...args_1], void 0, function* (authorization, xstoreid, storeId, collectionName, isActive, page, pageSize, limit, offset, sortBy, sortOrder, searchQuery, options = {}) {
|
|
5193
|
+
// verify required parameter 'authorization' is not null or undefined
|
|
5194
|
+
assertParamExists('apiAdminV1StoresXstoreidAnalyticsRulesGet', 'authorization', authorization);
|
|
5195
|
+
// verify required parameter 'xstoreid' is not null or undefined
|
|
5196
|
+
assertParamExists('apiAdminV1StoresXstoreidAnalyticsRulesGet', 'xstoreid', xstoreid);
|
|
5197
|
+
const localVarPath = `/api/admin/v1/stores/{xstoreid}/analytics/rules`
|
|
5198
|
+
.replace(`{${"xstoreid"}}`, encodeURIComponent(String(xstoreid)));
|
|
5199
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
5200
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
5201
|
+
let baseOptions;
|
|
5202
|
+
if (configuration) {
|
|
5203
|
+
baseOptions = configuration.baseOptions;
|
|
5204
|
+
}
|
|
5205
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
|
|
5206
|
+
const localVarHeaderParameter = {};
|
|
5207
|
+
const localVarQueryParameter = {};
|
|
5208
|
+
if (storeId !== undefined) {
|
|
5209
|
+
localVarQueryParameter['store_id'] = storeId;
|
|
5210
|
+
}
|
|
5211
|
+
if (collectionName !== undefined) {
|
|
5212
|
+
localVarQueryParameter['collection_name'] = collectionName;
|
|
5213
|
+
}
|
|
5214
|
+
if (isActive !== undefined) {
|
|
5215
|
+
localVarQueryParameter['is_active'] = isActive;
|
|
5216
|
+
}
|
|
5217
|
+
if (page !== undefined) {
|
|
5218
|
+
localVarQueryParameter['page'] = page;
|
|
5219
|
+
}
|
|
5220
|
+
if (pageSize !== undefined) {
|
|
5221
|
+
localVarQueryParameter['page_size'] = pageSize;
|
|
5222
|
+
}
|
|
5223
|
+
if (limit !== undefined) {
|
|
5224
|
+
localVarQueryParameter['limit'] = limit;
|
|
5225
|
+
}
|
|
5226
|
+
if (offset !== undefined) {
|
|
5227
|
+
localVarQueryParameter['offset'] = offset;
|
|
5228
|
+
}
|
|
5229
|
+
if (sortBy !== undefined) {
|
|
5230
|
+
localVarQueryParameter['sort_by'] = sortBy;
|
|
5231
|
+
}
|
|
5232
|
+
if (sortOrder !== undefined) {
|
|
5233
|
+
localVarQueryParameter['sort_order'] = sortOrder;
|
|
5234
|
+
}
|
|
5235
|
+
if (searchQuery !== undefined) {
|
|
5236
|
+
localVarQueryParameter['search_query'] = searchQuery;
|
|
5237
|
+
}
|
|
5238
|
+
if (authorization != null) {
|
|
5239
|
+
localVarHeaderParameter['Authorization'] = String(authorization);
|
|
5240
|
+
}
|
|
5241
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
5242
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
5243
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
5244
|
+
return {
|
|
5245
|
+
url: toPathString(localVarUrlObj),
|
|
5246
|
+
options: localVarRequestOptions,
|
|
5247
|
+
};
|
|
5248
|
+
}),
|
|
5104
5249
|
/**
|
|
5105
|
-
*
|
|
5106
|
-
* @summary
|
|
5107
|
-
* @param {
|
|
5108
|
-
* @param {
|
|
5250
|
+
* Create a new analytics rule for Typesense curation. Rules define how search results should be modified (promoted, hidden, filtered, sorted) based on query conditions.
|
|
5251
|
+
* @summary Create Analytics Rule
|
|
5252
|
+
* @param {string} authorization Bearer JWT token
|
|
5253
|
+
* @param {string} xstoreid Store ID (for store-specific routes)
|
|
5254
|
+
* @param {DataTypesCreateAnalyticsRuleRequest} dataTypesCreateAnalyticsRuleRequest Analytics rule configuration
|
|
5109
5255
|
* @param {*} [options] Override http request option.
|
|
5110
5256
|
* @throws {RequiredError}
|
|
5111
5257
|
*/
|
|
5112
|
-
|
|
5113
|
-
|
|
5114
|
-
|
|
5115
|
-
|
|
5116
|
-
|
|
5117
|
-
|
|
5118
|
-
|
|
5119
|
-
}
|
|
5120
|
-
|
|
5258
|
+
apiAdminV1StoresXstoreidAnalyticsRulesPost: (authorization_1, xstoreid_1, dataTypesCreateAnalyticsRuleRequest_1, ...args_1) => __awaiter(this, [authorization_1, xstoreid_1, dataTypesCreateAnalyticsRuleRequest_1, ...args_1], void 0, function* (authorization, xstoreid, dataTypesCreateAnalyticsRuleRequest, options = {}) {
|
|
5259
|
+
// verify required parameter 'authorization' is not null or undefined
|
|
5260
|
+
assertParamExists('apiAdminV1StoresXstoreidAnalyticsRulesPost', 'authorization', authorization);
|
|
5261
|
+
// verify required parameter 'xstoreid' is not null or undefined
|
|
5262
|
+
assertParamExists('apiAdminV1StoresXstoreidAnalyticsRulesPost', 'xstoreid', xstoreid);
|
|
5263
|
+
// verify required parameter 'dataTypesCreateAnalyticsRuleRequest' is not null or undefined
|
|
5264
|
+
assertParamExists('apiAdminV1StoresXstoreidAnalyticsRulesPost', 'dataTypesCreateAnalyticsRuleRequest', dataTypesCreateAnalyticsRuleRequest);
|
|
5265
|
+
const localVarPath = `/api/admin/v1/stores/{xstoreid}/analytics/rules`
|
|
5266
|
+
.replace(`{${"xstoreid"}}`, encodeURIComponent(String(xstoreid)));
|
|
5267
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
5268
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
5269
|
+
let baseOptions;
|
|
5270
|
+
if (configuration) {
|
|
5271
|
+
baseOptions = configuration.baseOptions;
|
|
5272
|
+
}
|
|
5273
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
|
|
5274
|
+
const localVarHeaderParameter = {};
|
|
5275
|
+
const localVarQueryParameter = {};
|
|
5276
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
5277
|
+
if (authorization != null) {
|
|
5278
|
+
localVarHeaderParameter['Authorization'] = String(authorization);
|
|
5279
|
+
}
|
|
5280
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
5281
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
5282
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
5283
|
+
localVarRequestOptions.data = serializeDataIfNeeded(dataTypesCreateAnalyticsRuleRequest, localVarRequestOptions, configuration);
|
|
5284
|
+
return {
|
|
5285
|
+
url: toPathString(localVarUrlObj),
|
|
5286
|
+
options: localVarRequestOptions,
|
|
5287
|
+
};
|
|
5288
|
+
}),
|
|
5121
5289
|
/**
|
|
5122
|
-
*
|
|
5123
|
-
* @summary
|
|
5290
|
+
* Permanently delete an analytics rule from both the database and Typesense. This operation cannot be undone.
|
|
5291
|
+
* @summary Delete Analytics Rule
|
|
5292
|
+
* @param {string} authorization Bearer JWT token
|
|
5293
|
+
* @param {string} xstoreid Store ID (for store-specific routes)
|
|
5294
|
+
* @param {string} ruleId Rule ID
|
|
5124
5295
|
* @param {*} [options] Override http request option.
|
|
5125
5296
|
* @throws {RequiredError}
|
|
5126
5297
|
*/
|
|
5127
|
-
|
|
5128
|
-
|
|
5129
|
-
|
|
5130
|
-
|
|
5131
|
-
|
|
5132
|
-
|
|
5133
|
-
|
|
5134
|
-
}
|
|
5135
|
-
|
|
5298
|
+
apiAdminV1StoresXstoreidAnalyticsRulesRuleIdDelete: (authorization_1, xstoreid_1, ruleId_1, ...args_1) => __awaiter(this, [authorization_1, xstoreid_1, ruleId_1, ...args_1], void 0, function* (authorization, xstoreid, ruleId, options = {}) {
|
|
5299
|
+
// verify required parameter 'authorization' is not null or undefined
|
|
5300
|
+
assertParamExists('apiAdminV1StoresXstoreidAnalyticsRulesRuleIdDelete', 'authorization', authorization);
|
|
5301
|
+
// verify required parameter 'xstoreid' is not null or undefined
|
|
5302
|
+
assertParamExists('apiAdminV1StoresXstoreidAnalyticsRulesRuleIdDelete', 'xstoreid', xstoreid);
|
|
5303
|
+
// verify required parameter 'ruleId' is not null or undefined
|
|
5304
|
+
assertParamExists('apiAdminV1StoresXstoreidAnalyticsRulesRuleIdDelete', 'ruleId', ruleId);
|
|
5305
|
+
const localVarPath = `/api/admin/v1/stores/{xstoreid}/analytics/rules/{ruleId}`
|
|
5306
|
+
.replace(`{${"xstoreid"}}`, encodeURIComponent(String(xstoreid)))
|
|
5307
|
+
.replace(`{${"ruleId"}}`, encodeURIComponent(String(ruleId)));
|
|
5308
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
5309
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
5310
|
+
let baseOptions;
|
|
5311
|
+
if (configuration) {
|
|
5312
|
+
baseOptions = configuration.baseOptions;
|
|
5313
|
+
}
|
|
5314
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'DELETE' }, baseOptions), options);
|
|
5315
|
+
const localVarHeaderParameter = {};
|
|
5316
|
+
const localVarQueryParameter = {};
|
|
5317
|
+
if (authorization != null) {
|
|
5318
|
+
localVarHeaderParameter['Authorization'] = String(authorization);
|
|
5319
|
+
}
|
|
5320
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
5321
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
5322
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
5323
|
+
return {
|
|
5324
|
+
url: toPathString(localVarUrlObj),
|
|
5325
|
+
options: localVarRequestOptions,
|
|
5326
|
+
};
|
|
5327
|
+
}),
|
|
5136
5328
|
/**
|
|
5137
|
-
*
|
|
5138
|
-
* @summary
|
|
5139
|
-
* @param {
|
|
5329
|
+
* Retrieve a specific analytics rule by its ID. Returns the complete rule configuration including Typesense override actions.
|
|
5330
|
+
* @summary Get Analytics Rule
|
|
5331
|
+
* @param {string} authorization Bearer JWT token
|
|
5332
|
+
* @param {string} xstoreid Store ID (for store-specific routes)
|
|
5333
|
+
* @param {string} ruleId Rule ID
|
|
5140
5334
|
* @param {*} [options] Override http request option.
|
|
5141
5335
|
* @throws {RequiredError}
|
|
5142
5336
|
*/
|
|
5143
|
-
|
|
5144
|
-
|
|
5337
|
+
apiAdminV1StoresXstoreidAnalyticsRulesRuleIdGet: (authorization_1, xstoreid_1, ruleId_1, ...args_1) => __awaiter(this, [authorization_1, xstoreid_1, ruleId_1, ...args_1], void 0, function* (authorization, xstoreid, ruleId, options = {}) {
|
|
5338
|
+
// verify required parameter 'authorization' is not null or undefined
|
|
5339
|
+
assertParamExists('apiAdminV1StoresXstoreidAnalyticsRulesRuleIdGet', 'authorization', authorization);
|
|
5340
|
+
// verify required parameter 'xstoreid' is not null or undefined
|
|
5341
|
+
assertParamExists('apiAdminV1StoresXstoreidAnalyticsRulesRuleIdGet', 'xstoreid', xstoreid);
|
|
5342
|
+
// verify required parameter 'ruleId' is not null or undefined
|
|
5343
|
+
assertParamExists('apiAdminV1StoresXstoreidAnalyticsRulesRuleIdGet', 'ruleId', ruleId);
|
|
5344
|
+
const localVarPath = `/api/admin/v1/stores/{xstoreid}/analytics/rules/{ruleId}`
|
|
5345
|
+
.replace(`{${"xstoreid"}}`, encodeURIComponent(String(xstoreid)))
|
|
5346
|
+
.replace(`{${"ruleId"}}`, encodeURIComponent(String(ruleId)));
|
|
5347
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
5348
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
5349
|
+
let baseOptions;
|
|
5350
|
+
if (configuration) {
|
|
5351
|
+
baseOptions = configuration.baseOptions;
|
|
5352
|
+
}
|
|
5353
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
|
|
5354
|
+
const localVarHeaderParameter = {};
|
|
5355
|
+
const localVarQueryParameter = {};
|
|
5356
|
+
if (authorization != null) {
|
|
5357
|
+
localVarHeaderParameter['Authorization'] = String(authorization);
|
|
5358
|
+
}
|
|
5359
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
5360
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
5361
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
5362
|
+
return {
|
|
5363
|
+
url: toPathString(localVarUrlObj),
|
|
5364
|
+
options: localVarRequestOptions,
|
|
5365
|
+
};
|
|
5366
|
+
}),
|
|
5367
|
+
/**
|
|
5368
|
+
* Update an existing analytics rule. Supports partial updates. When is_active is set to false, the rule is removed from Typesense. When is_active is set to true, the rule is synced to Typesense.
|
|
5369
|
+
* @summary Update Analytics Rule
|
|
5370
|
+
* @param {string} authorization Bearer JWT token
|
|
5371
|
+
* @param {string} xstoreid Store ID (for store-specific routes)
|
|
5372
|
+
* @param {string} ruleId Rule ID
|
|
5373
|
+
* @param {DataTypesUpdateAnalyticsRuleRequest} dataTypesUpdateAnalyticsRuleRequest Updated rule configuration (partial update supported)
|
|
5374
|
+
* @param {*} [options] Override http request option.
|
|
5375
|
+
* @throws {RequiredError}
|
|
5376
|
+
*/
|
|
5377
|
+
apiAdminV1StoresXstoreidAnalyticsRulesRuleIdPut: (authorization_1, xstoreid_1, ruleId_1, dataTypesUpdateAnalyticsRuleRequest_1, ...args_1) => __awaiter(this, [authorization_1, xstoreid_1, ruleId_1, dataTypesUpdateAnalyticsRuleRequest_1, ...args_1], void 0, function* (authorization, xstoreid, ruleId, dataTypesUpdateAnalyticsRuleRequest, options = {}) {
|
|
5378
|
+
// verify required parameter 'authorization' is not null or undefined
|
|
5379
|
+
assertParamExists('apiAdminV1StoresXstoreidAnalyticsRulesRuleIdPut', 'authorization', authorization);
|
|
5380
|
+
// verify required parameter 'xstoreid' is not null or undefined
|
|
5381
|
+
assertParamExists('apiAdminV1StoresXstoreidAnalyticsRulesRuleIdPut', 'xstoreid', xstoreid);
|
|
5382
|
+
// verify required parameter 'ruleId' is not null or undefined
|
|
5383
|
+
assertParamExists('apiAdminV1StoresXstoreidAnalyticsRulesRuleIdPut', 'ruleId', ruleId);
|
|
5384
|
+
// verify required parameter 'dataTypesUpdateAnalyticsRuleRequest' is not null or undefined
|
|
5385
|
+
assertParamExists('apiAdminV1StoresXstoreidAnalyticsRulesRuleIdPut', 'dataTypesUpdateAnalyticsRuleRequest', dataTypesUpdateAnalyticsRuleRequest);
|
|
5386
|
+
const localVarPath = `/api/admin/v1/stores/{xstoreid}/analytics/rules/{ruleId}`
|
|
5387
|
+
.replace(`{${"xstoreid"}}`, encodeURIComponent(String(xstoreid)))
|
|
5388
|
+
.replace(`{${"ruleId"}}`, encodeURIComponent(String(ruleId)));
|
|
5389
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
5390
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
5391
|
+
let baseOptions;
|
|
5392
|
+
if (configuration) {
|
|
5393
|
+
baseOptions = configuration.baseOptions;
|
|
5394
|
+
}
|
|
5395
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'PUT' }, baseOptions), options);
|
|
5396
|
+
const localVarHeaderParameter = {};
|
|
5397
|
+
const localVarQueryParameter = {};
|
|
5398
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
5399
|
+
if (authorization != null) {
|
|
5400
|
+
localVarHeaderParameter['Authorization'] = String(authorization);
|
|
5401
|
+
}
|
|
5402
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
5403
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
5404
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
5405
|
+
localVarRequestOptions.data = serializeDataIfNeeded(dataTypesUpdateAnalyticsRuleRequest, localVarRequestOptions, configuration);
|
|
5406
|
+
return {
|
|
5407
|
+
url: toPathString(localVarUrlObj),
|
|
5408
|
+
options: localVarRequestOptions,
|
|
5409
|
+
};
|
|
5410
|
+
}),
|
|
5411
|
+
/**
|
|
5412
|
+
* Manually synchronize analytics rules to Typesense. This endpoint can be used to force a sync of all active rules or specific rules to Typesense collections.
|
|
5413
|
+
* @summary Sync Rules to Typesense
|
|
5414
|
+
* @param {string} authorization Bearer JWT token
|
|
5415
|
+
* @param {string} xstoreid Store ID (for store-specific routes)
|
|
5416
|
+
* @param {DataTypesAnalyticsRuleSyncRequest} dataTypesAnalyticsRuleSyncRequest Sync configuration (optional filters)
|
|
5417
|
+
* @param {*} [options] Override http request option.
|
|
5418
|
+
* @throws {RequiredError}
|
|
5419
|
+
*/
|
|
5420
|
+
apiAdminV1StoresXstoreidAnalyticsRulesSyncPost: (authorization_1, xstoreid_1, dataTypesAnalyticsRuleSyncRequest_1, ...args_1) => __awaiter(this, [authorization_1, xstoreid_1, dataTypesAnalyticsRuleSyncRequest_1, ...args_1], void 0, function* (authorization, xstoreid, dataTypesAnalyticsRuleSyncRequest, options = {}) {
|
|
5421
|
+
// verify required parameter 'authorization' is not null or undefined
|
|
5422
|
+
assertParamExists('apiAdminV1StoresXstoreidAnalyticsRulesSyncPost', 'authorization', authorization);
|
|
5423
|
+
// verify required parameter 'xstoreid' is not null or undefined
|
|
5424
|
+
assertParamExists('apiAdminV1StoresXstoreidAnalyticsRulesSyncPost', 'xstoreid', xstoreid);
|
|
5425
|
+
// verify required parameter 'dataTypesAnalyticsRuleSyncRequest' is not null or undefined
|
|
5426
|
+
assertParamExists('apiAdminV1StoresXstoreidAnalyticsRulesSyncPost', 'dataTypesAnalyticsRuleSyncRequest', dataTypesAnalyticsRuleSyncRequest);
|
|
5427
|
+
const localVarPath = `/api/admin/v1/stores/{xstoreid}/analytics/rules/sync`
|
|
5428
|
+
.replace(`{${"xstoreid"}}`, encodeURIComponent(String(xstoreid)));
|
|
5429
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
5430
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
5431
|
+
let baseOptions;
|
|
5432
|
+
if (configuration) {
|
|
5433
|
+
baseOptions = configuration.baseOptions;
|
|
5434
|
+
}
|
|
5435
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
|
|
5436
|
+
const localVarHeaderParameter = {};
|
|
5437
|
+
const localVarQueryParameter = {};
|
|
5438
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
5439
|
+
if (authorization != null) {
|
|
5440
|
+
localVarHeaderParameter['Authorization'] = String(authorization);
|
|
5441
|
+
}
|
|
5442
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
5443
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
5444
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
5445
|
+
localVarRequestOptions.data = serializeDataIfNeeded(dataTypesAnalyticsRuleSyncRequest, localVarRequestOptions, configuration);
|
|
5446
|
+
return {
|
|
5447
|
+
url: toPathString(localVarUrlObj),
|
|
5448
|
+
options: localVarRequestOptions,
|
|
5449
|
+
};
|
|
5450
|
+
}),
|
|
5451
|
+
};
|
|
5452
|
+
};
|
|
5453
|
+
/**
|
|
5454
|
+
* AnalyticsRulesApi - functional programming interface
|
|
5455
|
+
* @export
|
|
5456
|
+
*/
|
|
5457
|
+
export const AnalyticsRulesApiFp = function (configuration) {
|
|
5458
|
+
const localVarAxiosParamCreator = AnalyticsRulesApiAxiosParamCreator(configuration);
|
|
5459
|
+
return {
|
|
5460
|
+
/**
|
|
5461
|
+
* Retrieve a paginated list of analytics rules with optional filtering by store, collection, and active status. Supports both page-based and offset-based pagination.
|
|
5462
|
+
* @summary List Analytics Rules
|
|
5463
|
+
* @param {string} authorization Bearer JWT token
|
|
5464
|
+
* @param {number} [storeId] Filter by store ID (for general routes)
|
|
5465
|
+
* @param {string} [collectionName] Filter by collection name
|
|
5466
|
+
* @param {boolean} [isActive] Filter by active status
|
|
5467
|
+
* @param {number} [page] Page number (1-based, alternative to limit/offset)
|
|
5468
|
+
* @param {number} [pageSize] Number of results per page (alternative to limit)
|
|
5469
|
+
* @param {number} [limit] Maximum number of results (default: 50)
|
|
5470
|
+
* @param {number} [offset] Offset for pagination (default: 0)
|
|
5471
|
+
* @param {string} [sortBy] Sort field (name, created_at, modified_at, rule_id)
|
|
5472
|
+
* @param {string} [sortOrder] Sort order (asc, desc, default: desc)
|
|
5473
|
+
* @param {string} [searchQuery] Search in rule names, descriptions, and rule_ids
|
|
5474
|
+
* @param {*} [options] Override http request option.
|
|
5475
|
+
* @throws {RequiredError}
|
|
5476
|
+
*/
|
|
5477
|
+
apiAdminV1AnalyticsRulesGet(authorization, storeId, collectionName, isActive, page, pageSize, limit, offset, sortBy, sortOrder, searchQuery, options) {
|
|
5478
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
5479
|
+
var _a, _b, _c;
|
|
5480
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.apiAdminV1AnalyticsRulesGet(authorization, storeId, collectionName, isActive, page, pageSize, limit, offset, sortBy, sortOrder, searchQuery, options);
|
|
5481
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
5482
|
+
const localVarOperationServerBasePath = (_c = (_b = operationServerMap['AnalyticsRulesApi.apiAdminV1AnalyticsRulesGet']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
5483
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
5484
|
+
});
|
|
5485
|
+
},
|
|
5486
|
+
/**
|
|
5487
|
+
* Create a new analytics rule for Typesense curation. Rules define how search results should be modified (promoted, hidden, filtered, sorted) based on query conditions.
|
|
5488
|
+
* @summary Create Analytics Rule
|
|
5489
|
+
* @param {string} authorization Bearer JWT token
|
|
5490
|
+
* @param {DataTypesCreateAnalyticsRuleRequest} dataTypesCreateAnalyticsRuleRequest Analytics rule configuration
|
|
5491
|
+
* @param {*} [options] Override http request option.
|
|
5492
|
+
* @throws {RequiredError}
|
|
5493
|
+
*/
|
|
5494
|
+
apiAdminV1AnalyticsRulesPost(authorization, dataTypesCreateAnalyticsRuleRequest, options) {
|
|
5495
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
5496
|
+
var _a, _b, _c;
|
|
5497
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.apiAdminV1AnalyticsRulesPost(authorization, dataTypesCreateAnalyticsRuleRequest, options);
|
|
5498
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
5499
|
+
const localVarOperationServerBasePath = (_c = (_b = operationServerMap['AnalyticsRulesApi.apiAdminV1AnalyticsRulesPost']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
5500
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
5501
|
+
});
|
|
5502
|
+
},
|
|
5503
|
+
/**
|
|
5504
|
+
* Permanently delete an analytics rule from both the database and Typesense. This operation cannot be undone.
|
|
5505
|
+
* @summary Delete Analytics Rule
|
|
5506
|
+
* @param {string} authorization Bearer JWT token
|
|
5507
|
+
* @param {string} ruleId Rule ID
|
|
5508
|
+
* @param {*} [options] Override http request option.
|
|
5509
|
+
* @throws {RequiredError}
|
|
5510
|
+
*/
|
|
5511
|
+
apiAdminV1AnalyticsRulesRuleIdDelete(authorization, ruleId, options) {
|
|
5512
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
5513
|
+
var _a, _b, _c;
|
|
5514
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.apiAdminV1AnalyticsRulesRuleIdDelete(authorization, ruleId, options);
|
|
5515
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
5516
|
+
const localVarOperationServerBasePath = (_c = (_b = operationServerMap['AnalyticsRulesApi.apiAdminV1AnalyticsRulesRuleIdDelete']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
5517
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
5518
|
+
});
|
|
5519
|
+
},
|
|
5520
|
+
/**
|
|
5521
|
+
* Retrieve a specific analytics rule by its ID. Returns the complete rule configuration including Typesense override actions.
|
|
5522
|
+
* @summary Get Analytics Rule
|
|
5523
|
+
* @param {string} authorization Bearer JWT token
|
|
5524
|
+
* @param {string} ruleId Rule ID
|
|
5525
|
+
* @param {*} [options] Override http request option.
|
|
5526
|
+
* @throws {RequiredError}
|
|
5527
|
+
*/
|
|
5528
|
+
apiAdminV1AnalyticsRulesRuleIdGet(authorization, ruleId, options) {
|
|
5529
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
5530
|
+
var _a, _b, _c;
|
|
5531
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.apiAdminV1AnalyticsRulesRuleIdGet(authorization, ruleId, options);
|
|
5532
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
5533
|
+
const localVarOperationServerBasePath = (_c = (_b = operationServerMap['AnalyticsRulesApi.apiAdminV1AnalyticsRulesRuleIdGet']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
5534
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
5535
|
+
});
|
|
5536
|
+
},
|
|
5537
|
+
/**
|
|
5538
|
+
* Update an existing analytics rule. Supports partial updates. When is_active is set to false, the rule is removed from Typesense. When is_active is set to true, the rule is synced to Typesense.
|
|
5539
|
+
* @summary Update Analytics Rule
|
|
5540
|
+
* @param {string} authorization Bearer JWT token
|
|
5541
|
+
* @param {string} ruleId Rule ID
|
|
5542
|
+
* @param {DataTypesUpdateAnalyticsRuleRequest} dataTypesUpdateAnalyticsRuleRequest Updated rule configuration (partial update supported)
|
|
5543
|
+
* @param {*} [options] Override http request option.
|
|
5544
|
+
* @throws {RequiredError}
|
|
5545
|
+
*/
|
|
5546
|
+
apiAdminV1AnalyticsRulesRuleIdPut(authorization, ruleId, dataTypesUpdateAnalyticsRuleRequest, options) {
|
|
5547
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
5548
|
+
var _a, _b, _c;
|
|
5549
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.apiAdminV1AnalyticsRulesRuleIdPut(authorization, ruleId, dataTypesUpdateAnalyticsRuleRequest, options);
|
|
5550
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
5551
|
+
const localVarOperationServerBasePath = (_c = (_b = operationServerMap['AnalyticsRulesApi.apiAdminV1AnalyticsRulesRuleIdPut']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
5552
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
5553
|
+
});
|
|
5554
|
+
},
|
|
5555
|
+
/**
|
|
5556
|
+
* Manually synchronize analytics rules to Typesense. This endpoint can be used to force a sync of all active rules or specific rules to Typesense collections.
|
|
5557
|
+
* @summary Sync Rules to Typesense
|
|
5558
|
+
* @param {string} authorization Bearer JWT token
|
|
5559
|
+
* @param {DataTypesAnalyticsRuleSyncRequest} dataTypesAnalyticsRuleSyncRequest Sync configuration (optional filters)
|
|
5560
|
+
* @param {*} [options] Override http request option.
|
|
5561
|
+
* @throws {RequiredError}
|
|
5562
|
+
*/
|
|
5563
|
+
apiAdminV1AnalyticsRulesSyncPost(authorization, dataTypesAnalyticsRuleSyncRequest, options) {
|
|
5564
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
5565
|
+
var _a, _b, _c;
|
|
5566
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.apiAdminV1AnalyticsRulesSyncPost(authorization, dataTypesAnalyticsRuleSyncRequest, options);
|
|
5567
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
5568
|
+
const localVarOperationServerBasePath = (_c = (_b = operationServerMap['AnalyticsRulesApi.apiAdminV1AnalyticsRulesSyncPost']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
5569
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
5570
|
+
});
|
|
5571
|
+
},
|
|
5572
|
+
/**
|
|
5573
|
+
* Retrieve a paginated list of analytics rules with optional filtering by store, collection, and active status. Supports both page-based and offset-based pagination.
|
|
5574
|
+
* @summary List Analytics Rules
|
|
5575
|
+
* @param {string} authorization Bearer JWT token
|
|
5576
|
+
* @param {string} xstoreid Store ID (for store-specific routes)
|
|
5577
|
+
* @param {number} [storeId] Filter by store ID (for general routes)
|
|
5578
|
+
* @param {string} [collectionName] Filter by collection name
|
|
5579
|
+
* @param {boolean} [isActive] Filter by active status
|
|
5580
|
+
* @param {number} [page] Page number (1-based, alternative to limit/offset)
|
|
5581
|
+
* @param {number} [pageSize] Number of results per page (alternative to limit)
|
|
5582
|
+
* @param {number} [limit] Maximum number of results (default: 50)
|
|
5583
|
+
* @param {number} [offset] Offset for pagination (default: 0)
|
|
5584
|
+
* @param {string} [sortBy] Sort field (name, created_at, modified_at, rule_id)
|
|
5585
|
+
* @param {string} [sortOrder] Sort order (asc, desc, default: desc)
|
|
5586
|
+
* @param {string} [searchQuery] Search in rule names, descriptions, and rule_ids
|
|
5587
|
+
* @param {*} [options] Override http request option.
|
|
5588
|
+
* @throws {RequiredError}
|
|
5589
|
+
*/
|
|
5590
|
+
apiAdminV1StoresXstoreidAnalyticsRulesGet(authorization, xstoreid, storeId, collectionName, isActive, page, pageSize, limit, offset, sortBy, sortOrder, searchQuery, options) {
|
|
5591
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
5592
|
+
var _a, _b, _c;
|
|
5593
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.apiAdminV1StoresXstoreidAnalyticsRulesGet(authorization, xstoreid, storeId, collectionName, isActive, page, pageSize, limit, offset, sortBy, sortOrder, searchQuery, options);
|
|
5594
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
5595
|
+
const localVarOperationServerBasePath = (_c = (_b = operationServerMap['AnalyticsRulesApi.apiAdminV1StoresXstoreidAnalyticsRulesGet']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
5596
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
5597
|
+
});
|
|
5598
|
+
},
|
|
5599
|
+
/**
|
|
5600
|
+
* Create a new analytics rule for Typesense curation. Rules define how search results should be modified (promoted, hidden, filtered, sorted) based on query conditions.
|
|
5601
|
+
* @summary Create Analytics Rule
|
|
5602
|
+
* @param {string} authorization Bearer JWT token
|
|
5603
|
+
* @param {string} xstoreid Store ID (for store-specific routes)
|
|
5604
|
+
* @param {DataTypesCreateAnalyticsRuleRequest} dataTypesCreateAnalyticsRuleRequest Analytics rule configuration
|
|
5605
|
+
* @param {*} [options] Override http request option.
|
|
5606
|
+
* @throws {RequiredError}
|
|
5607
|
+
*/
|
|
5608
|
+
apiAdminV1StoresXstoreidAnalyticsRulesPost(authorization, xstoreid, dataTypesCreateAnalyticsRuleRequest, options) {
|
|
5609
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
5610
|
+
var _a, _b, _c;
|
|
5611
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.apiAdminV1StoresXstoreidAnalyticsRulesPost(authorization, xstoreid, dataTypesCreateAnalyticsRuleRequest, options);
|
|
5612
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
5613
|
+
const localVarOperationServerBasePath = (_c = (_b = operationServerMap['AnalyticsRulesApi.apiAdminV1StoresXstoreidAnalyticsRulesPost']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
5614
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
5615
|
+
});
|
|
5616
|
+
},
|
|
5617
|
+
/**
|
|
5618
|
+
* Permanently delete an analytics rule from both the database and Typesense. This operation cannot be undone.
|
|
5619
|
+
* @summary Delete Analytics Rule
|
|
5620
|
+
* @param {string} authorization Bearer JWT token
|
|
5621
|
+
* @param {string} xstoreid Store ID (for store-specific routes)
|
|
5622
|
+
* @param {string} ruleId Rule ID
|
|
5623
|
+
* @param {*} [options] Override http request option.
|
|
5624
|
+
* @throws {RequiredError}
|
|
5625
|
+
*/
|
|
5626
|
+
apiAdminV1StoresXstoreidAnalyticsRulesRuleIdDelete(authorization, xstoreid, ruleId, options) {
|
|
5627
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
5628
|
+
var _a, _b, _c;
|
|
5629
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.apiAdminV1StoresXstoreidAnalyticsRulesRuleIdDelete(authorization, xstoreid, ruleId, options);
|
|
5630
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
5631
|
+
const localVarOperationServerBasePath = (_c = (_b = operationServerMap['AnalyticsRulesApi.apiAdminV1StoresXstoreidAnalyticsRulesRuleIdDelete']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
5632
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
5633
|
+
});
|
|
5634
|
+
},
|
|
5635
|
+
/**
|
|
5636
|
+
* Retrieve a specific analytics rule by its ID. Returns the complete rule configuration including Typesense override actions.
|
|
5637
|
+
* @summary Get Analytics Rule
|
|
5638
|
+
* @param {string} authorization Bearer JWT token
|
|
5639
|
+
* @param {string} xstoreid Store ID (for store-specific routes)
|
|
5640
|
+
* @param {string} ruleId Rule ID
|
|
5641
|
+
* @param {*} [options] Override http request option.
|
|
5642
|
+
* @throws {RequiredError}
|
|
5643
|
+
*/
|
|
5644
|
+
apiAdminV1StoresXstoreidAnalyticsRulesRuleIdGet(authorization, xstoreid, ruleId, options) {
|
|
5645
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
5646
|
+
var _a, _b, _c;
|
|
5647
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.apiAdminV1StoresXstoreidAnalyticsRulesRuleIdGet(authorization, xstoreid, ruleId, options);
|
|
5648
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
5649
|
+
const localVarOperationServerBasePath = (_c = (_b = operationServerMap['AnalyticsRulesApi.apiAdminV1StoresXstoreidAnalyticsRulesRuleIdGet']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
5650
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
5651
|
+
});
|
|
5652
|
+
},
|
|
5653
|
+
/**
|
|
5654
|
+
* Update an existing analytics rule. Supports partial updates. When is_active is set to false, the rule is removed from Typesense. When is_active is set to true, the rule is synced to Typesense.
|
|
5655
|
+
* @summary Update Analytics Rule
|
|
5656
|
+
* @param {string} authorization Bearer JWT token
|
|
5657
|
+
* @param {string} xstoreid Store ID (for store-specific routes)
|
|
5658
|
+
* @param {string} ruleId Rule ID
|
|
5659
|
+
* @param {DataTypesUpdateAnalyticsRuleRequest} dataTypesUpdateAnalyticsRuleRequest Updated rule configuration (partial update supported)
|
|
5660
|
+
* @param {*} [options] Override http request option.
|
|
5661
|
+
* @throws {RequiredError}
|
|
5662
|
+
*/
|
|
5663
|
+
apiAdminV1StoresXstoreidAnalyticsRulesRuleIdPut(authorization, xstoreid, ruleId, dataTypesUpdateAnalyticsRuleRequest, options) {
|
|
5664
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
5665
|
+
var _a, _b, _c;
|
|
5666
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.apiAdminV1StoresXstoreidAnalyticsRulesRuleIdPut(authorization, xstoreid, ruleId, dataTypesUpdateAnalyticsRuleRequest, options);
|
|
5667
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
5668
|
+
const localVarOperationServerBasePath = (_c = (_b = operationServerMap['AnalyticsRulesApi.apiAdminV1StoresXstoreidAnalyticsRulesRuleIdPut']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
5669
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
5670
|
+
});
|
|
5671
|
+
},
|
|
5672
|
+
/**
|
|
5673
|
+
* Manually synchronize analytics rules to Typesense. This endpoint can be used to force a sync of all active rules or specific rules to Typesense collections.
|
|
5674
|
+
* @summary Sync Rules to Typesense
|
|
5675
|
+
* @param {string} authorization Bearer JWT token
|
|
5676
|
+
* @param {string} xstoreid Store ID (for store-specific routes)
|
|
5677
|
+
* @param {DataTypesAnalyticsRuleSyncRequest} dataTypesAnalyticsRuleSyncRequest Sync configuration (optional filters)
|
|
5678
|
+
* @param {*} [options] Override http request option.
|
|
5679
|
+
* @throws {RequiredError}
|
|
5680
|
+
*/
|
|
5681
|
+
apiAdminV1StoresXstoreidAnalyticsRulesSyncPost(authorization, xstoreid, dataTypesAnalyticsRuleSyncRequest, options) {
|
|
5682
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
5683
|
+
var _a, _b, _c;
|
|
5684
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.apiAdminV1StoresXstoreidAnalyticsRulesSyncPost(authorization, xstoreid, dataTypesAnalyticsRuleSyncRequest, options);
|
|
5685
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
5686
|
+
const localVarOperationServerBasePath = (_c = (_b = operationServerMap['AnalyticsRulesApi.apiAdminV1StoresXstoreidAnalyticsRulesSyncPost']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
5687
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
5688
|
+
});
|
|
5689
|
+
},
|
|
5690
|
+
};
|
|
5691
|
+
};
|
|
5692
|
+
/**
|
|
5693
|
+
* AnalyticsRulesApi - factory interface
|
|
5694
|
+
* @export
|
|
5695
|
+
*/
|
|
5696
|
+
export const AnalyticsRulesApiFactory = function (configuration, basePath, axios) {
|
|
5697
|
+
const localVarFp = AnalyticsRulesApiFp(configuration);
|
|
5698
|
+
return {
|
|
5699
|
+
/**
|
|
5700
|
+
* Retrieve a paginated list of analytics rules with optional filtering by store, collection, and active status. Supports both page-based and offset-based pagination.
|
|
5701
|
+
* @summary List Analytics Rules
|
|
5702
|
+
* @param {string} authorization Bearer JWT token
|
|
5703
|
+
* @param {number} [storeId] Filter by store ID (for general routes)
|
|
5704
|
+
* @param {string} [collectionName] Filter by collection name
|
|
5705
|
+
* @param {boolean} [isActive] Filter by active status
|
|
5706
|
+
* @param {number} [page] Page number (1-based, alternative to limit/offset)
|
|
5707
|
+
* @param {number} [pageSize] Number of results per page (alternative to limit)
|
|
5708
|
+
* @param {number} [limit] Maximum number of results (default: 50)
|
|
5709
|
+
* @param {number} [offset] Offset for pagination (default: 0)
|
|
5710
|
+
* @param {string} [sortBy] Sort field (name, created_at, modified_at, rule_id)
|
|
5711
|
+
* @param {string} [sortOrder] Sort order (asc, desc, default: desc)
|
|
5712
|
+
* @param {string} [searchQuery] Search in rule names, descriptions, and rule_ids
|
|
5713
|
+
* @param {*} [options] Override http request option.
|
|
5714
|
+
* @throws {RequiredError}
|
|
5715
|
+
*/
|
|
5716
|
+
apiAdminV1AnalyticsRulesGet(authorization, storeId, collectionName, isActive, page, pageSize, limit, offset, sortBy, sortOrder, searchQuery, options) {
|
|
5717
|
+
return localVarFp.apiAdminV1AnalyticsRulesGet(authorization, storeId, collectionName, isActive, page, pageSize, limit, offset, sortBy, sortOrder, searchQuery, options).then((request) => request(axios, basePath));
|
|
5718
|
+
},
|
|
5719
|
+
/**
|
|
5720
|
+
* Create a new analytics rule for Typesense curation. Rules define how search results should be modified (promoted, hidden, filtered, sorted) based on query conditions.
|
|
5721
|
+
* @summary Create Analytics Rule
|
|
5722
|
+
* @param {string} authorization Bearer JWT token
|
|
5723
|
+
* @param {DataTypesCreateAnalyticsRuleRequest} dataTypesCreateAnalyticsRuleRequest Analytics rule configuration
|
|
5724
|
+
* @param {*} [options] Override http request option.
|
|
5725
|
+
* @throws {RequiredError}
|
|
5726
|
+
*/
|
|
5727
|
+
apiAdminV1AnalyticsRulesPost(authorization, dataTypesCreateAnalyticsRuleRequest, options) {
|
|
5728
|
+
return localVarFp.apiAdminV1AnalyticsRulesPost(authorization, dataTypesCreateAnalyticsRuleRequest, options).then((request) => request(axios, basePath));
|
|
5729
|
+
},
|
|
5730
|
+
/**
|
|
5731
|
+
* Permanently delete an analytics rule from both the database and Typesense. This operation cannot be undone.
|
|
5732
|
+
* @summary Delete Analytics Rule
|
|
5733
|
+
* @param {string} authorization Bearer JWT token
|
|
5734
|
+
* @param {string} ruleId Rule ID
|
|
5735
|
+
* @param {*} [options] Override http request option.
|
|
5736
|
+
* @throws {RequiredError}
|
|
5737
|
+
*/
|
|
5738
|
+
apiAdminV1AnalyticsRulesRuleIdDelete(authorization, ruleId, options) {
|
|
5739
|
+
return localVarFp.apiAdminV1AnalyticsRulesRuleIdDelete(authorization, ruleId, options).then((request) => request(axios, basePath));
|
|
5740
|
+
},
|
|
5741
|
+
/**
|
|
5742
|
+
* Retrieve a specific analytics rule by its ID. Returns the complete rule configuration including Typesense override actions.
|
|
5743
|
+
* @summary Get Analytics Rule
|
|
5744
|
+
* @param {string} authorization Bearer JWT token
|
|
5745
|
+
* @param {string} ruleId Rule ID
|
|
5746
|
+
* @param {*} [options] Override http request option.
|
|
5747
|
+
* @throws {RequiredError}
|
|
5748
|
+
*/
|
|
5749
|
+
apiAdminV1AnalyticsRulesRuleIdGet(authorization, ruleId, options) {
|
|
5750
|
+
return localVarFp.apiAdminV1AnalyticsRulesRuleIdGet(authorization, ruleId, options).then((request) => request(axios, basePath));
|
|
5751
|
+
},
|
|
5752
|
+
/**
|
|
5753
|
+
* Update an existing analytics rule. Supports partial updates. When is_active is set to false, the rule is removed from Typesense. When is_active is set to true, the rule is synced to Typesense.
|
|
5754
|
+
* @summary Update Analytics Rule
|
|
5755
|
+
* @param {string} authorization Bearer JWT token
|
|
5756
|
+
* @param {string} ruleId Rule ID
|
|
5757
|
+
* @param {DataTypesUpdateAnalyticsRuleRequest} dataTypesUpdateAnalyticsRuleRequest Updated rule configuration (partial update supported)
|
|
5758
|
+
* @param {*} [options] Override http request option.
|
|
5759
|
+
* @throws {RequiredError}
|
|
5760
|
+
*/
|
|
5761
|
+
apiAdminV1AnalyticsRulesRuleIdPut(authorization, ruleId, dataTypesUpdateAnalyticsRuleRequest, options) {
|
|
5762
|
+
return localVarFp.apiAdminV1AnalyticsRulesRuleIdPut(authorization, ruleId, dataTypesUpdateAnalyticsRuleRequest, options).then((request) => request(axios, basePath));
|
|
5763
|
+
},
|
|
5764
|
+
/**
|
|
5765
|
+
* Manually synchronize analytics rules to Typesense. This endpoint can be used to force a sync of all active rules or specific rules to Typesense collections.
|
|
5766
|
+
* @summary Sync Rules to Typesense
|
|
5767
|
+
* @param {string} authorization Bearer JWT token
|
|
5768
|
+
* @param {DataTypesAnalyticsRuleSyncRequest} dataTypesAnalyticsRuleSyncRequest Sync configuration (optional filters)
|
|
5769
|
+
* @param {*} [options] Override http request option.
|
|
5770
|
+
* @throws {RequiredError}
|
|
5771
|
+
*/
|
|
5772
|
+
apiAdminV1AnalyticsRulesSyncPost(authorization, dataTypesAnalyticsRuleSyncRequest, options) {
|
|
5773
|
+
return localVarFp.apiAdminV1AnalyticsRulesSyncPost(authorization, dataTypesAnalyticsRuleSyncRequest, options).then((request) => request(axios, basePath));
|
|
5774
|
+
},
|
|
5775
|
+
/**
|
|
5776
|
+
* Retrieve a paginated list of analytics rules with optional filtering by store, collection, and active status. Supports both page-based and offset-based pagination.
|
|
5777
|
+
* @summary List Analytics Rules
|
|
5778
|
+
* @param {string} authorization Bearer JWT token
|
|
5779
|
+
* @param {string} xstoreid Store ID (for store-specific routes)
|
|
5780
|
+
* @param {number} [storeId] Filter by store ID (for general routes)
|
|
5781
|
+
* @param {string} [collectionName] Filter by collection name
|
|
5782
|
+
* @param {boolean} [isActive] Filter by active status
|
|
5783
|
+
* @param {number} [page] Page number (1-based, alternative to limit/offset)
|
|
5784
|
+
* @param {number} [pageSize] Number of results per page (alternative to limit)
|
|
5785
|
+
* @param {number} [limit] Maximum number of results (default: 50)
|
|
5786
|
+
* @param {number} [offset] Offset for pagination (default: 0)
|
|
5787
|
+
* @param {string} [sortBy] Sort field (name, created_at, modified_at, rule_id)
|
|
5788
|
+
* @param {string} [sortOrder] Sort order (asc, desc, default: desc)
|
|
5789
|
+
* @param {string} [searchQuery] Search in rule names, descriptions, and rule_ids
|
|
5790
|
+
* @param {*} [options] Override http request option.
|
|
5791
|
+
* @throws {RequiredError}
|
|
5792
|
+
*/
|
|
5793
|
+
apiAdminV1StoresXstoreidAnalyticsRulesGet(authorization, xstoreid, storeId, collectionName, isActive, page, pageSize, limit, offset, sortBy, sortOrder, searchQuery, options) {
|
|
5794
|
+
return localVarFp.apiAdminV1StoresXstoreidAnalyticsRulesGet(authorization, xstoreid, storeId, collectionName, isActive, page, pageSize, limit, offset, sortBy, sortOrder, searchQuery, options).then((request) => request(axios, basePath));
|
|
5795
|
+
},
|
|
5796
|
+
/**
|
|
5797
|
+
* Create a new analytics rule for Typesense curation. Rules define how search results should be modified (promoted, hidden, filtered, sorted) based on query conditions.
|
|
5798
|
+
* @summary Create Analytics Rule
|
|
5799
|
+
* @param {string} authorization Bearer JWT token
|
|
5800
|
+
* @param {string} xstoreid Store ID (for store-specific routes)
|
|
5801
|
+
* @param {DataTypesCreateAnalyticsRuleRequest} dataTypesCreateAnalyticsRuleRequest Analytics rule configuration
|
|
5802
|
+
* @param {*} [options] Override http request option.
|
|
5803
|
+
* @throws {RequiredError}
|
|
5804
|
+
*/
|
|
5805
|
+
apiAdminV1StoresXstoreidAnalyticsRulesPost(authorization, xstoreid, dataTypesCreateAnalyticsRuleRequest, options) {
|
|
5806
|
+
return localVarFp.apiAdminV1StoresXstoreidAnalyticsRulesPost(authorization, xstoreid, dataTypesCreateAnalyticsRuleRequest, options).then((request) => request(axios, basePath));
|
|
5807
|
+
},
|
|
5808
|
+
/**
|
|
5809
|
+
* Permanently delete an analytics rule from both the database and Typesense. This operation cannot be undone.
|
|
5810
|
+
* @summary Delete Analytics Rule
|
|
5811
|
+
* @param {string} authorization Bearer JWT token
|
|
5812
|
+
* @param {string} xstoreid Store ID (for store-specific routes)
|
|
5813
|
+
* @param {string} ruleId Rule ID
|
|
5814
|
+
* @param {*} [options] Override http request option.
|
|
5815
|
+
* @throws {RequiredError}
|
|
5816
|
+
*/
|
|
5817
|
+
apiAdminV1StoresXstoreidAnalyticsRulesRuleIdDelete(authorization, xstoreid, ruleId, options) {
|
|
5818
|
+
return localVarFp.apiAdminV1StoresXstoreidAnalyticsRulesRuleIdDelete(authorization, xstoreid, ruleId, options).then((request) => request(axios, basePath));
|
|
5819
|
+
},
|
|
5820
|
+
/**
|
|
5821
|
+
* Retrieve a specific analytics rule by its ID. Returns the complete rule configuration including Typesense override actions.
|
|
5822
|
+
* @summary Get Analytics Rule
|
|
5823
|
+
* @param {string} authorization Bearer JWT token
|
|
5824
|
+
* @param {string} xstoreid Store ID (for store-specific routes)
|
|
5825
|
+
* @param {string} ruleId Rule ID
|
|
5826
|
+
* @param {*} [options] Override http request option.
|
|
5827
|
+
* @throws {RequiredError}
|
|
5828
|
+
*/
|
|
5829
|
+
apiAdminV1StoresXstoreidAnalyticsRulesRuleIdGet(authorization, xstoreid, ruleId, options) {
|
|
5830
|
+
return localVarFp.apiAdminV1StoresXstoreidAnalyticsRulesRuleIdGet(authorization, xstoreid, ruleId, options).then((request) => request(axios, basePath));
|
|
5831
|
+
},
|
|
5832
|
+
/**
|
|
5833
|
+
* Update an existing analytics rule. Supports partial updates. When is_active is set to false, the rule is removed from Typesense. When is_active is set to true, the rule is synced to Typesense.
|
|
5834
|
+
* @summary Update Analytics Rule
|
|
5835
|
+
* @param {string} authorization Bearer JWT token
|
|
5836
|
+
* @param {string} xstoreid Store ID (for store-specific routes)
|
|
5837
|
+
* @param {string} ruleId Rule ID
|
|
5838
|
+
* @param {DataTypesUpdateAnalyticsRuleRequest} dataTypesUpdateAnalyticsRuleRequest Updated rule configuration (partial update supported)
|
|
5839
|
+
* @param {*} [options] Override http request option.
|
|
5840
|
+
* @throws {RequiredError}
|
|
5841
|
+
*/
|
|
5842
|
+
apiAdminV1StoresXstoreidAnalyticsRulesRuleIdPut(authorization, xstoreid, ruleId, dataTypesUpdateAnalyticsRuleRequest, options) {
|
|
5843
|
+
return localVarFp.apiAdminV1StoresXstoreidAnalyticsRulesRuleIdPut(authorization, xstoreid, ruleId, dataTypesUpdateAnalyticsRuleRequest, options).then((request) => request(axios, basePath));
|
|
5844
|
+
},
|
|
5845
|
+
/**
|
|
5846
|
+
* Manually synchronize analytics rules to Typesense. This endpoint can be used to force a sync of all active rules or specific rules to Typesense collections.
|
|
5847
|
+
* @summary Sync Rules to Typesense
|
|
5848
|
+
* @param {string} authorization Bearer JWT token
|
|
5849
|
+
* @param {string} xstoreid Store ID (for store-specific routes)
|
|
5850
|
+
* @param {DataTypesAnalyticsRuleSyncRequest} dataTypesAnalyticsRuleSyncRequest Sync configuration (optional filters)
|
|
5851
|
+
* @param {*} [options] Override http request option.
|
|
5852
|
+
* @throws {RequiredError}
|
|
5853
|
+
*/
|
|
5854
|
+
apiAdminV1StoresXstoreidAnalyticsRulesSyncPost(authorization, xstoreid, dataTypesAnalyticsRuleSyncRequest, options) {
|
|
5855
|
+
return localVarFp.apiAdminV1StoresXstoreidAnalyticsRulesSyncPost(authorization, xstoreid, dataTypesAnalyticsRuleSyncRequest, options).then((request) => request(axios, basePath));
|
|
5856
|
+
},
|
|
5857
|
+
};
|
|
5858
|
+
};
|
|
5859
|
+
/**
|
|
5860
|
+
* AnalyticsRulesApi - object-oriented interface
|
|
5861
|
+
* @export
|
|
5862
|
+
* @class AnalyticsRulesApi
|
|
5863
|
+
* @extends {BaseAPI}
|
|
5864
|
+
*/
|
|
5865
|
+
export class AnalyticsRulesApi extends BaseAPI {
|
|
5866
|
+
/**
|
|
5867
|
+
* Retrieve a paginated list of analytics rules with optional filtering by store, collection, and active status. Supports both page-based and offset-based pagination.
|
|
5868
|
+
* @summary List Analytics Rules
|
|
5869
|
+
* @param {string} authorization Bearer JWT token
|
|
5870
|
+
* @param {number} [storeId] Filter by store ID (for general routes)
|
|
5871
|
+
* @param {string} [collectionName] Filter by collection name
|
|
5872
|
+
* @param {boolean} [isActive] Filter by active status
|
|
5873
|
+
* @param {number} [page] Page number (1-based, alternative to limit/offset)
|
|
5874
|
+
* @param {number} [pageSize] Number of results per page (alternative to limit)
|
|
5875
|
+
* @param {number} [limit] Maximum number of results (default: 50)
|
|
5876
|
+
* @param {number} [offset] Offset for pagination (default: 0)
|
|
5877
|
+
* @param {string} [sortBy] Sort field (name, created_at, modified_at, rule_id)
|
|
5878
|
+
* @param {string} [sortOrder] Sort order (asc, desc, default: desc)
|
|
5879
|
+
* @param {string} [searchQuery] Search in rule names, descriptions, and rule_ids
|
|
5880
|
+
* @param {*} [options] Override http request option.
|
|
5881
|
+
* @throws {RequiredError}
|
|
5882
|
+
* @memberof AnalyticsRulesApi
|
|
5883
|
+
*/
|
|
5884
|
+
apiAdminV1AnalyticsRulesGet(authorization, storeId, collectionName, isActive, page, pageSize, limit, offset, sortBy, sortOrder, searchQuery, options) {
|
|
5885
|
+
return AnalyticsRulesApiFp(this.configuration).apiAdminV1AnalyticsRulesGet(authorization, storeId, collectionName, isActive, page, pageSize, limit, offset, sortBy, sortOrder, searchQuery, options).then((request) => request(this.axios, this.basePath));
|
|
5886
|
+
}
|
|
5887
|
+
/**
|
|
5888
|
+
* Create a new analytics rule for Typesense curation. Rules define how search results should be modified (promoted, hidden, filtered, sorted) based on query conditions.
|
|
5889
|
+
* @summary Create Analytics Rule
|
|
5890
|
+
* @param {string} authorization Bearer JWT token
|
|
5891
|
+
* @param {DataTypesCreateAnalyticsRuleRequest} dataTypesCreateAnalyticsRuleRequest Analytics rule configuration
|
|
5892
|
+
* @param {*} [options] Override http request option.
|
|
5893
|
+
* @throws {RequiredError}
|
|
5894
|
+
* @memberof AnalyticsRulesApi
|
|
5895
|
+
*/
|
|
5896
|
+
apiAdminV1AnalyticsRulesPost(authorization, dataTypesCreateAnalyticsRuleRequest, options) {
|
|
5897
|
+
return AnalyticsRulesApiFp(this.configuration).apiAdminV1AnalyticsRulesPost(authorization, dataTypesCreateAnalyticsRuleRequest, options).then((request) => request(this.axios, this.basePath));
|
|
5898
|
+
}
|
|
5899
|
+
/**
|
|
5900
|
+
* Permanently delete an analytics rule from both the database and Typesense. This operation cannot be undone.
|
|
5901
|
+
* @summary Delete Analytics Rule
|
|
5902
|
+
* @param {string} authorization Bearer JWT token
|
|
5903
|
+
* @param {string} ruleId Rule ID
|
|
5904
|
+
* @param {*} [options] Override http request option.
|
|
5905
|
+
* @throws {RequiredError}
|
|
5906
|
+
* @memberof AnalyticsRulesApi
|
|
5907
|
+
*/
|
|
5908
|
+
apiAdminV1AnalyticsRulesRuleIdDelete(authorization, ruleId, options) {
|
|
5909
|
+
return AnalyticsRulesApiFp(this.configuration).apiAdminV1AnalyticsRulesRuleIdDelete(authorization, ruleId, options).then((request) => request(this.axios, this.basePath));
|
|
5910
|
+
}
|
|
5911
|
+
/**
|
|
5912
|
+
* Retrieve a specific analytics rule by its ID. Returns the complete rule configuration including Typesense override actions.
|
|
5913
|
+
* @summary Get Analytics Rule
|
|
5914
|
+
* @param {string} authorization Bearer JWT token
|
|
5915
|
+
* @param {string} ruleId Rule ID
|
|
5916
|
+
* @param {*} [options] Override http request option.
|
|
5917
|
+
* @throws {RequiredError}
|
|
5918
|
+
* @memberof AnalyticsRulesApi
|
|
5919
|
+
*/
|
|
5920
|
+
apiAdminV1AnalyticsRulesRuleIdGet(authorization, ruleId, options) {
|
|
5921
|
+
return AnalyticsRulesApiFp(this.configuration).apiAdminV1AnalyticsRulesRuleIdGet(authorization, ruleId, options).then((request) => request(this.axios, this.basePath));
|
|
5922
|
+
}
|
|
5923
|
+
/**
|
|
5924
|
+
* Update an existing analytics rule. Supports partial updates. When is_active is set to false, the rule is removed from Typesense. When is_active is set to true, the rule is synced to Typesense.
|
|
5925
|
+
* @summary Update Analytics Rule
|
|
5926
|
+
* @param {string} authorization Bearer JWT token
|
|
5927
|
+
* @param {string} ruleId Rule ID
|
|
5928
|
+
* @param {DataTypesUpdateAnalyticsRuleRequest} dataTypesUpdateAnalyticsRuleRequest Updated rule configuration (partial update supported)
|
|
5929
|
+
* @param {*} [options] Override http request option.
|
|
5930
|
+
* @throws {RequiredError}
|
|
5931
|
+
* @memberof AnalyticsRulesApi
|
|
5932
|
+
*/
|
|
5933
|
+
apiAdminV1AnalyticsRulesRuleIdPut(authorization, ruleId, dataTypesUpdateAnalyticsRuleRequest, options) {
|
|
5934
|
+
return AnalyticsRulesApiFp(this.configuration).apiAdminV1AnalyticsRulesRuleIdPut(authorization, ruleId, dataTypesUpdateAnalyticsRuleRequest, options).then((request) => request(this.axios, this.basePath));
|
|
5935
|
+
}
|
|
5936
|
+
/**
|
|
5937
|
+
* Manually synchronize analytics rules to Typesense. This endpoint can be used to force a sync of all active rules or specific rules to Typesense collections.
|
|
5938
|
+
* @summary Sync Rules to Typesense
|
|
5939
|
+
* @param {string} authorization Bearer JWT token
|
|
5940
|
+
* @param {DataTypesAnalyticsRuleSyncRequest} dataTypesAnalyticsRuleSyncRequest Sync configuration (optional filters)
|
|
5941
|
+
* @param {*} [options] Override http request option.
|
|
5942
|
+
* @throws {RequiredError}
|
|
5943
|
+
* @memberof AnalyticsRulesApi
|
|
5944
|
+
*/
|
|
5945
|
+
apiAdminV1AnalyticsRulesSyncPost(authorization, dataTypesAnalyticsRuleSyncRequest, options) {
|
|
5946
|
+
return AnalyticsRulesApiFp(this.configuration).apiAdminV1AnalyticsRulesSyncPost(authorization, dataTypesAnalyticsRuleSyncRequest, options).then((request) => request(this.axios, this.basePath));
|
|
5947
|
+
}
|
|
5948
|
+
/**
|
|
5949
|
+
* Retrieve a paginated list of analytics rules with optional filtering by store, collection, and active status. Supports both page-based and offset-based pagination.
|
|
5950
|
+
* @summary List Analytics Rules
|
|
5951
|
+
* @param {string} authorization Bearer JWT token
|
|
5952
|
+
* @param {string} xstoreid Store ID (for store-specific routes)
|
|
5953
|
+
* @param {number} [storeId] Filter by store ID (for general routes)
|
|
5954
|
+
* @param {string} [collectionName] Filter by collection name
|
|
5955
|
+
* @param {boolean} [isActive] Filter by active status
|
|
5956
|
+
* @param {number} [page] Page number (1-based, alternative to limit/offset)
|
|
5957
|
+
* @param {number} [pageSize] Number of results per page (alternative to limit)
|
|
5958
|
+
* @param {number} [limit] Maximum number of results (default: 50)
|
|
5959
|
+
* @param {number} [offset] Offset for pagination (default: 0)
|
|
5960
|
+
* @param {string} [sortBy] Sort field (name, created_at, modified_at, rule_id)
|
|
5961
|
+
* @param {string} [sortOrder] Sort order (asc, desc, default: desc)
|
|
5962
|
+
* @param {string} [searchQuery] Search in rule names, descriptions, and rule_ids
|
|
5963
|
+
* @param {*} [options] Override http request option.
|
|
5964
|
+
* @throws {RequiredError}
|
|
5965
|
+
* @memberof AnalyticsRulesApi
|
|
5966
|
+
*/
|
|
5967
|
+
apiAdminV1StoresXstoreidAnalyticsRulesGet(authorization, xstoreid, storeId, collectionName, isActive, page, pageSize, limit, offset, sortBy, sortOrder, searchQuery, options) {
|
|
5968
|
+
return AnalyticsRulesApiFp(this.configuration).apiAdminV1StoresXstoreidAnalyticsRulesGet(authorization, xstoreid, storeId, collectionName, isActive, page, pageSize, limit, offset, sortBy, sortOrder, searchQuery, options).then((request) => request(this.axios, this.basePath));
|
|
5969
|
+
}
|
|
5970
|
+
/**
|
|
5971
|
+
* Create a new analytics rule for Typesense curation. Rules define how search results should be modified (promoted, hidden, filtered, sorted) based on query conditions.
|
|
5972
|
+
* @summary Create Analytics Rule
|
|
5973
|
+
* @param {string} authorization Bearer JWT token
|
|
5974
|
+
* @param {string} xstoreid Store ID (for store-specific routes)
|
|
5975
|
+
* @param {DataTypesCreateAnalyticsRuleRequest} dataTypesCreateAnalyticsRuleRequest Analytics rule configuration
|
|
5976
|
+
* @param {*} [options] Override http request option.
|
|
5977
|
+
* @throws {RequiredError}
|
|
5978
|
+
* @memberof AnalyticsRulesApi
|
|
5979
|
+
*/
|
|
5980
|
+
apiAdminV1StoresXstoreidAnalyticsRulesPost(authorization, xstoreid, dataTypesCreateAnalyticsRuleRequest, options) {
|
|
5981
|
+
return AnalyticsRulesApiFp(this.configuration).apiAdminV1StoresXstoreidAnalyticsRulesPost(authorization, xstoreid, dataTypesCreateAnalyticsRuleRequest, options).then((request) => request(this.axios, this.basePath));
|
|
5982
|
+
}
|
|
5983
|
+
/**
|
|
5984
|
+
* Permanently delete an analytics rule from both the database and Typesense. This operation cannot be undone.
|
|
5985
|
+
* @summary Delete Analytics Rule
|
|
5986
|
+
* @param {string} authorization Bearer JWT token
|
|
5987
|
+
* @param {string} xstoreid Store ID (for store-specific routes)
|
|
5988
|
+
* @param {string} ruleId Rule ID
|
|
5989
|
+
* @param {*} [options] Override http request option.
|
|
5990
|
+
* @throws {RequiredError}
|
|
5991
|
+
* @memberof AnalyticsRulesApi
|
|
5992
|
+
*/
|
|
5993
|
+
apiAdminV1StoresXstoreidAnalyticsRulesRuleIdDelete(authorization, xstoreid, ruleId, options) {
|
|
5994
|
+
return AnalyticsRulesApiFp(this.configuration).apiAdminV1StoresXstoreidAnalyticsRulesRuleIdDelete(authorization, xstoreid, ruleId, options).then((request) => request(this.axios, this.basePath));
|
|
5995
|
+
}
|
|
5996
|
+
/**
|
|
5997
|
+
* Retrieve a specific analytics rule by its ID. Returns the complete rule configuration including Typesense override actions.
|
|
5998
|
+
* @summary Get Analytics Rule
|
|
5999
|
+
* @param {string} authorization Bearer JWT token
|
|
6000
|
+
* @param {string} xstoreid Store ID (for store-specific routes)
|
|
6001
|
+
* @param {string} ruleId Rule ID
|
|
6002
|
+
* @param {*} [options] Override http request option.
|
|
6003
|
+
* @throws {RequiredError}
|
|
6004
|
+
* @memberof AnalyticsRulesApi
|
|
6005
|
+
*/
|
|
6006
|
+
apiAdminV1StoresXstoreidAnalyticsRulesRuleIdGet(authorization, xstoreid, ruleId, options) {
|
|
6007
|
+
return AnalyticsRulesApiFp(this.configuration).apiAdminV1StoresXstoreidAnalyticsRulesRuleIdGet(authorization, xstoreid, ruleId, options).then((request) => request(this.axios, this.basePath));
|
|
6008
|
+
}
|
|
6009
|
+
/**
|
|
6010
|
+
* Update an existing analytics rule. Supports partial updates. When is_active is set to false, the rule is removed from Typesense. When is_active is set to true, the rule is synced to Typesense.
|
|
6011
|
+
* @summary Update Analytics Rule
|
|
6012
|
+
* @param {string} authorization Bearer JWT token
|
|
6013
|
+
* @param {string} xstoreid Store ID (for store-specific routes)
|
|
6014
|
+
* @param {string} ruleId Rule ID
|
|
6015
|
+
* @param {DataTypesUpdateAnalyticsRuleRequest} dataTypesUpdateAnalyticsRuleRequest Updated rule configuration (partial update supported)
|
|
6016
|
+
* @param {*} [options] Override http request option.
|
|
6017
|
+
* @throws {RequiredError}
|
|
6018
|
+
* @memberof AnalyticsRulesApi
|
|
6019
|
+
*/
|
|
6020
|
+
apiAdminV1StoresXstoreidAnalyticsRulesRuleIdPut(authorization, xstoreid, ruleId, dataTypesUpdateAnalyticsRuleRequest, options) {
|
|
6021
|
+
return AnalyticsRulesApiFp(this.configuration).apiAdminV1StoresXstoreidAnalyticsRulesRuleIdPut(authorization, xstoreid, ruleId, dataTypesUpdateAnalyticsRuleRequest, options).then((request) => request(this.axios, this.basePath));
|
|
6022
|
+
}
|
|
6023
|
+
/**
|
|
6024
|
+
* Manually synchronize analytics rules to Typesense. This endpoint can be used to force a sync of all active rules or specific rules to Typesense collections.
|
|
6025
|
+
* @summary Sync Rules to Typesense
|
|
6026
|
+
* @param {string} authorization Bearer JWT token
|
|
6027
|
+
* @param {string} xstoreid Store ID (for store-specific routes)
|
|
6028
|
+
* @param {DataTypesAnalyticsRuleSyncRequest} dataTypesAnalyticsRuleSyncRequest Sync configuration (optional filters)
|
|
6029
|
+
* @param {*} [options] Override http request option.
|
|
6030
|
+
* @throws {RequiredError}
|
|
6031
|
+
* @memberof AnalyticsRulesApi
|
|
6032
|
+
*/
|
|
6033
|
+
apiAdminV1StoresXstoreidAnalyticsRulesSyncPost(authorization, xstoreid, dataTypesAnalyticsRuleSyncRequest, options) {
|
|
6034
|
+
return AnalyticsRulesApiFp(this.configuration).apiAdminV1StoresXstoreidAnalyticsRulesSyncPost(authorization, xstoreid, dataTypesAnalyticsRuleSyncRequest, options).then((request) => request(this.axios, this.basePath));
|
|
6035
|
+
}
|
|
6036
|
+
}
|
|
6037
|
+
/**
|
|
6038
|
+
* ArticlesApi - axios parameter creator
|
|
6039
|
+
* @export
|
|
6040
|
+
*/
|
|
6041
|
+
export const ArticlesApiAxiosParamCreator = function (configuration) {
|
|
6042
|
+
return {
|
|
6043
|
+
/**
|
|
6044
|
+
* Delete an article by its ID.
|
|
6045
|
+
* @summary Delete an existing Article
|
|
6046
|
+
* @param {string} articleID Article ID
|
|
6047
|
+
* @param {*} [options] Override http request option.
|
|
6048
|
+
* @throws {RequiredError}
|
|
6049
|
+
*/
|
|
6050
|
+
adminArticlesArticleIDDelete: (articleID_1, ...args_1) => __awaiter(this, [articleID_1, ...args_1], void 0, function* (articleID, options = {}) {
|
|
6051
|
+
// verify required parameter 'articleID' is not null or undefined
|
|
6052
|
+
assertParamExists('adminArticlesArticleIDDelete', 'articleID', articleID);
|
|
6053
|
+
const localVarPath = `/admin/Articles/{articleID}`
|
|
6054
|
+
.replace(`{${"articleID"}}`, encodeURIComponent(String(articleID)));
|
|
6055
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
6056
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
6057
|
+
let baseOptions;
|
|
6058
|
+
if (configuration) {
|
|
6059
|
+
baseOptions = configuration.baseOptions;
|
|
6060
|
+
}
|
|
6061
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'DELETE' }, baseOptions), options);
|
|
6062
|
+
const localVarHeaderParameter = {};
|
|
6063
|
+
const localVarQueryParameter = {};
|
|
6064
|
+
// authentication BearerAuth required
|
|
6065
|
+
yield setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration);
|
|
6066
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
6067
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
6068
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
6069
|
+
return {
|
|
6070
|
+
url: toPathString(localVarUrlObj),
|
|
6071
|
+
options: localVarRequestOptions,
|
|
6072
|
+
};
|
|
6073
|
+
}),
|
|
6074
|
+
/**
|
|
6075
|
+
* Fetches article by id
|
|
6076
|
+
* @summary Fetches article by id
|
|
6077
|
+
* @param {number} articleID Article ID
|
|
6078
|
+
* @param {*} [options] Override http request option.
|
|
6079
|
+
* @throws {RequiredError}
|
|
6080
|
+
*/
|
|
6081
|
+
adminArticlesArticleIDGet: (articleID_1, ...args_1) => __awaiter(this, [articleID_1, ...args_1], void 0, function* (articleID, options = {}) {
|
|
6082
|
+
// verify required parameter 'articleID' is not null or undefined
|
|
6083
|
+
assertParamExists('adminArticlesArticleIDGet', 'articleID', articleID);
|
|
6084
|
+
const localVarPath = `/admin/Articles/{articleID}`
|
|
6085
|
+
.replace(`{${"articleID"}}`, encodeURIComponent(String(articleID)));
|
|
6086
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
6087
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
6088
|
+
let baseOptions;
|
|
6089
|
+
if (configuration) {
|
|
6090
|
+
baseOptions = configuration.baseOptions;
|
|
6091
|
+
}
|
|
6092
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
|
|
6093
|
+
const localVarHeaderParameter = {};
|
|
6094
|
+
const localVarQueryParameter = {};
|
|
6095
|
+
// authentication BearerAuth required
|
|
6096
|
+
yield setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration);
|
|
6097
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
6098
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
6099
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
6100
|
+
return {
|
|
6101
|
+
url: toPathString(localVarUrlObj),
|
|
6102
|
+
options: localVarRequestOptions,
|
|
6103
|
+
};
|
|
6104
|
+
}),
|
|
6105
|
+
/**
|
|
6106
|
+
* Update article information by ID.
|
|
6107
|
+
* @summary Update an existing Article
|
|
6108
|
+
* @param {number} articleID Article ID
|
|
6109
|
+
* @param {MgDocumentTypesCreateArticleRequestDto} mgDocumentTypesCreateArticleRequestDto Article data to update
|
|
6110
|
+
* @param {*} [options] Override http request option.
|
|
6111
|
+
* @throws {RequiredError}
|
|
6112
|
+
*/
|
|
6113
|
+
adminArticlesArticleIDPut: (articleID_1, mgDocumentTypesCreateArticleRequestDto_1, ...args_1) => __awaiter(this, [articleID_1, mgDocumentTypesCreateArticleRequestDto_1, ...args_1], void 0, function* (articleID, mgDocumentTypesCreateArticleRequestDto, options = {}) {
|
|
6114
|
+
// verify required parameter 'articleID' is not null or undefined
|
|
6115
|
+
assertParamExists('adminArticlesArticleIDPut', 'articleID', articleID);
|
|
6116
|
+
// verify required parameter 'mgDocumentTypesCreateArticleRequestDto' is not null or undefined
|
|
6117
|
+
assertParamExists('adminArticlesArticleIDPut', 'mgDocumentTypesCreateArticleRequestDto', mgDocumentTypesCreateArticleRequestDto);
|
|
6118
|
+
const localVarPath = `/admin/Articles/{articleID}`
|
|
6119
|
+
.replace(`{${"articleID"}}`, encodeURIComponent(String(articleID)));
|
|
6120
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
6121
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
6122
|
+
let baseOptions;
|
|
6123
|
+
if (configuration) {
|
|
6124
|
+
baseOptions = configuration.baseOptions;
|
|
6125
|
+
}
|
|
6126
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'PUT' }, baseOptions), options);
|
|
6127
|
+
const localVarHeaderParameter = {};
|
|
6128
|
+
const localVarQueryParameter = {};
|
|
6129
|
+
// authentication BearerAuth required
|
|
6130
|
+
yield setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration);
|
|
6131
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
6132
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
6133
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
6134
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
6135
|
+
localVarRequestOptions.data = serializeDataIfNeeded(mgDocumentTypesCreateArticleRequestDto, localVarRequestOptions, configuration);
|
|
6136
|
+
return {
|
|
6137
|
+
url: toPathString(localVarUrlObj),
|
|
6138
|
+
options: localVarRequestOptions,
|
|
6139
|
+
};
|
|
6140
|
+
}),
|
|
6141
|
+
/**
|
|
6142
|
+
* Fetches list of all Articles
|
|
6143
|
+
* @summary Fetches list of all Articles
|
|
6144
|
+
* @param {*} [options] Override http request option.
|
|
6145
|
+
* @throws {RequiredError}
|
|
6146
|
+
*/
|
|
6147
|
+
adminArticlesGet: (...args_1) => __awaiter(this, [...args_1], void 0, function* (options = {}) {
|
|
6148
|
+
const localVarPath = `/admin/Articles`;
|
|
6149
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
6150
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
6151
|
+
let baseOptions;
|
|
6152
|
+
if (configuration) {
|
|
6153
|
+
baseOptions = configuration.baseOptions;
|
|
6154
|
+
}
|
|
6155
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
|
|
6156
|
+
const localVarHeaderParameter = {};
|
|
6157
|
+
const localVarQueryParameter = {};
|
|
6158
|
+
// authentication BearerAuth required
|
|
6159
|
+
yield setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration);
|
|
6160
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
6161
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
6162
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
6163
|
+
return {
|
|
6164
|
+
url: toPathString(localVarUrlObj),
|
|
6165
|
+
options: localVarRequestOptions,
|
|
6166
|
+
};
|
|
6167
|
+
}),
|
|
6168
|
+
/**
|
|
6169
|
+
* Adds a new article to the system
|
|
6170
|
+
* @summary Creates a new article
|
|
6171
|
+
* @param {MgDocumentTypesCreateArticleRequestDto} mgDocumentTypesCreateArticleRequestDto data
|
|
6172
|
+
* @param {*} [options] Override http request option.
|
|
6173
|
+
* @throws {RequiredError}
|
|
6174
|
+
*/
|
|
6175
|
+
adminArticlesPost: (mgDocumentTypesCreateArticleRequestDto_1, ...args_1) => __awaiter(this, [mgDocumentTypesCreateArticleRequestDto_1, ...args_1], void 0, function* (mgDocumentTypesCreateArticleRequestDto, options = {}) {
|
|
6176
|
+
// verify required parameter 'mgDocumentTypesCreateArticleRequestDto' is not null or undefined
|
|
6177
|
+
assertParamExists('adminArticlesPost', 'mgDocumentTypesCreateArticleRequestDto', mgDocumentTypesCreateArticleRequestDto);
|
|
6178
|
+
const localVarPath = `/admin/Articles`;
|
|
6179
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
6180
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
6181
|
+
let baseOptions;
|
|
6182
|
+
if (configuration) {
|
|
6183
|
+
baseOptions = configuration.baseOptions;
|
|
6184
|
+
}
|
|
6185
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
|
|
6186
|
+
const localVarHeaderParameter = {};
|
|
6187
|
+
const localVarQueryParameter = {};
|
|
6188
|
+
// authentication BearerAuth required
|
|
6189
|
+
yield setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration);
|
|
6190
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
6191
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
6192
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
6193
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
6194
|
+
localVarRequestOptions.data = serializeDataIfNeeded(mgDocumentTypesCreateArticleRequestDto, localVarRequestOptions, configuration);
|
|
6195
|
+
return {
|
|
6196
|
+
url: toPathString(localVarUrlObj),
|
|
6197
|
+
options: localVarRequestOptions,
|
|
6198
|
+
};
|
|
6199
|
+
}),
|
|
6200
|
+
};
|
|
6201
|
+
};
|
|
6202
|
+
/**
|
|
6203
|
+
* ArticlesApi - functional programming interface
|
|
6204
|
+
* @export
|
|
6205
|
+
*/
|
|
6206
|
+
export const ArticlesApiFp = function (configuration) {
|
|
6207
|
+
const localVarAxiosParamCreator = ArticlesApiAxiosParamCreator(configuration);
|
|
6208
|
+
return {
|
|
6209
|
+
/**
|
|
6210
|
+
* Delete an article by its ID.
|
|
6211
|
+
* @summary Delete an existing Article
|
|
6212
|
+
* @param {string} articleID Article ID
|
|
6213
|
+
* @param {*} [options] Override http request option.
|
|
6214
|
+
* @throws {RequiredError}
|
|
6215
|
+
*/
|
|
6216
|
+
adminArticlesArticleIDDelete(articleID, options) {
|
|
6217
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
6218
|
+
var _a, _b, _c;
|
|
6219
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.adminArticlesArticleIDDelete(articleID, options);
|
|
6220
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
6221
|
+
const localVarOperationServerBasePath = (_c = (_b = operationServerMap['ArticlesApi.adminArticlesArticleIDDelete']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
6222
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
6223
|
+
});
|
|
6224
|
+
},
|
|
6225
|
+
/**
|
|
6226
|
+
* Fetches article by id
|
|
6227
|
+
* @summary Fetches article by id
|
|
6228
|
+
* @param {number} articleID Article ID
|
|
6229
|
+
* @param {*} [options] Override http request option.
|
|
6230
|
+
* @throws {RequiredError}
|
|
6231
|
+
*/
|
|
6232
|
+
adminArticlesArticleIDGet(articleID, options) {
|
|
6233
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
6234
|
+
var _a, _b, _c;
|
|
6235
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.adminArticlesArticleIDGet(articleID, options);
|
|
6236
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
6237
|
+
const localVarOperationServerBasePath = (_c = (_b = operationServerMap['ArticlesApi.adminArticlesArticleIDGet']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
6238
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
6239
|
+
});
|
|
6240
|
+
},
|
|
6241
|
+
/**
|
|
6242
|
+
* Update article information by ID.
|
|
6243
|
+
* @summary Update an existing Article
|
|
6244
|
+
* @param {number} articleID Article ID
|
|
6245
|
+
* @param {MgDocumentTypesCreateArticleRequestDto} mgDocumentTypesCreateArticleRequestDto Article data to update
|
|
6246
|
+
* @param {*} [options] Override http request option.
|
|
6247
|
+
* @throws {RequiredError}
|
|
6248
|
+
*/
|
|
6249
|
+
adminArticlesArticleIDPut(articleID, mgDocumentTypesCreateArticleRequestDto, options) {
|
|
6250
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
6251
|
+
var _a, _b, _c;
|
|
6252
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.adminArticlesArticleIDPut(articleID, mgDocumentTypesCreateArticleRequestDto, options);
|
|
6253
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
6254
|
+
const localVarOperationServerBasePath = (_c = (_b = operationServerMap['ArticlesApi.adminArticlesArticleIDPut']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
6255
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
6256
|
+
});
|
|
6257
|
+
},
|
|
6258
|
+
/**
|
|
6259
|
+
* Fetches list of all Articles
|
|
6260
|
+
* @summary Fetches list of all Articles
|
|
6261
|
+
* @param {*} [options] Override http request option.
|
|
6262
|
+
* @throws {RequiredError}
|
|
6263
|
+
*/
|
|
6264
|
+
adminArticlesGet(options) {
|
|
6265
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
6266
|
+
var _a, _b, _c;
|
|
6267
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.adminArticlesGet(options);
|
|
6268
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
6269
|
+
const localVarOperationServerBasePath = (_c = (_b = operationServerMap['ArticlesApi.adminArticlesGet']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
6270
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
6271
|
+
});
|
|
6272
|
+
},
|
|
6273
|
+
/**
|
|
6274
|
+
* Adds a new article to the system
|
|
6275
|
+
* @summary Creates a new article
|
|
6276
|
+
* @param {MgDocumentTypesCreateArticleRequestDto} mgDocumentTypesCreateArticleRequestDto data
|
|
6277
|
+
* @param {*} [options] Override http request option.
|
|
6278
|
+
* @throws {RequiredError}
|
|
6279
|
+
*/
|
|
6280
|
+
adminArticlesPost(mgDocumentTypesCreateArticleRequestDto, options) {
|
|
6281
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
5145
6282
|
var _a, _b, _c;
|
|
5146
6283
|
const localVarAxiosArgs = yield localVarAxiosParamCreator.adminArticlesPost(mgDocumentTypesCreateArticleRequestDto, options);
|
|
5147
6284
|
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
@@ -5387,111 +6524,283 @@ export const AuthApiFp = function (configuration) {
|
|
|
5387
6524
|
});
|
|
5388
6525
|
},
|
|
5389
6526
|
/**
|
|
5390
|
-
* Logs out the authenticated user
|
|
5391
|
-
* @summary Logout a user
|
|
6527
|
+
* Logs out the authenticated user
|
|
6528
|
+
* @summary Logout a user
|
|
6529
|
+
* @param {*} [options] Override http request option.
|
|
6530
|
+
* @throws {RequiredError}
|
|
6531
|
+
*/
|
|
6532
|
+
authLogoutPost(options) {
|
|
6533
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
6534
|
+
var _a, _b, _c;
|
|
6535
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.authLogoutPost(options);
|
|
6536
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
6537
|
+
const localVarOperationServerBasePath = (_c = (_b = operationServerMap['AuthApi.authLogoutPost']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
6538
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
6539
|
+
});
|
|
6540
|
+
},
|
|
6541
|
+
/**
|
|
6542
|
+
* Returns refreshed session data for authenticated user
|
|
6543
|
+
* @summary Get current auth session
|
|
6544
|
+
* @param {*} [options] Override http request option.
|
|
6545
|
+
* @throws {RequiredError}
|
|
6546
|
+
*/
|
|
6547
|
+
authSessionGet(options) {
|
|
6548
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
6549
|
+
var _a, _b, _c;
|
|
6550
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.authSessionGet(options);
|
|
6551
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
6552
|
+
const localVarOperationServerBasePath = (_c = (_b = operationServerMap['AuthApi.authSessionGet']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
6553
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
6554
|
+
});
|
|
6555
|
+
},
|
|
6556
|
+
};
|
|
6557
|
+
};
|
|
6558
|
+
/**
|
|
6559
|
+
* AuthApi - factory interface
|
|
6560
|
+
* @export
|
|
6561
|
+
*/
|
|
6562
|
+
export const AuthApiFactory = function (configuration, basePath, axios) {
|
|
6563
|
+
const localVarFp = AuthApiFp(configuration);
|
|
6564
|
+
return {
|
|
6565
|
+
/**
|
|
6566
|
+
* Authenticates a user with username and password
|
|
6567
|
+
* @summary Login a user
|
|
6568
|
+
* @param {DataTypesLoginRequest} dataTypesLoginRequest Login credentials
|
|
6569
|
+
* @param {*} [options] Override http request option.
|
|
6570
|
+
* @throws {RequiredError}
|
|
6571
|
+
*/
|
|
6572
|
+
authLoginPost(dataTypesLoginRequest, options) {
|
|
6573
|
+
return localVarFp.authLoginPost(dataTypesLoginRequest, options).then((request) => request(axios, basePath));
|
|
6574
|
+
},
|
|
6575
|
+
/**
|
|
6576
|
+
* Logs out the authenticated user
|
|
6577
|
+
* @summary Logout a user
|
|
6578
|
+
* @param {*} [options] Override http request option.
|
|
6579
|
+
* @throws {RequiredError}
|
|
6580
|
+
*/
|
|
6581
|
+
authLogoutPost(options) {
|
|
6582
|
+
return localVarFp.authLogoutPost(options).then((request) => request(axios, basePath));
|
|
6583
|
+
},
|
|
6584
|
+
/**
|
|
6585
|
+
* Returns refreshed session data for authenticated user
|
|
6586
|
+
* @summary Get current auth session
|
|
6587
|
+
* @param {*} [options] Override http request option.
|
|
6588
|
+
* @throws {RequiredError}
|
|
6589
|
+
*/
|
|
6590
|
+
authSessionGet(options) {
|
|
6591
|
+
return localVarFp.authSessionGet(options).then((request) => request(axios, basePath));
|
|
6592
|
+
},
|
|
6593
|
+
};
|
|
6594
|
+
};
|
|
6595
|
+
/**
|
|
6596
|
+
* AuthApi - object-oriented interface
|
|
6597
|
+
* @export
|
|
6598
|
+
* @class AuthApi
|
|
6599
|
+
* @extends {BaseAPI}
|
|
6600
|
+
*/
|
|
6601
|
+
export class AuthApi extends BaseAPI {
|
|
6602
|
+
/**
|
|
6603
|
+
* Authenticates a user with username and password
|
|
6604
|
+
* @summary Login a user
|
|
6605
|
+
* @param {DataTypesLoginRequest} dataTypesLoginRequest Login credentials
|
|
6606
|
+
* @param {*} [options] Override http request option.
|
|
6607
|
+
* @throws {RequiredError}
|
|
6608
|
+
* @memberof AuthApi
|
|
6609
|
+
*/
|
|
6610
|
+
authLoginPost(dataTypesLoginRequest, options) {
|
|
6611
|
+
return AuthApiFp(this.configuration).authLoginPost(dataTypesLoginRequest, options).then((request) => request(this.axios, this.basePath));
|
|
6612
|
+
}
|
|
6613
|
+
/**
|
|
6614
|
+
* Logs out the authenticated user
|
|
6615
|
+
* @summary Logout a user
|
|
6616
|
+
* @param {*} [options] Override http request option.
|
|
6617
|
+
* @throws {RequiredError}
|
|
6618
|
+
* @memberof AuthApi
|
|
6619
|
+
*/
|
|
6620
|
+
authLogoutPost(options) {
|
|
6621
|
+
return AuthApiFp(this.configuration).authLogoutPost(options).then((request) => request(this.axios, this.basePath));
|
|
6622
|
+
}
|
|
6623
|
+
/**
|
|
6624
|
+
* Returns refreshed session data for authenticated user
|
|
6625
|
+
* @summary Get current auth session
|
|
6626
|
+
* @param {*} [options] Override http request option.
|
|
6627
|
+
* @throws {RequiredError}
|
|
6628
|
+
* @memberof AuthApi
|
|
6629
|
+
*/
|
|
6630
|
+
authSessionGet(options) {
|
|
6631
|
+
return AuthApiFp(this.configuration).authSessionGet(options).then((request) => request(this.axios, this.basePath));
|
|
6632
|
+
}
|
|
6633
|
+
}
|
|
6634
|
+
/**
|
|
6635
|
+
* AutomatedRefundManagementApi - axios parameter creator
|
|
6636
|
+
* @export
|
|
6637
|
+
*/
|
|
6638
|
+
export const AutomatedRefundManagementApiAxiosParamCreator = function (configuration) {
|
|
6639
|
+
return {
|
|
6640
|
+
/**
|
|
6641
|
+
* Shows detailed refund calculation, subscription cancellation, and Razorpay processing details before execution
|
|
6642
|
+
* @summary Preview automated refund
|
|
6643
|
+
* @param {RefundRefundPreviewRequestDto} refundRefundPreviewRequestDto Refund preview request
|
|
6644
|
+
* @param {*} [options] Override http request option.
|
|
6645
|
+
* @throws {RequiredError}
|
|
6646
|
+
*/
|
|
6647
|
+
apiRefundAutomatedPreviewPost: (refundRefundPreviewRequestDto_1, ...args_1) => __awaiter(this, [refundRefundPreviewRequestDto_1, ...args_1], void 0, function* (refundRefundPreviewRequestDto, options = {}) {
|
|
6648
|
+
// verify required parameter 'refundRefundPreviewRequestDto' is not null or undefined
|
|
6649
|
+
assertParamExists('apiRefundAutomatedPreviewPost', 'refundRefundPreviewRequestDto', refundRefundPreviewRequestDto);
|
|
6650
|
+
const localVarPath = `/api/refund/automated/preview`;
|
|
6651
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
6652
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
6653
|
+
let baseOptions;
|
|
6654
|
+
if (configuration) {
|
|
6655
|
+
baseOptions = configuration.baseOptions;
|
|
6656
|
+
}
|
|
6657
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
|
|
6658
|
+
const localVarHeaderParameter = {};
|
|
6659
|
+
const localVarQueryParameter = {};
|
|
6660
|
+
// authentication BearerAuth required
|
|
6661
|
+
yield setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration);
|
|
6662
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
6663
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
6664
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
6665
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
6666
|
+
localVarRequestOptions.data = serializeDataIfNeeded(refundRefundPreviewRequestDto, localVarRequestOptions, configuration);
|
|
6667
|
+
return {
|
|
6668
|
+
url: toPathString(localVarUrlObj),
|
|
6669
|
+
options: localVarRequestOptions,
|
|
6670
|
+
};
|
|
6671
|
+
}),
|
|
6672
|
+
/**
|
|
6673
|
+
* Processes refund automatically with subscription cancellation, Razorpay integration, and credit adjustments
|
|
6674
|
+
* @summary Process automated refund
|
|
6675
|
+
* @param {RefundRefundPreviewRequestDto} refundRefundPreviewRequestDto Automated refund processing request
|
|
6676
|
+
* @param {*} [options] Override http request option.
|
|
6677
|
+
* @throws {RequiredError}
|
|
6678
|
+
*/
|
|
6679
|
+
apiRefundAutomatedProcessPost: (refundRefundPreviewRequestDto_1, ...args_1) => __awaiter(this, [refundRefundPreviewRequestDto_1, ...args_1], void 0, function* (refundRefundPreviewRequestDto, options = {}) {
|
|
6680
|
+
// verify required parameter 'refundRefundPreviewRequestDto' is not null or undefined
|
|
6681
|
+
assertParamExists('apiRefundAutomatedProcessPost', 'refundRefundPreviewRequestDto', refundRefundPreviewRequestDto);
|
|
6682
|
+
const localVarPath = `/api/refund/automated/process`;
|
|
6683
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
6684
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
6685
|
+
let baseOptions;
|
|
6686
|
+
if (configuration) {
|
|
6687
|
+
baseOptions = configuration.baseOptions;
|
|
6688
|
+
}
|
|
6689
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
|
|
6690
|
+
const localVarHeaderParameter = {};
|
|
6691
|
+
const localVarQueryParameter = {};
|
|
6692
|
+
// authentication BearerAuth required
|
|
6693
|
+
yield setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration);
|
|
6694
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
6695
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
6696
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
6697
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
6698
|
+
localVarRequestOptions.data = serializeDataIfNeeded(refundRefundPreviewRequestDto, localVarRequestOptions, configuration);
|
|
6699
|
+
return {
|
|
6700
|
+
url: toPathString(localVarUrlObj),
|
|
6701
|
+
options: localVarRequestOptions,
|
|
6702
|
+
};
|
|
6703
|
+
}),
|
|
6704
|
+
};
|
|
6705
|
+
};
|
|
6706
|
+
/**
|
|
6707
|
+
* AutomatedRefundManagementApi - functional programming interface
|
|
6708
|
+
* @export
|
|
6709
|
+
*/
|
|
6710
|
+
export const AutomatedRefundManagementApiFp = function (configuration) {
|
|
6711
|
+
const localVarAxiosParamCreator = AutomatedRefundManagementApiAxiosParamCreator(configuration);
|
|
6712
|
+
return {
|
|
6713
|
+
/**
|
|
6714
|
+
* Shows detailed refund calculation, subscription cancellation, and Razorpay processing details before execution
|
|
6715
|
+
* @summary Preview automated refund
|
|
6716
|
+
* @param {RefundRefundPreviewRequestDto} refundRefundPreviewRequestDto Refund preview request
|
|
5392
6717
|
* @param {*} [options] Override http request option.
|
|
5393
6718
|
* @throws {RequiredError}
|
|
5394
6719
|
*/
|
|
5395
|
-
|
|
6720
|
+
apiRefundAutomatedPreviewPost(refundRefundPreviewRequestDto, options) {
|
|
5396
6721
|
return __awaiter(this, void 0, void 0, function* () {
|
|
5397
6722
|
var _a, _b, _c;
|
|
5398
|
-
const localVarAxiosArgs = yield localVarAxiosParamCreator.
|
|
6723
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.apiRefundAutomatedPreviewPost(refundRefundPreviewRequestDto, options);
|
|
5399
6724
|
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
5400
|
-
const localVarOperationServerBasePath = (_c = (_b = operationServerMap['
|
|
6725
|
+
const localVarOperationServerBasePath = (_c = (_b = operationServerMap['AutomatedRefundManagementApi.apiRefundAutomatedPreviewPost']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
5401
6726
|
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
5402
6727
|
});
|
|
5403
6728
|
},
|
|
5404
6729
|
/**
|
|
5405
|
-
*
|
|
5406
|
-
* @summary
|
|
6730
|
+
* Processes refund automatically with subscription cancellation, Razorpay integration, and credit adjustments
|
|
6731
|
+
* @summary Process automated refund
|
|
6732
|
+
* @param {RefundRefundPreviewRequestDto} refundRefundPreviewRequestDto Automated refund processing request
|
|
5407
6733
|
* @param {*} [options] Override http request option.
|
|
5408
6734
|
* @throws {RequiredError}
|
|
5409
6735
|
*/
|
|
5410
|
-
|
|
6736
|
+
apiRefundAutomatedProcessPost(refundRefundPreviewRequestDto, options) {
|
|
5411
6737
|
return __awaiter(this, void 0, void 0, function* () {
|
|
5412
6738
|
var _a, _b, _c;
|
|
5413
|
-
const localVarAxiosArgs = yield localVarAxiosParamCreator.
|
|
6739
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.apiRefundAutomatedProcessPost(refundRefundPreviewRequestDto, options);
|
|
5414
6740
|
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
5415
|
-
const localVarOperationServerBasePath = (_c = (_b = operationServerMap['
|
|
6741
|
+
const localVarOperationServerBasePath = (_c = (_b = operationServerMap['AutomatedRefundManagementApi.apiRefundAutomatedProcessPost']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
5416
6742
|
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
5417
6743
|
});
|
|
5418
6744
|
},
|
|
5419
6745
|
};
|
|
5420
6746
|
};
|
|
5421
6747
|
/**
|
|
5422
|
-
*
|
|
6748
|
+
* AutomatedRefundManagementApi - factory interface
|
|
5423
6749
|
* @export
|
|
5424
6750
|
*/
|
|
5425
|
-
export const
|
|
5426
|
-
const localVarFp =
|
|
6751
|
+
export const AutomatedRefundManagementApiFactory = function (configuration, basePath, axios) {
|
|
6752
|
+
const localVarFp = AutomatedRefundManagementApiFp(configuration);
|
|
5427
6753
|
return {
|
|
5428
6754
|
/**
|
|
5429
|
-
*
|
|
5430
|
-
* @summary
|
|
5431
|
-
* @param {
|
|
5432
|
-
* @param {*} [options] Override http request option.
|
|
5433
|
-
* @throws {RequiredError}
|
|
5434
|
-
*/
|
|
5435
|
-
authLoginPost(dataTypesLoginRequest, options) {
|
|
5436
|
-
return localVarFp.authLoginPost(dataTypesLoginRequest, options).then((request) => request(axios, basePath));
|
|
5437
|
-
},
|
|
5438
|
-
/**
|
|
5439
|
-
* Logs out the authenticated user
|
|
5440
|
-
* @summary Logout a user
|
|
6755
|
+
* Shows detailed refund calculation, subscription cancellation, and Razorpay processing details before execution
|
|
6756
|
+
* @summary Preview automated refund
|
|
6757
|
+
* @param {RefundRefundPreviewRequestDto} refundRefundPreviewRequestDto Refund preview request
|
|
5441
6758
|
* @param {*} [options] Override http request option.
|
|
5442
6759
|
* @throws {RequiredError}
|
|
5443
6760
|
*/
|
|
5444
|
-
|
|
5445
|
-
return localVarFp.
|
|
6761
|
+
apiRefundAutomatedPreviewPost(refundRefundPreviewRequestDto, options) {
|
|
6762
|
+
return localVarFp.apiRefundAutomatedPreviewPost(refundRefundPreviewRequestDto, options).then((request) => request(axios, basePath));
|
|
5446
6763
|
},
|
|
5447
6764
|
/**
|
|
5448
|
-
*
|
|
5449
|
-
* @summary
|
|
6765
|
+
* Processes refund automatically with subscription cancellation, Razorpay integration, and credit adjustments
|
|
6766
|
+
* @summary Process automated refund
|
|
6767
|
+
* @param {RefundRefundPreviewRequestDto} refundRefundPreviewRequestDto Automated refund processing request
|
|
5450
6768
|
* @param {*} [options] Override http request option.
|
|
5451
6769
|
* @throws {RequiredError}
|
|
5452
6770
|
*/
|
|
5453
|
-
|
|
5454
|
-
return localVarFp.
|
|
6771
|
+
apiRefundAutomatedProcessPost(refundRefundPreviewRequestDto, options) {
|
|
6772
|
+
return localVarFp.apiRefundAutomatedProcessPost(refundRefundPreviewRequestDto, options).then((request) => request(axios, basePath));
|
|
5455
6773
|
},
|
|
5456
6774
|
};
|
|
5457
6775
|
};
|
|
5458
6776
|
/**
|
|
5459
|
-
*
|
|
6777
|
+
* AutomatedRefundManagementApi - object-oriented interface
|
|
5460
6778
|
* @export
|
|
5461
|
-
* @class
|
|
6779
|
+
* @class AutomatedRefundManagementApi
|
|
5462
6780
|
* @extends {BaseAPI}
|
|
5463
6781
|
*/
|
|
5464
|
-
export class
|
|
5465
|
-
/**
|
|
5466
|
-
* Authenticates a user with username and password
|
|
5467
|
-
* @summary Login a user
|
|
5468
|
-
* @param {DataTypesLoginRequest} dataTypesLoginRequest Login credentials
|
|
5469
|
-
* @param {*} [options] Override http request option.
|
|
5470
|
-
* @throws {RequiredError}
|
|
5471
|
-
* @memberof AuthApi
|
|
5472
|
-
*/
|
|
5473
|
-
authLoginPost(dataTypesLoginRequest, options) {
|
|
5474
|
-
return AuthApiFp(this.configuration).authLoginPost(dataTypesLoginRequest, options).then((request) => request(this.axios, this.basePath));
|
|
5475
|
-
}
|
|
6782
|
+
export class AutomatedRefundManagementApi extends BaseAPI {
|
|
5476
6783
|
/**
|
|
5477
|
-
*
|
|
5478
|
-
* @summary
|
|
6784
|
+
* Shows detailed refund calculation, subscription cancellation, and Razorpay processing details before execution
|
|
6785
|
+
* @summary Preview automated refund
|
|
6786
|
+
* @param {RefundRefundPreviewRequestDto} refundRefundPreviewRequestDto Refund preview request
|
|
5479
6787
|
* @param {*} [options] Override http request option.
|
|
5480
6788
|
* @throws {RequiredError}
|
|
5481
|
-
* @memberof
|
|
6789
|
+
* @memberof AutomatedRefundManagementApi
|
|
5482
6790
|
*/
|
|
5483
|
-
|
|
5484
|
-
return
|
|
6791
|
+
apiRefundAutomatedPreviewPost(refundRefundPreviewRequestDto, options) {
|
|
6792
|
+
return AutomatedRefundManagementApiFp(this.configuration).apiRefundAutomatedPreviewPost(refundRefundPreviewRequestDto, options).then((request) => request(this.axios, this.basePath));
|
|
5485
6793
|
}
|
|
5486
6794
|
/**
|
|
5487
|
-
*
|
|
5488
|
-
* @summary
|
|
6795
|
+
* Processes refund automatically with subscription cancellation, Razorpay integration, and credit adjustments
|
|
6796
|
+
* @summary Process automated refund
|
|
6797
|
+
* @param {RefundRefundPreviewRequestDto} refundRefundPreviewRequestDto Automated refund processing request
|
|
5489
6798
|
* @param {*} [options] Override http request option.
|
|
5490
6799
|
* @throws {RequiredError}
|
|
5491
|
-
* @memberof
|
|
6800
|
+
* @memberof AutomatedRefundManagementApi
|
|
5492
6801
|
*/
|
|
5493
|
-
|
|
5494
|
-
return
|
|
6802
|
+
apiRefundAutomatedProcessPost(refundRefundPreviewRequestDto, options) {
|
|
6803
|
+
return AutomatedRefundManagementApiFp(this.configuration).apiRefundAutomatedProcessPost(refundRefundPreviewRequestDto, options).then((request) => request(this.axios, this.basePath));
|
|
5495
6804
|
}
|
|
5496
6805
|
}
|
|
5497
6806
|
/**
|
|
@@ -18619,6 +19928,156 @@ export class QuerySuggestionsManagementApi extends BaseAPI {
|
|
|
18619
19928
|
*/
|
|
18620
19929
|
export const RefundManagementApiAxiosParamCreator = function (configuration) {
|
|
18621
19930
|
return {
|
|
19931
|
+
/**
|
|
19932
|
+
* Calculates refund amount based on remaining credits and original credit pricing
|
|
19933
|
+
* @summary Calculate refund amount
|
|
19934
|
+
* @param {DataTypesRefundCalculationRequestDto} dataTypesRefundCalculationRequestDto Refund calculation request
|
|
19935
|
+
* @param {*} [options] Override http request option.
|
|
19936
|
+
* @throws {RequiredError}
|
|
19937
|
+
*/
|
|
19938
|
+
apiRefundCalculatePost: (dataTypesRefundCalculationRequestDto_1, ...args_1) => __awaiter(this, [dataTypesRefundCalculationRequestDto_1, ...args_1], void 0, function* (dataTypesRefundCalculationRequestDto, options = {}) {
|
|
19939
|
+
// verify required parameter 'dataTypesRefundCalculationRequestDto' is not null or undefined
|
|
19940
|
+
assertParamExists('apiRefundCalculatePost', 'dataTypesRefundCalculationRequestDto', dataTypesRefundCalculationRequestDto);
|
|
19941
|
+
const localVarPath = `/api/refund/calculate`;
|
|
19942
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
19943
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
19944
|
+
let baseOptions;
|
|
19945
|
+
if (configuration) {
|
|
19946
|
+
baseOptions = configuration.baseOptions;
|
|
19947
|
+
}
|
|
19948
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
|
|
19949
|
+
const localVarHeaderParameter = {};
|
|
19950
|
+
const localVarQueryParameter = {};
|
|
19951
|
+
// authentication BearerAuth required
|
|
19952
|
+
yield setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration);
|
|
19953
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
19954
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
19955
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
19956
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
19957
|
+
localVarRequestOptions.data = serializeDataIfNeeded(dataTypesRefundCalculationRequestDto, localVarRequestOptions, configuration);
|
|
19958
|
+
return {
|
|
19959
|
+
url: toPathString(localVarUrlObj),
|
|
19960
|
+
options: localVarRequestOptions,
|
|
19961
|
+
};
|
|
19962
|
+
}),
|
|
19963
|
+
/**
|
|
19964
|
+
* Checks if a payment is eligible for refund
|
|
19965
|
+
* @summary Check refund eligibility
|
|
19966
|
+
* @param {number} paymentId Payment ID
|
|
19967
|
+
* @param {*} [options] Override http request option.
|
|
19968
|
+
* @throws {RequiredError}
|
|
19969
|
+
*/
|
|
19970
|
+
apiRefundEligibilityPaymentIdGet: (paymentId_1, ...args_1) => __awaiter(this, [paymentId_1, ...args_1], void 0, function* (paymentId, options = {}) {
|
|
19971
|
+
// verify required parameter 'paymentId' is not null or undefined
|
|
19972
|
+
assertParamExists('apiRefundEligibilityPaymentIdGet', 'paymentId', paymentId);
|
|
19973
|
+
const localVarPath = `/api/refund/eligibility/{payment_id}`
|
|
19974
|
+
.replace(`{${"payment_id"}}`, encodeURIComponent(String(paymentId)));
|
|
19975
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
19976
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
19977
|
+
let baseOptions;
|
|
19978
|
+
if (configuration) {
|
|
19979
|
+
baseOptions = configuration.baseOptions;
|
|
19980
|
+
}
|
|
19981
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
|
|
19982
|
+
const localVarHeaderParameter = {};
|
|
19983
|
+
const localVarQueryParameter = {};
|
|
19984
|
+
// authentication BearerAuth required
|
|
19985
|
+
yield setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration);
|
|
19986
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
19987
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
19988
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
19989
|
+
return {
|
|
19990
|
+
url: toPathString(localVarUrlObj),
|
|
19991
|
+
options: localVarRequestOptions,
|
|
19992
|
+
};
|
|
19993
|
+
}),
|
|
19994
|
+
/**
|
|
19995
|
+
* Retrieves refund history for an organization with filtering options
|
|
19996
|
+
* @summary Get refund history
|
|
19997
|
+
* @param {number} [orgId] Organization ID
|
|
19998
|
+
* @param {number} [paymentId] Payment ID
|
|
19999
|
+
* @param {string} [startDate] Start date (RFC3339)
|
|
20000
|
+
* @param {string} [endDate] End date (RFC3339)
|
|
20001
|
+
* @param {string} [status] Refund status
|
|
20002
|
+
* @param {number} [limit] Limit (default 20, max 100)
|
|
20003
|
+
* @param {number} [offset] Offset (default 0)
|
|
20004
|
+
* @param {*} [options] Override http request option.
|
|
20005
|
+
* @throws {RequiredError}
|
|
20006
|
+
*/
|
|
20007
|
+
apiRefundHistoryGet: (orgId_1, paymentId_1, startDate_1, endDate_1, status_1, limit_1, offset_1, ...args_1) => __awaiter(this, [orgId_1, paymentId_1, startDate_1, endDate_1, status_1, limit_1, offset_1, ...args_1], void 0, function* (orgId, paymentId, startDate, endDate, status, limit, offset, options = {}) {
|
|
20008
|
+
const localVarPath = `/api/refund/history`;
|
|
20009
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
20010
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
20011
|
+
let baseOptions;
|
|
20012
|
+
if (configuration) {
|
|
20013
|
+
baseOptions = configuration.baseOptions;
|
|
20014
|
+
}
|
|
20015
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
|
|
20016
|
+
const localVarHeaderParameter = {};
|
|
20017
|
+
const localVarQueryParameter = {};
|
|
20018
|
+
// authentication BearerAuth required
|
|
20019
|
+
yield setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration);
|
|
20020
|
+
if (orgId !== undefined) {
|
|
20021
|
+
localVarQueryParameter['org_id'] = orgId;
|
|
20022
|
+
}
|
|
20023
|
+
if (paymentId !== undefined) {
|
|
20024
|
+
localVarQueryParameter['payment_id'] = paymentId;
|
|
20025
|
+
}
|
|
20026
|
+
if (startDate !== undefined) {
|
|
20027
|
+
localVarQueryParameter['start_date'] = startDate;
|
|
20028
|
+
}
|
|
20029
|
+
if (endDate !== undefined) {
|
|
20030
|
+
localVarQueryParameter['end_date'] = endDate;
|
|
20031
|
+
}
|
|
20032
|
+
if (status !== undefined) {
|
|
20033
|
+
localVarQueryParameter['status'] = status;
|
|
20034
|
+
}
|
|
20035
|
+
if (limit !== undefined) {
|
|
20036
|
+
localVarQueryParameter['limit'] = limit;
|
|
20037
|
+
}
|
|
20038
|
+
if (offset !== undefined) {
|
|
20039
|
+
localVarQueryParameter['offset'] = offset;
|
|
20040
|
+
}
|
|
20041
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
20042
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
20043
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
20044
|
+
return {
|
|
20045
|
+
url: toPathString(localVarUrlObj),
|
|
20046
|
+
options: localVarRequestOptions,
|
|
20047
|
+
};
|
|
20048
|
+
}),
|
|
20049
|
+
/**
|
|
20050
|
+
* Processes a refund request and executes credit adjustments
|
|
20051
|
+
* @summary Process refund
|
|
20052
|
+
* @param {DataTypesProcessRefundRequestDto} dataTypesProcessRefundRequestDto Refund processing request
|
|
20053
|
+
* @param {*} [options] Override http request option.
|
|
20054
|
+
* @throws {RequiredError}
|
|
20055
|
+
*/
|
|
20056
|
+
apiRefundProcessPost: (dataTypesProcessRefundRequestDto_1, ...args_1) => __awaiter(this, [dataTypesProcessRefundRequestDto_1, ...args_1], void 0, function* (dataTypesProcessRefundRequestDto, options = {}) {
|
|
20057
|
+
// verify required parameter 'dataTypesProcessRefundRequestDto' is not null or undefined
|
|
20058
|
+
assertParamExists('apiRefundProcessPost', 'dataTypesProcessRefundRequestDto', dataTypesProcessRefundRequestDto);
|
|
20059
|
+
const localVarPath = `/api/refund/process`;
|
|
20060
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
20061
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
20062
|
+
let baseOptions;
|
|
20063
|
+
if (configuration) {
|
|
20064
|
+
baseOptions = configuration.baseOptions;
|
|
20065
|
+
}
|
|
20066
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
|
|
20067
|
+
const localVarHeaderParameter = {};
|
|
20068
|
+
const localVarQueryParameter = {};
|
|
20069
|
+
// authentication BearerAuth required
|
|
20070
|
+
yield setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration);
|
|
20071
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
20072
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
20073
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
20074
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
20075
|
+
localVarRequestOptions.data = serializeDataIfNeeded(dataTypesProcessRefundRequestDto, localVarRequestOptions, configuration);
|
|
20076
|
+
return {
|
|
20077
|
+
url: toPathString(localVarUrlObj),
|
|
20078
|
+
options: localVarRequestOptions,
|
|
20079
|
+
};
|
|
20080
|
+
}),
|
|
18622
20081
|
/**
|
|
18623
20082
|
* Approves or rejects a pending refund request
|
|
18624
20083
|
* @summary Process refund approval or rejection
|
|
@@ -18817,6 +20276,76 @@ export const RefundManagementApiAxiosParamCreator = function (configuration) {
|
|
|
18817
20276
|
export const RefundManagementApiFp = function (configuration) {
|
|
18818
20277
|
const localVarAxiosParamCreator = RefundManagementApiAxiosParamCreator(configuration);
|
|
18819
20278
|
return {
|
|
20279
|
+
/**
|
|
20280
|
+
* Calculates refund amount based on remaining credits and original credit pricing
|
|
20281
|
+
* @summary Calculate refund amount
|
|
20282
|
+
* @param {DataTypesRefundCalculationRequestDto} dataTypesRefundCalculationRequestDto Refund calculation request
|
|
20283
|
+
* @param {*} [options] Override http request option.
|
|
20284
|
+
* @throws {RequiredError}
|
|
20285
|
+
*/
|
|
20286
|
+
apiRefundCalculatePost(dataTypesRefundCalculationRequestDto, options) {
|
|
20287
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
20288
|
+
var _a, _b, _c;
|
|
20289
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.apiRefundCalculatePost(dataTypesRefundCalculationRequestDto, options);
|
|
20290
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
20291
|
+
const localVarOperationServerBasePath = (_c = (_b = operationServerMap['RefundManagementApi.apiRefundCalculatePost']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
20292
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
20293
|
+
});
|
|
20294
|
+
},
|
|
20295
|
+
/**
|
|
20296
|
+
* Checks if a payment is eligible for refund
|
|
20297
|
+
* @summary Check refund eligibility
|
|
20298
|
+
* @param {number} paymentId Payment ID
|
|
20299
|
+
* @param {*} [options] Override http request option.
|
|
20300
|
+
* @throws {RequiredError}
|
|
20301
|
+
*/
|
|
20302
|
+
apiRefundEligibilityPaymentIdGet(paymentId, options) {
|
|
20303
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
20304
|
+
var _a, _b, _c;
|
|
20305
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.apiRefundEligibilityPaymentIdGet(paymentId, options);
|
|
20306
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
20307
|
+
const localVarOperationServerBasePath = (_c = (_b = operationServerMap['RefundManagementApi.apiRefundEligibilityPaymentIdGet']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
20308
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
20309
|
+
});
|
|
20310
|
+
},
|
|
20311
|
+
/**
|
|
20312
|
+
* Retrieves refund history for an organization with filtering options
|
|
20313
|
+
* @summary Get refund history
|
|
20314
|
+
* @param {number} [orgId] Organization ID
|
|
20315
|
+
* @param {number} [paymentId] Payment ID
|
|
20316
|
+
* @param {string} [startDate] Start date (RFC3339)
|
|
20317
|
+
* @param {string} [endDate] End date (RFC3339)
|
|
20318
|
+
* @param {string} [status] Refund status
|
|
20319
|
+
* @param {number} [limit] Limit (default 20, max 100)
|
|
20320
|
+
* @param {number} [offset] Offset (default 0)
|
|
20321
|
+
* @param {*} [options] Override http request option.
|
|
20322
|
+
* @throws {RequiredError}
|
|
20323
|
+
*/
|
|
20324
|
+
apiRefundHistoryGet(orgId, paymentId, startDate, endDate, status, limit, offset, options) {
|
|
20325
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
20326
|
+
var _a, _b, _c;
|
|
20327
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.apiRefundHistoryGet(orgId, paymentId, startDate, endDate, status, limit, offset, options);
|
|
20328
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
20329
|
+
const localVarOperationServerBasePath = (_c = (_b = operationServerMap['RefundManagementApi.apiRefundHistoryGet']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
20330
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
20331
|
+
});
|
|
20332
|
+
},
|
|
20333
|
+
/**
|
|
20334
|
+
* Processes a refund request and executes credit adjustments
|
|
20335
|
+
* @summary Process refund
|
|
20336
|
+
* @param {DataTypesProcessRefundRequestDto} dataTypesProcessRefundRequestDto Refund processing request
|
|
20337
|
+
* @param {*} [options] Override http request option.
|
|
20338
|
+
* @throws {RequiredError}
|
|
20339
|
+
*/
|
|
20340
|
+
apiRefundProcessPost(dataTypesProcessRefundRequestDto, options) {
|
|
20341
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
20342
|
+
var _a, _b, _c;
|
|
20343
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.apiRefundProcessPost(dataTypesProcessRefundRequestDto, options);
|
|
20344
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
20345
|
+
const localVarOperationServerBasePath = (_c = (_b = operationServerMap['RefundManagementApi.apiRefundProcessPost']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
20346
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
20347
|
+
});
|
|
20348
|
+
},
|
|
18820
20349
|
/**
|
|
18821
20350
|
* Approves or rejects a pending refund request
|
|
18822
20351
|
* @summary Process refund approval or rejection
|
|
@@ -18914,6 +20443,52 @@ export const RefundManagementApiFp = function (configuration) {
|
|
|
18914
20443
|
export const RefundManagementApiFactory = function (configuration, basePath, axios) {
|
|
18915
20444
|
const localVarFp = RefundManagementApiFp(configuration);
|
|
18916
20445
|
return {
|
|
20446
|
+
/**
|
|
20447
|
+
* Calculates refund amount based on remaining credits and original credit pricing
|
|
20448
|
+
* @summary Calculate refund amount
|
|
20449
|
+
* @param {DataTypesRefundCalculationRequestDto} dataTypesRefundCalculationRequestDto Refund calculation request
|
|
20450
|
+
* @param {*} [options] Override http request option.
|
|
20451
|
+
* @throws {RequiredError}
|
|
20452
|
+
*/
|
|
20453
|
+
apiRefundCalculatePost(dataTypesRefundCalculationRequestDto, options) {
|
|
20454
|
+
return localVarFp.apiRefundCalculatePost(dataTypesRefundCalculationRequestDto, options).then((request) => request(axios, basePath));
|
|
20455
|
+
},
|
|
20456
|
+
/**
|
|
20457
|
+
* Checks if a payment is eligible for refund
|
|
20458
|
+
* @summary Check refund eligibility
|
|
20459
|
+
* @param {number} paymentId Payment ID
|
|
20460
|
+
* @param {*} [options] Override http request option.
|
|
20461
|
+
* @throws {RequiredError}
|
|
20462
|
+
*/
|
|
20463
|
+
apiRefundEligibilityPaymentIdGet(paymentId, options) {
|
|
20464
|
+
return localVarFp.apiRefundEligibilityPaymentIdGet(paymentId, options).then((request) => request(axios, basePath));
|
|
20465
|
+
},
|
|
20466
|
+
/**
|
|
20467
|
+
* Retrieves refund history for an organization with filtering options
|
|
20468
|
+
* @summary Get refund history
|
|
20469
|
+
* @param {number} [orgId] Organization ID
|
|
20470
|
+
* @param {number} [paymentId] Payment ID
|
|
20471
|
+
* @param {string} [startDate] Start date (RFC3339)
|
|
20472
|
+
* @param {string} [endDate] End date (RFC3339)
|
|
20473
|
+
* @param {string} [status] Refund status
|
|
20474
|
+
* @param {number} [limit] Limit (default 20, max 100)
|
|
20475
|
+
* @param {number} [offset] Offset (default 0)
|
|
20476
|
+
* @param {*} [options] Override http request option.
|
|
20477
|
+
* @throws {RequiredError}
|
|
20478
|
+
*/
|
|
20479
|
+
apiRefundHistoryGet(orgId, paymentId, startDate, endDate, status, limit, offset, options) {
|
|
20480
|
+
return localVarFp.apiRefundHistoryGet(orgId, paymentId, startDate, endDate, status, limit, offset, options).then((request) => request(axios, basePath));
|
|
20481
|
+
},
|
|
20482
|
+
/**
|
|
20483
|
+
* Processes a refund request and executes credit adjustments
|
|
20484
|
+
* @summary Process refund
|
|
20485
|
+
* @param {DataTypesProcessRefundRequestDto} dataTypesProcessRefundRequestDto Refund processing request
|
|
20486
|
+
* @param {*} [options] Override http request option.
|
|
20487
|
+
* @throws {RequiredError}
|
|
20488
|
+
*/
|
|
20489
|
+
apiRefundProcessPost(dataTypesProcessRefundRequestDto, options) {
|
|
20490
|
+
return localVarFp.apiRefundProcessPost(dataTypesProcessRefundRequestDto, options).then((request) => request(axios, basePath));
|
|
20491
|
+
},
|
|
18917
20492
|
/**
|
|
18918
20493
|
* Approves or rejects a pending refund request
|
|
18919
20494
|
* @summary Process refund approval or rejection
|
|
@@ -18981,6 +20556,56 @@ export const RefundManagementApiFactory = function (configuration, basePath, axi
|
|
|
18981
20556
|
* @extends {BaseAPI}
|
|
18982
20557
|
*/
|
|
18983
20558
|
export class RefundManagementApi extends BaseAPI {
|
|
20559
|
+
/**
|
|
20560
|
+
* Calculates refund amount based on remaining credits and original credit pricing
|
|
20561
|
+
* @summary Calculate refund amount
|
|
20562
|
+
* @param {DataTypesRefundCalculationRequestDto} dataTypesRefundCalculationRequestDto Refund calculation request
|
|
20563
|
+
* @param {*} [options] Override http request option.
|
|
20564
|
+
* @throws {RequiredError}
|
|
20565
|
+
* @memberof RefundManagementApi
|
|
20566
|
+
*/
|
|
20567
|
+
apiRefundCalculatePost(dataTypesRefundCalculationRequestDto, options) {
|
|
20568
|
+
return RefundManagementApiFp(this.configuration).apiRefundCalculatePost(dataTypesRefundCalculationRequestDto, options).then((request) => request(this.axios, this.basePath));
|
|
20569
|
+
}
|
|
20570
|
+
/**
|
|
20571
|
+
* Checks if a payment is eligible for refund
|
|
20572
|
+
* @summary Check refund eligibility
|
|
20573
|
+
* @param {number} paymentId Payment ID
|
|
20574
|
+
* @param {*} [options] Override http request option.
|
|
20575
|
+
* @throws {RequiredError}
|
|
20576
|
+
* @memberof RefundManagementApi
|
|
20577
|
+
*/
|
|
20578
|
+
apiRefundEligibilityPaymentIdGet(paymentId, options) {
|
|
20579
|
+
return RefundManagementApiFp(this.configuration).apiRefundEligibilityPaymentIdGet(paymentId, options).then((request) => request(this.axios, this.basePath));
|
|
20580
|
+
}
|
|
20581
|
+
/**
|
|
20582
|
+
* Retrieves refund history for an organization with filtering options
|
|
20583
|
+
* @summary Get refund history
|
|
20584
|
+
* @param {number} [orgId] Organization ID
|
|
20585
|
+
* @param {number} [paymentId] Payment ID
|
|
20586
|
+
* @param {string} [startDate] Start date (RFC3339)
|
|
20587
|
+
* @param {string} [endDate] End date (RFC3339)
|
|
20588
|
+
* @param {string} [status] Refund status
|
|
20589
|
+
* @param {number} [limit] Limit (default 20, max 100)
|
|
20590
|
+
* @param {number} [offset] Offset (default 0)
|
|
20591
|
+
* @param {*} [options] Override http request option.
|
|
20592
|
+
* @throws {RequiredError}
|
|
20593
|
+
* @memberof RefundManagementApi
|
|
20594
|
+
*/
|
|
20595
|
+
apiRefundHistoryGet(orgId, paymentId, startDate, endDate, status, limit, offset, options) {
|
|
20596
|
+
return RefundManagementApiFp(this.configuration).apiRefundHistoryGet(orgId, paymentId, startDate, endDate, status, limit, offset, options).then((request) => request(this.axios, this.basePath));
|
|
20597
|
+
}
|
|
20598
|
+
/**
|
|
20599
|
+
* Processes a refund request and executes credit adjustments
|
|
20600
|
+
* @summary Process refund
|
|
20601
|
+
* @param {DataTypesProcessRefundRequestDto} dataTypesProcessRefundRequestDto Refund processing request
|
|
20602
|
+
* @param {*} [options] Override http request option.
|
|
20603
|
+
* @throws {RequiredError}
|
|
20604
|
+
* @memberof RefundManagementApi
|
|
20605
|
+
*/
|
|
20606
|
+
apiRefundProcessPost(dataTypesProcessRefundRequestDto, options) {
|
|
20607
|
+
return RefundManagementApiFp(this.configuration).apiRefundProcessPost(dataTypesProcessRefundRequestDto, options).then((request) => request(this.axios, this.basePath));
|
|
20608
|
+
}
|
|
18984
20609
|
/**
|
|
18985
20610
|
* Approves or rejects a pending refund request
|
|
18986
20611
|
* @summary Process refund approval or rejection
|