import { api } from './client'

export function fetchThresholds() {
  return api.get('/api/v1/alert-thresholds')
}

export function createThreshold(payload) {
  return api.post('/api/v1/alert-thresholds', payload)
}

export function updateThreshold(id, payload) {
  return api.put(`/api/v1/alert-thresholds/${id}`, payload)
}

export function deleteThreshold(id) {
  return api.delete(`/api/v1/alert-thresholds/${id}`)
}
