import apiRequest from '@/network/http/apiRequest'

/**
 * 获取Api Request分页
 * @param data
 * @returns
 */
export function getApiLogByPage(data: any) {
  return apiRequest({
    url: '/api/log/page',
    method: 'GET',
    params: data,
  })
}

/**
 * 获取Api Request列表
 * @param data
 * @returns
 */
export function getApiLogByList(data: any) {
  return apiRequest({
    url: '/api/log',
    method: 'GET',
    params: data,
  })
}

/**
 * 根据Id获取Api Request
 * @param reqId
 * @returns
 */
export function getApiLogById(reqId: number) {
  return apiRequest({
    url: `/api/log/${reqId}`,
    method: 'GET',
  })
}

/**
 * 删除Api
 * @param reqId
 * @returns
 */
export function deleteApiLogById(reqId: number) {
  return apiRequest({
    url: `/api/log/${reqId}`,
    method: 'DELETE',
  })
}
