mirror of
https://github.com/JezzWTF/vibepod.git
synced 2026-06-01 15:22:14 +00:00
3974a4cf69
Agent-Logs-Url: https://github.com/JezzWTF/vibepod/sessions/a78fcf03-e979-4777-a428-18cc8eccc095 Co-authored-by: LyAhn <27559362+LyAhn@users.noreply.github.com>
21 lines
507 B
TypeScript
21 lines
507 B
TypeScript
import { NextResponse } from "next/server";
|
|
|
|
export async function GET() {
|
|
const pythonServerUrl =
|
|
process.env.VIBEVOICE_SERVER_URL ?? "http://localhost:8000";
|
|
|
|
try {
|
|
const res = await fetch(`${pythonServerUrl}/health`, {
|
|
method: "GET",
|
|
signal: AbortSignal.timeout(4000),
|
|
});
|
|
|
|
if (res.ok) {
|
|
return NextResponse.json({ status: "online" });
|
|
}
|
|
return NextResponse.json({ status: "offline" });
|
|
} catch {
|
|
return NextResponse.json({ status: "offline" });
|
|
}
|
|
}
|