Skip to content

Scodify236/innertube

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

InnerTube

A lightweight library to interact with YouTube API using InnerTube.

Installation

npm install innertube

Usage

const InnerTube = require('innertube');

async function example() {
  const yt = new InnerTube();

  try {
    // Get video player information
    const playerInfo = await yt.player({ videoId: 'dQw4w9WgXcQ' });
    
    // Search videos
    const searchResults = await yt.search({ query: 'JavaScript tutorials' });
    
    // Browse recommendations
    const browseResults = await yt.browse({ browseId: 'FEwhat_to_watch' });
  } catch (error) {
    console.error(error);
  }
}

Methods

  • player(options): Fetch video player information
  • search(options): Search YouTube videos
  • browse(options): Get recommendations
  • next(options): Fetch related content

License

MIT

Releases

No releases published

Packages

No packages published