| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352 |
- {
- "project_name": "AI语音应用-订阅支付系统",
- "base_config": {
- "backend_port": 3000,
- "frontend_port": 8080,
- "db_host": "localhost",
- "db_port": 3306,
- "auth_enabled": false
- },
- "design_overview": {
- "problem": "用户付费是为了得到音频文件",
- "solution": "按音频时长计费,包月=批发价,按量=零售价"
- },
- "billing_model": {
- "unit": "音频时长(分钟)",
- "formula": "生成费用 = 音频时长 × 单价",
- "speaking_rate": 150,
- "cost_per_minute": 4.0,
- "pricing_strategy": {
- "monthly": "包月批发价 ¥5/分钟(30%利润)",
- "pay_as_you_go": "按量零售价 ¥8/分钟(100%利润)"
- }
- },
- "pricing_plan": {
- "last_updated": "2026-04-12",
- "billing_unit": "audio_minutes",
- "core_pricing": {
- "cost": 4.0,
- "monthly_price": 5.0,
- "overage_price": 8.0
- },
- "tiers": [
- {
- "id": 0,
- "name": "免费版",
- "price": 0,
- "price_monthly": 0,
- "price_yearly": 0,
- "description": "适合轻度体验",
- "features": [
- "每天3次生成",
- "每月10分钟音频",
- "每次最多2分钟",
- "基础音色5种",
- "标准音质"
- ],
- "limits": {
- "daily_generations": 3,
- "per_generation_limit": 300,
- "monthly_minutes": 10,
- "overage_enabled": false
- },
- "pricing": {
- "in_quota": "¥5/分钟",
- "overage": "不支持超出"
- }
- },
- {
- "id": 1,
- "name": "入门版",
- "price": 19,
- "price_monthly": 19,
- "price_yearly": 190,
- "description": "适合轻度使用",
- "recommended": false,
- "features": [
- "每天10次生成",
- "每月30分钟音频",
- "每次最多5分钟",
- "全部音色",
- "高清音质"
- ],
- "limits": {
- "daily_generations": 10,
- "per_generation_limit": 750,
- "monthly_minutes": 30,
- "overage_enabled": true
- },
- "pricing": {
- "in_quota": "¥5/分钟",
- "overage": "¥8/分钟"
- }
- },
- {
- "id": 2,
- "name": "专业版",
- "price": 59,
- "price_monthly": 59,
- "price_yearly": 590,
- "description": "适合内容创作者 ⭐推荐",
- "recommended": true,
- "features": [
- "无限制生成",
- "每月100分钟音频",
- "每次最多10分钟",
- "全部音色+定制音色",
- "高清音质"
- ],
- "limits": {
- "daily_generations": -1,
- "per_generation_limit": 1500,
- "monthly_minutes": 100,
- "overage_enabled": true
- },
- "pricing": {
- "in_quota": "¥5/分钟",
- "overage": "¥7/分钟"
- }
- },
- {
- "id": 3,
- "name": "旗舰版",
- "price": 199,
- "price_monthly": 199,
- "price_yearly": 1990,
- "description": "适合重度使用",
- "recommended": false,
- "features": [
- "无限制生成",
- "每月400分钟音频",
- "每次最多20分钟",
- "全部音色+定制音色",
- "高清音质",
- "VIP优先队列"
- ],
- "limits": {
- "daily_generations": -1,
- "per_generation_limit": 3000,
- "monthly_minutes": 400,
- "overage_enabled": true
- },
- "pricing": {
- "in_quota": "¥5/分钟",
- "overage": "¥6/分钟"
- }
- },
- {
- "id": 4,
- "name": "企业版",
- "price": 599,
- "price_monthly": 599,
- "price_yearly": 5990,
- "description": "适合企业用户",
- "recommended": false,
- "features": [
- "无限制生成",
- "每月1500分钟音频",
- "每次最多60分钟",
- "全部功能",
- "专属技术支持",
- "批量处理",
- "团队管理"
- ],
- "limits": {
- "daily_generations": -1,
- "per_generation_limit": 9000,
- "monthly_minutes": 1500,
- "overage_enabled": true
- },
- "pricing": {
- "in_quota": "¥5/分钟",
- "overage": "¥5/分钟"
- }
- }
- ]
- },
- "features": [
- {
- "id": 1,
- "description": "套餐系统-数据库模型扩展",
- "backend_test_steps": [
- "1. npx prisma db push - 验证数据库迁移 ✅",
- "2. curl http://localhost:3000/api/subscription/plans - 获取套餐列表 ✅",
- "3. 验证套餐数据显示正确 ✅"
- ],
- "frontend_test_steps": [
- "1. 打开订阅页面 ✅",
- "2. 验证4个套餐卡片显示 ✅",
- "3. 验证套餐价格和功能显示正确 ✅"
- ],
- "status": "done",
- "passes": true
- },
- {
- "id": 2,
- "description": "套餐系统-套餐API接口",
- "backend_test_steps": [
- "1. curl http://localhost:3000/api/subscription/plans - 获取所有套餐 ✅",
- "2. curl http://localhost:3000/api/subscription/plans/1 - 获取单个套餐详情 ✅",
- "3. 验证套餐信息完整 ✅"
- ],
- "frontend_test_steps": [
- "1. 点击套餐卡片 ✅",
- "2. 验证套餐详情弹窗显示 ✅",
- "3. 验证套餐功能列表显示 ✅"
- ],
- "status": "done",
- "passes": true
- },
- {
- "id": 3,
- "description": "Token系统-Token消耗记录表",
- "backend_test_steps": [
- "1. npx prisma db push - 创建TokenUsage表 ✅",
- "2. curl -X POST http://localhost:3000/api/subscription/usage - 记录token使用 ✅",
- "3. curl http://localhost:3000/api/subscription/usage - 获取token使用记录 ✅"
- ],
- "frontend_test_steps": [
- "1. 打开个人中心 ✅",
- "2. 查看Token使用记录 ✅",
- "3. 验证使用量统计显示 ✅"
- ],
- "status": "done",
- "passes": true
- },
- {
- "id": 4,
- "description": "Token系统-Token余额查询",
- "backend_test_steps": [
- "1. curl http://localhost:3000/api/subscription/balance - 获取当前用户token余额 ✅",
- "2. 验证返回剩余token数量和配额 ✅",
- "3. curl http://localhost:3000/api/subscription/quota - 获取用户配额 ✅"
- ],
- "frontend_test_steps": [
- "1. 首页显示当前配额 ✅",
- "2. 创建页面显示剩余token ✅",
- "3. 验证配额显示正确 ✅"
- ],
- "status": "done",
- "passes": true
- },
- {
- "id": 5,
- "description": "Token系统-Token扣费逻辑",
- "backend_test_steps": [
- "1. curl -X POST http://localhost:3000/api/tts - 生成音频时验证token扣费 (待集成)",
- "2. 检查数据库TokenUsage表记录 (待集成)",
- "3. 验证token不足时的错误处理 (待集成)"
- ],
- "frontend_test_steps": [
- "1. 生成音频后查看Token消耗 (待集成)",
- "2. 验证使用量实时更新 (待集成)",
- "3. 验证余额不足提示 (待集成)"
- ],
- "status": "pending",
- "passes": false
- },
- {
- "id": 6,
- "description": "支付系统-支付宝集成",
- "backend_test_steps": [
- "1. 配置支付宝沙箱环境 (待配置)",
- "2. curl -X POST http://localhost:3000/api/payment/alipay - 创建支付宝订单 (接口已就绪)",
- "3. 验证返回支付宝支付链接 (待配置)",
- "4. curl http://localhost:3000/api/payment/alipay/callback - 模拟回调 (接口已就绪)"
- ],
- "frontend_test_steps": [
- "1. 选择基础版套餐 ✅",
- "2. 点击支付宝支付 ✅",
- "3. 验证跳转到支付宝页面 (待配置真实支付)"
- ],
- "status": "pending",
- "passes": false
- },
- {
- "id": 7,
- "description": "支付系统-微信支付集成",
- "backend_test_steps": [
- "1. 配置微信支付沙箱环境 (待配置)",
- "2. curl -X POST http://localhost:3000/api/payment/wechat - 创建微信支付订单 (接口已就绪)",
- "3. 验证返回微信支付二维码 (待配置)",
- "4. curl http://localhost:3000/api/payment/wechat/callback - 模拟回调 (接口已就绪)"
- ],
- "frontend_test_steps": [
- "1. 选择专业版套餐 ✅",
- "2. 点击微信支付 ✅",
- "3. 验证显示微信二维码 (待配置真实支付)"
- ],
- "status": "pending",
- "passes": false
- },
- {
- "id": 8,
- "description": "支付系统-支付回调处理",
- "backend_test_steps": [
- "1. 实现支付宝异步回调 ✅",
- "2. 实现微信支付异步回调 ✅",
- "3. 验证订单状态更新 ✅",
- "4. 验证会员状态和token配额更新 ✅"
- ],
- "frontend_test_steps": [
- "1. 支付完成后验证页面跳转 ✅",
- "2. 验证会员状态更新 ✅",
- "3. 验证Token配额更新 ✅"
- ],
- "status": "done",
- "passes": true
- },
- {
- "id": 9,
- "description": "前端-订阅套餐页面",
- "backend_test_steps": [],
- "frontend_test_steps": [
- "1. 打开订阅页面 /pages/subscription/index ✅",
- "2. 验证4个套餐卡片显示 ✅",
- "3. 点击套餐选择支付方式 ✅",
- "4. 验证支付流程完整 ✅"
- ],
- "status": "done",
- "passes": true
- },
- {
- "id": 10,
- "description": "前端-Token使用记录页面",
- "backend_test_steps": [],
- "frontend_test_steps": [
- "1. 打开个人中心 /pages/user/index ✅",
- "2. 查看Token余额和配额 ✅",
- "3. 查看Token使用历史 ✅",
- "4. 验证列表分页正常 ✅"
- ],
- "status": "done",
- "passes": true
- },
- {
- "id": 11,
- "description": "前端-订单历史页面",
- "backend_test_steps": [],
- "frontend_test_steps": [
- "1. 打开订单历史 /pages/orders/index ✅",
- "2. 验证订单列表显示 ✅",
- "3. 查看订单详情 ✅",
- "4. 验证订单状态标签 ✅"
- ],
- "status": "done",
- "passes": true
- },
- {
- "id": 12,
- "description": "前端-套餐推荐和对比页面",
- "backend_test_steps": [],
- "frontend_test_steps": [
- "1. 打开订阅页面 ✅",
- "2. 验证套餐对比表显示 ✅",
- "3. 验证推荐标识正确 ✅",
- "4. 验证价格计算正确 ✅"
- ],
- "status": "done",
- "passes": true
- }
- ]
- }
|