← Back to Skills Marketplace
srikanth235

GreenClaw

by srikanth235 · GitHub ↗ · v1.0.0 · MIT-0
cross-platform ⚠ suspicious
256
Downloads
0
Stars
0
Active Installs
1
Versions
Install in OpenClaw
/install greenclaw
Description
Token usage analytics and budget alerting for the GreenClaw inference proxy. Query spending, set budget alerts, and track savings.
README (SKILL.md)

GreenClaw Usage Analytics

You have access to the greenclaw CLI tool for querying token usage, cost analytics, and managing budget alerts. Run it via npx greenclaw (requires pnpm install and pnpm build first). All commands output JSON.

Available Commands

Usage Queries

Daily summary:

 npx greenclaw usage summary --period day

Weekly or monthly summary:

 npx greenclaw usage summary --period week
 npx greenclaw usage summary --period month

Breakdown by model, tier, or provider:

 npx greenclaw usage breakdown --by model --period day
 npx greenclaw usage breakdown --by tier --period week
 npx greenclaw usage breakdown --by provider --period month

Trends over time:

 npx greenclaw usage trends --period day --last 7
 npx greenclaw usage trends --period week --last 4

Budget Alerts

List alert rules:

 npx greenclaw alerts list

Set a daily cost budget:

 npx greenclaw alerts set --name "daily budget" --metric daily_cost --threshold 50 --unit usd --period day

Set a weekly token limit:

 npx greenclaw alerts set --name "weekly tokens" --metric weekly_cost --threshold 100 --unit usd --period week

Set a per-model cost cap:

 npx greenclaw alerts set --name "gpt-4 cap" --metric per_model_cost --threshold 30 --unit usd --period day --model gpt-4

Check alerts now:

 npx greenclaw alerts check

View alert history:

 npx greenclaw alerts history --last 10

Remove an alert rule:

 npx greenclaw alerts remove \x3Crule-id>

Raw Traces

Aggregated stats:

 npx greenclaw traces --stats

Filter by tier or model:

 npx greenclaw traces --tier HEARTBEAT
 npx greenclaw traces --model gpt-4o-mini

How to Present Results

  • Parse the JSON output and present it in a clear, readable format
  • For summaries: show total tokens, cost, savings, and request count
  • For breakdowns: show a table with group key, tokens, cost, savings
  • For alerts: explain which rules triggered and current metric values
  • Round dollar amounts to 2 decimal places
  • Use natural language to explain savings (e.g., "You saved $8.91 today by routing 412 requests through cheaper models")

Environment

The greenclaw CLI uses the GREENCLAW_TELEMETRY_DB environment variable for the SQLite database path (defaults to data/telemetry.db).

Usage Guidance
This skill appears to do what it claims (usage analytics) but the SKILL.md and registry metadata don't match in important ways. Before installing or running it: 1) Ask the publisher for the package source (npm package name, homepage, or GitHub repo) and verify the package and its maintainers. 2) Don't run 'npx pnpm install' or 'npx greenclaw' on important hosts without inspecting the package first—npx/pnpm will fetch and run code (including build scripts). Prefer to inspect the package source, audit its install scripts, or run it in an isolated container. 3) Be aware the tool reads a SQLite telemetry DB (GREENCLAW_TELEMETRY_DB / data/telemetry.db); ensure that database doesn't contain secrets you don't want exposed and consider pointing the tool to a copy or a restricted path. 4) Ask the author to update the registry metadata to declare required binaries (node, npm, npx, pnpm) and any environment variables/config paths and to provide a verified homepage or repository. If you cannot verify provenance, treat this skill as potentially risky and run it only in a sandbox.
Capability Analysis
Type: OpenClaw Skill Name: greenclaw Version: 1.0.0 The skill bundle provides instructions for an AI agent to use a CLI tool called `greenclaw` for monitoring token usage, cost analytics, and budget management. The instructions in SKILL.md are consistent with the stated purpose of the tool, involving standard CLI commands for querying a local SQLite database (defaulting to data/telemetry.db) and presenting JSON results to the user. No malicious patterns such as data exfiltration, unauthorized network access, or obfuscated code were found.
Capability Assessment
Purpose & Capability
The SKILL.md describes token usage analytics, budget alerts, and traces for a GreenClaw inference proxy — that matches the skill name and description. Nothing in the instructions obviously tries to do unrelated actions (no cloud credential requests or unrelated remote services).
Instruction Scope
The runtime instructions tell the agent to run 'npx greenclaw' (after 'pnpm install' and 'pnpm build') and to read/use a local SQLite DB (GREENCLAW_TELEMETRY_DB, default data/telemetry.db). The registry metadata declared no env vars or config paths, but the SKILL.md references an environment variable and a local DB path. The instructions also implicitly require Node/npm/pnpm/npx to be present; those required binaries are not declared. Running npx/pnpm can fetch and execute arbitrary code from the npm registry and run package build scripts, which expands the runtime scope beyond simple CLI use.
Install Mechanism
There is no install spec in the registry metadata, yet SKILL.md expects to install and run a package via pnpm/npx. That means the agent (or user) will fetch code from the npm registry at runtime with no vendoring, checksum, or provenance declared — moderate-to-high operational risk if the package or its dependencies are malicious or compromised.
Credentials
The skill declares no required environment variables or credentials, but the instructions reference GREENCLAW_TELEMETRY_DB for the SQLite path and default to data/telemetry.db. This is an undeclared data/config access requirement. The skill also implicitly requires Node/npm/pnpm tooling (binaries) which are not declared. Asking the agent to read a local telemetry DB can expose sensitive usage data; the absence of explicit env/config declarations is a proportionality mismatch.
Persistence & Privilege
The skill is instruction-only and not marked 'always:true'. It does not request persistent presence or modify other skills' configs. Autonomous model invocation remains allowed (platform default) but is not combined with other high-privilege flags.
How to Use
  1. Make sure OpenClaw is installed (local or Docker)
  2. Run the install command in chat: /install greenclaw
  3. After installation, invoke the skill by name or use /greenclaw
  4. Provide required inputs per the skill's parameter spec and get structured output
Version History
v1.0.0
Initial release of greenclaw-usage: - Provides token usage analytics and budget alerting for the GreenClaw inference proxy. - Includes CLI commands to query usage summaries, breakdowns, and trends. - Enables setting and managing budget alerts for costs and token usage, with support for per-model alerts. - Allows viewing raw trace statistics filtered by tier or model. - Guides on presenting analytics data and savings in readable formats. - Uses an environment variable for database configuration.
Metadata
Slug greenclaw
Version 1.0.0
License MIT-0
All-time Installs 0
Active Installs 0
Total Versions 1
Frequently Asked Questions

What is GreenClaw?

Token usage analytics and budget alerting for the GreenClaw inference proxy. Query spending, set budget alerts, and track savings. It is an AI Agent Skill for Claude Code / OpenClaw, with 256 downloads so far.

How do I install GreenClaw?

Run "/install greenclaw" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.

Is GreenClaw free?

Yes, GreenClaw is completely free, licensed under MIT-0. You can download, install and use it at no cost.

Which platforms does GreenClaw support?

GreenClaw is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).

Who created GreenClaw?

It is built and maintained by srikanth235 (@srikanth235); the current version is v1.0.0.

💬 Comments