Phase 2 · Batch 3: Provider Usage Scrapers as Optional Local Adapters #32
Labels
No Label
admin
agent-api
api
api-client
audit
backend
boards
cost-accounting
database
design
forgejo
frontend
issues
metrics
mutation
navigation
optional
phase:1
phase:2
phase:3
phase:4
phase:5
phase:6
polish
priority:high
priority:low
priority:medium
service
sync
usage-accuracy
validation
webhooks
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: null/Pipeline#32
Loading…
Reference in New Issue
No description provided.
Delete Branch "%!s(<nil>)"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Outcome
Local installs can display provider-native usage information when JSONL data is not enough.
Scope
backend/app/services/openclaw/usage_scrapers.py(or extendruntime_usage.py)backend/app/schemas/runtime_usage.pyImplementation Details
RuntimeUsageProviderAdapter/usageparser behavior into Python (tests first)Risk
Reference
scripts/scrape-claude-usage.sh: tmux session lifecycle, /usage invocation, lock file, output cachescripts/parse-claude-usage.py: parser for current session percent, remaining time, weekly fieldsserver.js: /api/claude-usage-scrape, /api/claude-usage, /api/gemini-usage-scrape, /api/gemini-usageDepends On
Labels
phase-2, backend, priority-medium
Verification Complete ✅
Batch 3 scope verified against existing implementation.
What the issue requested:
backend/app/services/openclaw/usage_scrapers.py✅backend/app/schemas/runtime_usage.py✅RuntimeUsageProviderAdapter✅/usageparser behavior into Python (tests first) ✅Existing implementation:
usage_scrapers.pyruntime_usage.pyschemaGET /gateways/{id}/provider-usagein gateways.pyRisk notes captured in code:
Result: Issue #32 scope matches implementation. Ready for implementation tracking.