Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

fme-news-api

Package Overview
Dependencies
Maintainers
1
Versions
11
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

fme-news-api

newsApi interface for the FME/Xronos project

  • 1.2.2
  • latest
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

Synopsis

Used by FortunesRocks.me LLC for news monitoring

Code Example

mongo.MongoClient.connect(mongoURL, async (err, db) => {
    if (err) {
        L.error("MongoDB not running? This package requires it");
        throw err;
    }
    L.info("===> Mongo connected");
    L.info("====> Have a new FmeNewsApi object");
    var nApi = new FmeNewsApi(db,gsheetConfig,newsApiKey);
    L.info("Setup Stream interface");
    nApi.stream = myStream;
    nApi.init();
    L.info("=====> Inited the newsApi");
  
})


Format of gsheetConfig for the FeedsDb to read and find the feeds;

if you don't know how to get this, read the google-edit-sheets NPM

{ "oauthEmail" : "BIG LONG KEY@developer.gserviceaccount.com", "oauthKeyFile" : "Path to GDOCS Pem file", "sheetId" : "unique key if for page", "debugLevel" : "info" }

Motivation

DrudgeReport is one of the most infulential news based websites in the world. Monirtoring the feed is crtical to news senstive markets.

Installation

npm install --save drudgereport

API Reference

Key:string = "Newsapi key"
gSheetConfg = "google-sheet-object" configuration file

export class FmeNewsArticle {
	created_at : Date;
	full_link : string;
	guid : string;
	image_url :  string;
	orig: any;
	source: string;
	source_type: string;
	excerpt: string;
	full_text: string;
	full_html: string;
	title: string;
	author: any;
	score: number;
}


Tests

There is a test-fme-news-api which is an implementation of the code above.

Contributors

FortunesRocks.me LLC contact me there if you have questions; npms + "than that litte a wrapped in a blanket"+fortunesrocks.me

License

ISC

Keywords

FAQs

Package last updated on 29 May 2018

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc