Skip to content

[Bug] Onboard UI fails to overwrite existing provider configurations #38657

@Fa1eon

Description

@Fa1eon

Bug type

Behavior bug (incorrect output/state without crash)

Summary

When attempting to update an existing model provider configuration through the Onboard UI, the changes are not persisted to the configuration files. The UI appears to save successfully, but the underlying JSON files retain the original (potentially incorrect) values. This forces users to manually edit multiple configuration files to correct any mistakes.

Steps to reproduce

  1. Open Onboard UI (e.g., openclaw onboard or web interface)
  2. Add a new model provider (e.g., Moonshot) with configuration:
    • API Key: sk-xxxxxxxx
    • Base URL: https://api.moonshot.cn/v1 (or an incorrect URL)
  3. Save the configuration
  4. Attempt to modify the same provider (e.g., correct the Base URL or API Key)
  5. Save again
  6. Check configuration files - changes are not reflected

Expected behavior

Onboard UI should overwrite existing provider configurations when saving changes, or provide a clear indication that the provider already exists and offer an update option.

Actual behavior

  • Onboard UI shows no error message
  • Configuration appears to save successfully
  • However, the following files retain original values:
    1. ~/.openclaw/agents/<agent>/agent/auth-profiles.json
    2. ~/.openclaw/agents/<agent>/agent/models.json
    3. ~/.openclaw/config/openclaw.json

OpenClaw version

2026.3.2

Operating system

macOS 15.4 (Darwin 24.6.0 arm64)

Install method

Homebrew

Logs, screenshots, and evidence

Impact and severity

Affected: All users who need to update existing model provider configurations through Onboard UI

Severity: Medium-High (blocks workflow for configuration corrections)

Frequency: 100% reproducible when attempting to update existing providers

Consequence:

  • Users cannot correct configuration mistakes through the UI
  • Forces manual editing of multiple JSON files
  • Requires technical knowledge to locate and edit configuration files
  • Poor user experience for a core configuration workflow
  • Users must restart gateway manually after editing files

Additional information

Scope

  • Confirmed affected: Moonshot provider
  • Status of other providers: Unknown (not tested)

Workaround

Manual editing of configuration files:

# Edit the three affected files
nano ~/.openclaw/agents/main/agent/auth-profiles.json
nano ~/.openclaw/agents/main/agent/models.json
nano ~/.openclaw/config/openclaw.json

# Restart gateway to apply changes
openclaw gateway restart

Suggested Fixes

  1. Preferred: Onboard UI should detect existing provider configurations and overwrite them on save
  2. Alternative: Show dialog asking "Provider already exists. Update existing configuration?"
  3. Minimum: Display error message if configuration cannot be updated

Context

This issue was discovered when attempting to correct an incorrect Base URL for the Moonshot provider. The initial configuration error could not be fixed through the UI, requiring manual intervention.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingbug:behaviorIncorrect behavior without a crash

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions