Skip to content

chensoul/wakapi-skill

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

wakapi-skill

ClawHub ClawHub version ClawHub downloads GitHub stars License Publish to ClawHub

Wakapi coding stats (summaries, projects, today status, totals) via a small Python CLI.

Python: ≥ 3.10 required (PEP 604 syntax in the script). .python-version and GitHub Actions CI use 3.10 (aligned with the minimum).

Documentation

File Contents
SKILL.md Agent instructions: when to use, env, minimal CLI examples, troubleshooting
references/wakapi-api.md Full API/CLI reference: URLs, auth, stats vs summaries, --range table, curl, timeouts, extended examples

Layout

wakapi-skill/
├── SKILL.md                 
├── README.md
├── LICENSE
├── references/
│   └── wakapi-api.md
├── scripts/
│   └── wakapi_query.py
├── tests/
│   └── test_wakapi_query.py

Configuration

Variable Required Purpose
WAKAPI_URL Yes Instance origin (e.g. https://wakapi.dev).
WAKAPI_API_KEY Yes* API key (HTTP Basic, key only). *Not required for health (GET /api/health).

Do not commit secrets. No other environment variables are read; CLI flags are documented in SKILL.md and references/wakapi-api.md.

Using & developing

Clone

git clone https://github.com/chensoul/wakapi-skill.git
cd wakapi-skill

Virtualenv (optional)

Python ≥ 3.10, stdlib only (CI uses 3.10 — see .python-version).

python3 -m venv .venv
source .venv/bin/activate

Run CLI

# Instance origin + API key (key not needed only for `health`)
export WAKAPI_URL="https://your-wakapi.example"
export WAKAPI_API_KEY="your-key"

python3 scripts/wakapi_query.py --help
python3 scripts/wakapi_query.py health                    # GET /api/health
python3 scripts/wakapi_query.py summaries --range today   # compat summaries ?range=
python3 scripts/wakapi_query.py summaries --range last_7_days --timezone Asia/Shanghai

Quick start: SKILL.md · full CLI/curl/presets: references/wakapi-api.md.

Tests

Wakapi:

python3 -m unittest discover -s tests -p 'test_*.py' -v

Coverage (optional)

pip install coverage
coverage run --source=scripts -m unittest discover -s tests -p 'test_*.py' -q
coverage report -m --include='scripts/wakapi_query.py'

What to edit

Area Files
Wakapi CLI scripts/wakapi_query.py
Agent docs SKILL.md, references/wakapi-api.md, …
Tests tests/test_wakapi_query.py

CI & publishing

Workflow When What
.github/workflows/ci.yml Push / PR py_compile, unittest, package-check (publish dir = Wakapi skill only; see .clawhubignore)
.github/workflows/release.yml Tag v* Tarball
.github/workflows/clawhub-publish.yml Tag / dispatch Publish wakapi-skill to ClawHub

ClawHub slug: wakapi-skill. Registry metadata: SKILL.md.

License

See LICENSE.

About

Wakapi coding stats (summaries, projects, today status, totals) via a small Python CLI.

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Languages