Skip to content

Use Mistral in your terminal

Use Mistral models with your own key. You pay Mistral directly; kunji never sees your bill.

  1. Create an API key at https://console.mistral.ai/api-keys.
  2. Run kunji keys add mistral and paste the key. kunji checks it works, then stores it in your OS keychain.
  3. Pick a default model from the list (type to search).
  4. Run kunji and start chatting.
Provider id mistral
Type OpenAI-compatible API
API address https://api.mistral.ai/v1
Key variable MISTRAL_API_KEY
Terminal window
kunji models mistral # see available models
kunji use mistral:<model> # make one your default
kunji chat -m mistral:<model> # or chat with it once

Inside a chat, switch to it with /model mistral:<model>; the conversation carries over.

For CI or scripts you can skip the keychain:

Terminal window
export MISTRAL_API_KEY=your-key-here
kunji ask -m mistral:<model> "Hello"