Sign in Start free
Documentation

Heyweek CLI Overview

The Heyweek command-line interface (CLI) brings your Heyweek account to the terminal. Track time, manage projects and clients, edit work logs, and switch…

Last updated:

The Heyweek command-line interface (CLI) brings your Heyweek account to the terminal. Track time, manage projects and clients, edit work logs, and switch between workspaces without leaving your command line. It's built for developers and power users who prefer working from a terminal.

Key features

  • Secure authentication β€” OAuth 2.0 device flow with tokens stored securely in your system's credential store.
  • Time tracking β€” Start, check, and stop timers from the terminal.
  • Project and client management β€” Create, list, edit, and delete projects and clients.
  • Work logs β€” Create, list, edit, and delete detailed log entries.
  • Workspace support β€” Create, list, edit, and switch between multiple workspaces.
  • Cross-platform β€” Runs on macOS, Linux, and Windows.
  • Auto-updates β€” The CLI checks for new versions every 24 hours and you can upgrade in place.

Command groups

The CLI is organized into command groups, each with its own subcommands:

  • hw auth β€” Authentication: login, logout, renew.
  • hw timer β€” Time tracking: start, status, stop.
  • hw project β€” Projects: create, list, edit, delete.
  • hw client β€” Clients: create, list, edit, delete.
  • hw log β€” Work logs: create, list, edit, delete.
  • hw workspace β€” Workspaces: create, list, edit, info, switch.
  • hw pomo β€” Start a Pomodoro focus timer.
  • hw version β€” Print the CLI version.
  • hw upgrade β€” Upgrade the CLI to the latest version.

See the Commands Reference for the full list of subcommands and flags.

Authentication and security

The CLI signs you in using the OAuth 2.0 device flow β€” there is no password to type into the terminal. Run hw auth login and follow the prompt to authorize the CLI in your browser. Access tokens are stored securely in your operating system's credential store rather than in plaintext, and you can refresh an expired token with hw auth renew.

A quick example

A typical session looks like this:

bash
<span class="token comment"># Log in to your account</span>
hw auth login

<span class="token comment"># Start tracking time with a description</span>
hw timer start <span class="token parameter variable">-d</span> <span class="token string">"Working on new feature"</span>

<span class="token comment"># Check the running timer</span>
hw timer status

<span class="token comment"># Stop the timer when you're done</span>
hw timer stop

Getting started

  1. Install the CLI β€” Get it running on your system.
  2. Log in β€” Run hw auth login to connect to your Heyweek account.
  3. Learn the commands β€” Explore the available commands and flags.

You can display help for any command at any time with the --help flag:

bash
hw <span class="token parameter variable">--help</span>
hw timer <span class="token parameter variable">--help</span>