scrape-fb-ogcache
v1.0.6
Published
Open Graph cache scraper for Node.js
Downloads
4
Maintainers
Readme
scrape-fb-ogcache
Scrapes open graph cache of Facebook with Node.js
With this package, you can write easily the code to scrape open graph cache of Facebook. On Sharing Debugger of facebook for developers web site, you can request scraping the cache for just one URL. But it is not useful for multi-page web site.
Installation
npm install --save scrape-fb-ogcache
Usage
// example with es2015
const scrape = require('scrape-fb-ogcache');
const token = <PUT YOUR APP TOKEN OF FACEBOOK>;
scrape(url, token, (res) => {
if (res.error) {
console.log(`[${total - sitemap.urlset.url.length} / ${total} : FAILED]`, url, res);
} else {
console.log(`[${total - sitemap.urlset.url.length} / ${total} : SUCCESS]`, url);
}
});