Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- const axios = require('axios');
- function YoutubeAudio(QUERY) {
- return new Promise((resolve, reject) => {
- axios
- .get('https://arugaz.my.id/api/media/ytaudio?url=' + encodeURIComponent(QUERY))
- .then(req => {
- resolve(req.data)
- })
- .catch(reject)
- })
- }
- /*
- Website: https://arugaz.my.id
- Github: https://github.com/arugaz
- */
- YoutubeAudio('https://youtu.be/6l5V3BWDcMw')
- .then(res => console.log(res))
- .catch(err => console.log(err))
Add Comment
Please, Sign In to add comment