Socket
Socket
Sign inDemoInstall

youtube-search-google-api

Package Overview
Dependencies
56
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    youtube-search-google-api

YouTube Search Google API for Node.js. Search for YouTube videos, channels, playlists and live events via Google API for Node.js.


Version published
Weekly downloads
11
increased by175%
Maintainers
1
Created
Weekly downloads
 

Changelog

Source

0.6.0

  • modify webpack config to add source maps support
  • modify readme to include downloads and dependencies badges
  • modify code to use better comparison for undefined
  • modify package.json to update dependencies

Readme

Source

Youtube Search Google API

Build Status Coverage Status Version License Downloads Dependencies

YouTube Search Google API for Node.js. Search for YouTube videos, channels, playlists and live events via Google API for Node.js.

Installing

This module is designed to be usable via server-side for Node.js or in a browser client-side.

npm install youtube-search-google-api

Configuration

There are 2 HTTP clients provided request and xhr. They handle the server-side and client-side respectively.

Browser Support

For Browserify, add a browser field to your package.json:

"browser": {
  "request": "xhr"
}

For Webpack, add a resolve.alias field to your configuration:

"resolve": {
  "alias": {
    "request$": "xhr"
  }
}

Usage

Authorization via Google API Key or OAuth 2.0 token is required by Google. More information regarding Google authentication can be found at Calling the API. All other parameters are optional.

import { YouTube, SearchRequest } from 'youtube-search-google-api'

const youtube = new YouTube()

youtube.search(new SearchRequest(
  {
    query: {
      key: 'AlzaSydu39i6-bseHDgCfG_SNE_hQwuGdc53Vws',
      maxResults: 50,
      order: 'viewCount',
      type: 'video',
      publishedAfter: '2017-10-01T00:00:00Z',
      q: 'pumpkin|halloween+dog -cat'
    }
  }, function(error, response, body) {
    // Handle the response...
  }))

Dependencies

This module depends on the following.

Contributing

Please read Contributing. Feel free to submit pull requests, issues and comments! Thank you. Participants will be added to the list of Contributors.

Alternatives

There is also a light weight alternative to this module Youtube Search.

License

YouTube Search Goggle API is Free and Open Source Software. It is licensed by the MIT License.

Keywords

FAQs

Last updated on 04 Nov 2017

Did you know?

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc