// tslint:disable
/**
 * Webitel API
 * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
 *
 * The version of the OpenAPI document: 24.04.0
 * Contact: support@webitel.com
 *
 * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
 * https://openapi-generator.tech
 * Do not edit the class manually.
 */
import { __awaiter } from "tslib";
import * as globalImportUrl from 'url';
import globalAxios from 'axios';
// Some imports not used depending on template conditions
// @ts-ignore
import { BASE_PATH, BaseAPI, RequiredError, } from '../base';
/**
 * ConfigServiceApi - axios parameter creator
 * @export
 */
export const ConfigServiceApiAxiosParamCreator = function (configuration) {
    return {
        /**
         *
         * @param {LoggerCreateConfigRequest} body
         * @param {*} [options] Override http request option.
         * @throws {RequiredError}
         */
        createConfig: (body, options = {}) => __awaiter(this, void 0, void 0, function* () {
            // verify required parameter 'body' is not null or undefined
            if (body === null || body === undefined) {
                throw new RequiredError('body', 'Required parameter body was null or undefined when calling createConfig.');
            }
            const localVarPath = `/logger/config`;
            const localVarUrlObj = globalImportUrl.parse(localVarPath, true);
            let baseOptions;
            if (configuration) {
                baseOptions = configuration.baseOptions;
            }
            const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
            const localVarHeaderParameter = {};
            const localVarQueryParameter = {};
            // authentication AccessToken required
            if (configuration && configuration.apiKey) {
                const localVarApiKeyValue = typeof configuration.apiKey === 'function'
                    ? yield configuration.apiKey('X-Webitel-Access')
                    : yield configuration.apiKey;
                localVarHeaderParameter['X-Webitel-Access'] = localVarApiKeyValue;
            }
            localVarHeaderParameter['Content-Type'] = 'application/json';
            localVarUrlObj.query = Object.assign(Object.assign(Object.assign({}, localVarUrlObj.query), localVarQueryParameter), options.query);
            // fix override query string Detail: https://stackoverflow.com/a/7517673/1077943
            delete localVarUrlObj.search;
            let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
            localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
            const needsSerialization = typeof body !== 'string' ||
                localVarRequestOptions.headers['Content-Type'] === 'application/json';
            localVarRequestOptions.data = needsSerialization
                ? JSON.stringify(body !== undefined ? body : {})
                : body || '';
            return {
                url: globalImportUrl.format(localVarUrlObj),
                options: localVarRequestOptions,
            };
        }),
        /**
         *
         * @param {number} configId
         * @param {*} [options] Override http request option.
         * @throws {RequiredError}
         */
        deleteConfig: (configId, options = {}) => __awaiter(this, void 0, void 0, function* () {
            // verify required parameter 'configId' is not null or undefined
            if (configId === null || configId === undefined) {
                throw new RequiredError('configId', 'Required parameter configId was null or undefined when calling deleteConfig.');
            }
            const localVarPath = `/logger/config/{config_id}`.replace(`{${'config_id'}}`, encodeURIComponent(String(configId)));
            const localVarUrlObj = globalImportUrl.parse(localVarPath, true);
            let baseOptions;
            if (configuration) {
                baseOptions = configuration.baseOptions;
            }
            const localVarRequestOptions = Object.assign(Object.assign({ method: 'DELETE' }, baseOptions), options);
            const localVarHeaderParameter = {};
            const localVarQueryParameter = {};
            // authentication AccessToken required
            if (configuration && configuration.apiKey) {
                const localVarApiKeyValue = typeof configuration.apiKey === 'function'
                    ? yield configuration.apiKey('X-Webitel-Access')
                    : yield configuration.apiKey;
                localVarHeaderParameter['X-Webitel-Access'] = localVarApiKeyValue;
            }
            localVarUrlObj.query = Object.assign(Object.assign(Object.assign({}, localVarUrlObj.query), localVarQueryParameter), options.query);
            // fix override query string Detail: https://stackoverflow.com/a/7517673/1077943
            delete localVarUrlObj.search;
            let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
            localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
            return {
                url: globalImportUrl.format(localVarUrlObj),
                options: localVarRequestOptions,
            };
        }),
        /**
         *
         * @param {number} configId
         * @param {ConfigServicePatchConfigBody} body
         * @param {*} [options] Override http request option.
         * @throws {RequiredError}
         */
        patchConfig: (configId, body, options = {}) => __awaiter(this, void 0, void 0, function* () {
            // verify required parameter 'configId' is not null or undefined
            if (configId === null || configId === undefined) {
                throw new RequiredError('configId', 'Required parameter configId was null or undefined when calling patchConfig.');
            }
            // verify required parameter 'body' is not null or undefined
            if (body === null || body === undefined) {
                throw new RequiredError('body', 'Required parameter body was null or undefined when calling patchConfig.');
            }
            const localVarPath = `/logger/config/{config_id}`.replace(`{${'config_id'}}`, encodeURIComponent(String(configId)));
            const localVarUrlObj = globalImportUrl.parse(localVarPath, true);
            let baseOptions;
            if (configuration) {
                baseOptions = configuration.baseOptions;
            }
            const localVarRequestOptions = Object.assign(Object.assign({ method: 'PATCH' }, baseOptions), options);
            const localVarHeaderParameter = {};
            const localVarQueryParameter = {};
            // authentication AccessToken required
            if (configuration && configuration.apiKey) {
                const localVarApiKeyValue = typeof configuration.apiKey === 'function'
                    ? yield configuration.apiKey('X-Webitel-Access')
                    : yield configuration.apiKey;
                localVarHeaderParameter['X-Webitel-Access'] = localVarApiKeyValue;
            }
            localVarHeaderParameter['Content-Type'] = 'application/json';
            localVarUrlObj.query = Object.assign(Object.assign(Object.assign({}, localVarUrlObj.query), localVarQueryParameter), options.query);
            // fix override query string Detail: https://stackoverflow.com/a/7517673/1077943
            delete localVarUrlObj.search;
            let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
            localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
            const needsSerialization = typeof body !== 'string' ||
                localVarRequestOptions.headers['Content-Type'] === 'application/json';
            localVarRequestOptions.data = needsSerialization
                ? JSON.stringify(body !== undefined ? body : {})
                : body || '';
            return {
                url: globalImportUrl.format(localVarUrlObj),
                options: localVarRequestOptions,
            };
        }),
        /**
         *
         * @param {number} configId int32 domainId &#x3D; 8;
         * @param {*} [options] Override http request option.
         * @throws {RequiredError}
         */
        readConfig: (configId, options = {}) => __awaiter(this, void 0, void 0, function* () {
            // verify required parameter 'configId' is not null or undefined
            if (configId === null || configId === undefined) {
                throw new RequiredError('configId', 'Required parameter configId was null or undefined when calling readConfig.');
            }
            const localVarPath = `/logger/config/{config_id}`.replace(`{${'config_id'}}`, encodeURIComponent(String(configId)));
            const localVarUrlObj = globalImportUrl.parse(localVarPath, true);
            let baseOptions;
            if (configuration) {
                baseOptions = configuration.baseOptions;
            }
            const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
            const localVarHeaderParameter = {};
            const localVarQueryParameter = {};
            // authentication AccessToken required
            if (configuration && configuration.apiKey) {
                const localVarApiKeyValue = typeof configuration.apiKey === 'function'
                    ? yield configuration.apiKey('X-Webitel-Access')
                    : yield configuration.apiKey;
                localVarHeaderParameter['X-Webitel-Access'] = localVarApiKeyValue;
            }
            localVarUrlObj.query = Object.assign(Object.assign(Object.assign({}, localVarUrlObj.query), localVarQueryParameter), options.query);
            // fix override query string Detail: https://stackoverflow.com/a/7517673/1077943
            delete localVarUrlObj.search;
            let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
            localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
            return {
                url: globalImportUrl.format(localVarUrlObj),
                options: localVarRequestOptions,
            };
        }),
        /**
         *
         * @param {boolean} [includeExisting]
         * @param {*} [options] Override http request option.
         * @throws {RequiredError}
         */
        readSystemObjects: (includeExisting, options = {}) => __awaiter(this, void 0, void 0, function* () {
            const localVarPath = `/logger/available_objects`;
            const localVarUrlObj = globalImportUrl.parse(localVarPath, true);
            let baseOptions;
            if (configuration) {
                baseOptions = configuration.baseOptions;
            }
            const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
            const localVarHeaderParameter = {};
            const localVarQueryParameter = {};
            // authentication AccessToken required
            if (configuration && configuration.apiKey) {
                const localVarApiKeyValue = typeof configuration.apiKey === 'function'
                    ? yield configuration.apiKey('X-Webitel-Access')
                    : yield configuration.apiKey;
                localVarHeaderParameter['X-Webitel-Access'] = localVarApiKeyValue;
            }
            if (includeExisting !== undefined) {
                localVarQueryParameter['include_existing'] = includeExisting;
            }
            localVarUrlObj.query = Object.assign(Object.assign(Object.assign({}, localVarUrlObj.query), localVarQueryParameter), options.query);
            // fix override query string Detail: https://stackoverflow.com/a/7517673/1077943
            delete localVarUrlObj.search;
            let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
            localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
            return {
                url: globalImportUrl.format(localVarUrlObj),
                options: localVarRequestOptions,
            };
        }),
        /**
         *
         * @param {number} [page]
         * @param {number} [size]
         * @param {string} [q]
         * @param {string} [sort]
         * @param {Array<string>} [fields]
         * @param {Array<'cc_queue' | 'schema' | 'users' | 'devices' | 'calendars' | 'cc_list' | 'cc_team' | 'cc_agent' | 'cc_resource' | 'cc_resource_group' | 'chat_bots' | 'cases' | 'contacts' | 'cc_list_number' | 'case_comments' | 'record_file'>} [object] NOT USED
         * @param {*} [options] Override http request option.
         * @throws {RequiredError}
         */
        searchConfig: (page, size, q, sort, fields, object, options = {}) => __awaiter(this, void 0, void 0, function* () {
            const localVarPath = `/logger/config`;
            const localVarUrlObj = globalImportUrl.parse(localVarPath, true);
            let baseOptions;
            if (configuration) {
                baseOptions = configuration.baseOptions;
            }
            const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
            const localVarHeaderParameter = {};
            const localVarQueryParameter = {};
            // authentication AccessToken required
            if (configuration && configuration.apiKey) {
                const localVarApiKeyValue = typeof configuration.apiKey === 'function'
                    ? yield configuration.apiKey('X-Webitel-Access')
                    : yield configuration.apiKey;
                localVarHeaderParameter['X-Webitel-Access'] = localVarApiKeyValue;
            }
            if (page !== undefined) {
                localVarQueryParameter['page'] = page;
            }
            if (size !== undefined) {
                localVarQueryParameter['size'] = size;
            }
            if (q !== undefined) {
                localVarQueryParameter['q'] = q;
            }
            if (sort !== undefined) {
                localVarQueryParameter['sort'] = sort;
            }
            if (fields) {
                localVarQueryParameter['fields'] = fields;
            }
            if (object) {
                localVarQueryParameter['object'] = object;
            }
            localVarUrlObj.query = Object.assign(Object.assign(Object.assign({}, localVarUrlObj.query), localVarQueryParameter), options.query);
            // fix override query string Detail: https://stackoverflow.com/a/7517673/1077943
            delete localVarUrlObj.search;
            let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
            localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
            return {
                url: globalImportUrl.format(localVarUrlObj),
                options: localVarRequestOptions,
            };
        }),
        /**
         *
         * @param {number} configId
         * @param {ConfigServiceUpdateConfigBody} body
         * @param {*} [options] Override http request option.
         * @throws {RequiredError}
         */
        updateConfig: (configId, body, options = {}) => __awaiter(this, void 0, void 0, function* () {
            // verify required parameter 'configId' is not null or undefined
            if (configId === null || configId === undefined) {
                throw new RequiredError('configId', 'Required parameter configId was null or undefined when calling updateConfig.');
            }
            // verify required parameter 'body' is not null or undefined
            if (body === null || body === undefined) {
                throw new RequiredError('body', 'Required parameter body was null or undefined when calling updateConfig.');
            }
            const localVarPath = `/logger/config/{config_id}`.replace(`{${'config_id'}}`, encodeURIComponent(String(configId)));
            const localVarUrlObj = globalImportUrl.parse(localVarPath, true);
            let baseOptions;
            if (configuration) {
                baseOptions = configuration.baseOptions;
            }
            const localVarRequestOptions = Object.assign(Object.assign({ method: 'PUT' }, baseOptions), options);
            const localVarHeaderParameter = {};
            const localVarQueryParameter = {};
            // authentication AccessToken required
            if (configuration && configuration.apiKey) {
                const localVarApiKeyValue = typeof configuration.apiKey === 'function'
                    ? yield configuration.apiKey('X-Webitel-Access')
                    : yield configuration.apiKey;
                localVarHeaderParameter['X-Webitel-Access'] = localVarApiKeyValue;
            }
            localVarHeaderParameter['Content-Type'] = 'application/json';
            localVarUrlObj.query = Object.assign(Object.assign(Object.assign({}, localVarUrlObj.query), localVarQueryParameter), options.query);
            // fix override query string Detail: https://stackoverflow.com/a/7517673/1077943
            delete localVarUrlObj.search;
            let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
            localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
            const needsSerialization = typeof body !== 'string' ||
                localVarRequestOptions.headers['Content-Type'] === 'application/json';
            localVarRequestOptions.data = needsSerialization
                ? JSON.stringify(body !== undefined ? body : {})
                : body || '';
            return {
                url: globalImportUrl.format(localVarUrlObj),
                options: localVarRequestOptions,
            };
        }),
    };
};
/**
 * ConfigServiceApi - functional programming interface
 * @export
 */
export const ConfigServiceApiFp = function (configuration) {
    return {
        /**
         *
         * @param {LoggerCreateConfigRequest} body
         * @param {*} [options] Override http request option.
         * @throws {RequiredError}
         */
        createConfig(body, options) {
            return __awaiter(this, void 0, void 0, function* () {
                const localVarAxiosArgs = yield ConfigServiceApiAxiosParamCreator(configuration).createConfig(body, options);
                return (axios = globalAxios, basePath = BASE_PATH) => {
                    const axiosRequestArgs = Object.assign(Object.assign({}, localVarAxiosArgs.options), { url: basePath + localVarAxiosArgs.url });
                    return axios.request(axiosRequestArgs);
                };
            });
        },
        /**
         *
         * @param {number} configId
         * @param {*} [options] Override http request option.
         * @throws {RequiredError}
         */
        deleteConfig(configId, options) {
            return __awaiter(this, void 0, void 0, function* () {
                const localVarAxiosArgs = yield ConfigServiceApiAxiosParamCreator(configuration).deleteConfig(configId, options);
                return (axios = globalAxios, basePath = BASE_PATH) => {
                    const axiosRequestArgs = Object.assign(Object.assign({}, localVarAxiosArgs.options), { url: basePath + localVarAxiosArgs.url });
                    return axios.request(axiosRequestArgs);
                };
            });
        },
        /**
         *
         * @param {number} configId
         * @param {ConfigServicePatchConfigBody} body
         * @param {*} [options] Override http request option.
         * @throws {RequiredError}
         */
        patchConfig(configId, body, options) {
            return __awaiter(this, void 0, void 0, function* () {
                const localVarAxiosArgs = yield ConfigServiceApiAxiosParamCreator(configuration).patchConfig(configId, body, options);
                return (axios = globalAxios, basePath = BASE_PATH) => {
                    const axiosRequestArgs = Object.assign(Object.assign({}, localVarAxiosArgs.options), { url: basePath + localVarAxiosArgs.url });
                    return axios.request(axiosRequestArgs);
                };
            });
        },
        /**
         *
         * @param {number} configId int32 domainId &#x3D; 8;
         * @param {*} [options] Override http request option.
         * @throws {RequiredError}
         */
        readConfig(configId, options) {
            return __awaiter(this, void 0, void 0, function* () {
                const localVarAxiosArgs = yield ConfigServiceApiAxiosParamCreator(configuration).readConfig(configId, options);
                return (axios = globalAxios, basePath = BASE_PATH) => {
                    const axiosRequestArgs = Object.assign(Object.assign({}, localVarAxiosArgs.options), { url: basePath + localVarAxiosArgs.url });
                    return axios.request(axiosRequestArgs);
                };
            });
        },
        /**
         *
         * @param {boolean} [includeExisting]
         * @param {*} [options] Override http request option.
         * @throws {RequiredError}
         */
        readSystemObjects(includeExisting, options) {
            return __awaiter(this, void 0, void 0, function* () {
                const localVarAxiosArgs = yield ConfigServiceApiAxiosParamCreator(configuration).readSystemObjects(includeExisting, options);
                return (axios = globalAxios, basePath = BASE_PATH) => {
                    const axiosRequestArgs = Object.assign(Object.assign({}, localVarAxiosArgs.options), { url: basePath + localVarAxiosArgs.url });
                    return axios.request(axiosRequestArgs);
                };
            });
        },
        /**
         *
         * @param {number} [page]
         * @param {number} [size]
         * @param {string} [q]
         * @param {string} [sort]
         * @param {Array<string>} [fields]
         * @param {Array<'cc_queue' | 'schema' | 'users' | 'devices' | 'calendars' | 'cc_list' | 'cc_team' | 'cc_agent' | 'cc_resource' | 'cc_resource_group' | 'chat_bots' | 'cases' | 'contacts' | 'cc_list_number' | 'case_comments' | 'record_file'>} [object] NOT USED
         * @param {*} [options] Override http request option.
         * @throws {RequiredError}
         */
        searchConfig(page, size, q, sort, fields, object, options) {
            return __awaiter(this, void 0, void 0, function* () {
                const localVarAxiosArgs = yield ConfigServiceApiAxiosParamCreator(configuration).searchConfig(page, size, q, sort, fields, object, options);
                return (axios = globalAxios, basePath = BASE_PATH) => {
                    const axiosRequestArgs = Object.assign(Object.assign({}, localVarAxiosArgs.options), { url: basePath + localVarAxiosArgs.url });
                    return axios.request(axiosRequestArgs);
                };
            });
        },
        /**
         *
         * @param {number} configId
         * @param {ConfigServiceUpdateConfigBody} body
         * @param {*} [options] Override http request option.
         * @throws {RequiredError}
         */
        updateConfig(configId, body, options) {
            return __awaiter(this, void 0, void 0, function* () {
                const localVarAxiosArgs = yield ConfigServiceApiAxiosParamCreator(configuration).updateConfig(configId, body, options);
                return (axios = globalAxios, basePath = BASE_PATH) => {
                    const axiosRequestArgs = Object.assign(Object.assign({}, localVarAxiosArgs.options), { url: basePath + localVarAxiosArgs.url });
                    return axios.request(axiosRequestArgs);
                };
            });
        },
    };
};
/**
 * ConfigServiceApi - factory interface
 * @export
 */
export const ConfigServiceApiFactory = function (configuration, basePath, axios) {
    return {
        /**
         *
         * @param {LoggerCreateConfigRequest} body
         * @param {*} [options] Override http request option.
         * @throws {RequiredError}
         */
        createConfig(body, options) {
            return ConfigServiceApiFp(configuration)
                .createConfig(body, options)
                .then((request) => request(axios, basePath));
        },
        /**
         *
         * @param {number} configId
         * @param {*} [options] Override http request option.
         * @throws {RequiredError}
         */
        deleteConfig(configId, options) {
            return ConfigServiceApiFp(configuration)
                .deleteConfig(configId, options)
                .then((request) => request(axios, basePath));
        },
        /**
         *
         * @param {number} configId
         * @param {ConfigServicePatchConfigBody} body
         * @param {*} [options] Override http request option.
         * @throws {RequiredError}
         */
        patchConfig(configId, body, options) {
            return ConfigServiceApiFp(configuration)
                .patchConfig(configId, body, options)
                .then((request) => request(axios, basePath));
        },
        /**
         *
         * @param {number} configId int32 domainId &#x3D; 8;
         * @param {*} [options] Override http request option.
         * @throws {RequiredError}
         */
        readConfig(configId, options) {
            return ConfigServiceApiFp(configuration)
                .readConfig(configId, options)
                .then((request) => request(axios, basePath));
        },
        /**
         *
         * @param {boolean} [includeExisting]
         * @param {*} [options] Override http request option.
         * @throws {RequiredError}
         */
        readSystemObjects(includeExisting, options) {
            return ConfigServiceApiFp(configuration)
                .readSystemObjects(includeExisting, options)
                .then((request) => request(axios, basePath));
        },
        /**
         *
         * @param {number} [page]
         * @param {number} [size]
         * @param {string} [q]
         * @param {string} [sort]
         * @param {Array<string>} [fields]
         * @param {Array<'cc_queue' | 'schema' | 'users' | 'devices' | 'calendars' | 'cc_list' | 'cc_team' | 'cc_agent' | 'cc_resource' | 'cc_resource_group' | 'chat_bots' | 'cases' | 'contacts' | 'cc_list_number' | 'case_comments' | 'record_file'>} [object] NOT USED
         * @param {*} [options] Override http request option.
         * @throws {RequiredError}
         */
        searchConfig(page, size, q, sort, fields, object, options) {
            return ConfigServiceApiFp(configuration)
                .searchConfig(page, size, q, sort, fields, object, options)
                .then((request) => request(axios, basePath));
        },
        /**
         *
         * @param {number} configId
         * @param {ConfigServiceUpdateConfigBody} body
         * @param {*} [options] Override http request option.
         * @throws {RequiredError}
         */
        updateConfig(configId, body, options) {
            return ConfigServiceApiFp(configuration)
                .updateConfig(configId, body, options)
                .then((request) => request(axios, basePath));
        },
    };
};
/**
 * ConfigServiceApi - object-oriented interface
 * @export
 * @class ConfigServiceApi
 * @extends {BaseAPI}
 */
export class ConfigServiceApi extends BaseAPI {
    /**
     *
     * @param {LoggerCreateConfigRequest} body
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     * @memberof ConfigServiceApi
     */
    createConfig(body, options) {
        return ConfigServiceApiFp(this.configuration)
            .createConfig(body, options)
            .then((request) => request(this.axios, this.basePath));
    }
    /**
     *
     * @param {number} configId
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     * @memberof ConfigServiceApi
     */
    deleteConfig(configId, options) {
        return ConfigServiceApiFp(this.configuration)
            .deleteConfig(configId, options)
            .then((request) => request(this.axios, this.basePath));
    }
    /**
     *
     * @param {number} configId
     * @param {ConfigServicePatchConfigBody} body
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     * @memberof ConfigServiceApi
     */
    patchConfig(configId, body, options) {
        return ConfigServiceApiFp(this.configuration)
            .patchConfig(configId, body, options)
            .then((request) => request(this.axios, this.basePath));
    }
    /**
     *
     * @param {number} configId int32 domainId &#x3D; 8;
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     * @memberof ConfigServiceApi
     */
    readConfig(configId, options) {
        return ConfigServiceApiFp(this.configuration)
            .readConfig(configId, options)
            .then((request) => request(this.axios, this.basePath));
    }
    /**
     *
     * @param {boolean} [includeExisting]
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     * @memberof ConfigServiceApi
     */
    readSystemObjects(includeExisting, options) {
        return ConfigServiceApiFp(this.configuration)
            .readSystemObjects(includeExisting, options)
            .then((request) => request(this.axios, this.basePath));
    }
    /**
     *
     * @param {number} [page]
     * @param {number} [size]
     * @param {string} [q]
     * @param {string} [sort]
     * @param {Array<string>} [fields]
     * @param {Array<'cc_queue' | 'schema' | 'users' | 'devices' | 'calendars' | 'cc_list' | 'cc_team' | 'cc_agent' | 'cc_resource' | 'cc_resource_group' | 'chat_bots' | 'cases' | 'contacts' | 'cc_list_number' | 'case_comments' | 'record_file'>} [object] NOT USED
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     * @memberof ConfigServiceApi
     */
    searchConfig(page, size, q, sort, fields, object, options) {
        return ConfigServiceApiFp(this.configuration)
            .searchConfig(page, size, q, sort, fields, object, options)
            .then((request) => request(this.axios, this.basePath));
    }
    /**
     *
     * @param {number} configId
     * @param {ConfigServiceUpdateConfigBody} body
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     * @memberof ConfigServiceApi
     */
    updateConfig(configId, body, options) {
        return ConfigServiceApiFp(this.configuration)
            .updateConfig(configId, body, options)
            .then((request) => request(this.axios, this.basePath));
    }
}
//# sourceMappingURL=config-service-api.js.map