import { environment } from '../../enviroments/enviroments';
import axios from 'axios';

const { localhost, localeRu, apiPrefix, exportsCSV } = environment;

export function exportCSV(token: string | null): any {
  return axios({
    method: 'get',
    baseURL: `
      ${localhost + localeRu + apiPrefix + exportsCSV.incidents}
    `,
    headers: {
      Authorization: `Token ${token}`,
    },
  });
}
export function celery(token: string | null, cel: any): any {
  return axios({
    method: 'get',
    baseURL: `${localhost + localeRu + apiPrefix}celery/${cel}`,
    headers: {
      Authorization: `Token ${token}`,
    },
  });
}
