import axiosInstance from 'api/axios';
import { GET_WARHOUSES } from 'api/URL';

const warhouses_api = {
  async getWarhouses(params: { cargoType: 'AUTO' | 'AVIA' }): Promise<any> {
    const data = await axiosInstance.get<any>(GET_WARHOUSES, {
      params: {
        ...params,
      },
    });

    return data.data;
  },
};

export default warhouses_api;
