import axios from "axios"; type UserInfo = { name: string; patreon: boolean; timezone: string | null; }; export type GuildInfo = { id: string; name: string; }; export function fetchUserInfo(): Promise { return axios.get("/api/user").then((resp) => resp.data) as Promise; } export function fetchUserGuilds(): Promise { return axios.get("/api/user/guilds").then((resp) => resp.data) as Promise; }