Skip to content

Instantly share code, notes, and snippets.

@FDSoftware
Created February 23, 2020 19:44
Show Gist options
  • Save FDSoftware/55a19b496bbe09ac0a930e6500f9a91d to your computer and use it in GitHub Desktop.
Save FDSoftware/55a19b496bbe09ac0a930e6500f9a91d to your computer and use it in GitHub Desktop.
Test de "simple-youtube-api"
const YouTube = require('simple-youtube-api');
const youtube = new YouTube('aca va el don token');
youtube
.getPlaylist(
'https://www.youtube.com/watch?v=tbayNy9Dg-g&list=RDomh3Pbb-e0k&index=2'
)
.then(playlist => {
console.log(`Titulo de la playlist: ${playlist.title}`);
playlist
.getVideos()
.then(videos => {
console.log(
`Tengo: ${
videos.length === 50 ? '50+' : videos.length
} videos.`
);
videos.map(m => {
console.log(m.title);
});
})
.catch(console.log);
})
.catch(console.log);
Titulo de la playlist: Mix - G_P_5 (feat. DOGLOAD) - TAX COLLECTOR
Tengo: 26 videos.
Gopnik McBlyat - Snakes in Tracksuits
G_P_5 - MiG-15 [HARDBASS]
SLAV KING - Boris vs. DJ Blyatman
G_P_5 (feat. DOGLOAD) - TAX COLLECTOR
uamee - PROTIVOGAZ
Giorno's Theme Hardbass (JoRo Remix)
uamee - IL-76
uamee - TU-142
uamee - KOPEIKA
Generation Hardbass - Boris vs. DJ Blyatman
RED ROUBLES - Boris vs. XS Project
uamee - BASS BOI [HARDBASS]
DJ Blyatman - Gopnik
uamee - CHERNOBYL BONESAW MASSACRE [HARDBASS]
Hard Bass School - Narkotik Kal
uamee - OUT OF KVASS
uamee - MONKEY BUSINESS 2019
uamee - HALVA
DJ Blyatman - Boris
uamee - PRIPYAT AT NIGHT
DJ Blyatman - Atom
Alan Aztec (feat. uamee) - MOTHER RUSSIA [uamee extended edit]
uamee - HIGH QUALITY NAHUI [HARDBASS]
DJ Blyatman & HBKN - Eastern Bloc (Official Music Video)
Hard Bass School - Narkoman (Official Video Clip)
uamee - SMASHED IN WARSAW
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment