Flux for any OpenAI-compatible tool

If your tool asks for a base URL and an API key, it works with Flux. Three values and you are done.

Set it up

  1. Find the setting called base URL, API base, endpoint or OpenAI-compatible provider, and enter these three values.

    text
    Base URL: https://api.fluxrouter.ai/v1
    API key:  sk-YOUR-FLUX-KEY
    Model:    flux-auto
  2. If the tool reads environment variables instead, these two are the most common.

    bash
    export OPENAI_BASE_URL="https://api.fluxrouter.ai/v1"
    export OPENAI_API_KEY="sk-YOUR-FLUX-KEY"

Worked examples

OpenHands

  1. Set the LLM variables. Keep the openai/ prefix on the model so OpenHands uses its OpenAI-compatible driver.

    bash
    export LLM_BASE_URL="https://api.fluxrouter.ai/v1"
    export LLM_API_KEY="sk-YOUR-FLUX-KEY"
    export LLM_MODEL="openai/flux-auto"

llm

  1. Simon Willison’s llm reads custom endpoints from extra-openai-models.yaml. Add an entry, then store your key with llm keys set flux. extra-openai-models.yaml

    extra-openai-models.yaml
    - model_id: flux-auto
      api_base: https://api.fluxrouter.ai/v1
      api_key_name: flux

Plandex

  1. Add a custom provider that points at Flux.

    text
    baseUrl: https://api.fluxrouter.ai/v1
    apiKey: sk-YOUR-FLUX-KEY

Mods

  1. Add an apis entry to your mods config.

    yaml
    apis:
      flux:
        base-url: https://api.fluxrouter.ai/v1
        models:
          flux-auto:
            aliases: ["flux"]

Check the first call

  1. Send "Reply with the word ready." from your tool. A reply means your key, base URL and model are right.

  2. Open Activity in your Flux account to see the call counted against the model that answered and the key that made it.

What your tool gets

What your tool gets through Flux
AbilityTodayHow it reaches your tool
Every major modelLiveAutomatic, through the base URL.
Read a web pageLiveAdd the Flux tools server (below).
Search the webRolling outSwitched on and being checked. Not promised yet.
Make imagesLiveAdd the Flux tools server (below).
SpeakRolling outSwitched on and being checked. Not promised yet.
Transcribe audioNot in agents yetLive on the API for your own code. No agent reaches it yet.
Act in your appsShippingNot live yet. It is on the way.
MemoryShippingNot live yet. It is on the way.
Second opinionRolling outSwitched on and being checked. Not promised yet.

Statuses come from the same record as the abilities on the homepage, so they change everywhere at once.

Add the Flux tools server

Page reading and image making reach a tool through the Flux tools server, an MCP server on the same key. Web search joins it once it is live.

  1. If your tool can add a remote MCP server with a header, add the Flux tools server. Most tools use this shape; check your tool’s docs for the file it reads.

    json
    {
      "mcpServers": {
        "flux-tools": {
          "url": "https://api.fluxrouter.ai/mcp-tools/",
          "headers": {
            "Authorization": "Bearer sk-YOUR-FLUX-KEY"
          }
        }
      }
    }

Good to know

  • flux-auto bills at the Standard rate, or the Fast rate when it sends your request to the Fast lane and a Fast model answers. Never more than Standard. Pin a model and you pay that model’s rate instead.
  • Flux can pick a different model from one request to the next. A prompt cache belongs to one model, so a switch can mean a cache miss. If a long session leans on caching, pin a model.
  • The Flux tools server needs a funded key. Without one, its tools return an error instead of a result.

If it won’t connect

You get a 404 or "not found".
Use https://api.fluxrouter.ai/v1 exactly. The tool adds /chat/completions or /responses itself. If it also adds /v1, drop /v1 from the base so you do not end up with /v1/v1.
Every request comes back 401.
The key is missing or mistyped, or an old provider key is still set and wins. Paste your Flux key again and remove the other key.
The tool rejects the model name.
Some tools only accept names from their own list. Type flux-auto as a custom model if the tool allows it, or pick a flux- lane name it accepts: flux-fast, flux-standard or flux-reasoning.

More fixes: my tool won’t connect.