import api from "../axios"; import { API_ENDPOINTS } from "../endpoints"; import { TContactApiResponseSchema } from "../types/TContacts"; export const contactUsService = { getAllContactUs: async ( params?: Record, ): Promise => { try { return (await api.get(API_ENDPOINTS.CONTACT_US.BASE(), { params })).data; } catch (error) { console.error( "ERROR caught in contact-us service => getAllContactUs", error, ); throw error; } }, deleteContactUs: async (id: string) => { try { return (await api.delete(API_ENDPOINTS.CONTACT_US.BASE(id))).data; } catch (error) { console.error( "ERROR caught in contact-us service => deleteContactUs", error, ); throw error; } }, };