Skip to content

500 error when configuring Mistral AI API key #3937

Closed

Description

@bekossy

Configuring the Mistral AI provider fails with a backend 500 error and the API key cannot be saved.

Steps to reproduce:

  • Go to Settings
  • Open Models
  • Click Configure now for Mistral AI
  • Enter API key
  • Click Confirm

Request payload:

{
  "header": {
    "name": "Mistral AI",
    "description": ""
  },
  "secret": {
    "kind": "provider_key",
    "data": {
      "provider": {
        "key": "TEST_KEY"
      }
    }
  }
}

Screenshot 2026-03-09 at 10.00.50 AM.png

Activity

  1. self-assigned this
    on Mar 9, 2026
  2. linear commented on Mar 9, 2026

    @linear
  3. dosubot commented on Mar 9, 2026

    @dosubot

    This looks like a potential backend validation or configuration issue. A few things to check:

    Most likely cause: There may be a payload structure mismatch between what the frontend sends and what the backend expects. The validator logic expects a nested structure (data["provider"]["key"]), but test fixtures show a flat structure like {"provider": "openai", "key": "sk-xxx"}.

    Other potential causes:

    To investigate further: Check the backend logs for the specific error details - all exceptions are logged with a support_id that would help pinpoint the exact failure.

    There's also a related UI bug (AGE-3443) where provider configurations incorrectly default to Mistral AI.

    To reply, just mention @dosu.


    Docs are dead. Just use Dosu.

    Leave Feedback Ask Dosu about agenta Share Dosu with your team

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

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions