Files
message-inbox-web-frontend-sdk/apps/web/app/api/bff/channels/[id]/read/route.ts
T
2026-07-17 21:48:37 +05:30

11 lines
365 B
TypeScript

import { NextRequest, NextResponse } from "next/server";
import { getBackend } from "@/lib/backend";
export const dynamic = "force-dynamic";
export async function POST(_req: NextRequest, { params }: { params: Promise<{ id: string }> }) {
const { id } = await params;
const channel = await getBackend().markRead(id);
return NextResponse.json({ channel });
}