import { request } from './config'


export function listStorage(params: any) {
  return request({
    url: '/storage/list',
    method: 'get',
    params
  })
}

export function createStorage(data: any) {
  return request({
    url: '/storage/create',
    method: 'post',
    data
  })
}

export function readStorage(data: any) {
  return request({
    url: '/storage/read',
    method: 'get',
    data
  })
}

export function updateStorage(data: any) {
  return request({
    url: '/storage/update',
    method: 'post',
    data
  })
}

export function deleteStorage(data: any) {
  return request({
    url: '/storage/delete',
    method: 'post',
    data
  })
}

const uploadPath = import.meta.env.VITE_APP_BASE_URL + '/storage/create'
export { uploadPath }
