AltimateAI / AltimateAI/altimate-code

feat: support custom endpoint and bearer token configuration in TUI

Offen
#675 0 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
Vorherrschende Sprache
TypeScript
Sterne
811
Forks
134
Ø Merge
3 T. 2 Std.
Gemergte PRs (30 T.)
50

Beschreibung

## Problem

Configuring a custom gateway endpoint (e.g. for Amazon Bedrock behind a corporate proxy) currently requires manually editing `~/.config/altimate-code/altimate-code.json` and setting `AWS_BEARER_TOKEN_BEDROCK` as an environment variable or running `providers login` from the CLI.

This is friction for customers who expect to configure everything from within the TUI.

## Proposal

Add TUI flows for:

1. **Custom endpoint configuration** — When selecting or configuring the `amazon-bedrock` provider, allow the user to enter a custom `baseURL`/`endpoint` directly in the TUI. This should write to the global config (`provider.amazon-bedrock.options.baseURL`).

2. **Bearer token entry** — Allow entering the `AWS_BEARER_TOKEN_BEDROCK` token from a TUI prompt (similar to how `providers login` works on the CLI, but accessible from within an active TUI session).

## Context

Customers using custom LLM gateways on top of Bedrock (e.g. `https://api./claude-code-aws-bedrock/v1`) currently need to:
- Manually create/edit `altimate-code.json` with the correct `provider.amazon-bedrock.options.baseURL`
- Set `AWS_BEARER_TOKEN_BEDROCK` in their shell profile or run `altimate-code providers login -p amazon-bedrock` separately

This is especially painful for first-time setup where the user hasn't created a config file yet.

## Relevant Code

- Provider handler: `packages/opencode/src/provider/provider.ts` (line 301, `"amazon-bedrock"` handler)
- Config schema: `packages/opencode/src/config/config.ts` (line 1008, provider options)
- CLI login: `packages/opencode/src/cli/cmd/providers.ts` (line 250, `ProvidersLoginCommand`)
- Auth storage: `packages/opencode/src/auth/service.ts`

Beitragsleitfaden

Beitragsleitfaden öffnen

Bewertung

Dieses Issue wurde noch nicht bewertet.

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.