问题描述
我正在从网页上抓取信息,除此以外,我已经能够获取所有信息:一个带有令牌的脚本。目前,我已经向网页提出了获取请求,并且看到了它返回脚本的位置。我的代码是:
const axios = require('axios');
const cheerio = require('cheerio');
const buyItem = async (cookie,assetId) => {
// Get x-csrf-token,product id,and price
await axios.default.request({
url: `https://www.roblox.com/catalog/${assetId}`,method: "GET",headers: {Cookie: `.ROBLOSecurity=${cookie};`}
}).then(response => {
const $ = cheerio.load(response.data);
console.log(response)
})
};
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)