TensaHub › free.ai

free.ai

Free self-hosted models without a key (chat, code, vision), 7 model(s) indexed. curl, Python and JavaScript samples, live testing.

Test and rate in the catalog

Type
Provider
Provider
free.ai
Pricing
Free
Keyless access
Yes
Base URL (OpenAI-compatible)
https://api.free.ai/v1
Inputs
Text
Developer rating
Not rated yet
Documentation
https://free.ai

Code samples

cURL

curl https://api.free.ai/v1/chat/completions \
  -H "Content-Type: application/json" \
  -d '{"model":"qwen7b","messages":[{"role":"user","content":"Hello, introduce yourself in one sentence."}]}'

Python

# pip install openai
import os
from openai import OpenAI

client = OpenAI(base_url="https://api.free.ai/v1", api_key="unused")
r = client.chat.completions.create(
    model="qwen7b",
    messages=[{"role": "user", "content": "Hello, introduce yourself in one sentence."}],
)
print(r.choices[0].message.content)

JavaScript

// npm install openai
import OpenAI from 'openai'

const client = new OpenAI({ baseURL: 'https://api.free.ai/v1', apiKey: 'unused' })
const r = await client.chat.completions.create({
  model: 'qwen7b',
  messages: [{ role: 'user', content: 'Hello, introduce yourself in one sentence.' }],
})
console.log(r.choices[0].message.content)

Generate the integration code →

Popular searches

Frequently asked questions

Is the free.ai API free?

Yes: free.ai can be used for free and without an API key, within the provider’s rate limits.

How do I call free.ai from my code?

free.ai exposes an OpenAI-compatible API at https://api.free.ai/v1: use any OpenAI SDK (Python, JavaScript…) with this base URL. Ready-to-use code (streaming, JSON, retries) is available in the developer toolkit.

Alternatives