2025-05-24 23:03:10 +02:00

11 lines
403 B
TypeScript

import { NextRequest, NextResponse } from "next/server";
import prisma from "@/app/prisma";
export async function GET(request: NextRequest) {
try {
const notifications = await prisma.notificationProvider.findMany();
return NextResponse.json({ notifications });
} catch (error: any) {
return NextResponse.json({ error: "Internal Server Error" }, { status: 500 });
}
}