Created
July 26, 2016 06:35
-
-
Save infinito84/209d08d5198a608c21dd3bf86697049c to your computer and use it in GitHub Desktop.
Easy download of images from facebook, through a facebookid
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var request = require('request'); | |
var fs = require('fs') | |
var data = { | |
facebookid : '1627151517597811' | |
} | |
request('https://graph.facebook.com/'+ data.facebookid +'/picture?type=large') | |
.pipe(fs.createWriteStream('facebook_'+ data.facebookid +'.jpg')) | |
.on('close', function(){ | |
console.log(data) | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment