Repolode
looplj

looplj/axonhub

Open-source AI gateway that lets any OpenAI or Anthropic SDK call 100+ LLM providers without code changes, with failover, load balancing and cost tracking.

Open-source alternative to:OpenRouter

Stars
5,379
Forks
738
Open issues
97
Last commit
13 hours ago

What is it?

AxonHub is an AI gateway that sits between your application and model providers. Applications keep using their existing OpenAI, Anthropic or other AI SDK, and AxonHub converts each request into the format expected by the target provider. Switching from GPT-4 to Claude or Gemini is done through configuration rather than rewriting client code.

Beyond protocol translation, the project adds operational features: automatic failover and load balancing across channels, per-request tracing with a full timeline, and tracking of input, output and cached tokens to show the cost of each call. It also includes role-based access control, usage quotas and data isolation for teams.

The gateway supports text generation, image generation, embedding and rerank APIs. Its provider list includes OpenAI, Anthropic, Gemini, DeepSeek, Zhipu, Moonshot, Doubao and OpenRouter, and it can be deployed with Docker. The project is written in Go and licensed under Apache-2.0 with some components under LGPL-3.0.

Key features

  • 01Call OpenAI, Anthropic and Gemini-style APIs through a single endpoint with existing SDKs.
  • 02Automatic failover and load balancing across configured channels.
  • 03Per-request tracing with a timeline for debugging.
  • 04Cost tracking for input, output and cached tokens.
  • 05Role-based access control, quotas and data isolation.
  • 06Supports chat, image generation, embedding and rerank APIs.

Use cases

  • Teams that want to switch between LLM providers without changing application code.
  • Platforms that need usage quotas, cost visibility and access control for multiple users.
  • Applications requiring automatic failover when a model provider is unavailable.
  • Developers running AI coding tools such as Claude Code or Codex through a shared gateway.

Quick start

  1. 1

    Deploy AxonHub by having your agent follow the deploy-axonhub skill

  2. 2

    Open the AxonHub URL, create the admin account, then add channels with your provider API keys

  3. 3

    Create an AxonHub API key in the API Keys section for your clients

  4. 4

    Point the OpenAI SDK at http://localhost:8090/v1 and send a first chat request

Things to know

  • The README gives no direct install command; deployment is described through an agent skill.
  • You must supply your own API keys for each upstream model provider.
  • AWS Bedrock and Google Cloud support is still marked as testing.

Topics

FAQ

What is axonhub?
Open-source AI gateway that lets any OpenAI or Anthropic SDK call 100+ LLM providers without code changes, with failover, load balancing and cost tracking. AxonHub is an AI gateway that sits between your application and model providers. Applications keep using their existing OpenAI, Anthropic or other AI SDK, and AxonHub converts each request into the format expected by the target provider. Switching from GPT-4 to Claude or Gemini is done through configuration rather than rewriting client code.
Is axonhub free to use? What license does it have?
axonhub is open source under the Apache-2.0 license. Check the license terms before using it in commercial products.
Is axonhub still maintained?
Actively maintained. The last commit to axonhub was on Oct 21, 2026.
What can I use axonhub for?
Teams that want to switch between LLM providers without changing application code. Platforms that need usage quotas, cost visibility and access control for multiple users. Applications requiring automatic failover when a model provider is unavailable. Developers running AI coding tools such as Claude Code or Codex through a shared gateway.
How do I install axonhub?
Deploy AxonHub by having your agent follow the deploy-axonhub skill Open the AxonHub URL, create the admin account, then add channels with your provider API keys Create an AxonHub API key in the API Keys section for your clients Point the OpenAI SDK at http://localhost:8090/v1 and send a first chat request
Where can I get axonhub?
The source code and installation instructions are on GitHub: https://github.com/looplj/axonhub

Summary generated by AI from the project's README. GitHub stats refresh daily.

Related projects