fine tuning

This commit is contained in:
2026-03-07 00:52:20 +00:00
parent 60230ccfec
commit 6c4595279a
5 changed files with 56 additions and 31 deletions
@@ -366,6 +366,10 @@ export const PROVIDERS: { key: string; piId: string }[] = [
{ key: 'Cerebras', piId: 'cerebras' },
];
piMonoRouter.get('/providers', async (ctx) => {
return ctx.json(PROVIDERS);
});
piMonoRouter.get('/auth', async (ctx) => {
const auth = await readAuthJson();
const providers = PROVIDERS.filter((p) => auth[p.piId]?.key?.trim()).map((p) => p.key);