Yesterday worked, today no longer.

var fd = new URLSearchParams(); function loot(){ return fetch('https://loot.farm/fullprice.json', { method: "GET", cache: "no-cache" }).then(response=>response.json()); }; function skinsjar(){ return fetch('https://skinsjar.com/api/v3/load/bots?refresh=0&v=2', { method: "GET", cache: "no-cache" }).then(response=>response.json()); }; function csmoney(){ return fetch('https://cs.money/load_bots_inventory', { method: "GET", cache: "no-cache" }).then(response=>response.json()); }; function tradeskins(){ return fetch('https://trade-skins.com/load_all_bots_inventory', { method: "GET", cache: "no-cache" }).then(response=>response.json()); }; function swap(){ return fetch('https://csgoswap.com/api/inventory/bot', { method: "POST", cache: "no-cache" }).then(response=>response.json()); }; function bot(){ fd.set('who', 'bot'); return fetch('https://www.thecsgobot.com/api/service.inventory.json', { method: "POST", cache: "no-cache", body: fd }).then(response=>response.json()); }; function start(data){ //обработка }; Promise.all([skinsjar(), tradeskins(), swap(), bot(), loot(), csmoney()]).then(results=> start(results)); 

Uncaught (in promise) SyntaxError: Unexpected token < in JSON at position 0

  • somewhere instead of JSON you get HTML. - etki
  • @etki really, 1 of the sites went for processing and there is an html message about it. - Mr Lucky Tomas
  • @etki help with 1 problem? I need to get about 10,000 data from 1 site with different GET parameters, but as you understand, without async it will take a long time, and promise results in net::ERR_INSUFFICIENT_RESOURCES , what to do? - Mr Lucky Tomas

0