/** * Generated by orval v8.19.0 🍺 * Do not edit manually. * Webitel API * OpenAPI spec version: 24.04.0 */ import axios from '@aliasedDeps/api-services/axios'; import type { AxiosInstance, AxiosRequestConfig, AxiosResponse } from 'axios'; import type { ApiDeleteLDAPRequest, ApiLDAPCatalog, ApiLDAProcess, ApiLDAProcessResponse, ApiLDAPSearchRequest, ApiLDAPSearchResponse, ApiLDAPTemplate, ApiLDAPTemplateResponse, ApiSearchLDAPResponse, DeleteLDAPCatalogParams, LDAPCreateLDAPTemplateBody, LDAPDeleteLDAPTemplateBody, LDAPLDAPSearchBody, LDAPResyncLDAPCatalogBody, LDAPSearch2Params, LDAPSearch4Params, LDAPUpdateLDAPCatalogBody, LDAPUpdateLDAPTemplateBody, LocateLDAPCatalogParams, LocateLDAProcessParams, LocateLDAPTemplateParams, SearchLDAPCatalogParams, SearchLDAProcessParams, SearchLDAPTemplateParams, } from '../_models'; // --- header start // export const // --- title start getLdap = // --- title end (axiosInstance: AxiosInstance = axios) => { // --- header end /** * @summary Delete LDAP profile(s) ... */ const deleteLDAPCatalog2 = ( apiDeleteLDAPRequest: ApiDeleteLDAPRequest, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.delete(`/ldap`, { data: apiDeleteLDAPRequest, ...options, }); }; /** * @summary Search for LDAP directories ... */ const searchLDAPCatalog = ( params?: SearchLDAPCatalogParams, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.get(`/ldap`, { ...options, params: { ...params, ...options?.params, }, }); }; /** * @summary Create LDAP profile */ const createLDAPCatalog = ( apiLDAPCatalog: ApiLDAPCatalog, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.post(`/ldap`, apiLDAPCatalog, options); }; /** * @summary LDAPSearch performs LDAP Search operation ... */ const lDAPSearch4 = ( params?: LDAPSearch4Params, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.get(`/ldap/search`, { ...options, params: { ...params, ...options?.params, }, }); }; /** * @summary LDAPSearch performs LDAP Search operation ... */ const lDAPSearch3 = ( apiLDAPSearchRequest: ApiLDAPSearchRequest, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.post( `/ldap/search`, apiLDAPSearchRequest, options, ); }; /** * @summary Update LDAP profile details */ const updateLDAPCatalog2 = ( lDAPUpdateLDAPCatalogBody: LDAPUpdateLDAPCatalogBody, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.patch( `/ldap/catalog.id}`, lDAPUpdateLDAPCatalogBody, options, ); }; /** * @summary Update LDAP profile details */ const updateLDAPCatalog = ( lDAPUpdateLDAPCatalogBody: LDAPUpdateLDAPCatalogBody, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.put( `/ldap/catalog.id}`, lDAPUpdateLDAPCatalogBody, options, ); }; const createLDAPTemplate = ( lDAPCreateLDAPTemplateBody: LDAPCreateLDAPTemplateBody, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.post( `/ldap/catalog.id}/templates`, lDAPCreateLDAPTemplateBody, options, ); }; /** * @summary (ResyncLDAPResponse) { */ const searchLDAProcess = ( catalogId: string, params?: SearchLDAProcessParams, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.get(`/ldap/${catalogId}/rsync`, { ...options, params: { ...params, ...options?.params, }, }); }; /** * (ResyncLDAPResponse) { * @summary Resync LDAP directory catalog changes ... */ const resyncLDAPCatalog = ( catalogId: string, lDAPResyncLDAPCatalogBody: LDAPResyncLDAPCatalogBody, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.post( `/ldap/${catalogId}/rsync`, lDAPResyncLDAPCatalogBody, options, ); }; /** * @summary (ResyncLDAPResponse) { */ const locateLDAProcess = ( catalogId: string, id: string[], params?: LocateLDAProcessParams, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.get(`/ldap/${catalogId}/rsync/${id}`, { ...options, params: { ...params, ...options?.params, }, }); }; /** * @summary LDAPSearch performs LDAP Search operation ... */ const lDAPSearch2 = ( catalogId: string, params?: LDAPSearch2Params, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.get(`/ldap/${catalogId}/search`, { ...options, params: { ...params, ...options?.params, }, }); }; /** * @summary LDAPSearch performs LDAP Search operation ... */ const lDAPSearch = ( catalogId: string, lDAPLDAPSearchBody: LDAPLDAPSearchBody, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.post( `/ldap/${catalogId}/search`, lDAPLDAPSearchBody, options, ); }; const deleteLDAPTemplate2 = ( catalogId: string, lDAPDeleteLDAPTemplateBody: LDAPDeleteLDAPTemplateBody, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.delete(`/ldap/${catalogId}/templates`, { data: lDAPDeleteLDAPTemplateBody, ...options, }); }; const searchLDAPTemplate = ( catalogId: string, params?: SearchLDAPTemplateParams, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.get(`/ldap/${catalogId}/templates`, { ...options, params: { ...params, ...options?.params, }, }); }; const deleteLDAPTemplate = ( catalogId: string, id: string[], lDAPDeleteLDAPTemplateBody: LDAPDeleteLDAPTemplateBody, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.delete(`/ldap/${catalogId}/templates/${id}`, { data: lDAPDeleteLDAPTemplateBody, ...options, }); }; const locateLDAPTemplate = ( catalogId: string, id: string[], params?: LocateLDAPTemplateParams, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.get(`/ldap/${catalogId}/templates/${id}`, { ...options, params: { ...params, ...options?.params, }, }); }; /** * @summary Delete LDAP profile(s) ... */ const deleteLDAPCatalog = ( id: string, params?: DeleteLDAPCatalogParams, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.delete(`/ldap/${id}`, { ...options, params: { ...params, ...options?.params, }, }); }; /** * @summary Read LDAP catalog profile by .id */ const locateLDAPCatalog = ( id: string[], params?: LocateLDAPCatalogParams, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.get(`/ldap/${id}`, { ...options, params: { ...params, ...options?.params, }, }); }; const updateLDAPTemplate = ( lDAPUpdateLDAPTemplateBody: LDAPUpdateLDAPTemplateBody, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.patch( `/ldap/template.catalog.id}/templates/template.id}`, lDAPUpdateLDAPTemplateBody, options, ); }; const updateLDAPTemplate2 = ( lDAPUpdateLDAPTemplateBody: LDAPUpdateLDAPTemplateBody, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.put( `/ldap/template.catalog.id}/templates/template.id}`, lDAPUpdateLDAPTemplateBody, options, ); }; // --- footer start return { deleteLDAPCatalog2, searchLDAPCatalog, createLDAPCatalog, lDAPSearch4, lDAPSearch3, updateLDAPCatalog2, updateLDAPCatalog, createLDAPTemplate, searchLDAProcess, resyncLDAPCatalog, locateLDAProcess, lDAPSearch2, lDAPSearch, deleteLDAPTemplate2, searchLDAPTemplate, deleteLDAPTemplate, locateLDAPTemplate, deleteLDAPCatalog, locateLDAPCatalog, updateLDAPTemplate, updateLDAPTemplate2, }; }; export type DeleteLDAPCatalog2Result = AxiosResponse; export type SearchLDAPCatalogResult = AxiosResponse; export type CreateLDAPCatalogResult = AxiosResponse; export type LDAPSearch4Result = AxiosResponse; export type LDAPSearch3Result = AxiosResponse; export type UpdateLDAPCatalog2Result = AxiosResponse; export type UpdateLDAPCatalogResult = AxiosResponse; export type CreateLDAPTemplateResult = AxiosResponse; export type SearchLDAProcessResult = AxiosResponse; export type ResyncLDAPCatalogResult = AxiosResponse; export type LocateLDAProcessResult = AxiosResponse; export type LDAPSearch2Result = AxiosResponse; export type LDAPSearchResult = AxiosResponse; export type DeleteLDAPTemplate2Result = AxiosResponse; export type SearchLDAPTemplateResult = AxiosResponse; export type DeleteLDAPTemplateResult = AxiosResponse; export type LocateLDAPTemplateResult = AxiosResponse; export type DeleteLDAPCatalogResult = AxiosResponse; export type LocateLDAPCatalogResult = AxiosResponse; export type UpdateLDAPTemplateResult = AxiosResponse; export type UpdateLDAPTemplate2Result = AxiosResponse; // --- footer end