CLI Tool

The Mojave CLI is a lightweight command-line interface that lets you interact with your Mojave workspace directly from your terminal. It’s ideal for developers, power users, and remote teams who want to manage time, projects, and invoices without switching context.

Installation

Install globally using npm:

bashCopyEditnpm install -g mojave-cli

After installation, verify the command:

bashCopyEditmojave --version

Authentication

Set your API token using:

bashCopyEditmojave auth --token YOUR_API_TOKEN

The token is stored securely in your system keychain or config file depending on OS.

Available Commands

Command

Description

mojave auth

Set or view API token

mojave me

View current user profile

mojave projects

List all projects

mojave projects:create

Create a new project

mojave time:start

Start tracking time

mojave time:stop

Stop the currently running timer

mojave time:log

Log time manually

mojave invoices

List recent invoices

mojave invoices:send

Send an invoice by ID

Example Usage

View current user

Start a timer

bashCopyEditmojave time:start --project prj_1234 --notes "Design review"

Stop the timer

bashCopyEditmojave time:stop

Create a new project

bashCopyEditmojave projects:create --name "Marketing Website" --client cli_ab12cd

Log time manually

Configuration

You can view or change saved config using:

bashCopyEditmojave config

This shows your current token, default project, and timezone settings.

Output Formats

Add --json to any command to get machine-readable output:

bashCopyEditmojave projects --json

Best Practices

  • Use aliases for frequently used commands

  • Add mojave scripts into your CI workflows

  • Pipe outputs into logs or file exports

  • Set project defaults using mojave config --project prj_xyz

Was this helpful?

Was this helpful?

Was this helpful?

Table of content

Table of content

Table of content

CLI Tool

CLI Tool