Skip to content
Updates & support on Telegram

Environment variables

Native OpenAI-compatible support

Gemini CLI against a custom OpenAI-compatible backend

Gemini CLI can target a custom endpoint through its environment configuration. Point it at the gateway to run its loop on this catalog.

Base URL

https://uncensoredai.dev/v1

  1. 01

    Set the endpoint

    Export the base URL and key before starting the CLI. The /v1 suffix is required.

    macOS / Linux
    export OPENAI_BASE_URL="https://uncensoredai.dev/v1"
    export OPENAI_API_KEY="sk-ua-XXXX-XXXX-XXXX-XXXX"
    gemini --model deepseek-v4.1-flash
    Windows (PowerShell)
    $env:OPENAI_BASE_URL = "https://uncensoredai.dev/v1"
    $env:OPENAI_API_KEY = "sk-ua-XXXX-XXXX-XXXX-XXXX"
    gemini --model deepseek-v4.1-flash
  2. 02

    Confirm the model

    If the CLI rejects the model, check that the id exists in the catalog and that you did not add a provider prefix.

Commands and configuration below are shown exactly as the tool expects them, so they stay in English.

FAQ

Does the CLI keep its own tools?+

Yes. File editing and shell tools run locally; only the model calls go to the gateway.

Which tier suits long sessions?+

A large-context model such as gpt-6-sol or kimi-k3.

More integrations

Gemini CLI Custom Endpoint — Setup Guide · UncensoredAI