Skip to content

v0.7.0

Choose a tag to compare

@Magnus-Gille Magnus-Gille released this 19 Aug 07:57
· 100 commits to main since this release
899da83

Fixes two externally reported issues — #95 and #96 — both found by @hedborg running noxctl against a live Fortnox account on Windows 11. Thank you.

Windows fixes

  • OAuth setup was broken on Windows. The browser launch ran cmd /c start <url>, and cmd.exe treats every unescaped & in the query string as a command separator — so Fortnox received the authorization URL truncated at the first parameter and rejected it. Windows now launches through PowerShell Start-Process, and the URL is printed unconditionally on every platform.
  • Saving credentials failed with Unable to find type [System.Security.Cryptography.ProtectedData] on PowerShell configurations that don't preload System.Security.
  • logout --all claimed to remove credentials that were never stored — the Windows delete used fs.rm(..., { force: true }), which resolves for a missing file. Found by the new Windows CI leg.

OAuth scopes

project, costcenter and price were implemented but never requested, so those endpoints returned 403 even with the permissions enabled on your Fortnox app. They're now in the default set.

Offers and orders are opt-in. Fortnox gates the offer and order scopes on the Order licence, and requesting a scope the company isn't licensed for fails the entire authorization — so making them default would lock out Bokföring + Kundfaktura companies. Use noxctl init --with-orders (or FORTNOX_WITH_ORDERS=1), mirroring --with-salary.

The 403 hint also named the wrong scope for offers, orders and both payment families, and noxctl doctor / fortnox_status counted scopes they never actually probed.

Upgrading

Existing installations are unaffected until you re-run noxctl init — credentials renew against the scope set they recorded. Before re-running init, enable Projekt, Kostnadsställe and Priser on your Fortnox app, or the authorization will be rejected.

MCP tool fixes

  • fortnox_create_supplier / fortnox_update_supplier declared 10 of the Supplier resource's 41 writable fields. The MCP SDK silently strips undeclared arguments, so setting e.g. YourReference did nothing at all — no error, the field just never reached Fortnox. Both schemas now cover the full field set.
  • Voided voucher rows (Removed: true) rendered identically to live rows, which read as a double-booking. They're now prefixed [REMOVED].

Also

  • CI now runs the suite on windows-latest. Every bug in #95 was Windows-only and Linux-only CI could not have caught any of them.
  • Column formatters no longer bypass terminal control-character stripping.

Full changelog: v0.6.1...v0.7.0