ClawMeter for Openclaw

A self-hosted dashboard for monitoring OpenClaw API spending and token usage with real-time budget alerts.

someone0070
v1.0.0
Feb 16, 2026
0
1.3k
0

Install & Download

1. ClawHub CLI

The fastest way to install a skill directly from the registry.

npx clawhub@latest install clawmeter

2. Manual Installation

Copy the skill folder to one of these locations

Global
~/.openclaw/skills/
Workspace
<project>/skills/

Priority: Workspace > Local > Bundled

3. Prompt Installation

Copy this prompt to OpenClaw to install it automatically.

Help me install clawmeter using Clawhub. If Clawhub is not installed, install it first (npm i -g clawhub).

Prefer to download?

Get the raw skill files in a ZIP archive.

What is ClawMeter?

ClawMeter is a self-hosted cost tracking dashboard that transforms raw session logs into actionable financial insights, making it a vital part of your Openclaw Skills library. It calculates token usage and API costs in real-time, providing developers and teams with the visibility needed to optimize model selection and prevent budget overruns.

By integrating directly with your agent workspace, this skill allows for natural language queries about spending and provides a visual dashboard for deep-dive analytics. Whether you are managing a single personal agent or a fleet of production tools, this utility ensures your AI spending remains predictable and transparent.

ClawMeter Use Cases

  • Personal budget management to keep monthly AI costs under a specific threshold through automated monitoring.
  • Team cost allocation for shared OpenClaw instances to identify which agents or projects are the most expensive.
  • Model selection optimization by comparing cost-per-message and token usage across different LLM providers.
  • Production monitoring to catch cost spikes immediately and prevent runaway spending in automated environments.

How ClawMeter Works

  1. The skill monitors the OpenClaw agents directory to detect new session log entries in real-time.
  2. It ingests usage data including input tokens, output tokens, and model identifiers into a local SQLite database.
  3. Costs are calculated using a built-in pricing engine that tracks rates for various AI providers and models.
  4. A web-based dashboard serves real-time analytics and a REST API allows agents to report spending directly in the chat.
  5. The system automatically compares current spending against configured daily and monthly limits to trigger alerts.

ClawMeter Setup

  1. Clone the repository: Navigate to your workspace and download the skill source.
cd ~/.openclaw/workspace
git clone https://github.com/yourusername/clawmeter.git
cd clawmeter
  1. Install dependencies: Install the required Node.js environment.
npm install
  1. Configuration: Set up your environment variables for paths and budget limits.
cp .env.example .env
# Edit .env to customize paths and limits
  1. Initialize and Start: Ingest existing session logs and launch the local dashboard.
npm run ingest
npm start

ClawMeter Data Schema & Taxonomy

ClawMeter organizes data using a local SQLite database for maximum efficiency and privacy:

  • Sessions Table: Records individual session IDs, associated agents, specific models used, and total calculated costs.
  • Daily Aggregates: Summarizes input and output tokens, message counts, and total spending on a per-day basis.
  • Model Taxonomy: Categorizes usage by provider (Anthropic, OpenAI, etc.) and specific model tier for granular reporting.
  • Alert History: Logs budget threshold breaches, including the timestamp and the notification method used.

ClawMeter Advanced Features

  • Proactive budget alerts delivered via Telegram notifications or Email via SMTP.
  • Natural language integration allowing OpenClaw agents to answer questions like "How much have I spent today?"
  • Custom model pricing support through a configurable pricing manifest for private or fine-tuned models.
  • Comprehensive REST API for exporting data to external business intelligence tools or custom scripts.
  • Automated data management including background log ingestion and optional archival of historical records.

SKILL.md


Loading

Related Openclaw Skills

METADATA

Github Stars: 0
forks: 0

Featured*