CLI: Configuration

The Keito CLI loads configuration from environment variables and a local config.toml file.

Config File Location

keito auth login writes to the platform config directory:

OS Path
macOS ~/Library/Application Support/keito/config.toml
Linux ~/.config/keito/config.toml
Windows %APPDATA%\keito\config.toml

On Unix-like systems, the CLI writes the config directory as 0700 and the config file as 0600.

Config Shape

api_key = "kto_xxxxx"
account_id = "company_id_here"
workspace_id = "company_id_here" # legacy alias

# Optional. Defaults to the production API.
api_url = "https://app.keito.ai"

workspace_id is a legacy alias for account_id. New setup should use account_id.

Production API

The default API URL is:

https://app.keito.ai

The CLI sends API v2 requests under /api/v2. Only set api_url when testing against a non-production Keito environment.

Environment Variables

Variable Description
KEITO_API_KEY kto_... API key; overrides config
KEITO_ACCOUNT_ID Company ID sent as Keito-Account-Id
KEITO_WORKSPACE_ID Legacy alias for KEITO_ACCOUNT_ID

Precedence

API key:

  1. KEITO_API_KEY
  2. api_key in config.toml

Account/company ID:

  1. --workspace
  2. KEITO_ACCOUNT_ID
  3. KEITO_WORKSPACE_ID
  4. account_id in config.toml
  5. workspace_id in config.toml

Global Flags

Flag Description
--json Force JSON output
--workspace <id> Override the Company ID for one invocation
--quiet Suppress non-essential output
--verbose Enable debug logging
--help Show command help
--version Show CLI version

When stdout is piped, the CLI automatically uses JSON output. Use --json to force JSON in a terminal.

Unsupported Config Commands

The current production CLI does not include keito config init, keito config set, shell completions, or project-level .keito.toml defaults.