Skip to content

Releases: pbek/tokstat

tokstat v0.7.0

26 Feb 14:40
5cf2503

Choose a tag to compare

Changelog

Added

  • Azure OpenAI provider support
    • New provider for monitoring Azure-hosted OpenAI deployments
    • API key authentication with resource name configuration
    • Tracks token usage, request counts, and rate limits across deployments
    • Supports AZURE_RESOURCE_NAME environment variable for resource name configuration
    • Login via tokstat login azure --name my-azure
    • Available in both CLI and TUI dashboard

Installation

Download the appropriate binary for your platform:

  • Linux (x86_64): tokstat-*-x86_64-unknown-linux-gnu.tar.gz
  • macOS (Apple Silicon): tokstat-*-aarch64-apple-darwin.tar.gz

Or install via Nix:

nix build github:pbek/tokstat/v0.7.0

tokstat v0.6.0

19 Feb 20:31
8693d7e

Choose a tag to compare

Changelog

Added

  • Account reordering in dashboard

    • Press Shift+J to move selected account down in the list
    • Press Shift+K to move selected account up in the list
    • Account order is automatically saved and persists across sessions
  • Model multipliers panel in dashboard

    • Links to the official GitHub documentation for the current model multiplier table

Installation

Download the appropriate binary for your platform:

  • Linux (x86_64): tokstat-*-x86_64-unknown-linux-gnu.tar.gz
  • macOS (Apple Silicon): tokstat-*-aarch64-apple-darwin.tar.gz

Or install via Nix:

nix build github:pbek/tokstat/v0.6.0

tokstat v0.5.0

16 Feb 16:16
6488f31

Choose a tag to compare

Changelog

Added

  • Copy confirmation code during Copilot login
    • Press 'c' during GitHub Copilot OAuth device flow to copy the user code to clipboard
    • Shows clear prompt with options: press 'c' to copy or Enter to continue
    • Works cross-platform (Linux X11/Wayland, macOS, Windows)
    • Displays confirmation message when code is successfully copied

Changed

  • Improved "No providers configured" message

    • Now mentions both CLI (tokstat login) and dashboard (a key) options for adding accounts
    • Provides clearer guidance for new users on how to get started
  • Improved text input dialogs in dashboard

    • Better visual design with colored borders and styled titles (cyan for rename, magenta for create)
    • Added emoji icons (✏️ for rename, 📝 for create) for quick visual recognition
    • Clear input field labels ("New name:", "Name:") with bold styling
    • Helpful placeholder text when input is empty
    • Single custom cursor indicator (▌) instead of dual cursors
    • Shows current account name when renaming
    • Added helpful tips in account creation dialog
    • Improved key shortcut labels with green (Enter) and red (Esc) colors
    • Consistent visual style across both rename and create dialogs

Fixed

  • Fixed dashboard not fully redrawing after account creation
    • Terminal screen is now properly cleared and redrawn after returning from external login flow
    • No longer requires window resize to refresh the UI

Installation

Download the appropriate binary for your platform:

  • Linux (x86_64): tokstat-*-x86_64-unknown-linux-gnu.tar.gz
  • macOS (Apple Silicon): tokstat-*-aarch64-apple-darwin.tar.gz

Or install via Nix:

nix build github:pbek/tokstat/v0.5.0

tokstat v0.4.0

15 Feb 21:28
baf5713

Choose a tag to compare

Changelog

Added

  • Quota History Tracking
    • Store up to 100 quota snapshots per account when values change
    • History panel displayed directly in the dashboard under usage gauges
    • Shows timestamp and all quota values (tokens, requests, cost) for each change
    • History persists to ~/.config/tokstat/quota_history.json
    • Automatically removes history when accounts are deleted
    • History is updated on every quota refresh when changes are detected

Changed

  • Dashboard Layout Redesign
    • History panel now aligned to top, directly under usage gauges
    • Dynamic layout calculation for info panel (7 lines) + gauges (3 lines each)
    • History panel fills remaining vertical space
    • Removed separate history toggle mode - history always visible

Fixed

  • Fixed OpenRouter cost panel alignment in dashboard
    • Cost gauge now properly aligns with Account Info panel for OpenRouter accounts
    • Dynamic layout calculation based on which gauges are present (requests, tokens, cost)
    • Ensures consistent visual alignment across all provider types

Installation

Download the appropriate binary for your platform:

  • Linux (x86_64): tokstat-*-x86_64-unknown-linux-gnu.tar.gz
  • macOS (Apple Silicon): tokstat-*-aarch64-apple-darwin.tar.gz

Or install via Nix:

nix build github:pbek/tokstat/v0.4.0

tokstat v0.3.1

15 Feb 14:34
f600710

Choose a tag to compare

Changelog

Fixed

  • Fixed CLI output formatting
    • Removed extra space after stopwatch emoji in "Updated" timestamp line
    • Improves visual consistency in the fancy CLI output

Installation

Download the appropriate binary for your platform:

  • Linux (x86_64): tokstat-*-x86_64-unknown-linux-gnu.tar.gz
  • macOS (Apple Silicon): tokstat-*-aarch64-apple-darwin.tar.gz

Or install via Nix:

nix build github:pbek/tokstat/v0.3.1

tokstat v0.3.0

15 Feb 14:04
7b7769b

Choose a tag to compare

Changelog

Added

  • Dashboard now works without any accounts configured
    • Welcome screen displayed when no accounts exist
    • Shows "Getting Started" guide with supported providers
    • Prompts user to press n to add their first account
    • Allows full TUI configuration from a clean state

