From cb435c8239e098f9530af324fc1e547a440b4814 Mon Sep 17 00:00:00 2001 From: guyuexuan <2651919937@qq.com> Date: Wed, 13 Jan 2021 15:50:26 +0800 Subject: [PATCH] =?UTF-8?q?API=20=E8=AF=B7=E6=B1=82=E8=B6=85=E6=97=B6?= =?UTF-8?q?=E7=94=B1=203000=20=E6=94=B9=E4=B8=BA=2010000?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- jd_fruit.js | 8 ++++---- jd_jdfactory.js | 8 ++++---- jd_jxnc.js | 6 +++--- jd_plantBean.js | 8 ++++---- 4 files changed, 15 insertions(+), 15 deletions(-) diff --git a/jd_fruit.js b/jd_fruit.js index d69e661a..99ce136f 100644 --- a/jd_fruit.js +++ b/jd_fruit.js @@ -1168,7 +1168,7 @@ async function initForFarm() { "User-Agent": $.isNode() ? (process.env.JD_USER_AGENT ? process.env.JD_USER_AGENT : (require('./USER_AGENTS').USER_AGENT)) : ($.getdata('JDUA') ? $.getdata('JDUA') : "jdapp;iPhone;9.2.2;14.2;%E4%BA%AC%E4%B8%9C/9.2.2 CFNetwork/1206 Darwin/20.1.0"), "Content-Type": "application/x-www-form-urlencoded" }, - timeout: 3000, + timeout: 10000, }; $.post(option, (err, resp, data) => { try { @@ -1240,7 +1240,7 @@ function timeFormat(time) { } function readShareCode() { return new Promise(async resolve => { - $.get({url: `http://api.turinglabs.net/api/v1/jd/farm/read/${randomCount}/`, timeout: 3000,}, (err, resp, data) => { + $.get({url: `http://api.turinglabs.net/api/v1/jd/farm/read/${randomCount}/`, timeout: 10000,}, (err, resp, data) => { try { if (err) { console.log(`${JSON.stringify(err)}`) @@ -1357,7 +1357,7 @@ function TotalBean() { "Referer": "https://wqs.jd.com/my/jingdou/my.shtml?sceneval=2", "User-Agent": $.isNode() ? (process.env.JD_USER_AGENT ? process.env.JD_USER_AGENT : (require('./USER_AGENTS').USER_AGENT)) : ($.getdata('JDUA') ? $.getdata('JDUA') : "jdapp;iPhone;9.2.2;14.2;%E4%BA%AC%E4%B8%9C/9.2.2 CFNetwork/1206 Darwin/20.1.0") }, - "timeout": 3000, + "timeout": 10000, } $.post(options, (err, resp, data) => { try { @@ -1426,7 +1426,7 @@ function taskUrl(function_id, body = {}) { Cookie: cookie, UserAgent: $.isNode() ? (process.env.JD_USER_AGENT ? process.env.JD_USER_AGENT : (require('./USER_AGENTS').USER_AGENT)) : ($.getdata('JDUA') ? $.getdata('JDUA') : "jdapp;iPhone;9.2.2;14.2;%E4%BA%AC%E4%B8%9C/9.2.2 CFNetwork/1206 Darwin/20.1.0"), }, - timeout: 3000, + timeout: 10000, } } // prettier-ignore diff --git a/jd_jdfactory.js b/jd_jdfactory.js index c5989111..d1de85b2 100644 --- a/jd_jdfactory.js +++ b/jd_jdfactory.js @@ -504,7 +504,7 @@ function queryVkComponent() { "User-Agent": $.isNode() ? (process.env.JD_USER_AGENT ? process.env.JD_USER_AGENT : (require('./USER_AGENTS').USER_AGENT)) : ($.getdata('JDUA') ? $.getdata('JDUA') : "jdapp;iPhone;9.2.2;14.2;%E4%BA%AC%E4%B8%9C/9.2.2 CFNetwork/1206 Darwin/20.1.0"), "Accept-Language": `zh-Hans-CN;q=1, en-CN;q=0.9`, }, - "timeout": 3000, + "timeout": 10000, } $.post(options, (err, resp, data) => { try { @@ -622,7 +622,7 @@ function jdfactory_getHomeData() { function readShareCode() { console.log(`开始`) return new Promise(async resolve => { - $.get({url: `http://api.turinglabs.net/api/v1/jd/ddfactory/read/${randomCount}/`, timeout: 3000}, (err, resp, data) => { + $.get({url: `http://api.turinglabs.net/api/v1/jd/ddfactory/read/${randomCount}/`, timeout: 10000}, (err, resp, data) => { try { if (err) { console.log(`${JSON.stringify(err)}`) @@ -697,7 +697,7 @@ function taskPostUrl(function_id, body = {}, function_id2) { 'Content-Type': 'application/x-www-form-urlencoded', "User-Agent": $.isNode() ? (process.env.JD_USER_AGENT ? process.env.JD_USER_AGENT : (require('./USER_AGENTS').USER_AGENT)) : ($.getdata('JDUA') ? $.getdata('JDUA') : "jdapp;iPhone;9.2.2;14.2;%E4%BA%AC%E4%B8%9C/9.2.2 CFNetwork/1206 Darwin/20.1.0"), }, - timeout: 3000, + timeout: 10000, } } function TotalBean() { @@ -714,7 +714,7 @@ function TotalBean() { "Referer": "https://wqs.jd.com/my/jingdou/my.shtml?sceneval=2", "User-Agent": $.isNode() ? (process.env.JD_USER_AGENT ? process.env.JD_USER_AGENT : (require('./USER_AGENTS').USER_AGENT)) : ($.getdata('JDUA') ? $.getdata('JDUA') : "jdapp;iPhone;9.2.2;14.2;%E4%BA%AC%E4%B8%9C/9.2.2 CFNetwork/1206 Darwin/20.1.0") }, - "timeout": 3000, + "timeout": 10000, } $.post(options, (err, resp, data) => { try { diff --git a/jd_jxnc.js b/jd_jxnc.js index 1befe111..164b1230 100644 --- a/jd_jxnc.js +++ b/jd_jxnc.js @@ -416,7 +416,7 @@ function submitInviteId(userName) { $.post( { url: `https://api.ninesix.cc/api/jx-nc/${$.info.smp}/${encodeURIComponent(userName)}?active=${$.info.active}`, - timeout: 3000 + timeout: 10000 }, (err, resp, _data) => { try { @@ -442,7 +442,7 @@ function submitInviteId(userName) { function getAssistUser() { return new Promise(resolve => { try { - $.get({url: `https://api.ninesix.cc/api/jx-nc?active=${$.info.active}`, timeout: 3000}, async (err, resp, _data) => { + $.get({url: `https://api.ninesix.cc/api/jx-nc?active=${$.info.active}`, timeout: 10000}, async (err, resp, _data) => { try { const {code, data = {}} = JSON.parse(_data); if (data.value) { @@ -563,7 +563,7 @@ function taskUrl(function_path, body) { Host: `wq.jd.com`, 'Accept-Language': `zh-cn`, }, - timeout: 3000, + timeout: 10000, }; } diff --git a/jd_plantBean.js b/jd_plantBean.js index 6d66f350..8d132b7b 100644 --- a/jd_plantBean.js +++ b/jd_plantBean.js @@ -514,7 +514,7 @@ async function plantBeanIndex() { } function readShareCode() { return new Promise(async resolve => { - $.get({url: `http://api.turinglabs.net/api/v1/jd/bean/read/${randomCount}/`, timeout: 3000}, (err, resp, data) => { + $.get({url: `http://api.turinglabs.net/api/v1/jd/bean/read/${randomCount}/`, timeout: 10000}, (err, resp, data) => { try { if (err) { console.log(`${JSON.stringify(err)}`) @@ -636,7 +636,7 @@ function requestGet(function_id, body = {}) { 'Accept-Encoding': 'gzip, deflate, br', 'Content-Type': "application/x-www-form-urlencoded" }, - timeout: 3000, + timeout: 10000, }; $.get(option, (err, resp, data) => { try { @@ -668,7 +668,7 @@ function TotalBean() { "Referer": "https://wqs.jd.com/my/jingdou/my.shtml?sceneval=2", "User-Agent": $.isNode() ? (process.env.JD_USER_AGENT ? process.env.JD_USER_AGENT : (require('./USER_AGENTS').USER_AGENT)) : ($.getdata('JDUA') ? $.getdata('JDUA') : "jdapp;iPhone;9.2.2;14.2;%E4%BA%AC%E4%B8%9C/9.2.2 CFNetwork/1206 Darwin/20.1.0") }, - "timeout": 3000, + "timeout": 10000, } $.post(options, (err, resp, data) => { try { @@ -732,7 +732,7 @@ function taskUrl(function_id, body) { "Accept-Encoding": "gzip, deflate, br", "Content-Type": "application/x-www-form-urlencoded" }, - timeout: 3000, + timeout: 10000, } } function getParam(url, name) {