feat: add cloudflare ai gateway provider

This commit is contained in:
Peter Steinberger
2026-02-04 04:10:13 -08:00
parent 19ecdce275
commit 5b0851ebd8
28 changed files with 663 additions and 9 deletions

View File

@@ -169,7 +169,11 @@ export async function resolveApiKeyForProfile(params: {
}
if (cred.type === "api_key") {
return { apiKey: cred.key, provider: cred.provider, email: cred.email };
const key = cred.key?.trim();
if (!key) {
return null;
}
return { apiKey: key, provider: cred.provider, email: cred.email };
}
if (cred.type === "token") {
const token = cred.token?.trim();