7.4 billion tokens per month. 34 free LLM providers. 635 free model endpoints. All behind one /v1 endpoint, plus any custom OpenAI-compatible endpoint. Smart routing, automatic failover, encrypted keys. Personal experimentation only.
TypeScript
fix(keys): stop offering Auray to new users (#1563) (#1574)
Tashfeen6927ea46e13e
diff --git a/client/src/components/keys/add-key-form.tsx b/client/src/components/keys/add-key-form.tsxindex ad3856ec..c9113837 100644--- a/client/src/components/keys/add-key-form.tsx+++ b/client/src/components/keys/add-key-form.tsx@@ -13,7 +13,7 @@ import { toast } from '@/lib/toast'import type { FallbackEntry } from '@/lib/routing'import { scopeCandidates, shouldOfferModelPicker, type ScopeCandidate } from '@/lib/model-scope-selection'import { SEARCH_PROVIDERS } from '@/lib/search'-import { GetKeyLink, PLATFORMS } from './shared'+import { GetKeyLink, LISTED_PLATFORMS, PLATFORMS } from './shared'/** A key that just landed, plus the models the picker should offer for it.* Only produced when the picker is actually worth showing (#657) — otherwise@@ -95,7 +95,7 @@ export function AddKeyForm({ onSuccess, initialPlatform }: { onSuccess: (offer?:const platformOptions = useMemo(() => [...SEARCH_PROVIDERS.map(p => ({ ...p, group: t('search.pickerSearch') })),- ...PLATFORMS.map(p => ({ ...p, group: t('search.pickerModels') })),+ ...LISTED_PLATFORMS.map(p => ({ ...p, group: t('search.pickerModels') })),]// The selected provider always stays listed, so hiding added ones never// blanks out the trigger label.diff --git a/client/src/components/keys/add-model-dialog.tsx b/client/src/components/keys/add-model-dialog.tsxindex 06fca056..ef6e24ca 100644--- a/client/src/components/keys/add-model-dialog.tsx+++ b/client/src/components/keys/add-model-dialog.tsx@@ -12,7 +12,7 @@ import { FieldError } from '@/components/ui/field-error'import { useI18n } from '@/i18n'import { toast } from '@/lib/toast'import type { ApiKey } from '@freellmapi/shared/types'-import { PLATFORMS, CUSTOM_GROUP } from '@/components/keys/shared'+import { LISTED_PLATFORMS, CUSTOM_GROUP } from '@/components/keys/shared'export interface AddModelDialogProps {open: boolean@@ -127,7 +127,7 @@ function AddModelForm({ open, onOpenChange, initialPlatform, initialKeyId }: AddaddModelMutation.mutate(payload)}- const allProviders = [...PLATFORMS, CUSTOM_GROUP]+ const allProviders = [...LISTED_PLATFORMS, CUSTOM_GROUP]return (<Dialog open={open} onOpenChange={onOpenChange}>diff --git a/client/src/components/keys/import-keys-section.tsx b/client/src/components/keys/import-keys-section.tsxindex 3b0da599..e29194e8 100644--- a/client/src/components/keys/import-keys-section.tsx+++ b/client/src/components/keys/import-keys-section.tsx@@ -10,7 +10,7 @@ import type { ImportKey, ImportSelectedResponse, Platform, PreviewKey, PreviewReimport { Upload } from 'lucide-react'import { useI18n } from '@/i18n'import { toast } from '@/lib/toast'-import { CUSTOM_GROUP, PLATFORMS } from './shared'+import { CUSTOM_GROUP, LISTED_PLATFORMS } from './shared'interface ImportRow extends PreviewKey {selected: boolean@@ -34,7 +34,7 @@ export function ImportKeysSection({ onImported }: { onImported?: () => void } =// imported row is the one case where it belongs there: the file already// names the endpoint, and without the option the row can never be selected// and the endpoint can never be restored (#687).- const importablePlatforms = [...PLATFORMS.filter(p => !p.keyless), CUSTOM_GROUP]+ const importablePlatforms = [...LISTED_PLATFORMS.filter(p => !p.keyless), CUSTOM_GROUP]function platformFromPreview(key: PreviewKey): Platform | '' {// A custom row is only importable with its base URL; there is nowhere todiff --git a/client/src/components/keys/shared.tsx b/client/src/components/keys/shared.tsxindex bb79b055..20730ee2 100644--- a/client/src/components/keys/shared.tsx+++ b/client/src/components/keys/shared.tsx@@ -26,10 +26,13 @@ export function GetKeyLink({ url }: { url: string }) {// one (#1331): the key field is optional, a blank submit stores a sentinel so// routing treats the platform as configured and calls go out anonymously, and// a real key is stored and sent like any other.-export const PLATFORMS: { value: Platform; label: string; url: string; keyless?: boolean }[] = [+// `hidden: true` providers stopped offering free API access: they are no longer+// offered to new users (add/import/add-model pickers, setup checklist), but an+// existing key still shows with its label so it can be edited or removed.+export const PLATFORMS: { value: Platform; label: string; url: string; keyless?: boolean; hidden?: boolean }[] = [{ value: 'aclide', label: 'ACLIDE (shared monthly credits)', url: 'https://aclide.com/en/dashboard/api-keys' },{ value: 'speka', label: 'Speka ($1 shared monthly credits)', url: 'https://speka.me/dashboard/keys' },- { value: 'auray', label: 'Auray (50 shared monthly credits)', url: 'https://app.auray.ai' },+ { value: 'auray', label: 'Auray', url: 'https://app.auray.ai', hidden: true },{ value: 'beatapi', label: 'BeatAPI (JEV decisions; temporary free offer)', url: 'https://beatapi.io' },{ value: 'typhoon', label: 'Typhoon (free research API)', url: 'https://playground.opentyphoon.ai' },{ value: 'plugsky', label: 'Plugsky (free chat aliases)', url: 'https://plugsky.com/dashboard' },@@ -102,6 +105,9 @@ export const PLATFORMS: { value: Platform; label: string; url: string; keyless?:{ value: 'xfyun', label: 'iFlytek Spark (free Lite, needs cn real-name)', url: 'https://console.xfyun.cn' },]+/** Providers a new user can pick (`hidden` ones only stay for existing keys). */+export const LISTED_PLATFORMS = PLATFORMS.filter(p => !p.hidden)+// 'custom' is configured through its own form (base URL + model), not the// generic key dropdown — but it still appears in the grouped provider list.export const CUSTOM_GROUP: { value: Platform; label: string; url: string } = {diff --git a/server/src/__tests__/routes/keys-providers-checklist.test.ts b/server/src/__tests__/routes/keys-providers-checklist.test.tsindex 9e335ee8..2171a8c1 100644--- a/server/src/__tests__/routes/keys-providers-checklist.test.ts+++ b/server/src/__tests__/routes/keys-providers-checklist.test.ts@@ -81,4 +81,15 @@ describe('GET /api/keys/providers — provider checklist (#543)', () => {expect(body.summary.configured).toBe(1);expect(body.summary.unconfigured).toBe(body.summary.total - 1);});++ it('stops suggesting an unlisted provider (Auray, #1563) but still shows it to a user who has a key', async () => {+ const before = await request(app, '/api/keys/providers');+ expect(before.body.providers.some((p: { platform: string }) => p.platform === 'auray')).toBe(false);++ addKey('auray');+ const after = await request(app, '/api/keys/providers');+ expect(after.body.providers.find((p: { platform: string }) => p.platform === 'auray'))+ .toMatchObject({ platform: 'auray', configured: true, keyCount: 1 });+ expect(after.body.summary.total).toBe(before.body.summary.total + 1);+ });});diff --git a/server/src/routes/keys.ts b/server/src/routes/keys.tsindex 31cc529d..64c6772c 100644--- a/server/src/routes/keys.ts+++ b/server/src/routes/keys.ts@@ -38,6 +38,13 @@ import { KEY_PROXY_URL_ERROR, KEY_PROXY_URL_MAX, decryptProxyUrl, encryptProxyUrexport const keysRouter = Router();+// Providers that stopped offering free API access but keep their adapter so+// existing keys still work if the catalog re-enables them. The setup+// checklist stops suggesting them to anyone who has no key yet; the dashboard+// pickers hide them through `hidden` in client/src/components/keys/shared.tsx.+// Auray: free accounts locked and API access charged (#1563).+const UNLISTED_PLATFORMS = new Set<string>(['auray']);+// Active providers — must match providers/index.ts registrations + shared/types.ts Platform.// Moonshot and MiniMax direct integrations were dropped in V4. HuggingFace// was dropped in V4 and re-added in V13 via the router.huggingface.co route.@@ -329,6 +336,7 @@ keysRouter.get('/providers', (_req: Request, res: Response) => {enabledKeyCount: counts?.enabled_keys ?? 0,};})+ .filter(p => p.configured || !UNLISTED_PLATFORMS.has(p.platform)).sort((a, b) => a.name.localeCompare(b.name));const configured = providers.filter(p => p.configured).length;