/** * 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 { SearchFilesByCallParams, SearchFilesParams, SearchScreenRecordingsByAgentParams, SearchScreenRecordingsParams, StorageDeleteFilesRequest, StorageDeleteFilesResponse, StorageDeleteQuarantineFilesRequest, StorageFileServiceDeleteScreenRecordingsBody, StorageFileServiceDeleteScreenRecordingsByAgentBody, StorageFileServiceDeleteVideocallFilesBody, StorageListFile, StorageRestoreFilesRequest, StorageRestoreFilesResponse, } from '../_models'; // --- header start // export const // --- title start getFileService = // --- title end (axiosInstance: AxiosInstance = axios) => { // --- header end const deleteVideocallFiles = ( callId: string, storageFileServiceDeleteVideocallFilesBody: StorageFileServiceDeleteVideocallFilesBody, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.delete(`/calls/${callId}/files`, { data: storageFileServiceDeleteVideocallFilesBody, ...options, }); }; const searchFilesByCall = ( callId: string, params?: SearchFilesByCallParams, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.get(`/calls/${callId}/files`, { ...options, params: { ...params, ...options?.params, }, }); }; const searchScreenRecordingsByAgent = ( agentId: string, params?: SearchScreenRecordingsByAgentParams, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.get(`/storage/agent/${agentId}`, { ...options, params: { ...params, ...options?.params, }, }); }; const deleteScreenRecordingsByAgent = ( agentId: string, id: string[], storageFileServiceDeleteScreenRecordingsByAgentBody: StorageFileServiceDeleteScreenRecordingsByAgentBody, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.delete(`/storage/agent/${agentId}/${id}`, { data: storageFileServiceDeleteScreenRecordingsByAgentBody, ...options, }); }; const deleteFiles = ( storageDeleteFilesRequest: StorageDeleteFilesRequest, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.delete(`/storage/file`, { data: storageDeleteFilesRequest, ...options, }); }; const searchFiles = ( params?: SearchFilesParams, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.get(`/storage/file`, { ...options, params: { ...params, ...options?.params, }, }); }; const deleteQuarantineFiles = ( storageDeleteQuarantineFilesRequest: StorageDeleteQuarantineFilesRequest, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.delete(`/storage/file/quarantine`, { data: storageDeleteQuarantineFilesRequest, ...options, }); }; const restoreFiles = ( storageRestoreFilesRequest: StorageRestoreFilesRequest, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.patch( `/storage/file/restore`, storageRestoreFilesRequest, options, ); }; const searchScreenRecordings = ( userId: string, params?: SearchScreenRecordingsParams, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.get(`/storage/users/${userId}`, { ...options, params: { ...params, ...options?.params, }, }); }; const deleteScreenRecordings = ( userId: string, id: string[], storageFileServiceDeleteScreenRecordingsBody: StorageFileServiceDeleteScreenRecordingsBody, options?: AxiosRequestConfig, ): Promise> => { return axiosInstance.delete(`/storage/users/${userId}/${id}`, { data: storageFileServiceDeleteScreenRecordingsBody, ...options, }); }; // --- footer start return { deleteVideocallFiles, searchFilesByCall, searchScreenRecordingsByAgent, deleteScreenRecordingsByAgent, deleteFiles, searchFiles, deleteQuarantineFiles, restoreFiles, searchScreenRecordings, deleteScreenRecordings, }; }; export type DeleteVideocallFilesResult = AxiosResponse; export type SearchFilesByCallResult = AxiosResponse; export type SearchScreenRecordingsByAgentResult = AxiosResponse; export type DeleteScreenRecordingsByAgentResult = AxiosResponse; export type DeleteFilesResult = AxiosResponse; export type SearchFilesResult = AxiosResponse; export type DeleteQuarantineFilesResult = AxiosResponse; export type RestoreFilesResult = AxiosResponse; export type SearchScreenRecordingsResult = AxiosResponse; export type DeleteScreenRecordingsResult = AxiosResponse; // --- footer end