Applies to: Mattermost Agents plugin (mattermost-ai) v2.x; Mattermost Server v11.x and later
Symptoms: AI bot responses fail and the Agents plugin logs errors repeatedly when a local or self-hosted OpenAI-compatible service is configured without an API key.
🛑 Problem
The Agents plugin requires a non-empty API Key field for every configured AI service, including local and self-hosted OpenAI-compatible services (such as Ollama, LM Studio, LocalAI, or vLLM) that do not require API key authentication. Leaving the field blank causes all model-fetch and inference requests to fail.
Symptoms
Users or administrators experiencing this issue will see:
failed to fetch models: bifrost - no valid keys found for provider: openai
Additional symptoms:
- The model dropdown in System Console > Plugins > Agents does not populate after entering the service URL.
- AI bot users receive no response in channels.
- The error repeats dozens of times per session in
mattermost.log.
âś… Solution
Enter any non-empty placeholder value in the API Key field of the affected AI service. The plugin only checks that the field is populated; it does not validate the key or forward it to the provider. No restart of Mattermost Server or the Agents plugin is required.
Enter a Placeholder API Key
- Navigate to System Console > Plugins > Agents.
- Under AI Services, select the affected service entry (configured as OpenAI Compatible), or click Add an AI Service if none exists.
- In the API Key field, enter any non-empty string:
placeholder
- Click Save.
- Reopen the model dropdown - the list should now load from your provider endpoint.
⚠️ Important: The placeholder value is never forwarded to the provider. It satisfies the plugin's internal field-presence check only. No server or plugin restart is required after saving.
Additional Resources
For more information, see:
Comments
Article is closed for comments.