当我这样做时:
const uuidapi = await axios.get('https://api.hypixel.net/player?key=mykey&name=' + args[1]);
console.log(uuidapi);
我收到来自Axios的回复:
https://paste.menudocs.org/paste/7vppu
So my question is: How do I get the Data after "socialMedia"? Heres how socialMedia
looks like:
"socialMedia": {
"links": {
"YOUTUBE": "https://www.youtube.com/channel/UC1L7H9qQyB2zZgt-1XUv6jA",
"DISCORD": "Altpapier#4847
}
}
Why does it say socialMedia: [Object]
, and how do I get more than this?
I can't use const { data } = await axios.get(URL);
because I want to get 2 URL responses with the complete data.
See this question: How can I get the full object in Node.js's console.log(), rather than '[Object]'?
you can use
console.dir( yourObject, { depth: null } )
所有数据已经在这里,只是console.log的格式并不打印每个嵌套的对象。 如果您更换
通过
它会更好地工作