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

guardian-news

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

guardian-news

Guardian News API node module.

  • 0.0.2
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

Guardian News API NodeJS Module

This module can be used to query the Guardian's API. This module provides a thin wrapper around request.js to Guardian's API. All functions return promises. To learn more about the API, and which parameters can be passed to each function you can use the API explorer or the documentation.

Examples

Searching Content

var guardian = require('guardian-news');

guardian.config({
  apiKey : 'API-KEY'
});

guardian.content({
  q : 'clowns',
  fromDate : '2010-01-19'
}).then(function(response){
  console.log(response);
}, function(err){
  console.log(err);
});

Searching Sections

guardian.sections({
  q : 'sports'
}).then(function(response){
  
});

Searching Tags

guardian.sections({
  q : 'sports/tennis',
  page : 2
}).then(function(response){
  
});

Keywords

FAQs

Package last updated on 14 Jul 2015

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