A dedicated monitoring tool to track and analyze token consumption across all Openclaw Skills sessions and sub-agents.
The fastest way to install a skill directly from the registry.
npx clawhub@latest install token-counter
Copy the skill folder to one of these locations
~/.openclaw/skills/ <project>/skills/ Priority: Workspace > Local > Bundled
Copy this prompt to OpenClaw to install it automatically.
Help me install token-counter using Clawhub. If Clawhub is not installed, install it first (npm i -g clawhub).
Get the raw skill files in a ZIP archive.
The Token Counter provides developers with a robust way to audit and optimize their AI spending. By analyzing local session transcripts and metadata, this skill delivers a comprehensive breakdown of token usage attributed to specific models, tools, and clients. It is an essential addition to any suite of Openclaw Skills for those needing detailed evidence for cost optimization and resource management.
This utility parses .jsonl files and cron definitions to ensure that no token remains unaccounted for, whether it was spent in a main session or an automated background task. It helps transform raw logs into actionable intelligence by identifying where resources are being directed.
To begin tracking your usage, run the basic report command from your terminal to see activity from the last 7 days:
$OPENCLAW_SKILLS_DIR/token-counter/scripts/token-counter --period 7d
To save a daily snapshot of your data to your workspace for historical analysis, use the save flag:
$OPENCLAW_SKILLS_DIR/token-counter/scripts/token-counter --period 1d --save
Validation of the installation can be performed using the skill-creator validation script located in your skills directory.
The Token Counter organizes data by scanning the following file structures to build its reports:
| Component | Location | Description |
|---|---|---|
| Session Metadata | $OPENCLAW_DATA_DIR/agents/main/sessions/sessions.json |
Contains primary session definitions and metadata mapping. |
| Usage Logs | $OPENCLAW_DATA_DIR/agents/main/sessions/*.jsonl |
Primary source of token usage and tool call records. |
| Cron Definitions | $OPENCLAW_DATA_DIR/cron/jobs.json |
Used to attribute tokens to scheduled automated tasks. |
| JSON Snapshots | $OPENCLAW_WORKSPACE/token-usage/daily/ |
Destination for persisted daily usage records for trend analysis. |
Loading
A defense-in-depth security layer that sanitizes external AI skills by regenerating them from scratch to eliminate hidden prompt injection and malicious payloads.

A specialized CLI tool for Openclaw Skills designed to analyze, compress, and optimize token consumption in AI agent sessions.

A specialized skill for building award-winning, immersive web experiences with advanced animations, creative interactions, and high-end visual storytelling.

A strategic framework for optimizing context window usage through partitioning and automated checkpointing for long-running agent sessions.

A floating, animated desktop avatar that visualizes your AI agent's emotions, tasks, and real-time status.

ClawSmith is a comprehensive automation engine designed to help developers build, secure, and optimize high-quality Openclaw Skills with a single command.








































