Skip to content

feat(providers): add Mistral (Vibe Code + La Plateforme API budgets) - #226

Open
atostivint wants to merge 2 commits into
CodeZeno:mainfrom
atostivint:feat/mistral-provider
Open

atostivint wants to merge 2 commits into
CodeZeno:mainfrom
atostivint:feat/mistral-provider

Conversation

@atostivint

Copy link
Copy Markdown

Adds Mistral as the 8th usage provider.

  • Poller: GET https://api.mistral.ai/v1/billing/budget (Bearer + x-api-key); vibe_budget -> weekly row (label Vibe), api_budget -> monthly row (label API), both with the month-end reset_at
  • Credentials: MISTRAL_API_KEY env, then Vibe CLI .env (VIBE_HOME / USERPROFILE), then Windows Credential Manager entries written by vibe --setup (ai.mistral.vibe); secrets never logged
  • UI: show_mistral setting, 14 locales, official Mistral pixel-M brand mark (U+F008) in brand-marks.ttf, context-menu item (cmd 67), studio helper expressions
  • Themes: provider rows + tray icon surfaces with Mistral red #FF4A00, incl. segmented bars for both Vibe and API budgets, in classic-usage-widget / classic-vertical / compact-fluent-quad
  • Docs: README, USER_GUIDE, CHANGELOG

Tests: 629 passed / 0 failed (cargo-bg test --release). Live-tested on Windows with a real Vibe sign-in (widget shows API % and Vibe % with the month-end reset).

New 8th provider Mistral (ProviderId::Mistral = 7, key mistral, native menu cmd 67, disabled by default).

Poller src/poller/mistral.rs reads GET https://api.mistral.ai/v1/billing/budget (Bearer + x-api-key): vibe_budget -> weekly window label Vibe, api_budget -> monthly window label API, both with the API reset_at (calendar month end). Unknown response fields ignored.

Credentials in order: MISTRAL_API_KEY env var; Vibe CLI .env (VIBE_HOME/.env then USERPROFILE/.vibe/.env); Windows Credential Manager targets ai.mistral.vibe and MISTRAL_API_KEY@ai.mistral.vibe as written by vibe --setup. Watch snapshot hashes/metadata only, secrets never logged.

UI: show_mistral setting, mistral_* strings in all 14 locales, brand mark U+F008 in brand-marks.ttf (official Mistral pixel-M from mistral.ai logo SVG), provider-mistral context menu item, mistral in usage_line whitelist, 10 studio helper expressions.

Themes: mistral provider rows and mistral-tray-icon surfaces in classic-usage-widget, classic-vertical, compact-fluent-quad with Mistral red #FF4A00 accent, including segmented progress bars for both Vibe (weekly) and API (monthly) budgets.

Docs: README provider setup and credentials, USER_GUIDE, CHANGELOG. Tests: 629 passed / 0 failed (cargo-bg test --release), incl. 8 new poller::mistral tests and brand-mark rasterization checks.
…t 2026) for brand mark U+F008

Single-path Inkscape outline from Icon-Mistral-Black.svg (Mistral_Brandkit_2026), scaled to match the other brand marks (bbox 21,156-979,840 in 1000upm, hmtx 1000/21). Font stays monochrome: glyph renders in the UI text color (white on dark), verified with white-on-dark and black-on-white previews.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant