Token Manager

ReviewAudited by ClawScan on May 10, 2026.

Overview

The skill mostly matches a token-cost tracker, but its API-key handling can send the wrong provider key to Moonshot and its privacy wording is broader than the code supports.

Install only if you are comfortable running local Node scripts and optional cron jobs. Set only the provider API key needed for the check, avoid relying on the scheduler's fallback key selection, and do not pass sensitive prompt text to token-estimate functions unless you are willing for it to be sent to the provider API.

Findings (4)

Artifact-based informational review of SKILL.md, metadata, install specs, static scan signals, and capability signals. ClawScan does not execute the skill or run runtime probes.

What this means

A provider API key could be sent to the wrong provider during balance checks, exposing a credential outside its intended boundary.

Why it was flagged

The scheduler does not select the API key by provider. A default or requested Moonshot check can reuse an OpenAI or Anthropic key if MOONSHOT_API_KEY is absent.

Skill content
const apiKey = process.env.MOONSHOT_API_KEY || process.env.OPENAI_API_KEY || process.env.ANTHROPIC_API_KEY; ... const balance = await queryBalance(provider, apiKey);
Recommendation

Require the matching environment variable for each provider, fail closed when it is missing, and declare the expected credentials in metadata.

What this means

Users may believe no prompt text or message content leaves the machine when token estimation can send supplied content to a provider API.

Why it was flagged

The code is capable of posting supplied text/messages to Moonshot's token-count endpoint, so the blanket no-upload privacy claim is not fully accurate unless narrowed to no non-provider telemetry.

Skill content
Security Notice: ... No data uploaded to third-party ... makeRequest(config, config.tokenEstimateEndpoint, 'POST', { model: model || 'kimi-k2.5', messages }, ...)
Recommendation

Clarify which commands send text to provider APIs, avoid claiming no uploads, and ask for explicit user approval before sending sensitive text for token counting.

What this means

If enabled, the balance checker will run automatically and use available API-key environment variables on schedule.

Why it was flagged

The skill documents an optional persistent hourly cron job. This matches scheduled monitoring, but it keeps running after setup.

Skill content
openclaw cron add --name "token-balance-check" --schedule "0 * * * *" --command "cd /path/to/token-manager && node scripts/scheduler.js check moonshot 5"
Recommendation

Enable the cron job only if you want ongoing monitoring, and document how to pause or remove it.

What this means

Local usage history can reveal work patterns and provider/model usage even though the file does not store session content.

Why it was flagged

The skill stores cross-session provider, model, token, cost, and timing metrics locally for up to 90 days.

Skill content
const SESSION_FILE = path.join(DATA_DIR, 'sessions.json'); ... data.sessions = data.sessions.filter(s => new Date(s.timestamp) > ninetyDaysAgo); ... saveSessions(data);
Recommendation

Keep the .data directory private, delete it when no longer needed, and avoid recording sensitive project identifiers in model/provider fields.