京东全民养红包挂机脚本分享 自动做任务得金币

  • 作者:admin
  • 分类:活动
  • 发布时间:2019.10.22 10:46
  • 阅读:-

京东全民养红包挂机脚本分享 自动做任务得金币

双十一活动已经持续来了,最近的京东全民养红包活动不知道大家参加没

每天手动做任务太麻烦了 下边介绍下挂机自动脚本,省去自己做任务的烦恼

代码可以自动完成任务 但是测试2个号 除了邀请的任务

其他任务总是差一两个 不介意的朋友们可以弄一下 其他剩余的可以自己弄一下

可以自己修改index*后边的数调整延时,1000代表1s

黑号会报 productList undefind,用前去app活动页面看看火爆不火爆


步骤如下:用电脑参加

 

1、打开http://www.jd.com 登录京东账号

 

2、打开https://happy.m.jd.com/babelDiy/GZWVJFLMXBQVEBDQZWMY/XJf8bH6oXDWSgS91daDJzXh9bU7/index.html 进入活动页面


3、按F12 点击Console 输入代码 之后按一下回车键 就会自动完成了

4、完成后 可以到活动页面查看一下 是否完成

 

代码如下:

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*3500)
                })(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*3500)
                })(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*2400)
                })(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*3000)
                })(i)       
        }
}
//精彩会场
function autoShopping(){
        for(let i = 0,leng = 3;i<leng;i++){
                (function(index){
                        setTimeout(()=>{
                                autoPost(0,3);
                                console.log(`精彩会场:${leng} 当前任务数:${index + 1}`);
                                },
                        index*4000)
                })(i)       
        }
}
start();


微信公众号:薅羊毛活动网
小程序转二维码微信机器人:关注公众号回复 转码
点击这里给我发消息
嘿!有什么能为您效劳的吗?