/** * 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 { DeleteBackendProfileParams, ReadBackendProfileParams, SearchBackendProfileParams, StorageBackendProfile, StorageBackendProfileServicePatchBackendProfileBody, StorageBackendProfileServiceUpdateBackendProfileBody, StorageCreateBackendProfileRequest, StorageListBackendProfile, } from '../_models'; // --- header start // export const // --- title start getBackendProfileService = // --- title end (axiosInstance: AxiosInstance = axios) => { // --- header end /** * @summary List of BackendProfile */ const searchBackendProfile = ( params?: SearchBackendProfileParams, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.get(`/storage/backend_profiles`, { ...options, params: { ...params, ...options?.params, }, }); }; /** * @summary Create BackendProfile */ const createBackendProfile = ( storageCreateBackendProfileRequest: StorageCreateBackendProfileRequest, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.post( `/storage/backend_profiles`, storageCreateBackendProfileRequest, options, ); }; /** * @summary Remove BackendProfile */ const deleteBackendProfile = ( id: string, params?: DeleteBackendProfileParams, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.delete(`/storage/backend_profiles/${id}`, { ...options, params: { ...params, ...options?.params, }, }); }; /** * @summary BackendProfile item */ const readBackendProfile = ( id: string, params?: ReadBackendProfileParams, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.get(`/storage/backend_profiles/${id}`, { ...options, params: { ...params, ...options?.params, }, }); }; /** * @summary Patch BackendProfile */ const patchBackendProfile = ( id: string, storageBackendProfileServicePatchBackendProfileBody: StorageBackendProfileServicePatchBackendProfileBody, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.patch( `/storage/backend_profiles/${id}`, storageBackendProfileServicePatchBackendProfileBody, options, ); }; /** * @summary Update BackendProfile */ const updateBackendProfile = ( id: string, storageBackendProfileServiceUpdateBackendProfileBody: StorageBackendProfileServiceUpdateBackendProfileBody, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.put( `/storage/backend_profiles/${id}`, storageBackendProfileServiceUpdateBackendProfileBody, options, ); }; // --- footer start return { searchBackendProfile, createBackendProfile, deleteBackendProfile, readBackendProfile, patchBackendProfile, updateBackendProfile, }; }; export type SearchBackendProfileResult = AxiosResponse; export type CreateBackendProfileResult = AxiosResponse; export type DeleteBackendProfileResult = AxiosResponse; export type ReadBackendProfileResult = AxiosResponse; export type PatchBackendProfileResult = AxiosResponse; export type UpdateBackendProfileResult = AxiosResponse; // --- footer end