淘寶京東雙十一擼一擼


淘寶和京東雙十一全自動擼一擼腳本

作者:樂樂

一、淘寶自動養貓貓腳本

(一)、所需工具

Auto.js安裝包(下載鏈接:https://www.lanzous.com/i70nqwd)、淘寶APP

(二)、使用步驟

1.安裝軟件,給予權限

安裝Auto.js APP,並打開一次軟件,提示需要獲取無障礙權限,跟着給予它權限

2.導入腳本

(1)點擊Auto.js軟件右下角的+號,選擇文件

(2)給文件隨便取一個名字,比如我叫taobao

(3)把下面的代碼粘貼進去,右上角點擊保存

alert('准備運行', '點擊確定,5秒后開始運行');
sleep(3000)
toast('開始運行點擊嘍!');
sleep(3000)      //中間延時時間,3000=3秒
for(var c = 1; c < 20; c++){       //需要循環的次數,也就是進店次數
    toast('正在運行逛店鋪:第' + c + '次');
    text('去進店').findOne().click()
    sleep(5000)
    var x = device.width;
    var y = device.height;
    swipe(Math.floor(x*0.5),Math.floor(y*0.8),Math.floor(x*0.5),Math.floor(y*0.3), 20000);    //對窗口進行滑動
    sleep(3000)
    back()
    toast('逛店鋪:第' + c + '次,執行完畢');
    sleep(3000)
}
sleep(3000)
toast('瀏覽店鋪已經結束,開始瀏覽會場');
do{  //無限判斷去瀏覽,如果有就進去,沒有停止腳本運行
    toast('開始瀏覽');
    var fi = text('去瀏覽').findOne(6000).click()
    sleep(3000)
    var x = device.width;
    var y = device.height;
    swipe(Math.floor(x*0.5),Math.floor(y*0.8),Math.floor(x*0.5),Math.floor(y*0.3), 18000);
    back()
    toast('本次瀏覽結束');
    sleep(3000)
}while(fi == true)
alert('全部瀏覽結束,腳本運行完成');
console.log('全部瀏覽結束,腳本運行完成')
sleep(3000)

3.准備運行

(1)打開淘寶APP,到下面的界面

(2)返回Auto.js軟件,點擊運行

彈窗后點擊確定,切回淘寶界面,全自動運行開始


二、京東全自動養紅包腳本

(一)、所需工具

電腦,電腦上裝好瀏覽器

(二)、使用步驟

1.手機京東開啟活動

確保參與了這個活動

2.登錄京東

電腦使用瀏覽器打開官網 https://www.jd.com/ ,登錄你的京東賬戶

3.打開活動頁面

(打開此頁面就好,頁面不是給你看的)
https://happy.m.jd.com/babelDiy/GZWVJFLMXBQVEBDQZWMY/XJf8bH6oXDWSgS91daDJzXh9bU7/index.html

4.粘貼代碼

摁一下F12鍵(也有可能是Fn+F12),找不到就右鍵審查元素(也叫檢查),找到控制台,把如下代碼粘貼進去
腳本代碼

let productList=[],shopList=[],url="https://api.m.jd.com/client.action";function autoPost(id,type){fetch(`${url}?timestamp=${new Date().getTime()}`,{method:"POST",mode:"cors",credentials:"include",headers:{"Content-Type":"application/x-www-form-urlencoded"},body:`functionId=raisepacket_collectScore&body={"type":${type},"ext":"${id}","appsign":1,"msgsign":2}&client=wh5`}).then(function(response){return response.json()}).then(function(res){console.log(res.data.biz_msg)})}function start(){fetch(`${url}?${new Date().getTime()}`,{method:"POST",mode:"cors",credentials:"include",headers:{"Content-Type":"application/x-www-form-urlencoded"},body:'functionId=raisepacket_getShopAndProductList&body=&client=wh5'}).then(function(response){return response.json()}).then(function(res){productList=res.data.result.productList;shopList=res.data.result.shopList;console.log(`獲取到任務,商品:${productList.length}商品:${shopList.length}`);autoProductTask()})}function autoProductTask(){for(let i=0,leng=productList.length;i<leng;i++){(function(index){setTimeout(()=>{let item=productList[index];autoPost(item['id'],4);console.log(`商品總任務數:${leng}當前任務數:${index+1}`);if(leng-1==index){autoShopTask()}},index*1500)})(i)}}function autoShopTask(){for(let i=0,leng=shopList.length;i<leng;i++){(function(index){setTimeout(()=>{let item=shopList[index];autoPost(item['id'],2);console.log(`商鋪總任務數:${leng}當前任務數:${index+1}`);if(leng-1==index){autoPlay()}},index*1500)})(i)}}function autoPlay(){for(let i=0,leng=4;i<leng;i++){(function(index){setTimeout(()=>{autoPost(0,5);console.log(`好玩互動:${leng}當前任務數:${index+1}`);if(leng-1==index){autoInteract()}},index*1000)})(i)}}function autoInteract(){for(let i=0,leng=4;i<leng;i++){(function(index){setTimeout(()=>{autoPost(0,10);console.log(`視頻直播:${leng}當前任務數:${index+1}`);if(leng-1==index){autoShopping()}},index*1000)})(i)}}function autoShopping(){for(let i=0,leng=3;i<leng;i++){(function(index){setTimeout(()=>{autoPost(0,3);console.log(`精彩會場:${leng}當前任務數:${index+1}`)},index*1000)})(i)}}start();
  • 火狐瀏覽器F12頁面

    打開控制台,粘貼代碼

  • Chrome瀏覽器F12頁面

    打開控制台粘貼代碼

5.等待效果

回車運行即可


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM