import useAxios from "axios-hooks";

export default function () {
  const url = `/learn/v1/enterprise`;

  const [{ ...coursesData }] = useAxios({
    url: `${url}/courses/`,
    method: "GET",
    params: { "status[]": "ending_soon,active,scheduled", page_size: 4 },
  });

  const [{ ...remainingSlotData }] = useAxios({
    url: `${url}/teams/remaining_slot/`,
    method: "GET",
  });

  const [{ ...storageSummaryData }] = useAxios({
    url: `/media/v1/enterprise/filemanager/overview/`,
    method: "GET",
  });

  return {
    coursesData,
    remainingSlotData,
    storageSummaryData,
  };
}
