Skip to content

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

feat(providers): add IteraCompute free OpenAI-compatible gateway (#1649) (#1655)

tashdroid2359d30bc2d7
diff --git a/client/src/components/keys/shared.tsx b/client/src/components/keys/shared.tsx
index 19870120..9815478a 100644
--- a/client/src/components/keys/shared.tsx
+++ b/client/src/components/keys/shared.tsx
@@ -35,6 +35,7 @@ export const PLATFORMS: { value: Platform; label: string; url: string; keyless?:
{ value: 'beatapi', label: 'BeatAPI (JEV decisions; temporary free offer)', url: 'https://beatapi.io' },
{ value: 'apinex', label: 'APINex (shared daily free chat and decisions)', url: 'https://apinex.bond/keys' },
{ value: 'onomeo', label: 'onomeo (30 free calls / 5 hours, shared)', url: 'https://onomeo.com/dashboard' },
+ { value: 'iteracompute', label: 'IteraCompute (30M free tokens / month, shared)', url: 'https://iteracompute.com/free/' },
{ value: 'typhoon', label: 'Typhoon (free research API)', url: 'https://playground.opentyphoon.ai' },
{ value: 'plugsky', label: 'Plugsky (free chat aliases)', url: 'https://plugsky.com/dashboard' },
{ value: 'inferbase', label: 'Inferbase (shared monthly and daily allowance)', url: 'https://inferbase.ai' },
diff --git a/client/src/lib/routing.ts b/client/src/lib/routing.ts
index 02f4e983..b3dca104 100644
--- a/client/src/lib/routing.ts
+++ b/client/src/lib/routing.ts
@@ -486,6 +486,7 @@ export const platformColors: Record<string, string> = {
beatapi: '#8b5cf6',
apinex: '#06b6d4',
onomeo: '#f97316',
+ iteracompute:'#f59e0b',
}
// ── Grouped (unified) rendering ──────────────────────────────────────────────
diff --git a/docs/ITERACOMPUTE.md b/docs/ITERACOMPUTE.md
new file mode 100644
index 00000000..66937193
--- /dev/null
+++ b/docs/ITERACOMPUTE.md
@@ -0,0 +1,41 @@
+# IteraCompute
+
+IteraCompute uses `https://api.iteracompute.com/v1`, with Bearer API-key
+authentication, on the OpenAI chat-completions shape. Add a key in the
+dashboard or import `ITERACOMPUTE_API_KEY` from an environment file.
+
+- Chat and SSE: `POST /chat/completions`, OpenAI request/response shape.
+- Public model list, no key needed: `GET /models` returns every model with
+ `is_free` and per-1M-token prices. Credentials are ignored on this endpoint
+ (a bogus `Authorization` header still returns `200`, verified live
+ 2026-10-22), so it is NOT a credential probe.
+- Key validation is off (`supportsKeyValidation === false`): the only
+ authenticated endpoint is `/chat/completions`, and every request reserves
+ against the monthly allowance before settling (free-tier terms). A health
+ probe would burn user quota, so validity is proven by the first served
+ request instead; a bogus key fails at request time with `401
+ authentication_error invalid_api_key` (verified live 2026-10-22).
+
+## Free eligibility, verified 2026-10-22
+
+The free tier is one account-wide monthly TOKEN allowance: `qwen/qwen3.8-27b`
+gets 30M tokens/month (input + output, reasoning included) at 160,000 TPM with
+128K free context. No daily quota, no paid overage: once the allowance is spent
+the API answers 429 until the reset at 00:00 UTC on the 1st (no rollover).
+Free accounts may queue at peak; full or timed-out queues return 429 with
+`Retry-After`, infrastructure failures 503. For plain answers without reasoning
+text, send `"chat_template_kwargs": {"enable_thinking": false}`.
+
+`moonshotai/kimi-k3-free` also shows `is_free: true` on the model list but
+requires a $10 cumulative recharge first, so it does not meet the never-paid
+rule from #853 and stays out of the catalog.
+
+Model rows are published only through the signed Oracle catalog. No seeds,
+model-discovery enrollment, or database migration bypasses the existing
+Premium-now / Free-after-30-days release gate.
+
+Sources:
+
+- <https://iteracompute.com/free/>
+- <https://iteracompute.com/free-tier-terms/>
+- issue #1649
diff --git a/server/src/__tests__/services/iteracompute.test.ts b/server/src/__tests__/services/iteracompute.test.ts
new file mode 100644
index 00000000..e2cf93d0
--- /dev/null
+++ b/server/src/__tests__/services/iteracompute.test.ts
@@ -0,0 +1,69 @@
+import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest';
+import { initDb, getDb } from '../../db/index.js';
+import { getProvider } from '../../providers/index.js';
+import { IteraComputeProvider, ITERACOMPUTE_BASE_URL } from '../../providers/iteracompute.js';
+import { AUTH_JSON_PROVIDER_MAP, parseKeysFromFile } from '../../lib/key-parser.js';
+import { inferPoolForPlatform } from '../../services/provider-quota.js';
+
+const json = (body: unknown, status = 200) => new Response(JSON.stringify(body), { status });
+const completion = (model?: string) => ({ id: 'c', object: 'chat.completion', created: 1, model,
+ choices: [{ index: 0, message: { role: 'assistant', content: 'OK' }, finish_reason: 'stop' }],
+ usage: { prompt_tokens: 3, completion_tokens: 1, total_tokens: 4 } });
+
+beforeEach(() => { process.env.ENCRYPTION_KEY = '0'.repeat(64); initDb(':memory:'); });
+afterEach(() => { vi.restoreAllMocks(); getDb().close(); });
+
+describe('iteracompute registration and import (#1649)', () => {
+ it('registers the adapter, the env import alias and one shared monthly pool', () => {
+ expect(getProvider('iteracompute')).toBeInstanceOf(IteraComputeProvider);
+ expect(getProvider('iteracompute')!.keyless).toBe(false);
+ expect(parseKeysFromFile('ITERACOMPUTE_API_KEY=test-key', 'keys.env').keys[0].platform).toBe('iteracompute');
+ expect(AUTH_JSON_PROVIDER_MAP.iteracompute).toBe('iteracompute');
+ // One 30M-token monthly allowance shared across every free model, so a 429
+ // on one model benches the platform, not the model.
+ expect(inferPoolForPlatform('iteracompute', 'qwen/qwen3.8-27b'))
+ .toBe(inferPoolForPlatform('iteracompute', 'qwen/qwen3.9-30b'));
+ });
+});
+
+describe('iteracompute key validation (#1649)', () => {
+ // GET /models is anonymous (a bogus Bearer header still returns 200, verified
+ // live 2026-10-22) and /chat/completions reserves monthly allowance per
+ // request, so there is no free credential probe — same stance as freeai
+ // (#1459): inconclusive, never a false verdict, never quota spent.
+ it('never probes: validation is inconclusive by design', async () => {
+ const fetch = vi.spyOn(global, 'fetch');
+ const provider = new IteraComputeProvider();
+ expect(provider.supportsKeyValidation).toBe(false);
+ await expect(provider.validateKey('test-key')).rejects.toThrow(/no free credential-validation endpoint/i);
+ // The probe must never hit the network: no free credential endpoint exists.
+ expect(fetch).not.toHaveBeenCalled();
+ });
+});
+
+describe('iteracompute chat', () => {
+ it('forwards OpenAI-shape completions with attribution', async () => {
+ const fetch = vi.spyOn(global, 'fetch').mockResolvedValue(json(completion('qwen/qwen3.8-27b')));
+ const result = await new IteraComputeProvider().chatCompletion('test-key', [{ role: 'user', content: 'Hi' }], 'qwen/qwen3.8-27b', { max_tokens: 512 });
+ expect(fetch.mock.calls[0][0]).toBe(`${ITERACOMPUTE_BASE_URL}/chat/completions`);
+ expect(JSON.parse(String(fetch.mock.calls[0][1]?.body))).toMatchObject({ model: 'qwen/qwen3.8-27b', max_tokens: 512 });
+ expect(result.choices[0].message.content).toBe('OK');
+ expect(result._routed_via).toEqual({ platform: 'iteracompute', model: 'qwen/qwen3.8-27b' });
+ });
+
+ // A bad key is only discovered at request time (validation is off), so the
+ // 401 must surface as an invalid-key verdict through the normal error path.
+ it('surfaces the live 401 invalid_api_key shape as an upstream error', async () => {
+ vi.spyOn(global, 'fetch').mockResolvedValue(json({ error: { message: 'IteraCompute authentication failed', type: 'authentication_error', code: 'invalid_api_key' } }, 401));
+ await expect(new IteraComputeProvider().chatCompletion('bad-key', [{ role: 'user', content: 'Hi' }], 'qwen/qwen3.8-27b'))
+ .rejects.toMatchObject({ status: 401 });
+ });
+
+ // Full/timed-out free queues answer 429 + Retry-After per the free-tier
+ // terms; the status must reach the fallback loop intact.
+ it('surfaces a 429 queue rejection as a retryable upstream error', async () => {
+ vi.spyOn(global, 'fetch').mockResolvedValue(json({ error: { message: 'queue full' } }, 429));
+ await expect(new IteraComputeProvider().chatCompletion('test-key', [{ role: 'user', content: 'Hi' }], 'qwen/qwen3.8-27b'))
+ .rejects.toMatchObject({ status: 429 });
+ });
+});
diff --git a/server/src/lib/key-parser.ts b/server/src/lib/key-parser.ts
index cf3128a1..03f8f00c 100644
--- a/server/src/lib/key-parser.ts
+++ b/server/src/lib/key-parser.ts
@@ -49,6 +49,7 @@ export const PREFIX_MAP: Record<string, string> = {
BEATAPI_: 'beatapi',
APINEX_: 'apinex',
ONOMEO_: 'onomeo',
+ ITERACOMPUTE_: 'iteracompute',
BEAT_API_: 'beatapi',
SERPSEARCH_: 'serpsearch',
SERP_SEARCH_: 'serpsearch',
@@ -166,6 +167,7 @@ export const AUTH_JSON_PROVIDER_MAP: Record<string, string> = {
beatapi: 'beatapi',
apinex: 'apinex',
onomeo: 'onomeo',
+ iteracompute: 'iteracompute',
serpsearch: 'serpsearch',
typhoon: 'typhoon',
plugsky: 'plugsky',
diff --git a/server/src/providers/index.ts b/server/src/providers/index.ts
index 4f992d85..409a30e7 100644
--- a/server/src/providers/index.ts
+++ b/server/src/providers/index.ts
@@ -41,6 +41,7 @@ import { LogfareProvider } from './logfare.js';
import { BeatApiProvider } from './beatapi.js';
import { ApinexProvider } from './apinex.js';
import { OnomeoProvider } from './onomeo.js';
+import { IteraComputeProvider } from './iteracompute.js';
import { SerpSearchProvider } from './serpsearch.js';
const providers = new Map<Platform, BaseProvider>();
@@ -88,6 +89,9 @@ register(new MoondreamProvider());
register(new BeatApiProvider());
register(new ApinexProvider());
register(new OnomeoProvider());
+// IteraCompute (#1649): free OpenAI-compatible gateway, one account-wide
+// monthly token allowance; no free credential probe (see adapter docs).
+register(new IteraComputeProvider());
register(new SerpSearchProvider());
// Free-plan grants are shared wallets, not free credits per model. Eligibility
diff --git a/server/src/providers/iteracompute.ts b/server/src/providers/iteracompute.ts
new file mode 100644
index 00000000..0397466c
--- /dev/null
+++ b/server/src/providers/iteracompute.ts
@@ -0,0 +1,42 @@
+import type { KeyValidationResult } from './base.js';
+import { OpenAICompatProvider } from './openai-compat.js';
+
+export const ITERACOMPUTE_BASE_URL = 'https://api.iteracompute.com/v1';
+
+/**
+ * IteraCompute (#1649): an OpenAI-compatible gateway whose free tier is one
+ * account-wide monthly TOKEN allowance — 30M tokens (input + output, reasoning
+ * included) per account, 160,000 TPM, resetting at 00:00 UTC on the 1st with
+ * no rollover and no paid overage (free-tier terms, Oct 2026). The free model
+ * published today is `qwen/qwen3.8-27b` (`is_free: true`, zero prices on the
+ * public model list; the paid rows share the key, so the 30-day free gate and
+ * the signed catalog decide what actually routes here).
+ *
+ * Key validation is deliberately OFF (mirrors freeai #1459): `GET /models` is
+ * anonymous — a bogus `Authorization` header still returns 200 (verified live
+ * 2026-10-22) — and the only authenticated endpoint is `/chat/completions`,
+ * which reserves against the monthly allowance on every request (the terms
+ * say requests reserve their maximum usage before settling). A health probe
+ * would therefore either prove nothing or burn user quota, so validity is
+ * established by the first served request instead (markKeyHealthyFromRequest).
+ * A real call with a bad key does answer `401 authentication_error
+ * invalid_api_key`, which is what fails it over at request time.
+ */
+export class IteraComputeProvider extends OpenAICompatProvider {
+ constructor() {
+ // Free capacity is shared and queues at peak times (429 + Retry-After when
+ // full), so the first byte can be slower than the 60s compat default.
+ super({ platform: 'iteracompute', name: 'IteraCompute', baseUrl: ITERACOMPUTE_BASE_URL, timeoutMs: 120_000 });
+ }
+
+ override get supportsKeyValidation(): boolean {
+ return false;
+ }
+
+ override async validateKey(_apiKey: string): Promise<KeyValidationResult> {
+ // No endpoint distinguishes genuine from bogus keys for free: /models
+ // ignores credentials, /chat/completions reserves monthly allowance.
+ // Throw so the health pass keeps the key's current state unknown.
+ throw new Error('IteraCompute has no free credential-validation endpoint; key validity is unknown (no quota spent)');
+ }
+}
diff --git a/server/src/routes/keys.ts b/server/src/routes/keys.ts
index 0e8110b1..aadccb3e 100644
--- a/server/src/routes/keys.ts
+++ b/server/src/routes/keys.ts
@@ -65,6 +65,7 @@ const PLATFORMS = [
'beatapi',
'apinex',
'onomeo',
+ 'iteracompute',
'serpsearch',
'freeai',
'google', 'groq', 'cerebras', 'sail', 'electronhub', 'experiential', 'router9', 'septor', 'clod', 'speechify', 'blaze', 'lucidity', 'airforce', 'dreamprompting', 'waterfall', 'logfare', 'bai', 'radeon', 'nvidia', 'mistral',
diff --git a/server/src/services/provider-quota.ts b/server/src/services/provider-quota.ts
index d5df50d5..da9c12c9 100644
--- a/server/src/services/provider-quota.ts
+++ b/server/src/services/provider-quota.ts
@@ -122,6 +122,9 @@ export function inferPoolForPlatform(platform: Platform, modelId?: string | null
// onomeo: one 30-calls/5-hour account allowance across every free model,
// so one pool (issue #1460).
if (platform === 'onomeo') return 'onomeo::five-hour-free';
+ // IteraCompute: one 30M-token monthly account allowance across every free
+ // model (input + output combined), so one pool (issue #1649).
+ if (platform === 'iteracompute') return 'iteracompute::monthly-free';
if (platform === 'plugsky') return 'plugsky::fair-use';
if (platform === 'inferbase') return 'inferbase::managed-free';
if (platform === 'simplellm') return 'simplellm::free';
@@ -186,6 +189,7 @@ export function inferPoolForPlatform(platform: Platform, modelId?: string | null
function isSharedPool(platform: Platform): boolean {
if (platform === 'apinex') return true;
if (platform === 'onomeo') return true;
+ if (platform === 'iteracompute') return true;
if (platform === 'aclide') return true;
if (platform === 'speka') return true;
if (platform === 'plugsky') return true;
diff --git a/shared/types.ts b/shared/types.ts
index 08409bf5..fa2b14f9 100644
--- a/shared/types.ts
+++ b/shared/types.ts
@@ -79,6 +79,9 @@ export type Platform =
// OpenAI-compatible gateway; free models share a 30-calls/5-hour account
// allowance on top of a site-wide pool (issue #1460).
| 'onomeo'
+ // OpenAI-compatible gateway; the free tier is one account-wide monthly
+ // token allowance (30M, resets monthly; issue #1649).
+ | 'iteracompute'
// Ongoing free research API for chat and speech recognition; catalog only.
| 'typhoon'
// Permanent free chat aliases, shared fair-use quota; signed catalog only.