y13sint/FreeQwenApi

Локальный API-прокси для Qwen AI с поддержкой сохранения контекста диалогов и управления сессиями через REST API

What it solves

FreeQwenApi gives you a local API endpoint that speaks OpenAI's language while using your own Qwen Chat web account as the backend. Instead of paying for an official Qwen API or running a heavy local model, you simply log into Qwen Chat once, and the proxy translates incoming OpenAI-style requests into calls that Qwen Chat understands. This lets you use all the tools you already have (like Open WebUI, LiteLLM, or custom scripts) with Qwen's models, including text, image, and video generation.

How it works

It's a browser-based proxy, not a local model. When you run npm run auth, a Chromium browser opens so you can sign in to Qwen Chat. The session is saved locally, and the server runs on http://localhost:3264/api. Every request to that address is passed through to Qwen Chat using your logged-in session. The proxy supports standard endpoints like /api/chat/completions, /api/images/generations, and /api/videos/generations, and it can handle multiple Qwen accounts for automatic round-robin rotation when one hits its limits.

Who it’s for

This is for developers and tinkerers who want to use Qwen Chat's models programmatically without an official API key. It's especially handy for people who already use OpenAI-compatible tools and want to point them at Qwen. The README shows examples for Open WebUI, Hermes Agent, LiteLLM, and Claude Code, so it's suitable for local AI agents and custom workflows.

Highlights

  • Chat Completions API – compatible with the OpenAI SDK, Open WebUI, LiteLLM, and agents.
  • Image and video generation – through Qwen Chat, with no need for a DashScope key.
  • Multi-account support – add, relogin, remove, and rotate across accounts automatically when limits are hit.
  • File uploads – an endpoint for sending files and attachments to Qwen.
  • Open WebUI integration – works as an OpenAI-compatible backend.
  • Hermes / LiteLLM / Claude Code examples – ready-made configs for local agents.
  • Docker support – containerised setup with volume mounts for sessions, logs, and uploads.
  • Health and model sync commands – npm run smoke, npm run models:sync, and status endpoints.

Related

  • Project
  • Project
  • Project
  • Project