Fixed

  • Fixed Copilot quota reset date parsing
    • Added support for simple date format (YYYY-MM-DD) in addition to RFC3339
    • Reset date now properly displays for GitHub Copilot accounts

Changed

  • Dashboard now displays quota reset date
    • Added "Quota Resets" field to the Account Info section
    • Shows the date when quota limits reset (YYYY-MM-DD format)

Installation

Download the appropriate binary for your platform:

  • Linux (x86_64): tokstat-*-x86_64-unknown-linux-gnu.tar.gz
  • macOS (Apple Silicon): tokstat-*-aarch64-apple-darwin.tar.gz

Or install via Nix:

nix build github:pbek/tokstat/v0.3.0

tokstat v0.2.0

14 Feb 14:50
7e8753e

Choose a tag to compare

Changelog

Added

  • Interactive account management directly from the dashboard
    • Add new accounts with n key
      • Opens provider selector popup showing available providers (GitHub Copilot, OpenRouter)
      • Navigate providers with ↑↓ arrow keys, Enter to select, Esc to cancel
      • Optional custom name input: After selecting provider, enter an optional account name
        • Default name auto-generated as {provider}_{timestamp}
        • Type a custom name or press Enter to accept the default
        • Esc cancels the entire account creation flow
      • Temporarily exits TUI to run the appropriate authentication flow
        • GitHub Copilot: OAuth device flow with user code
        • OpenRouter: API key input with validation
      • Automatically reloads accounts list and refreshes quota data after successful creation
      • New account becomes selected after creation
    • Delete accounts with d key
      • Shows confirmation dialog displaying the account name to be deleted
      • Press Enter to confirm deletion, Esc to cancel
      • Automatically removes account credentials from secure storage
      • Reloads accounts list and adjusts selection index after deletion
      • Clears and refreshes quota data to reflect changes

Changed

  • Breaking: Changed keyboard shortcuts in dashboard
    • R (uppercase) now refreshes quota information
    • r (lowercase) now triggers rename mode
  • Fixed alignment of right-side panels in dashboard - requests panel now properly aligned with account info panel
  • Added "Requests" title/label to the requests panel for better clarity
  • Updated dashboard with beautiful visual gauges
    • All metrics (Requests, Tokens, Cost) now displayed as color-coded progress bars
    • Consistent styling with the CLI output: Green (<50%), Yellow (50-80%), Red (>80%)
    • Dark gray borders with colored progress indicators
    • Shows remaining requests and percentages for all metrics
  • Smart terminal detection with automatic fallback
    • Detects when output is being piped (non-interactive)
    • Automatically falls back to clean text-only output when piping
    • Preserves all information in an easy-to-parse format
    • No ANSI escape codes in piped output for better script compatibility
  • Updated dashboard color scheme to use only predefined colors
    • Header now uses multi-color scheme: LightMagenta (tokstat), Magenta (separator), LightCyan (subtitle)
    • Header border changed to Magenta
    • Selection highlight changed from Cyan to Magenta for consistency
    • Removed all RGB color values for better terminal compatibility
  • Completely redesigned the default tokstat output (when run without subcommands)
    • Default output now uses beautiful colored CLI display
      • Box-drawing characters for elegant account cards with magenta borders
      • Visual progress bars for Requests, Tokens, and Cost metrics
      • Color-coded indicators: Green (<50%), Yellow (50-80%), Red (>80%)
      • Provider-specific emojis (🤖 for Copilot, 🌐 for OpenRouter, 🔌 for others)
      • No alternate screen needed - displays inline with scrollback preserved
    • Added --json flag for scriptable JSON output
    • Use tokstat --json to output account data as structured JSON
    • Perfect for scripting and automation (pipe to jq, etc.)
    • Includes all account details: name, provider, usage, limits, timestamps
    • Failed quota fetches include error messages in the JSON
    • Empty accounts list outputs [] for easy parsing

Installation

Download the appropriate binary for your platform:

  • Linux (x86_64): tokstat-*-x86_64-unknown-linux-gnu.tar.gz
  • macOS (Apple Silicon): tokstat-*-aarch64-apple-darwin.tar.gz

Or install via Nix:

nix build github:pbek/tokstat/v0.2.0

tokstat v0.1.0

13 Feb 21:47
e54bec1

Choose a tag to compare

Changelog

Added

  • Initial release of tokstat CLI tool for monitoring token quotas across AI providers
  • Support for GitHub Copilot provider: OAuth device flow login, token usage tracking
  • Support for OpenRouter provider: API key authentication, cost and credit limit monitoring
  • Interactive terminal dashboard (TUI) for viewing quota information across all accounts
  • CLI commands: login, list, dashboard, remove, refresh, version
  • Shell completion support for bash, fish, and zsh
  • Secure credential storage using system keyring
  • Modular provider architecture for easy addition of new AI service integrations
  • Comprehensive error handling and user-friendly output
  • Added ability to rename accounts in the TUI dashboard using 'n' key shortcut
  • Updated footer in dashboard to show all available shortcuts including the new rename option

Installation

Download the appropriate binary for your platform:

  • Linux (x86_64): tokstat-*-x86_64-unknown-linux-gnu.tar.gz
  • macOS (Apple Silicon): tokstat-*-aarch64-apple-darwin.tar.gz

Or install via Nix:

nix build github:pbek/tokstat/v0.1.0