api-config.json 5.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220
  1. {
  2. "name": "product-detail-query",
  3. "displayName": "Amazon 产品详情查询",
  4. "description": "根据 ASIN 获取 Amazon 产品详情,包括标题、价格、评分、销量、BSR、品牌、类目、变体、趋势等完整信息。用于竞品分析、市场全景、定价策略。",
  5. "category": "voc",
  6. "version": "1.1.0",
  7. "endpoint": {
  8. "method": "POST",
  9. "url": "https://server.fmode.cn/api/voc/forward",
  10. "headers": {
  11. "Content-Type": "application/json",
  12. "Authorization": "Bearer r:858b3ee92314d5447d1fc3cdc10462d7"
  13. }
  14. },
  15. "parameters": {
  16. "type": "object",
  17. "required": [
  18. "ASIN"
  19. ],
  20. "properties": {
  21. "ASIN": {
  22. "type": "string",
  23. "description": "Amazon 产品唯一标识符(10位字母数字),必须大写。例:B0CSVRWJ1H",
  24. "pattern": "^[A-Z0-9]{10}$"
  25. },
  26. "domain": {
  27. "type": "integer",
  28. "description": "Amazon 站点 ID: 1=amazon.com, 2=amazon.co.uk, 3=amazon.de, 4=amazon.co.jp, 5=amazon.fr, 6=amazon.it, 7=amazon.es, 8=amazon.ca",
  29. "default": 1,
  30. "enum": [
  31. 1,
  32. 2,
  33. 3,
  34. 4,
  35. 5,
  36. 6,
  37. 7,
  38. 8
  39. ]
  40. },
  41. "Trend": {
  42. "type": "integer",
  43. "description": "是否返回趋势数据: 1=是, 0=否",
  44. "default": 1,
  45. "enum": [
  46. 0,
  47. 1
  48. ]
  49. },
  50. "QueryTrendStartDt": {
  51. "type": "string",
  52. "description": "趋势数据起始日期,格式 YYYYMMDD,留空则使用默认范围",
  53. "default": ""
  54. },
  55. "QueryTrendEndDt": {
  56. "type": "string",
  57. "description": "趋势数据结束日期,格式 YYYYMMDD,留空则使用默认范围",
  58. "default": ""
  59. }
  60. }
  61. },
  62. "requestTransform": {
  63. "description": "将参数转换为 Sorftime forward 格式",
  64. "template": {
  65. "path": "/api/ProductRequest",
  66. "method": "POST",
  67. "query": {
  68. "domain": "{{domain}}"
  69. },
  70. "body": {
  71. "ASIN": "{{ASIN}}",
  72. "Trend": "{{Trend}}",
  73. "QueryTrendStartDt": "{{QueryTrendStartDt}}",
  74. "QueryTrendEndDt": "{{QueryTrendEndDt}}"
  75. }
  76. }
  77. },
  78. "response": {
  79. "type": "object",
  80. "description": "产品详情对象",
  81. "properties": {
  82. "Title": {
  83. "type": "string",
  84. "description": "产品标题"
  85. },
  86. "Price": {
  87. "type": "number",
  88. "description": "当前售价(美元)"
  89. },
  90. "SalesPrice": {
  91. "type": "number",
  92. "description": "促销价(美元)"
  93. },
  94. "Brand": {
  95. "type": "string",
  96. "description": "品牌名称"
  97. },
  98. "StoreName": {
  99. "type": "string",
  100. "description": "店铺名称"
  101. },
  102. "Rating": {
  103. "type": "number",
  104. "description": "平均评分 (0-5)"
  105. },
  106. "RatingsCount": {
  107. "type": "integer",
  108. "description": "评论总数"
  109. },
  110. "fiveStartRatings": {
  111. "type": "number",
  112. "description": "5星评分百分比"
  113. },
  114. "fourStartRatings": {
  115. "type": "number",
  116. "description": "4星评分百分比"
  117. },
  118. "threeStartRatings": {
  119. "type": "number",
  120. "description": "3星评分百分比"
  121. },
  122. "twoStartRatings": {
  123. "type": "number",
  124. "description": "2星评分百分比"
  125. },
  126. "oneStartRatings": {
  127. "type": "number",
  128. "description": "1星评分百分比"
  129. },
  130. "MonthlySales": {
  131. "type": "integer",
  132. "description": "月销量估算"
  133. },
  134. "BSR": {
  135. "type": "integer",
  136. "description": "Best Sellers Rank 大类排名"
  137. },
  138. "Category": {
  139. "type": "array",
  140. "description": "类目层级"
  141. },
  142. "BsrCategory": {
  143. "type": "array",
  144. "description": "BSR 类目层级"
  145. },
  146. "Photo": {
  147. "type": "array",
  148. "description": "产品图片 URL 列表"
  149. },
  150. "Feature": {
  151. "type": "object",
  152. "description": "产品 Bullet Points 卖点"
  153. },
  154. "Description": {
  155. "type": "string",
  156. "description": "产品描述"
  157. },
  158. "Property": {
  159. "type": "string",
  160. "description": "产品属性(JSON 字符串)"
  161. },
  162. "VariationASIN": {
  163. "type": "array",
  164. "description": "变体 ASIN 列表"
  165. },
  166. "Size": {
  167. "type": "array",
  168. "description": "尺寸选项"
  169. },
  170. "ShipsFrom": {
  171. "type": "string",
  172. "description": "发货地"
  173. },
  174. "ProductType": {
  175. "type": "string",
  176. "description": "配送类型 (FBA/FBM)"
  177. },
  178. "DealType": {
  179. "type": "string",
  180. "description": "促销类型"
  181. },
  182. "UpdateDate": {
  183. "type": "string",
  184. "description": "数据更新日期"
  185. }
  186. }
  187. },
  188. "usageExamples": [
  189. {
  190. "name": "查询单个产品详情",
  191. "input": {
  192. "ASIN": "B0CSVRWJ1H",
  193. "domain": 1,
  194. "Trend": 1
  195. },
  196. "description": "获取美国站产品 B0CSVRWJ1H 的完整信息和趋势数据"
  197. }
  198. ],
  199. "reportMapping": {
  200. "slides": [
  201. "市场全景(Slide3)",
  202. "竞品对标(Slide4)",
  203. "品类矩阵(Slide6)"
  204. ],
  205. "dataPoints": [
  206. "价格",
  207. "评分",
  208. "月销量",
  209. "BSR",
  210. "品牌",
  211. "类目"
  212. ]
  213. },
  214. "timeout": 10000,
  215. "retry": {
  216. "maxAttempts": 3,
  217. "delay": 1000,
  218. "backoffMultiplier": 2
  219. }
  220. }