Research
Recent Trends in Malicious Packages Targeting Discord
The Socket research team breaks down a sampling of malicious packages that download and execute files, among other suspicious behaviors, targeting the popular Discord platform.
cobra-search
Advanced tools
Readme
simple youtube search API and CLI
npm install yt-search # local module usage
const yts = require( 'yt-search' )
const r = await yts( 'superman theme' )
const videos = r.videos.slice( 0, 3 )
videos.forEach( function ( v ) {
const views = String( v.views ).padStart( 10, ' ' )
console.log( `${ views } | ${ v.title } (${ v.timestamp }) | ${ v.author.name }` )
} )
38878009 | Superman Theme (4:13) | Super Man
8861479 | Superman • Main Theme • John Williams (4:26) | HD Film Tributes
7802473 | Superman - Main Theme (BBC Proms) (4:46) | brassbone player
https://runkit.com/talmobi/runkit-npm-yt-search-basic
const video = await yts( { videoId: '_4Vt0UGwmgQ' } )
console.log( video.title + ` (${ video.duration.timestamp })` )
Philip Glass. - Koyaanisqatsi (original version) (3:29)
https://runkit.com/talmobi/runkit-npm-yt-search-video
const list = await yts( { listId: 'PL7k0JFoxwvTbKL8kjGI_CaV31QxCGf1vJ' } )
console.log( 'playlist title: ' + list.title )
list.videos.forEach( function ( video ) {
console.log( video.title )
} )
playlist title: Superman Themes
The Max Fleischer Cartoon (From "Superman")
[Deleted video]
Superman Theme
[Private video]
Superman The Animated Series Full Theme
Smallville theme song
Reprise / Fly Away
Superman Doomsday Soundtrack- Main Title
Hans Zimmer - Man of Steel Theme
Supergirl CW Soundtrack - Superman Theme Extended
https://runkit.com/talmobi/runkit-npm-yt-search-playlist
yt-search superman theme
If you have mpv
installed, yt-search can directly play yt videos (or audio only)
yt-search-video Dank Memes Videos
yt-search-audio Wagner
If you don't have mpv
installed, you can alternatively try installing yt-play-cli
npm install -g yt-play-cli
see: https://github.com/talmobi/yt-play
Simple function to get youtube search results.
Not sure..
Using HTTP requests and parsing the results with cheerio.
CLI interactive mode with node-fzf
var opts = { query: 'superman theme' }
yts( opts, function ( err, r ) {
if ( err ) throw err
console.log( r.videos ) // video results
console.log( r.playlists ) // playlist results
console.log( r.channels ) // channel results
console.log( r.live ) // live stream results
} )
var opts = { videoId: 'e9vrfEoc8_g' }
yts( opts, function ( err, video ) {
if ( err ) throw err
console.log( video ) // single video metadata
} )
var opts = { listId: 'PL7k0JFoxwvTbKL8kjGI_CaV31QxCGf1vJ' }
yts( opts, function ( err, playlist ) {
if ( err ) throw err
console.log( playlist ) // single playlist metadata
console.log( playlist.videos ) // playlist videos
} )
npm test
FAQs
search youtube
We found that cobra-search demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
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.
Research
The Socket research team breaks down a sampling of malicious packages that download and execute files, among other suspicious behaviors, targeting the popular Discord platform.
Security News
Socket CEO Feross Aboukhadijeh joins a16z partners to discuss how modern, sophisticated supply chain attacks require AI-driven defenses and explore the challenges and solutions in leveraging AI for threat detection early in the development life cycle.
Security News
NIST's new AI Risk Management Framework aims to enhance the security and reliability of generative AI systems and address the unique challenges of malicious AI exploits.