简体   繁体   中英

Subscribe to RSS feed with Google Feed API and Node.js

From a Node.js server, I connected to Google Feed API (with https://stackoverflow.com/a/22821516/3303704 ). But it seems to load the whole RSS feed every time I use it. Since I want to follow a lot of RSS feeds, it is not going to be scalable. How can I susbcribe to the RSS feeds, that is having pushed to my server only the new items of the RSS feeds, as they are published? The solution described here ( http://googleajaxsearchapi.blogspot.com/2010/05/google-feed-api-now-with-instant.html ) does not seem to work...

If it is useful, what I then do with the items of the RSS feeds is: (1) select only the links to articles with >1500 words (for that I use Cheerio) and (2) save these links to a database (MongoDB, connected to server with Mongoose).

I am afraid the Google Feeds API may not be the best candidate here as it's mostly a 'client side' API which would allow you to embed RSS feed's content on an HTML page. If used from a backend, you'll probably have to poll them which will be cumbersome (and may conflict with Google's terms of usage).

You may want to check Superfeedr for this. We do provide a Node.js wrapper that does what you're looking for.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM