feat: Add service provider OpenRouter

This commit is contained in:
hycqwq
2025-05-03 19:55:15 +08:00
parent 3809375694
commit 2a59a38c23
13 changed files with 884 additions and 0 deletions

View File

@@ -15,6 +15,7 @@ import { handle as siliconflowHandler } from "../../siliconflow";
import { handle as xaiHandler } from "../../xai";
import { handle as chatglmHandler } from "../../glm";
import { handle as proxyHandler } from "../../proxy";
import { handle as openrouterHandler } from "../../openrouter";
async function handle(
req: NextRequest,
@@ -50,6 +51,8 @@ async function handle(
return chatglmHandler(req, { params });
case ApiPath.SiliconFlow:
return siliconflowHandler(req, { params });
case ApiPath.OpenRouter:
return openrouterHandler(req, { params });
case ApiPath.OpenAI:
return openaiHandler(req, { params });
default: