A beautiful command-line tool for monitoring your Tibber power consumption and electricity prices.
- β‘ Real-time monitoring - Stream live power consumption from your Tibber Pulse
- π° Price tracking - View current, today's, and tomorrow's electricity prices
- π Home management - List and manage multiple Tibber homes
- π¨ Beautiful output - Colored, formatted CLI output (or JSON/Markdown)
- π Cross-platform - Works on Linux, macOS, and Windows
Download the latest release for your platform from Releases.
git clone https://github.com/kristofferrisa/powerctl-cli.git
cd powerctl-cli
make build
./tibber --help-
Get your API token from developer.tibber.com/settings/access-token
-
Run setup wizard:
tibber config init
-
View your home:
tibber home
Option 1: Environment variable (recommended)
export TIBBER_TOKEN="your-token-here"
tibber homeOption 2: Config file
tibber config init # Interactive setup
# or manually edit ~/.tibber/config.yamlOption 3: Command flag
tibber --config /path/to/config.yaml hometibber homeβ‘ My House
ββββββββββ
π Address
123 Main Street
12345 Oslo, Norway
π Details
Size: 150 mΒ²
Residents: 2
Main Fuse: 25 A
β‘ Pulse
Status: β Connected
tibber pricesβ‘ Electricity Prices
ββββββββββββββββββββββ
NOW 0.45 NOK/kWh β Normal
π
Today
βΆ 14:00 ββββββββββββββββββββ 0.45 NOK
15:00 ββββββββββββββββββββ 0.62 NOK
16:00 ββββββββββββββββββββ 0.78 NOK
tibber liveβ‘ Live Power
ββββββββββββββ
1,234 W
π Today
Consumed: 12.50 kWh
Cost: 45.30 NOK
π Grid
Voltage: 230 / 231 / 229 V
Current: 5.2 / 3.1 / 4.5 A
Press Ctrl+C to stop streaming.
Default output is beautiful colored CLI. Change format with --format:
JSON (for scripting/piping):
tibber prices --format json | jq '.current.total'Markdown (for AI/documentation):
tibber home --format markdownLocation: ~/.tibber/config.yaml
token: "your-api-token"
home_id: "optional-default-home-id" # Skip home selection
format: "pretty" # Options: pretty, json, markdownView current config:
tibber config showUpdate a value:
tibber config set format jsonmake build # Build ./tibber
make build-all # Cross-compile all platformsmake test # Run all tests
go test ./internal/config -run TestLoad # Run specific testmake fmt # Format code
make lint # Run linter (requires golangci-lint)- GraphQL endpoint:
https://api.tibber.com/v1-beta/gql - WebSocket (live):
wss://websocket-api.tibber.com/v1-beta/gql/subscriptions - Rate limits: 20 WebSocket connections per hour
- Documentation: developer.tibber.com
"No API token found"
- Set
TIBBER_TOKENenvironment variable or runtibber config init
"Pulse not enabled"
- Ensure your Tibber Pulse is connected and active
- Check status at tibber.com
Live stream disconnects
- Rate limit is 20 connections/hour
- WebSocket auto-reconnects on temporary failures
Contributions welcome! Please read ARCHITECTURE.md for code structure details.
- Fork the repository
- Create a feature branch (
git checkout -b feat-amazing-feature) - Commit changes (
git commit -m 'Add amazing feature') - Push to branch (
git push origin feat-amazing-feature) - Open a Pull Request
MIT License - see LICENSE for details.
- Built with Cobra CLI framework
- Uses Tibber's official GraphQL API
- Inspired by Unix philosophy: do one thing well
Made with β‘ by Kristoffer Risa