Free.ai Docs
in Amasogonda.
OpenAI-compatible chat API. One Bearer token, 477 tools. Run this curl, then read on.
curl https://api.free.ai/v1/chat/ \
-H "Authorization: Bearer sk-free-YOUR-KEY" \
-H "Content-Type: application/json" \
-d '{"model":"qwen2.5-7b","messages":[{"role":"user","content":"Hello!"}]}'
Kuri?
Gutangira
Chat
POST /v1/chat/
{
"model": "qwen2.5-7b",
"messages": [
{"role": "user", "content": "Hello!"}
]
}
Ishusho
POST /v1/image/generate/
{
"model": "flux",
"prompt": "a quiet cabin at dusk",
"width": 1024,
"height": 1024
}
Guhindura Ishusho
POST /v1/image/edit/
multipart:
image: <file>
prompt: "remove the chair"
operation: "edit"
Kuri
POST /v1/tts/
{
"model": "kokoro",
"voice": "af_heart",
"text": "Hello there!"
}
Kuri Umwandiko
POST /v1/stt/
multipart:
audio: <file>
model: "whisper-large-v3"
language: "auto"
Guhindura
POST /v1/translate/
{
"text": "Hello",
"target_lang": "es"
}
SDKs
Inyandikonyakwirema
Ibibazo bizwa kenshi
Hejuru Ku /, Ibaruwa, na Gufungura / Konti: /? tab =. na A Urufunguzo (- -). - ya: Umutekano Twebwe Kugaragaza: i Byuzuye Urufunguzo Rimwe.
/ v1 / / i Ishusho: []. Ubutumwa. Ibikubiyemo ya: i Umwandiko, Birenzeho A Ikoresha: Igikoresho. + Ishusho Gusubiramo A Imyandikire: Na: Ibisohoka URL:, Gusangiza URL:, na.
-: nibyo ku. Nka - Na: i Ibyatanzwe: {...} Nka i Porotokole. Iheruka Ubutumwa ni Ibyatanzwe: [].
. A Ibikoresho Porogaramu i Ibikoresho - Igishushanyo. - - Guhamagara: Gusubiramo; - Gusubiramo Kuri A - Ubwoko i Ishusho.
. - Gucanaho Udushushondanga Kwemera Ishusho URL Ibigize (Cyangwa)., Ijwi Nka Ifishi - Ibyatanzwe Kuri / v1 /., Koresha / v1 / PDF / Kuri na Bigyanye i Igisubizo.
A & Ukwezi: & Ubutumwa Kuri Imishinga (1, Kigenga, 1,). Oya - ISEGONDA. & Ku munsi Kigenga Kuri Urubuga, OYA.
freeai-code on npm + PyPI for our Coder IDE wrapper. For the raw API, the OpenAI SDKs (Python + Node) and most LLM frameworks (LangChain, LlamaIndex, Vercel AI SDK) work - set base_url to https://api.free.ai/v1 and your Bearer key.
Shyiraho Umukono buri Na: - KURI i Kigaragara Gihinguranya. Isinya ni in i - - Umutwe: (-). Icyo ari cyo cyose Isinya OYA BIHUYE (,).
{error:{message, type, code}}. 402 = out of credits (response includes upgrade URL + shortfall in tokens). 429 = daily pool exhausted (web only). 400 = validation error. 5xx = our problem; retry with exponential backoff.
/ v1 / / Impera Akadomo i Kubaza... Igishushanyo na i Ishusho. Umukiriya Inyandikoporogaramu ku Kabiri Imirongo - +.
Yes - every self-hosted model is open-source (Apache 2.0 / MIT). Our gpu_api repo is public; clone it, supply your GPU, and run the same inference stack. For a managed private cloud install, contact us.
Self-hosted models run free on your 30,000-token daily pool, then bill the raw token count. Premium models are pay-as-you-go: 1.50× retail markup, dropping to 1.30× at $500/30d and 1.15× at $2,000/30d. Live cost is on every model page and on every API response; token top-ups start at $1.