Skip to content

Add per-provider custom API URL configuration in AI Providers UI#132

Open
Copilot wants to merge 4 commits intomainfrom
copilot/add-custom-url-api-menu
Open

Add per-provider custom API URL configuration in AI Providers UI#132
Copilot wants to merge 4 commits intomainfrom
copilot/add-custom-url-api-menu

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented May 8, 2026

The AI Providers flow only supported fixed provider base URLs. This update adds provider-level API URL editing so users can point each provider to custom endpoints while keeping default URLs as the initial value.

  • Provider configuration UI

    • Added an API URL input to ProviderDetailScreen.
    • Prefills from saved provider config (baseUrl) or falls back to provider default (AiProvider.baseUrl).
    • Enforces non-empty URL before save.
  • Persistence + write path updates

    • Extended ProviderConfigService.saveProviderConfig(...) to accept baseUrl.
    • Updated both config write paths (proot Node write + direct fallback write) to persist the user-entered URL instead of always using static provider defaults.
  • Navigation/data wiring

    • ProvidersScreen now passes existing provider baseUrl into ProviderDetailScreen so edits are round-trippable.
await ProviderConfigService.saveProviderConfig(
  provider: widget.provider,
  apiKey: apiKey,
  baseUrl: baseUrl, // user-configurable endpoint
  model: model,
);

Copilot AI linked an issue May 8, 2026 that may be closed by this pull request
Copilot AI changed the title [WIP] Add menu for assigning custom API URLs for AI providers Add per-provider custom API URL configuration in AI Providers UI May 8, 2026
Copilot AI requested a review from mithun50 May 8, 2026 06:55
@mithun50
Copy link
Copy Markdown
Owner

mithun50 commented May 8, 2026

@copilot please study about how the OpenClaw works in that custome api url and key configuration.

Copy link
Copy Markdown
Contributor Author

Copilot AI commented May 8, 2026

@copilot please study about how the OpenClaw works in that custome api url and key configuration.

I reviewed OpenClaw’s provider config behavior and aligned our implementation with its expected shape (models.providers.<provider>.models as [{ id: ... }]). I also updated provider detail prefill to read each provider’s own saved model (instead of always using global active model), with active-model fallback. Addressed in commits dd7cd8a and 519014a.

@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 8, 2026

Build Successful

Version: v1.8.7

Download APKs

Architecture Download
arm64-v8a (recommended) OpenClaw-v1.8.7-arm64-v8a.apk
armeabi-v7a (32-bit) OpenClaw-v1.8.7-armeabi-v7a.apk
x86_64 (emulator) OpenClaw-v1.8.7-x86_64.apk
Universal (all ABIs) OpenClaw-v1.8.7-universal.apk
App Bundle (Play Store) OpenClaw-v1.8.7.aab

Download from Actions Artifacts


Built from db18964 by GitHub Actions

@mithun50 mithun50 marked this pull request as ready for review May 8, 2026 12:18
Copy link
Copy Markdown

@cubic-dev-ai cubic-dev-ai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No issues found across 3 files

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Custom URL API

2 participants