Expense Tracker Skill
Quick Start
Initial Setup (First Time)
CODEBLOCK0
This will:
- 1. Ask you to set a master password (for encrypting credentials)
- Select storage backend and configure API keys
Storage backends:
- 1. Local file - No config needed
- Notion - Requires API Key + Database ID
- Google Sheet - Requires credentials path + Spreadsheet ID
- Supabase - Requires URL + Anon Key
Set Password (For Subsequent Uses)
CODEBLOCK1
Or enter interactively when prompted.
Record Expense
CODEBLOCK2
Record Income
CODEBLOCK3
View Records
CODEBLOCK4
Statistics
CODEBLOCK5
Security
Credentials are encrypted using AES-256-GCM with PBKDF2 key derivation.
- - Config file: INLINECODE0
- Never stores plain text passwords or API keys
Categories
- -
food - Food & Dining - INLINECODE2 - Transportation
- INLINECODE3 - Shopping
- INLINECODE4 - Entertainment
- INLINECODE5 - Salary
- INLINECODE6 - Bonus
- INLINECODE7 - Investment
- INLINECODE8 - Other
Commands Reference
| Command | Description |
|---|
| INLINECODE9 | Set password & configure backend (first time) |
| INLINECODE10 |
Set password for decryption |
|
add <amount> <note> <category> | Add new record |
|
list | View recent records |
|
list --month | This month's records |
|
list --category | Group by category |
|
stats | Monthly summary |
|
stats -m <n> | N months ago |
Data Format
Each record:
CODEBLOCK6
费用追踪技能
快速入门
初始设置(首次使用)
bash
expense-tracker setup
此操作将:
- 1. 要求您设置主密码(用于加密凭证)
- 选择存储后端并配置API密钥
存储后端:
- 1. 本地文件 - 无需配置
- Notion - 需要API密钥 + 数据库ID
- Google Sheet - 需要凭证路径 + 电子表格ID
- Supabase - 需要URL + 匿名密钥
设置密码(后续使用)
bash
expense-tracker pass <您的密码>
或在提示时交互式输入。
记录支出
bash
expense-tracker add -50 午餐 food
格式:expense-tracker add <金额> <备注> <类别>
负金额 = 支出
记录收入
bash
expense-tracker add 5000 工资 salary
正金额 = 收入
查看记录
bash
expense-tracker list # 最近10条记录
expense-tracker list --month # 本月记录
expense-tracker list --category # 按类别查看
统计
bash
expense-tracker stats # 本月统计
expense-tracker stats -m 2 # 两个月前
安全性
凭证使用 AES-256-GCM 加密,并采用PBKDF2密钥派生。
- - 配置文件:~/.openclaw/expense-tracker/config.enc
- 绝不存储明文密码或API密钥
类别
- - food - 餐饮
- transport - 交通
- shopping - 购物
- entertainment - 娱乐
- salary - 工资
- bonus - 奖金
- investment - 投资
- other - 其他
命令参考
| 命令 | 描述 |
|---|
| setup | 设置密码并配置后端(首次使用) |
| pass <密码> |
设置解密密码 |
| add <金额> <备注> <类别> | 添加新记录 |
| list | 查看最近记录 |
| list --month | 本月记录 |
| list --category | 按类别分组 |
| stats | 月度汇总 |
| stats -m
| n个月前 |
数据格式
每条记录:
json
{
id: uuid,
type: expense|income,
amount: -50,
category: food,
note: lunch,
date: 2026-03-03,
created_at: 2026-03-03T20:23:00Z
}