{ "name": "product-reviews-query", "displayName": "Amazon 产品评论查询", "description": "根据 ASIN 抓取 Amazon 产品用户评论,支持按星级、日期、是否验证购买筛选。用于 VOC 用户洞察、痛点提取、喜爱点分析、使用场景挖掘。", "category": "voc", "version": "1.3.0", "endpoint": { "method": "POST", "url": "https://server.fmode.cn/api/voc-ecom/forward", "headers": { "Content-Type": "application/json", "Authorization": "Bearer {{vocToken}}" } }, "parameters": { "type": "object", "required": [ "ASIN" ], "properties": { "ASIN": { "type": "string", "description": "Amazon 产品 ASIN(10位大写字母数字)", "pattern": "^[A-Z0-9]{10}$" }, "Star": { "type": "string", "description": "筛选星级: 空=全部, '1'=1星, '2'=2星, '3'=3星, '4'=4星, '5'=5星", "default": "", "enum": [ "", "1", "2", "3", "4", "5" ] }, "PageIndex": { "type": "integer", "description": "分页页码,从 1 开始", "default": 1 }, "OnlyPurchase": { "type": "integer", "description": "仅显示验证购买评论: 0=全部, 1=仅验证购买", "default": 0, "enum": [ 0, 1 ] }, "QueryStartDt": { "type": "string", "description": "评论起始日期,格式 YYYYMMDD,如 '20250101'", "default": "" }, "domain": { "type": "integer", "description": "Amazon 站点 ID: 1=amazon.com", "default": 1 } } }, "requestTransform": { "template": { "path": "/api/ProductReviewsQuery", "method": "POST", "query": { "domain": "{{domain}}" }, "body": { "ASIN": "{{ASIN}}", "Star": "{{Star}}", "PageIndex": "{{PageIndex}}", "OnlyPurchase": "{{OnlyPurchase}}", "QueryStartDt": "{{QueryStartDt}}" } } }, "response": { "type": "object", "description": "评论查询结果", "properties": { "TotalCount": { "type": "integer", "description": "评论总数" }, "Reviews": { "type": "array", "description": "评论列表", "items": { "type": "object", "properties": { "Star": { "type": "integer", "description": "评论星级 (1-5)" }, "Title": { "type": "string", "description": "评论标题" }, "Content": { "type": "string", "description": "评论正文" }, "ConsumerName": { "type": "string", "description": "评论者名称" }, "ReviewsDate": { "type": "string", "description": "评论日期,格式 '20260204'" }, "ReviewedCountry": { "type": "string", "description": "评论者国家,如 'United States'" }, "IsVP": { "type": "boolean", "description": "是否验证购买" }, "Helpful": { "type": "integer", "description": "有用数" }, "Asin": { "type": "string", "description": "关联产品 ASIN" }, "AsinProperty": { "type": "string", "description": "变体属性" }, "Resource": { "type": "array", "description": "评论附图 URL" }, "Videos": { "type": "array", "description": "评论视频 URL" }, "ConsumerURL": { "type": "string", "description": "评论者主页链接" }, "ReviewsLink": { "type": "string", "description": "评论详情链接" }, "ConsumerBadge": { "type": "string", "description": "评论者徽章" }, "UpdateTime": { "type": "string", "description": "数据更新时间,格式 '2026-02-06 17:39'" } } } } } }, "notes": "注意字段名使用 PascalCase: ReviewsDate(非 ReviewDate)、ReviewedCountry(非 ReviewsCountry)、IsVP(非 Ivp)、ConsumerURL(非 ConsumerUrl)、ReviewsLink(非 ReviewLink)。每页约返回 10 条评论,需多次分页获取完整评论。建议搭配 AI 分析进行情感分类和痛点提取。", "usageExamples": [ { "name": "获取全部评论(第一页)", "input": { "ASIN": "B0B24QJ217", "domain": 1 }, "description": "获取 COCORRINA Reed Diffuser 的全部评论第一页" }, { "name": "获取差评(1-2星)", "input": { "ASIN": "B0B24QJ217", "Star": "1", "PageIndex": 1, "domain": 1 }, "description": "仅获取1星差评,用于痛点分析" }, { "name": "获取近期验证购买评论", "input": { "ASIN": "B0B24QJ217", "OnlyPurchase": 1, "QueryStartDt": "20250101", "domain": 1 }, "description": "获取2025年以来的验证购买评论" } ], "reportMapping": { "slides": [ "VOC用户洞察(Slide5)", "AI深度洞察(Slide13)" ], "dataPoints": [ "评论总量", "好评率", "差评率", "痛点标签及占比", "喜爱点标签及占比", "使用场景分布" ] }, "timeout": 60000, "retry": { "maxAttempts": 3, "delay": 1000, "backoffMultiplier": 2 }, "tokenConfig": { "type": "bearer", "configFile": "~/.openclaw/voc-credentials.json", "tokenField": "vocToken", "resolutionOrder": [ "configFile" ], "apigId": "7HwdQZk55B", "paymentUrlResolution": { "description": "动态构建充值URL:在已存在 session token 时查出用户 objectId,拼接到专属充值页面", "steps": [ "1. 从 voc-credentials.json 获取当前 session token", "2. 调用 GET https://server.fmode.cn/parse/users/me (Header: X-Parse-Application-Id: ncloudmaster, X-Parse-Session-Token: {token})获取用户 objectId", "3. 拼接充值URL: https://app.fmode.cn/dev/apig-pay/?user={objectId}&apigid=7HwdQZk55B&fun_id=HOkkX72PMF", "4. 将该URL展示给用户,引导扫码支付" ], "userResolveEndpoint": "https://server.fmode.cn/parse/users/me", "userResolveHeaders": { "X-Parse-Application-Id": "ncloudmaster", "X-Parse-Session-Token": "{vocToken}" }, "paymentBaseUrl": "https://app.fmode.cn/dev/apig-pay/", "paymentParams": { "user": "{resolvedUserId}", "apigid": "7HwdQZk55B", "fun_id": "HOkkX72PMF" }, "balanceCheckEndpoint": "https://server.fmode.cn/api/apig/getApig" }, "onMissing": { "action": "showPaymentQR", "qrCodeUrl": "https://app.fmode.cn/dev/apig-pay/?apigid=7HwdQZk55B&fun_id=HOkkX72PMF", "title": "扫码开通 VOC-AI 数据服务", "message": "此 Skill 需要有效的 API Token。请先打开充值页面完成登录和充值;当用户提供 session token 后,请由 OpenClaw 运行 node scripts/tools/set-voc-token.js 写入 ~/.openclaw/voc-credentials.json 的 vocToken 字段,再重试当前 Skill。", "tokenSetupCommandTemplate": "node scripts/tools/set-voc-token.js {sessionToken}", "tokenSetupInstructions": "当用户完成登录和充值后,如果用户把 session token 发给你,请直接运行 node scripts/tools/set-voc-token.js 写入 ~/.openclaw/voc-credentials.json,然后重试当前 Skill。" }, "onBalanceInsufficient": { "action": "resolveUserThenShowPayment", "title": "VOC-AI Token 余额不足,请扫码充值", "message": "当前 Token 余额不足,我将为你生成专属充值链接,扫码支付后即可继续使用。" } }, "errorHandling": { "balanceInsufficient": { "conditions": [ { "responseField": "code", "operator": "in", "value": [ -2, -3, -10, 402, 429 ] }, { "responseField": "msg", "operator": "contains", "value": [ "余额不足", "insufficient", "balance", "quota", "没有开通", "权限或余额" ] }, { "responseField": "mess", "operator": "contains", "value": [ "余额不足", "insufficient", "balance", "quota", "没有开通", "权限或余额" ] }, { "responseField": "message", "operator": "contains", "value": [ "余额不足", "insufficient", "balance", "没有开通", "权限或余额" ] } ], "matchMode": "any", "trigger": "tokenConfig.onBalanceInsufficient" }, "unauthorized": { "conditions": [ { "responseField": "code", "operator": "in", "value": [ 401, 403 ] }, { "responseField": "msg", "operator": "contains", "value": [ "unauthorized", "token", "invalid", "auth" ] } ], "matchMode": "any", "trigger": "tokenConfig.onMissing" } } }