frontend/src/routes/api/get-community-stats/+server.ts
2024-09-23 01:20:45 +02:00

17 lines
409 B
TypeScript

import type { RequestHandler } from "./$types";
export const GET: RequestHandler = async ({ locals }) => {
const { fastifyURL } = locals;
const response = await fetch(fastifyURL + "/get-community-stats", {
method: "GET",
headers: {
"Content-Type": "application/json",
},
});
const output = await response.json();
return new Response(JSON.stringify(output));
};