AIClient2API Usage Checker
Query and display AIClient2API usage statistics, including credits consumed, remaining quotas, subscription type, and expiration dates.
Quick Start
Check current usage:
CODEBLOCK0
Refresh usage data:
CODEBLOCK1
Or read the usage cache file directly:
CODEBLOCK2
Usage Information
The script reads from ~/web/AIClient-2-API/configs/usage-cache.json and displays:
- - Account information: Email, user ID, subscription type
- Free trial status: Current usage, limit, expiration date
- Monthly quota: Credits used, limit, reset date
- Overage policy: Rate, cap, current charges
Key Metrics
- - Credits: Usage units for API calls
- Free Trial: Temporary promotional credits (if active)
- Monthly Quota: Recurring monthly allocation
- Next Reset: When the monthly quota refreshes
Notes
- - Usage data is cached and updated periodically by AIClient2API (every few minutes)
- The cache file is located at INLINECODE1
- For real-time data, access the web UI at
http://127.0.0.1:16825 (requires authentication) - To manually trigger a refresh via Web UI:
1. Visit
http://127.0.0.1:16825
2. Login with password from
configs/pwd
3. Navigate to Providers section and click refresh button
AIClient2API 使用情况检查器
查询并显示AIClient2API的使用统计信息,包括已消耗积分、剩余配额、订阅类型和到期日期。
快速开始
检查当前使用情况:
bash
bash scripts/check_usage.sh
刷新使用数据:
bash
bash scripts/refresh_usage.sh
或直接读取使用缓存文件:
bash
cat ~/web/AIClient-2-API/configs/usage-cache.json
使用信息
该脚本从 ~/web/AIClient-2-API/configs/usage-cache.json 读取并显示:
- - 账户信息:邮箱、用户ID、订阅类型
- 免费试用状态:当前使用量、限额、到期日期
- 月度配额:已用积分、限额、重置日期
- 超额策略:费率、上限、当前费用
关键指标
- - 积分:API调用的使用单位
- 免费试用:临时促销积分(如有效)
- 月度配额:每月循环分配的额度
- 下次重置:月度配额刷新时间
注意事项
- - 使用数据由AIClient2API缓存并定期更新(每隔几分钟)
- 缓存文件位于 ~/web/AIClient-2-API/configs/usage-cache.json
- 如需实时数据,请访问Web界面 http://127.0.0.1:16825(需要认证)
- 通过Web界面手动触发刷新:
1. 访问 http://127.0.0.1:16825
2. 使用 configs/pwd 中的密码登录
3. 导航至提供商部分并点击刷新按钮