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

clinews

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

clinews

A command line interface for getting news stories from https://newsapi.org

  • 1.1.0
  • latest
  • npm
  • Socket score

Version published
Weekly downloads
4
increased by100%
Maintainers
1
Weekly downloads
 
Created
Source

clinews :earth_africa: :newspaper: :computer:

npm npm license

A CLI for reading the news which supports over 70 sources. Get all the latest headlines from around the world without leaving your terminal. Powered by NewsAPI.org.

clinews allows you to:

  • Fetch all the latest stories from a particular news source
  • List all possible news sources the API provides
  • Search across all the sources for a particular word or phrase in the title.

Installation

Note: You must be on node version 7.6.0 or later to use clinews.

npm

npm i -g clinews

yarn

yarn global add clinews

Usage

Fetch stories from a source

Fetch all the latest news stories from bbc-news:

news fetch bbc-news

other examples...

news fetch techcrunch
news fetch hacker-news

List all news sources

Show all the sources you can get news from. Use the Fetch Id field with the fetch command to get news for that source.

news sources

Search for news stories across all sources matching search criteria

You can search across all 70+ news sources to find stories with a title matching your criteria. For example, to find all news stories with titles containing the words "Donald Trump" you can execute the following. Note that searches are also case insensitive. The 2 commands below are equivalent.

news search "Donald Trump"

or

news search "donald trump"

Options

clinews supports some extra flags as well. See below:

-V, --version              output the version number
-l, --limit <limit>        limit the amount of news stories you want to see.
-c, --category <category>  category of sources you want to see. Choices include: business, entertainment, gaming, general, music, politics, science-and-nature, sport, technology.
-h, --help                 output usage information

You can run news --help to get this information at any time.

Keywords

FAQs

Package last updated on 28 Apr 2019

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