@ambiguoustr/openclaw-wakatime
v0.9.10
Published
Official-style OpenClaw plugin for tracking activity in WakaTime
Maintainers
Readme
openclaw-wakatime
TypeScript-native WakaTime plugin for OpenClaw.
Published npm package: @ambiguoustr/openclaw-wakatime
This plugin tracks OpenClaw runtime activity and sends heartbeats through the official wakatime CLI:
message_received/message_sentcommand:*(via internal hook registration)after_tool_call(read/edit/writeuse file entities from tool params such aspath/file_path; file language is auto-detected bywakatime-cli)session_start/session_end
Runtime files are written under ~/.openclaw/wakatime/:
plugin.logqueue.jsonlsessions.jsonl
Requirements
- OpenClaw
>= 2026.3.x - WakaTime CLI installed and authenticated (
~/.wakatime.cfgorWAKATIME_API_KEY) - Command examples use POSIX shell syntax; on Windows use equivalent PowerShell/CMD commands.
Authentication
The plugin does not store or manage your WakaTime API key directly.
It only invokes the official wakatime CLI.
Key resolution is handled by WakaTime CLI:
- Recommended:
~/.wakatime.cfgwithapi_key = waka_... - Alternative: environment variable
WAKATIME_API_KEY
Prefer ~/.wakatime.cfg for reliability, because shell environment variables are not always inherited by the OpenClaw gateway process.
Fresh Start (new machine)
- Install and authenticate WakaTime CLI.
- Confirm key is available (for example with
~/.wakatime.cfg). - Install/enable this plugin.
- Restart gateway (
openclaw gateway restart). - Trigger one real message/tool call and verify heartbeats.
Missing/invalid key behavior
- Plugin still loads in OpenClaw.
- Heartbeat sending fails until credentials are fixed.
- Failed heartbeats are queued in
~/.openclaw/wakatime/queue.jsonl. - After fixing credentials, queued heartbeats are retried automatically.
Install (local path)
cd ~/.openclaw/plugins/openclaw-wakatime
node setup_wakatime.mjsThe setup script updates ~/.openclaw/openclaw.json:
plugins.load.pathsincludes this directoryplugins.entries.openclaw-wakatime.enabled = true
Then it restarts gateway by default and prints plugin status.
Install (npm)
openclaw plugins install @ambiguoustr/openclaw-wakatime --pin
openclaw plugins info openclaw-wakatimeConfigure
Plugin config lives at:
plugins.entries.openclaw-wakatime.config
Example:
{
"plugins": {
"entries": {
"openclaw-wakatime": {
"enabled": true,
"config": {
"enabled": true,
"project": "agent-vibe-coding",
"category": "ai coding",
"useContextProject": false,
"heartbeatIntervalSeconds": 120,
"queueRetryBatchSize": 50,
"queueFlushIntervalSeconds": 60,
"trackMessages": true,
"trackCommands": true,
"trackTools": true,
"trackSessions": true
}
}
}
}
}After config edits, restart gateway.
Verify
openclaw plugins info openclaw-wakatime
openclaw plugins listThen send a real channel message or command and check:
tail -f ~/.openclaw/wakatime/plugin.logPackaging Notes
This repository follows the OpenClaw plugin spec:
openclaw.plugin.jsonmanifest (required)- TypeScript plugin entrypoint (
index.ts) - package metadata with
openclaw.extensions
Release and community submission runbook:
RELEASE.mdCOMMUNITY_SUBMISSION.md
Migration From Legacy Version
0.9.9 is a full TS rewrite.
Removed runtime paths:
- Python tracker modules (
wakatime_openclaw.py,wakatime_hooks.py,wakatime_wrapper.py) - legacy
hooks/wakatime-imbridge - legacy zsh preexec hook integration
If you previously used those paths, switch to plugin config under plugins.entries.openclaw-wakatime.
