Skip to content

Repository files navigation

Toks logo

Toks

Claude Code and Codex usage, clearly.

Linux · Native Rust · Local-first

A local-first Linux desktop app for tracking Claude Code, Codex, and OpenCode token usage, estimated costs, models, and usage remaining.

Toks overview showing usage trends and remaining usage limits

Install

With an AI coding agent

Install Toks from https://github.com/Luzivog/toks and follow its README.

Manually

Toks currently supports Linux. Install Rust with rustup, sign in to the Codex CLI and/or Claude Code, then:

git clone https://github.com/Luzivog/toks.git
cd toks
cargo build -p toks --release --locked
cargo build -p toks-core --bin toks-router --release --locked
./install.sh

Open Toks from your application launcher. The installer is user-local: the app and its Codex router go to ~/.local/bin. The install does not require sudo.

Debian / Ubuntu build requirements
sudo apt-get update
sudo apt-get install -y \
  build-essential clang cmake perl pkg-config \
  libfontconfig1-dev libvulkan-dev libwayland-dev libxcb1-dev \
  libxkbcommon-dev libxkbcommon-x11-dev

A working Vulkan driver and an X11 or Wayland desktop session are also required.

How it works

Toks reads local Codex, Claude Code, and OpenCode history. Once captured, usage survives provider-log cleanup in a compact local archive. It only goes online to refresh plan limits and public pricing. Tokscale is not required.

Costs are API-rate estimates, not subscription spend.

Development

cargo run -p toks --locked
cargo test -p toks --lib --locked
scripts/quality/check-repository.sh

Architecture, conventions, and contribution expectations are documented in AGENTS.md.

Credits and license

Toks is available under the MIT License. The ingestion engine was derived from Tokscale; attribution is preserved in NOTICE. The UI was inspired by T3 Code.

About

A local-first Linux desktop app for tracking Claude Code and Codex usage, costs, models, and plan limits.

Topics

Resources

Stars

2 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages