14 lines
398 B
TypeScript
14 lines
398 B
TypeScript
import { apiFetch, jsonResponse } from '../../../../_lib/api';
|
|
|
|
export const dynamic = 'force-dynamic';
|
|
|
|
export async function GET(
|
|
_req: Request,
|
|
{ params }: { params: Promise<{ token: string }> },
|
|
): Promise<Response> {
|
|
const { token } = await params;
|
|
const res = await apiFetch(`/admin/bot/qr/${token}`);
|
|
const payload = await res.json();
|
|
return jsonResponse(payload, res.status);
|
|
}
|