From 53f67c6eb269785acb34da9d913982386eacbc64 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Sat, 20 Dec 2025 06:38:09 +0000 Subject: [PATCH 1/2] Initial plan From 69d5c6f0cb8a3e00cefae5cb118659dfb3417c75 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Sat, 20 Dec 2025 06:43:11 +0000 Subject: [PATCH 2/2] Fix Perplexity AI provider by adding hardcoded model list Co-authored-by: Siumauricio <47042324+Siumauricio@users.noreply.github.com> --- apps/dokploy/server/api/routers/ai.ts | 34 +++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) diff --git a/apps/dokploy/server/api/routers/ai.ts b/apps/dokploy/server/api/routers/ai.ts index e03da905d..ff2d1ee8a 100644 --- a/apps/dokploy/server/api/routers/ai.ts +++ b/apps/dokploy/server/api/routers/ai.ts @@ -68,6 +68,40 @@ export const aiRouter = createTRPCRouter({ { headers: {} }, ); break; + case "perplexity": + // Perplexity doesn't have a /models endpoint, return hardcoded list + return [ + { + id: "sonar-deep-research", + object: "model", + created: Date.now(), + owned_by: "perplexity", + }, + { + id: "sonar-reasoning-pro", + object: "model", + created: Date.now(), + owned_by: "perplexity", + }, + { + id: "sonar-reasoning", + object: "model", + created: Date.now(), + owned_by: "perplexity", + }, + { + id: "sonar-pro", + object: "model", + created: Date.now(), + owned_by: "perplexity", + }, + { + id: "sonar", + object: "model", + created: Date.now(), + owned_by: "perplexity", + }, + ] as Model[]; default: if (!input.apiKey) throw new TRPCError({