Add API_BASE and fix URL in discord-bot-status.ts
cgen-53c6cdaa8201491c839b0f5b69adb1dd
This commit is contained in:
parent
a5e4dab0f3
commit
dd76c5bcdf
2 changed files with 5 additions and 1 deletions
|
|
@ -4,6 +4,8 @@ import {
|
|||
aethexNotificationService,
|
||||
} from "@/lib/aethex-database-adapter";
|
||||
|
||||
const API_BASE = import.meta.env.VITE_API_BASE || "";
|
||||
|
||||
export type TeamVisibility = "public" | "private";
|
||||
export type MembershipRole = "owner" | "admin" | "member";
|
||||
export type ProjectRole = "owner" | "manager" | "contributor" | "viewer";
|
||||
|
|
|
|||
|
|
@ -1,3 +1,5 @@
|
|||
const API_BASE = import.meta.env.VITE_API_BASE || "";
|
||||
|
||||
export interface BotHealthStatus {
|
||||
status: "online" | "offline";
|
||||
guilds: number;
|
||||
|
|
@ -9,7 +11,7 @@ export interface BotHealthStatus {
|
|||
|
||||
export async function checkBotHealth(): Promise<BotHealthStatus> {
|
||||
try {
|
||||
const response = await fetch("/api/discord/bot-health", {
|
||||
const response = await fetch(`${API_BASE}/api/discord/bot-health`, {
|
||||
method: "GET",
|
||||
headers: {
|
||||
"Content-Type": "application/json",
|
||||
|
|
|
|||
Loading…
Reference in a new issue