Command-line interface for momo.coach time tracking.
Track your work hours from the terminal. Start a stopwatch, log time to projects, and view your daily timelogs — all without leaving the command line.
- Stopwatch — Start, pause, and stop a running timer
- Time logging — Log time to projects with descriptions
- Manual entries — Add time entries directly (HH:MM format)
- Daily status — View today's timelogs with colored project indicators
- Project CRUD — Create, list, update, and delete projects with custom colors
- Timelog management — Delete incorrect timelogs
- Zero dependencies — Uses only Node.js built-in modules (native
fetch) - Config-driven — Credentials stored in
~/.config/momo-cli/ - AI-friendly — Full CLI for automation and AI assistants 🤖
- Node.js 18+ (uses native
fetch) - A momo.coach account
# Clone the repository
git clone https://github.com/boris721/momo-cli.git
cd momo-cli
# Make it available globally
npm linkGet your API credentials from your momo.coach account settings, then:
# Store credentials
momo auth <secret_key> <client_id>
# Verify authentication
momo auth statusmomo sw # Show current stopwatch status
momo sw start # Start the stopwatch
momo sw pause # Pause the stopwatch
momo sw stop # Stop and reset stopwatch# Using the stopwatch (logs elapsed time, then resets)
momo sw start
# ... work ...
momo log myproject "What I worked on"
# Manual time entry
momo log 01:30 myproject "1.5 hours of work"momo status # Show today's timelogs
momo status --ids # Show timelogs with IDs (for deletion)Output:
Timelogs for 2026-02-13:
██ 01:00 [momo] "API development"
██ 00:30 [momo-cli] "CLI improvements"
██ 00:45 [admin] "Email setup"
─────────────────────────
02:15 TOTAL
Each timelog shows a colored square matching the project color.
momo status --ids # Get timelog IDs
momo timelog delete <id> --force # Delete a timelogmomo project list # List all projects
momo project add "New Project" # Create project
momo project add "Client X" --color #3498db # With color
momo project add "Side Project" --description "Weekend hacking"
momo project update "Client X" --color #e74c3c # Update color
momo project update "Client X" --description "New desc"
momo project delete "Old Project" --force # Delete projectmomo colors # Show available colors for projectsmomo help # Show help
momo --version # Show versionCredentials are stored in ~/.config/momo-cli/config.json:
{
"secret": "sk-...",
"clientId": "momo-..."
}bin/
momo # CLI entry point
lib/
api.js # HTTP client for momo.coach API
commands.js # Command implementations
config.js # Config loading/saving
format.js # Time formatting utilities
test/
*.test.js # Unit tests
Base URL: https://api.momo.coach
Authentication headers:
Authorization: Bearer <secret>Clientid: <client_id>
| Endpoint | Method | Description |
|---|---|---|
/stopwatch |
GET | Get stopwatch state |
/stopwatch |
POST | Start stopwatch |
/stopwatch |
PUT | Pause stopwatch |
/stopwatch |
DELETE | Stop/reset stopwatch |
/time |
POST | Create timelog |
/time/delete |
POST | Delete timelog {id} |
/time/range/from/{from}/to/{to} |
GET | Get timelogs for date range |
/project |
GET | List projects |
/project |
POST | Create project |
/project |
PUT | Update project |
/project/delete |
POST | Delete project {id} |
/color |
GET | List available colors |
npm testTests use Node.js built-in test runner.
MIT © 2026 Boris & Paul Panserrieu