mirror of
https://github.com/lingke-net/koring-space.git
synced 2026-09-12 05:45:17 +08:00
13 lines
364 B
TypeScript
13 lines
364 B
TypeScript
import { NextResponse } from "next/server";
|
|||
|
|
|
||
|
|
export async function GET() {
|
||
|
|
const res = await fetch(
|
||
|
|
"https://koring-launcher-file-api.lenjing.cloud/launcher/beta/version.json"
|
||
|
|
);
|
||
|
|
if (!res.ok) {
|
||
|
|
return NextResponse.json({ error: `HTTP ${res.status}` }, { status: res.status });
|
||
|
|
}
|
||
|
|
const data = await res.json();
|
||
|
|
return NextResponse.json(data);
|
||
|
|
}
|