Skip to content

Use Goose with amazee.ai

Goose is an open-source AI agent by Block that automates coding tasks from your terminal or desktop. Connect it to amazee.ai to run Goose through your regional endpoint with full data residency and budget controls.

Prerequisites


Option 1 — Use the built-in OpenAI provider

Goose's built-in OpenAI provider supports custom endpoints, so you can point it directly at amazee.ai.

Goose Desktop

  1. Open the sidebar and go to Settings
  2. Under Model Provider, select OpenAI
  3. Fill in:
Field Value
API Key your amazee.ai API key
Host https://llm.[your-region].amazee.ai
  1. Set your model to claude-sonnet-4-5 (or any model from Available Models)
  2. Click Submit

Goose CLI

Run the configuration command:

goose configure
  1. Select Configure Providers
  2. Choose OpenAI as the provider
  3. Enter your amazee.ai API key when prompted for OPENAI_API_KEY
  4. Enter https://llm.[your-region].amazee.ai when prompted for OPENAI_HOST
  5. Leave OPENAI_BASE_PATH as the default (v1/chat/completions)
  6. Enter your preferred model (e.g. claude-sonnet-4-5)

Replace [your-region] with your region code (e.g. ch103, us103, de103).


Option 2 — Add a custom provider

Custom providers let you give the connection a friendly name (e.g. "amazee.ai") and store a list of preferred models. This is useful if you switch between multiple endpoints.

Goose CLI

goose configure
  1. Select Configure Providers
  2. Select Add A Custom Provider
  3. Fill in the prompts:
Prompt Value
API Type OpenAI Compatible
Name amazee.ai (or any display name)
API URL https://llm.[your-region].amazee.ai/v1
Authentication Required Yes
API Key your amazee.ai API key
  1. Enter your preferred model (e.g. claude-sonnet-4-5)

Config file

You can also create the provider config file directly. Save this as ~/.config/goose/custom_providers/amazeeai.json (macOS/Linux) or %APPDATA%\Block\goose\config\custom_providers\amazeeai.json (Windows):

{
  "type": "openai",
  "display_name": "amazee.ai",
  "description": "amazee.ai regional AI gateway",
  "api_key_env": "AMAZEEAI_API_KEY",
  "base_url": "https://llm.[your-region].amazee.ai/v1",
  "models": [
    "claude-sonnet-4-5",
    "claude-haiku-4-5",
    "claude-opus-4"
  ]
}

Then set your API key as an environment variable in your shell profile (~/.zshrc, ~/.bashrc):

export AMAZEEAI_API_KEY="your-api-key-here"

Verify

Start a Goose session and give it a simple task:

goose
goose> list the files in this directory

Check my.amazee.ioUsage to confirm requests are flowing through your amazee.ai endpoint.


Troubleshooting

Auth errors : Verify your API key is correct. For Option 1, check that OPENAI_API_KEY is set. For Option 2, check the environment variable named in api_key_env is exported.

Model not found : Use the exact model ID from Available Models. Goose does not auto-complete model names for custom endpoints.

Connection errors : Make sure the host URL includes your region code and uses https://. For the custom provider config, the base_url should end with /v1.

Tool calling not working : Goose relies on tool calling support. Use Claude models (Sonnet, Haiku, Opus) which have full tool calling support through amazee.ai.