feat: 去除basic auth认证,添加登录和登出 API,更新中间件以支持 cookie 验证

This commit is contained in:
2025-11-23 10:13:08 +08:00
parent fd68c8a452
commit 4b24940f7e
6 changed files with 479 additions and 200 deletions
+7
View File
@@ -0,0 +1,7 @@
import { NextResponse } from 'next/server';
export async function POST() {
const response = NextResponse.json({ success: true });
response.cookies.delete('auth_token');
return response;
}