import { api } from '@/lib/api' import type { SupplierResponse } from '@/types/api' export interface SupplierBody { name: string contactInfo?: string | null isActive?: boolean } export const suppliers = { list: () => api.get('/suppliers').then(r => r.data), get: (id: string) => api.get(`/suppliers/${id}`).then(r => r.data), create: (body: SupplierBody) => api.post('/suppliers', body).then(r => r.data), update: (id: string, body: Partial) => api.put(`/suppliers/${id}`, body).then(r => r.data), remove: (id: string) => api.delete(`/suppliers/${id}`), }