import request from '@/utils/request';
import config, { getUploadUrl } from '@/config/config';
import { getToken } from '@/utils/authority';

const uploadUrl = getUploadUrl();

export default function uploadFile(params) {
	return request(uploadUrl, {
		method: 'POST',
    headers: {
      Authorization: `bearer ${getToken()}`,
    },
		body: params,
	});
}
