商品销量是直接评判卖得好不好的依据,也是计算销售额的基础。自己店铺的商品,销售情况在后台当然能够看得到,但竟店、品牌以及行业的数据要看就麻烦了。相信很多企业、商家甚至是个人都会有这样的需求,本文就分享下商品销量的采集方法。
PC端
Chrome随便打开一个商品,可以看到页面上显示了月销量,一定要登录才能看到哦。
然后直接F12打开开发者工具,搜索3509,出来的有很多,筛选下就能找到正确的接口。能不能快速找到就看个人经验了,主要就搜索相关关键词,老司机很快都能找到的。
没错,就是这个接口了
请求头:
https://detailskip.taobao.com/service/getData/1/p1/item/detail/sib.htm?itemId=573678898150&sellerId=3969446167&modules=dynStock,qrcode,viewer,price,duty,xmpPromotion,delivery,upp,activity,fqg,zjys,couponActivity,soldQuantity,page,originalPrice,tradeContract&callback=onSibRequestSuccess
响应数据:
onSibRequestSuccess({"code":{"code":0,"message":"SUCCESS"},"data":{"viewer":{"admin":false,"bs":"149","buyDomain":"buy.taobao.com","buyerId":"755832606","cartDomain":"cart.taobao.com","cc":false,"countryCode":"CN","ctUser":false,"lgin":true,"serviceTab":"ITEM","tkn":"97b36ee76e0b"},"deliveryFee":{"data":{"areaId":330109,"areaName":"\u6D59\u6C5F\u676D\u5DDE\u8427\u5C71\u533A","sendCity":"\u6D59\u6C5F\u91D1\u534E","serviceInfo":{"sku":{"3931588103184":[{"id":"100_-4","info":"\u5FEB\u9012 \u514D\u8FD0\u8D39","isDefault":true,"markInfo":"\u73B0\u8D27 \u4ED8\u6B3E\u540E48\u5C0F\u65F6\u5185\u53D1\u8D27\uFF0C\u9884\u8BA111\u670822\u65E5\u9001\u8FBE"}],"4760161323126":[{"id":"100_-4","info":"\u5FEB\u9012 \u514D\u8FD0\u8D39","isDefault":true,"markInfo":"\u73B0\u8D27 \u4ED8\u6B3E\u540E48\u5C0F\u65F6\u5185\u53D1\u8D27\uFF0C\u9884\u8BA111\u670822\u65E5\u9001\u8FBE"}],"3743723708220":[{"id":"100_-4","info":"\u5FEB\u9012 \u514D\u8FD0\u8D39","isDefault":true,"markInfo":"\u73B0\u8D27 \u4ED8\u6B3E\u540E48\u5C0F\u65F6\u5185\u53D1\u8D27\uFF0C\u9884\u8BA111\u670822\u65E5\u9001\u8FBE"}],"3743723708221":[{"id":"100_-4","info":"\u5FEB\u9012 \u514D\u8FD0\u8D39","isDefault":true,"markInfo":"\u73B0\u8D27 \u4ED8\u6B3E\u540E48\u5C0F\u65F6\u5185\u53D1\u8D27\uFF0C\u9884\u8BA111\u670822\u65E5\u9001\u8FBE"}],"3743723708222":[{"id":"100_-4","info":"\u5FEB\u9012 \u514D\u8FD0\u8D39","isDefault":true,"markInfo":"\u73B0\u8D27 \u4ED8\u6B3E\u540E48\u5C0F\u65F6\u5185\u53D1\u8D27\uFF0C\u9884\u8BA111\u670822\u65E5\u9001\u8FBE"}],"3743723708223":[{"id":"100_-4","info":"\u5FEB\u9012 \u514D\u8FD0\u8D39","isDefault":true,"markInfo":"\u73B0\u8D27 \u4ED8\u6B3E\u540E48\u5C0F\u65F6\u5185\u53D1\u8D27\uFF0C\u9884\u8BA111\u670822\u65E5\u9001\u8FBE"}],"3743723708224":[{"id":"100_-4","info":"\u5FEB\u9012 \u514D\u8FD0\u8D39","isDefault":true,"markInfo":"\u73B0\u8D27 \u4ED8\u6B3E\u540E48\u5C0F\u65F6\u5185\u53D1\u8D27\uFF0C\u9884\u8BA111\u670822\u65E5\u9001\u8FBE"}],"3743723708225":[{"id":"100_-4","info":"\u5FEB\u9012 \u514D\u8FD0\u8D39","isDefault":true,"markInfo":"\u73B0\u8D27 \u4ED8\u6B3E\u540E48\u5C0F\u65F6\u5185\u53D1\u8D27\uFF0C\u9884\u8BA111\u670822\u65E5\u9001\u8FBE"}],"3936973055769":[{"id":"100_-4","info":"\u5FEB\u9012 \u514D\u8FD0\u8D39","isDefault":true,"markInfo":"\u73B0\u8D27 \u4ED8\u6B3E\u540E48\u5C0F\u65F6\u5185\u53D1\u8D27\uFF0C\u9884\u8BA111\u670822\u65E5\u9001\u8FBE"}],"3743723708226":[{"id":"100_-4","info":"\u5FEB\u9012 \u514D\u8FD0\u8D39","isDefault":true,"markInfo":"\u73B0\u8D27 \u4ED8\u6B3E\u540E48\u5C0F\u65F6\u5185\u53D1\u8D27\uFF0C\u9884\u8BA111\u670822\u65E5\u9001\u8FBE"}],"3743723708227":[{"id":"100_-4","info":"\u5FEB\u9012 \u514D\u8FD0\u8D39","isDefault":true,"markInfo":"\u73B0\u8D27 \u4ED8\u6B3E\u540E48\u5C0F\u65F6\u5185\u53D1\u8D27\uFF0C\u9884\u8BA111\u670822\u65E5\u9001\u8FBE"}],"3743723708228":[{"id":"100_-4","info":"\u5FEB\u9012 \u514D\u8FD0\u8D39","isDefault":true,"markInfo":"\u73B0\u8D27 \u4ED8\u6B3E\u540E48\u5C0F\u65F6\u5185\u53D1\u8D27\uFF0C\u9884\u8BA111\u670822\u65E5\u9001\u8FBE"}],"3743723708229":[{"id":"100_-4","info":"\u5FEB\u9012 \u514D\u8FD0\u8D39","isDefault":true,"markInfo":"\u73B0\u8D27 \u4ED8\u6B3E\u540E48\u5C0F\u65F6\u5185\u53D1\u8D27\uFF0C\u9884\u8BA111\u670822\u65E5\u9001\u8FBE"}],"default":[{"id":"100_-4","info":"\u5FEB\u9012 \u514D\u8FD0\u8D39","isDefault":true,"markInfo":"\u73B0\u8D27 \u4ED8\u6B3E\u540E48\u5C0F\u65F6\u5185\u53D1\u8D27\uFF0C\u9884\u8BA111\u670822\u65E5\u9001\u8FBE"}],"4416136758870":[{"id":"100_-4","info":"\u5FEB\u9012 \u514D\u8FD0\u8D39","isDefault":true,"markInfo":"\u73B0\u8D27 \u4ED8\u6B3E\u540E48\u5C0F\u65F6\u5185\u53D1\u8D27\uFF0C\u9884\u8BA111\u670822\u65E5\u9001\u8FBE"}],"4310586218759":[{"id":"100_-4","info":"\u5FEB\u9012 \u514D\u8FD0\u8D39","isDefault":true,"markInfo":"\u73B0\u8D27 \u4ED8\u6B3E\u540E48\u5C0F\u65F6\u5185\u53D1\u8D27\uFF0C\u9884\u8BA111\u670822\u65E5\u9001\u8FBE"}],"4464222204758":[{"id":"100_-4","info":"\u5FEB\u9012 \u514D\u8FD0\u8D39","isDefault":true,"markInfo":"\u73B0\u8D27 \u4ED8\u6B3E\u540E48\u5C0F\u65F6\u5185\u53D1\u8D27\uFF0C\u9884\u8BA111\u670822\u65E5\u9001\u8FBE"}],"3743723708230":[{"id":"100_-4","info":"\u5FEB\u9012 \u514D\u8FD0\u8D39","isDefault":true,"markInfo":"\u73B0\u8D27 \u4ED8\u6B3E\u540E48\u5C0F\u65F6\u5185\u53D1\u8D27\uFF0C\u9884\u8BA111\u670822\u65E5\u9001\u8FBE"}],"3743723708231":[{"id":"100_-4","info":"\u5FEB\u9012 \u514D\u8FD0\u8D39","isDefault":true,"markInfo":"\u73B0\u8D27 \u4ED8\u6B3E\u540E48\u5C0F\u65F6\u5185\u53D1\u8D27\uFF0C\u9884\u8BA111\u670822\u65E5\u9001\u8FBE"}],"3743723708232":[{"id":"100_-4","info":"\u5FEB\u9012 \u514D\u8FD0\u8D39","isDefault":true,"markInfo":"\u73B0\u8D27 \u4ED8\u6B3E\u540E48\u5C0F\u65F6\u5185\u53D1\u8D27\uFF0C\u9884\u8BA111\u670822\u65E5\u9001\u8FBE"}],"3743723708233":[{"id":"100_-4","info":"\u5FEB\u9012 \u514D\u8FD0\u8D39","isDefault":true,"markInfo":"\u73B0\u8D27 \u4ED8\u6B3E\u540E48\u5C0F\u65F6\u5185\u53D1\u8D27\uFF0C\u9884\u8BA111\u670822\u65E5\u9001\u8FBE"}],"3743723708234":[{"id":"100_-4","info":"\u5FEB\u9012 \u514D\u8FD0\u8D39","isDefault":true,"markInfo":"\u73B0\u8D27 \u4ED8\u6B3E\u540E48\u5C0F\u65F6\u5185\u53D1\u8D27\uFF0C\u9884\u8BA111\u670822\u65E5\u9001\u8FBE"}],"3743723708235":[{"id":"100_-4","info":"\u5FEB\u9012 \u514D\u8FD0\u8D39","isDefault":true,"markInfo":"\u73B0\u8D27 \u4ED8\u6B3E\u540E48\u5C0F\u65F6\u5185\u53D1\u8D27\uFF0C\u9884\u8BA111\u670822\u65E5\u9001\u8FBE"}],"3743723708238":[{"id":"100_-4","info":"\u5FEB\u9012 \u514D\u8FD0\u8D39","isDefault":true,"markInfo":"\u73B0\u8D27 \u4ED8\u6B3E\u540E48\u5C0F\u65F6\u5185\u53D1\u8D27\uFF0C\u9884\u8BA111\u670822\u65E5\u9001\u8FBE"}],"4464222204757":[{"id":"100_-4","info":"\u5FEB\u9012 \u514D\u8FD0\u8D39","isDefault":true,"markInfo":"\u73B0\u8D27 \u4ED8\u6B3E\u540E48\u5C0F\u65F6\u5185\u53D1\u8D27\uFF0C\u9884\u8BA111\u670822\u65E5\u9001\u8FBE"}],"3743723708239":[{"id":"100_-4","info":"\u5FEB\u9012 \u514D\u8FD0\u8D39","isDefault":true,"markInfo":"\u73B0\u8D27 \u4ED8\u6B3E\u540E48\u5C0F\u65F6\u5185\u53D1\u8D27\uFF0C\u9884\u8BA111\u670822\u65E5\u9001\u8FBE"}],"3743723708218":[{"id":"100_-4","info":"\u5FEB\u9012 \u514D\u8FD0\u8D39","isDefault":true,"markInfo":"\u73B0\u8D27 \u4ED8\u6B3E\u540E48\u5C0F\u65F6\u5185\u53D1\u8D27\uFF0C\u9884\u8BA111\u670822\u65E5\u9001\u8FBE"}],"3743723708219":[{"id":"100_-4","info":"\u5FEB\u9012 \u514D\u8FD0\u8D39","isDefault":true,"markInfo":"\u73B0\u8D27 \u4ED8\u6B3E\u540E48\u5C0F\u65F6\u5185\u53D1\u8D27\uFF0C\u9884\u8BA111\u670822\u65E5\u9001\u8FBE"}],"4328374144896":[{"id":"100_-4","info":"\u5FEB\u9012 \u514D\u8FD0\u8D39","isDefault":true,"markInfo":"\u73B0\u8D27 \u4ED8\u6B3E\u540E48\u5C0F\u65F6\u5185\u53D1\u8D27\uFF0C\u9884\u8BA111\u670822\u65E5\u9001\u8FBE"}],"3924267871090":[{"id":"100_-4","info":"\u5FEB\u9012 \u514D\u8FD0\u8D39","isDefault":true,"markInfo":"\u73B0\u8D27 \u4ED8\u6B3E\u540E48\u5C0F\u65F6\u5185\u53D1\u8D27\uFF0C\u9884\u8BA111\u670822\u65E5\u9001\u8FBE"}]}}},"dataUrl":"\/\/detailskip.taobao.com\/json\/deliveryFee.htm","message":"ok","success":true},"originalPrice":{";1627207:28334;":{"price":"5.01"},";1627207:80557;":{"price":"5.01"},";1627207:28326;":{"price":"5.01"},"def":{"price":"5.01"},";1627207:28320;":{"price":"5.01"},";1627207:80882;":{"price":"5.01"},";1627207:4918587664;":{"price":"5.01"},";1627207:3232479;":{"price":"5.01"},";1627207:21178725;":{"price":"5.01"},";1627207:15409374;":{"price":"5.01"},";1627207:7447408;":{"price":"5.01"},";1627207:39491616;":{"price":"5.01"},";1627207:3232483;":{"price":"5.01"},";1627207:20412615;":{"price":"5.01"},";1627207:5483105;":{"price":"5.01"},";1627207:12367710720;":{"price":"5.01"},";1627207:28341;":{"price":"5.01"},";1627207:3594022;":{"price":"5.01"},";1627207:3883690;":{"price":"5.01"},";1627207:3232484;":{"price":"5.01"},";1627207:6535235;":{"price":"5.01"},";1627207:90554;":{"price":"5.01"},";1627207:3232480;":{"price":"5.01"},";1627207:28866;":{"price":"5.01"},";1627207:3819996;":{"price":"5.01"},";1627207:52813;":{"price":"5.01"},";1627207:28327;":{"price":"5.01"},";1627207:129819;":{"price":"5.01"},";1627207:13808289;":{"price":"5.01"},";1627207:3707775;":{"price":"5.01"}},"upp":{"-2":"\u6DD8\u91D1\u5E01\u6700\u9AD8\u53EF\u62B5\u5546\u54C1\u4EF7<em class='tb-h'> 3%<\/em>","-5":"<em class='tb_red'><strong>15<\/strong>\u6DD8\u91D1\u5E01<\/em><em class='tb_dashes_box'> \u62B5\uFFE50.15<\/em> <em class='tb_tjb_price'>\uFFE54.85<\/em>","3743723708221":"<em class='tb_red'><strong>15<\/strong>\u6DD8\u91D1\u5E01<\/em><em class='tb_dashes_box'> \u62B5\uFFE50.15<\/em> <em class='tb_tjb_price'>\uFFE54.85<\/em>","3743723708220":"<em class='tb_red'><strong>15<\/strong>\u6DD8\u91D1\u5E01<\/em><em class='tb_dashes_box'> \u62B5\uFFE50.15<\/em> <em class='tb_tjb_price'>\uFFE54.85<\/em>","3743723708223":"<em class='tb_red'><strong>15<\/strong>\u6DD8\u91D1\u5E01<\/em><em class='tb_dashes_box'> \u62B5\uFFE50.15<\/em> <em class='tb_tjb_price'>\uFFE54.85<\/em>","3743723708222":"<em class='tb_red'><strong>15<\/strong>\u6DD8\u91D1\u5E01<\/em><em class='tb_dashes_box'> \u62B5\uFFE50.15<\/em> <em class='tb_tjb_price'>\uFFE54.85<\/em>","3743723708219":"<em class='tb_red'><strong>15<\/strong>\u6DD8\u91D1\u5E01<\/em><em class='tb_dashes_box'> \u62B5\uFFE50.15<\/em> <em class='tb_tjb_price'>\uFFE54.85<\/em>","3743723708218":"<em class='tb_red'><strong>15<\/strong>\u6DD8\u91D1\u5E01<\/em><em class='tb_dashes_box'> \u62B5\uFFE50.15<\/em> <em class='tb_tjb_price'>\uFFE54.85<\/em>","4416136758870":"<em class='tb_red'><strong>15<\/strong>\u6DD8\u91D1\u5E01<\/em><em class='tb_dashes_box'> \u62B5\uFFE50.15<\/em> <em class='tb_tjb_price'>\uFFE54.85<\/em>","4310586218759":"<em class='tb_red'><strong>15<\/strong>\u6DD8\u91D1\u5E01<\/em><em class='tb_dashes_box'> \u62B5\uFFE50.15<\/em> <em class='tb_tjb_price'>\uFFE54.85<\/em>","4328374144896":"<em class='tb_red'><strong>15<\/strong>\u6DD8\u91D1\u5E01<\/em><em class='tb_dashes_box'> \u62B5\uFFE50.15<\/em> <em class='tb_tjb_price'>\uFFE54.85<\/em>","4760161323126":"<em class='tb_red'><strong>15<\/strong>\u6DD8\u91D1\u5E01<\/em><em class='tb_dashes_box'> \u62B5\uFFE50.15<\/em> <em class='tb_tjb_price'>\uFFE54.85<\/em>","3931588103184":"<em class='tb_red'><strong>15<\/strong>\u6DD8\u91D1\u5E01<\/em><em class='tb_dashes_box'> \u62B5\uFFE50.15<\/em> <em class='tb_tjb_price'>\uFFE54.85<\/em>","3936973055769":"<em class='tb_red'><strong>15<\/strong>\u6DD8\u91D1\u5E01<\/em><em class='tb_dashes_box'> \u62B5\uFFE50.15<\/em> <em class='tb_tjb_price'>\uFFE54.85<\/em>","3743723708229":"<em class='tb_red'><strong>15<\/strong>\u6DD8\u91D1\u5E01<\/em><em class='tb_dashes_box'> \u62B5\uFFE50.15<\/em> <em class='tb_tjb_price'>\uFFE54.85<\/em>","3743723708228":"<em class='tb_red'><strong>15<\/strong>\u6DD8\u91D1\u5E01<\/em><em class='tb_dashes_box'> \u62B5\uFFE50.15<\/em> <em class='tb_tjb_price'>\uFFE54.85<\/em>","3743723708231":"<em class='tb_red'><strong>15<\/strong>\u6DD8\u91D1\u5E01<\/em><em class='tb_dashes_box'> \u62B5\uFFE50.15<\/em> <em class='tb_tjb_price'>\uFFE54.85<\/em>","3743723708230":"<em class='tb_red'><strong>15<\/strong>\u6DD8\u91D1\u5E01<\/em><em class='tb_dashes_box'> \u62B5\uFFE50.15<\/em> <em class='tb_tjb_price'>\uFFE54.85<\/em>","3743723708225":"<em class='tb_red'><strong>15<\/strong>\u6DD8\u91D1\u5E01<\/em><em class='tb_dashes_box'> \u62B5\uFFE50.15<\/em> <em class='tb_tjb_price'>\uFFE54.85<\/em>","3924267871090":"<em class='tb_red'><strong>15<\/strong>\u6DD8\u91D1\u5E01<\/em><em class='tb_dashes_box'> \u62B5\uFFE50.15<\/em> <em class='tb_tjb_price'>\uFFE54.85<\/em>","3743723708224":"<em class='tb_red'><strong>15<\/strong>\u6DD8\u91D1\u5E01<\/em><em class='tb_dashes_box'> \u62B5\uFFE50.15<\/em> <em class='tb_tjb_price'>\uFFE54.85<\/em>","3743723708227":"<em class='tb_red'><strong>15<\/strong>\u6DD8\u91D1\u5E01<\/em><em class='tb_dashes_box'> \u62B5\uFFE50.15<\/em> <em class='tb_tjb_price'>\uFFE54.85<\/em>","3743723708226":"<em class='tb_red'><strong>15<\/strong>\u6DD8\u91D1\u5E01<\/em><em class='tb_dashes_box'> \u62B5\uFFE50.15<\/em> <em class='tb_tjb_price'>\uFFE54.85<\/em>","4464222204758":"<em class='tb_red'><strong>15<\/strong>\u6DD8\u91D1\u5E01<\/em><em class='tb_dashes_box'> \u62B5\uFFE50.15<\/em> <em class='tb_tjb_price'>\uFFE54.85<\/em>","3743723708239":"<em class='tb_red'><strong>15<\/strong>\u6DD8\u91D1\u5E01<\/em><em class='tb_dashes_box'> \u62B5\uFFE50.15<\/em> <em class='tb_tjb_price'>\uFFE54.85<\/em>","4464222204757":"<em class='tb_red'><strong>15<\/strong>\u6DD8\u91D1\u5E01<\/em><em class='tb_dashes_box'> \u62B5\uFFE50.15<\/em> <em class='tb_tjb_price'>\uFFE54.85<\/em>","3743723708238":"<em class='tb_red'><strong>15<\/strong>\u6DD8\u91D1\u5E01<\/em><em class='tb_dashes_box'> \u62B5\uFFE50.15<\/em> <em class='tb_tjb_price'>\uFFE54.85<\/em>","3743723708233":"<em class='tb_red'><strong>15<\/strong>\u6DD8\u91D1\u5E01<\/em><em class='tb_dashes_box'> \u62B5\uFFE50.15<\/em> <em class='tb_tjb_price'>\uFFE54.85<\/em>","3743723708232":"<em class='tb_red'><strong>15<\/strong>\u6DD8\u91D1\u5E01<\/em><em class='tb_dashes_box'> \u62B5\uFFE50.15<\/em> <em class='tb_tjb_price'>\uFFE54.85<\/em>","3743723708235":"<em class='tb_red'><strong>15<\/strong>\u6DD8\u91D1\u5E01<\/em><em class='tb_dashes_box'> \u62B5\uFFE50.15<\/em> <em class='tb_tjb_price'>\uFFE54.85<\/em>","3743723708234":"<em class='tb_red'><strong>15<\/strong>\u6DD8\u91D1\u5E01<\/em><em class='tb_dashes_box'> \u62B5\uFFE50.15<\/em> <em class='tb_tjb_price'>\uFFE54.85<\/em>"},"price":"5.01","tradeContract":{"pay":[{"icons":["\/\/img.alicdn.com\/tfs\/TB1KTHfQFXXXXbnXFXXXXXXXXXX-16-16.png","\/\/img.alicdn.com\/tfs\/TB1XeDvQFXXXXc5XXXXXXXXXXXX-32-32.png"],"title":"\u8682\u8681\u82B1\u5457","url":"\/\/payservice.alipay.com\/intro\/index.htm?c=hb"},{"icons":["\/\/img.alicdn.com\/tfs\/TB1w6O3QFXXXXX4aXXXXXXXXXXX-16-16.png","\/\/img.alicdn.com\/tfs\/TB1c7HAQFXXXXakXXXXXXXXXXXX-32-32.png"],"title":"\u4FE1\u7528\u5361\u652F\u4ED8","url":"\/\/payservice.alipay.com\/intro\/index.htm?c=xyk"},{"icons":["\/\/img.alicdn.com\/tfs\/TB1dvGWQFXXXXcFaXXXXXXXXXXX-16-16.png","\/\/img.alicdn.com\/tfs\/TB1FdDlQFXXXXa5XpXXXXXXXXXX-32-32.png"],"title":"\u96C6\u5206\u5B9D","url":"\/\/jf.alipay.com"}],"service":[{"desc":"\u6EE1\u8DB37\u5929\u65E0\u7406\u7531\u9000\u6362\u8D27\u7533\u8BF7\u7684\u524D\u63D0\u4E0B\uFF0C\u5305\u90AE\u5546\u54C1\u9700\u8981\u4E70\u5BB6\u627F\u62C5\u9000\u8D27\u90AE\u8D39\uFF0C\u975E\u5305\u90AE\u5546\u54C1\u9700\u8981\u4E70\u5BB6\u627F\u62C5\u53D1\u8D27\u548C\u9000\u8D27\u90AE\u8D39\u3002","icons":["\/\/img.alicdn.com\/tps\/i1\/T1EQA5FpVgXXceOP_X-16-16.jpg",null],"linkType":1,"title":"7\u5929\u65E0\u7406\u7531"}]},"dynStock":{"holdQuantity":0,"sellableQuantity":200,"sku":{";1627207:28334;":{"holdQuantity":0,"oversold":false,"sellableQuantity":200,"stock":200},";1627207:80557;":{"holdQuantity":0,"oversold":false,"sellableQuantity":200,"stock":200},";1627207:28326;":{"holdQuantity":0,"oversold":false,"sellableQuantity":200,"stock":200},";1627207:28320;":{"holdQuantity":0,"oversold":false,"sellableQuantity":200,"stock":200},";1627207:80882;":{"holdQuantity":0,"oversold":false,"sellableQuantity":200,"stock":200},";1627207:4918587664;":{"holdQuantity":0,"oversold":false,"sellableQuantity":200,"stock":200},";1627207:3232479;":{"holdQuantity":0,"oversold":false,"sellableQuantity":200,"stock":200},";1627207:21178725;":{"holdQuantity":0,"oversold":false,"sellableQuantity":200,"stock":200},";1627207:15409374;":{"holdQuantity":0,"oversold":false,"sellableQuantity":200,"stock":200},";1627207:7447408;":{"holdQuantity":0,"oversold":false,"sellableQuantity":200,"stock":200},";1627207:39491616;":{"holdQuantity":0,"oversold":false,"sellableQuantity":200,"stock":200},";1627207:3232483;":{"holdQuantity":0,"oversold":false,"sellableQuantity":200,"stock":200},";1627207:20412615;":{"holdQuantity":0,"oversold":false,"sellableQuantity":200,"stock":200},";1627207:5483105;":{"holdQuantity":0,"oversold":false,"sellableQuantity":200,"stock":200},";1627207:12367710720;":{"holdQuantity":0,"oversold":false,"sellableQuantity":200,"stock":200},";1627207:28341;":{"holdQuantity":0,"oversold":false,"sellableQuantity":200,"stock":200},";1627207:3594022;":{"holdQuantity":0,"oversold":false,"sellableQuantity":200,"stock":200},";1627207:3883690;":{"holdQuantity":0,"oversold":false,"sellableQuantity":200,"stock":200},";1627207:3232484;":{"holdQuantity":0,"oversold":false,"sellableQuantity":200,"stock":200},";1627207:6535235;":{"holdQuantity":0,"oversold":false,"sellableQuantity":200,"stock":200},";1627207:90554;":{"holdQuantity":0,"oversold":false,"sellableQuantity":200,"stock":200},";1627207:3232480;":{"holdQuantity":0,"oversold":false,"sellableQuantity":200,"stock":200},";1627207:28866;":{"holdQuantity":0,"oversold":false,"sellableQuantity":200,"stock":200},";1627207:3819996;":{"holdQuantity":0,"oversold":false,"sellableQuantity":200,"stock":200},";1627207:52813;":{"holdQuantity":0,"oversold":false,"sellableQuantity":200,"stock":200},";1627207:28327;":{"holdQuantity":0,"oversold":false,"sellableQuantity":200,"stock":200},";1627207:129819;":{"holdQuantity":0,"oversold":false,"sellableQuantity":200,"stock":200},";1627207:13808289;":{"holdQuantity":0,"oversold":false,"sellableQuantity":200,"stock":200},";1627207:3707775;":{"holdQuantity":0,"oversold":false,"sellableQuantity":200,"stock":200}},"stock":200,"stockType":"normal"},"qrcodeImgUrl":"\/\/gcodex.alicdn.com\/qrcode.do?biz_code=xcode&short_name=a.ZRs8&cmd=createSub¶m=id:573678898150;scm:20140619.pc_detail.itemId.0","couponActivity":{"buyerHasMianxi":false,"coupon":{},"showMianxiTips":false},"promotion":{"promoData":{";1627207:28334;":[{"cart":true,"loginPromotion":false,"price":"5.00","start":false,"type":"\u6D3B\u52A8\u4E2D"}],";1627207:80557;":[{"cart":true,"loginPromotion":false,"price":"5.00","start":false,"type":"\u6D3B\u52A8\u4E2D"}],";1627207:28326;":[{"cart":true,"loginPromotion":false,"price":"5.00","start":false,"type":"\u6D3B\u52A8\u4E2D"}],"def":[{"cart":true,"loginPromotion":false,"price":"5.00","start":false,"type":"\u6D3B\u52A8\u4E2D"}],";1627207:28320;":[{"cart":true,"loginPromotion":false,"price":"5.00","start":false,"type":"\u6D3B\u52A8\u4E2D"}],";1627207:80882;":[{"cart":true,"loginPromotion":false,"price":"5.00","start":false,"type":"\u6D3B\u52A8\u4E2D"}],";1627207:4918587664;":[{"cart":true,"loginPromotion":false,"price":"5.00","start":false,"type":"\u6D3B\u52A8\u4E2D"}],";1627207:3232479;":[{"cart":true,"loginPromotion":false,"price":"5.00","start":false,"type":"\u6D3B\u52A8\u4E2D"}],";1627207:21178725;":[{"cart":true,"loginPromotion":false,"price":"5.00","start":false,"type":"\u6D3B\u52A8\u4E2D"}],";1627207:15409374;":[{"cart":true,"loginPromotion":false,"price":"5.00","start":false,"type":"\u6D3B\u52A8\u4E2D"}],";1627207:7447408;":[{"cart":true,"loginPromotion":false,"price":"5.00","start":false,"type":"\u6D3B\u52A8\u4E2D"}],";1627207:39491616;":[{"cart":true,"loginPromotion":false,"price":"5.00","start":false,"type":"\u6D3B\u52A8\u4E2D"}],";1627207:3232483;":[{"cart":true,"loginPromotion":false,"price":"5.00","start":false,"type":"\u6D3B\u52A8\u4E2D"}],";1627207:20412615;":[{"cart":true,"loginPromotion":false,"price":"5.00","start":false,"type":"\u6D3B\u52A8\u4E2D"}],";1627207:5483105;":[{"cart":true,"loginPromotion":false,"price":"5.00","start":false,"type":"\u6D3B\u52A8\u4E2D"}],";1627207:12367710720;":[{"cart":true,"loginPromotion":false,"price":"5.00","start":false,"type":"\u6D3B\u52A8\u4E2D"}],";1627207:28341;":[{"cart":true,"loginPromotion":false,"price":"5.00","start":false,"type":"\u6D3B\u52A8\u4E2D"}],";1627207:3594022;":[{"cart":true,"loginPromotion":false,"price":"5.00","start":false,"type":"\u6D3B\u52A8\u4E2D"}],";1627207:3883690;":[{"cart":true,"loginPromotion":false,"price":"5.00","start":false,"type":"\u6D3B\u52A8\u4E2D"}],";1627207:3232484;":[{"cart":true,"loginPromotion":false,"price":"5.00","start":false,"type":"\u6D3B\u52A8\u4E2D"}],";1627207:6535235;":[{"cart":true,"loginPromotion":false,"price":"5.00","start":false,"type":"\u6D3B\u52A8\u4E2D"}],";1627207:90554;":[{"cart":true,"loginPromotion":false,"price":"5.00","start":false,"type":"\u6D3B\u52A8\u4E2D"}],";1627207:3232480;":[{"cart":true,"loginPromotion":false,"price":"5.00","start":false,"type":"\u6D3B\u52A8\u4E2D"}],";1627207:28866;":[{"cart":true,"loginPromotion":false,"price":"5.00","start":false,"type":"\u6D3B\u52A8\u4E2D"}],";1627207:3819996;":[{"cart":true,"loginPromotion":false,"price":"5.00","start":false,"type":"\u6D3B\u52A8\u4E2D"}],";1627207:52813;":[{"cart":true,"loginPromotion":false,"price":"5.00","start":false,"type":"\u6D3B\u52A8\u4E2D"}],";1627207:28327;":[{"cart":true,"loginPromotion":false,"price":"5.00","start":false,"type":"\u6D3B\u52A8\u4E2D"}],";1627207:129819;":[{"cart":true,"loginPromotion":false,"price":"5.00","start":false,"type":"\u6D3B\u52A8\u4E2D"}],";1627207:13808289;":[{"cart":true,"loginPromotion":false,"price":"5.00","start":false,"type":"\u6D3B\u52A8\u4E2D"}],";1627207:3707775;":[{"cart":true,"loginPromotion":false,"price":"5.00","start":false,"type":"\u6D3B\u52A8\u4E2D"}]},"saleDetailMap":{}},"soldQuantity":{"soldTotalCount":"3509"}}});
既然接口找到了,那就是测试验证了,看看是不是其他商品也能用,请求的数据对不对等等,过程这里就赘述了,最后要解决两个问题:
- 需要登录cookie
- 销量会有模糊值,如500+,2000+这种
第一个问题,自己准备一些登录的cookie,或者网上买一些;只有cookie还不行,因为请求不了多少就会需要滑滑块了,还需要搞定滑块问题,获取x5sec参数,带上这个参数就可以持续请求一段时间,滑块可以自己解决或者找其他打码的。
第二个问题,通过调整相关参数来解决返回精确销量。
App端
app端的销量数据就在详情接口里,sellCount,vagueSellCount字段。
淘特App
淘特的销量也在商品详情接口里,但只有总销量没有月销量,而且部分商品还获取不了。
其他
天猫、点淘、e淘什么的有兴趣的可以自行研究。
Python接入示例
请求:
def get_item_sold():proxy = ''app_key = '' # 需要联系作者api_id = '03252f337ac364122353eda0b02d0e20' # 总销# api_id = '51a47c99a0eb960e3e8c791b9241fa3c' # 月销data = dict(tids='614452582693,581732170816', proxy=proxy)t = int(time.time())params = dict(app_key=app_key, t=t, data=json.dumps(data))url = f'http://hostname:port/api/{api_id}'res = requests.get(url=url, params=params, timeout=15)print(res.text)
响应:
{"code": 1, "msg": "success", "data": [{"tid": 614452582693, "ts": 907}, {"tid": 629369723186, "ts": 441}]}
错误码:
# 未知异常UNKNOWN_ERROR = 0# 非法签名ILLEGAL_SIGN = 201CONCURRENT_OVERRUN = 202# 应用未授权APP_UNAUTHORIZED = 301# API未授权API_UNAUTHORIZED = 302# API授权未生效API_AUTH_INEFFECTIVE = 303
交流学习或接入测试+作者Q(昵称)
如有问题请联系删除或调整