user.api.js 265 Bytes
Newer Older
1
2
3
4
5
6
7
8
9
10
import axios from "axios";
import { API_BASE_URL } from "./endpoints";

const login = async (email, password) => {
  const payload = { email, password };
  const { data } = await axios.post(`${API_BASE_URL}/user`, payload);
  return data;
};

export default login;