Wednesday, 10 May 2017

I'm trying to make an API request in node using snekfetch, but return is not what was expected

What I have is

const fetch = require('snekfetch');
fetch.get('https://owapi.net/api/v3/u/Dad-12262/stats')
    .then(r => console.log(r.body));

The log I get is: enter image description here

However when I visit the link in my browser I get a whole slew of information. I'm not sure what I'm missing from my request.



via andrewb

No comments:

Post a Comment