# Fortytwo Docs > Documentation for the Fortytwo API: OpenAI-compatible chat completions on open-weight models. Guides, models and pricing, API reference and legal documents. - [Fortytwo API](https://docs.fortytwo.network/index.md): OpenAI-compatible chat completions on open-weight models, with zero data retention by default. - [Quickstart](https://docs.fortytwo.network/docs/quickstart.md): Buy credits, create an API key and send your first chat completion. - [Get access](https://docs.fortytwo.network/docs/access.md): Create an API key, send it with each request, and set spend limits. - [OpenAI compatibility](https://docs.fortytwo.network/docs/openai-compatibility.md): Point an OpenAI SDK at the Fortytwo API, and see which fields differ from OpenAI Chat Completions. - [Chat completions](https://docs.fortytwo.network/docs/chat-completions.md): POST /v1/chat/completions: request fields, messages, tool calling, structured output and the response. - [Streaming](https://docs.fortytwo.network/docs/streaming.md): Receive a chat completion as server-sent events: event format, final usage, timeouts and errors. - [Image input](https://docs.fortytwo.network/docs/images.md): Send images in a chat completion, by HTTPS URL or base64 data URL. - [Errors](https://docs.fortytwo.network/docs/errors.md): The error envelope, every code the API returns, and which ones to retry. - [Data handling](https://docs.fortytwo.network/docs/data-handling.md): Zero data retention, no training on customer content, prompt caching, where inference runs and how long records are kept. - [Get help](https://docs.fortytwo.network/docs/support.md): How to reach Fortytwo: which form or address fits which request, and how to recognise official messages. - [Common problems](https://docs.fortytwo.network/docs/support-common-problems.md): What to do when something goes wrong: account, API errors, models, limits, billing, promotional credits and safety. - [Promotional credits](https://docs.fortytwo.network/docs/promotional-credits.md): How promo codes and offers add promotional credits, how they are spent, and where to see them. - [Research papers](https://docs.fortytwo.network/docs/papers.md): Papers and technical reports by Fortytwo on swarm inference and peer-ranked consensus. - [Use Fortytwo with your agent](https://docs.fortytwo.network/agents/index.md): Connect Hermes Agent, Kilo Code, Cline, pi or another AI agent to the Fortytwo API in a few steps, or let your agent set itself up. - [Agent compatibility](https://docs.fortytwo.network/agents/compatibility.md): Which AI agents, editors and chat apps work with the Fortytwo API, what each one needs, and where to find its setup guide. - [Connect Hermes Agent](https://docs.fortytwo.network/agents/hermes-agent.md): Set up Hermes Agent with the Fortytwo API: install the desktop app, add Fortytwo as a custom endpoint and chat with qwen/qwen3.8-27b. Terminal setup included. - [Connect Kilo Code](https://docs.fortytwo.network/agents/kilo-code.md): Set up Kilo Code in VS Code with the Fortytwo API: install the extension, add Fortytwo as a custom OpenAI-compatible provider and select qwen/qwen3.8-27b. - [Connect Cline](https://docs.fortytwo.network/agents/cline.md): Set up Cline in VS Code with the Fortytwo API: install the extension, choose OpenAI Compatible, enter the Fortytwo base URL and key, and select qwen/qwen3.8-27b. - [Connect pi](https://docs.fortytwo.network/agents/pi.md): Set up the pi coding agent with the Fortytwo API: install pi, add Fortytwo to models.json, sign in with your API key and select qwen/qwen3.8-27b. - [Connect Kilo CLI and OpenCode](https://docs.fortytwo.network/agents/kilo-cli.md): Set up Kilo CLI or OpenCode with the Fortytwo API: add Fortytwo as an OpenAI-compatible provider, connect it with /connect and select qwen/qwen3.8-27b. - [Connect Codex through LiteLLM](https://docs.fortytwo.network/agents/codex.md): Use OpenAI Codex CLI with the Fortytwo API: Codex needs the Responses API, so run a local LiteLLM proxy that translates it to Chat Completions. - [Models](https://docs.fortytwo.network/docs/models.md): Each model's ID, capabilities, limits and licence, and how models are retired. - [Pricing](https://docs.fortytwo.network/docs/pricing.md): Prices per model, what is billed, and how credits work. - [Tiers and limits](https://docs.fortytwo.network/docs/limits.md): Tiers, requests per minute and per hour, how a tier is reached, and size and time limits. - [API conventions](https://docs.fortytwo.network/apis/api-reference-intro.md): Base URL, authentication and request IDs for both endpoints. - [Create a chat completion](https://docs.fortytwo.network/apis/chat-completions.md): Generates a response to a conversation, as JSON or as server-sent events. Guide: [Chat completions](/docs/chat-completions). - [List models](https://docs.fortytwo.network/apis/get-models.md): Lists the model IDs the API accepts. Limits and features are on [Models](/docs/models). - [Legal documents](https://docs.fortytwo.network/legal/index.md): The terms, policies and registers that apply to the Fortytwo API and the platform. - [Terms of Service](https://docs.fortytwo.network/legal/terms-of-service.md) - [Privacy Policy](https://docs.fortytwo.network/legal/privacy-policy.md) - [Cookie Policy](https://docs.fortytwo.network/legal/cookie-policy.md) - [Provider Register](https://docs.fortytwo.network/legal/providers.md) - [Third-Party Licences](https://docs.fortytwo.network/legal/third-party-licenses.md) - [Vulnerability Disclosure Policy](https://docs.fortytwo.network/legal/vulnerability-disclosure-policy.md) ## OpenAPI Specs - [fortytwo_openapi](/apis/fortytwo_openapi.json) This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.