I am using Mistral Medium 3.5 with OpenCode for your AI Coding Crash Course
Host: api.mistral.ai
Wire Format: REST API (JSON over HTTPS)
Command:
curl -X POST https://api.mistral.ai/v1/chat/completions \
-H "Authorization: Bearer $MISTRAL_API_KEY" \
-H "Content-Type: application/json" \
-d '{"model": "mistral-medium-3.5", "messages": [{"role": "user", "content": "Your prompt here"}]}'
OpenCode supports any OpenAI-compatible endpoint, and Mistral Medium 3.5 is fully OpenAI-compatible. This means you can use the Mistral API endpoint (https://api.mistral.ai/v1/chat/completions) and model ID (mistral-medium-3.5) directly in OpenCode by configuring it as a custom OpenAI-compatible provider. The wire format is REST API (JSON over HTTPS), and authentication is via a Bearer token in the Authorization header.
In OpenCode, you would typically add a custom provider with:
Base URL: https://api.mistral.ai/v1
Model: mistral-medium-3.5
API Key: Your Mistral API key
This setup is confirmed to work by the OpenCode community and documentation
I am using Mistral Medium 3.5 with OpenCode for your AI Coding Crash Course
Host: api.mistral.ai
Wire Format: REST API (JSON over HTTPS)
Command:
OpenCode supports any OpenAI-compatible endpoint, and Mistral Medium 3.5 is fully OpenAI-compatible. This means you can use the Mistral API endpoint (https://api.mistral.ai/v1/chat/completions) and model ID (mistral-medium-3.5) directly in OpenCode by configuring it as a custom OpenAI-compatible provider. The wire format is REST API (JSON over HTTPS), and authentication is via a Bearer token in the Authorization header.
In OpenCode, you would typically add a custom provider with:
Base URL: https://api.mistral.ai/v1
Model: mistral-medium-3.5
API Key: Your Mistral API key
This setup is confirmed to work by the OpenCode community and documentation