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

google-books-search-promise

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

google-books-search-promise

Promisified Wrapper for Google Books Search API

  • 1.1.0
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
0
Maintainers
1
Weekly downloads
 
Created
Source

google-books-search-promise

A promisified wrapper for Google Books search API

Install

npm install google-books-search-promise

Require

let gbs = require('google-books-search-promise')('API Key');

Methods

  • search {function} - In depth search function, that supports Multiple query options.
  • searchByTitle {function} - Search for a specific title using only a string.

gbs.search

  • query

Only query.q is required

  query {
    q : '(String) Search for volumes that contain this text string.'
    intitle: '(String) Returns results where the text following this keyword is found in the title.'
    inauthor: '(String) Returns results where the text following this keyword is found in the author.'
    inpublisher: '(String) Returns results where the text following this keyword is found in the publisher.'
    subject: '(String) Returns results where the text following this keyword is listed in the category list of the volume.'
    isbn: '(String) Returns results where the text following this keyword is the ISBN number.'
    lccn: '(String) Returns results where the text following this keyword is the Library of Congress Control Number.'
    oclc: '(String) Returns results where the text following this keyword is the Online Computer Library Center number.'
  }
  • options

    Both options are required

  options {
    offset : '(Number) Offset number for pagination'
    limit: '(Number) The maximum number of entries to return. must be between 1 and 40'
  }
gbs.search(query, options)
  .then(result => {
    console.log(result);
  })
  .catch( error => {
    console.log(error);
  });

gbs.searchByTitle

  • title
  title {string}
  • options

    Both options are required

  options {
    offset : '(Number) Offset number for pagination'
    limit: '(Number) The maximum number of entries to return. must be between 1 and 40'
  }
gbs.searchByTitle(title, options)
  .then(result => {
    console.log(result);
  })
  .catch( error => {
    console.log(error);
  });

FAQs

Package last updated on 31 Dec 2016

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