Archives
Trending
Support
Login
clear text
XML
Django
JavaScript
MATLAB
C
C++
C#
Python
SQL
Shell
Bash
Markdown
YAML
JSON
HTML
CSS
PHP
Java
Ruby
Go
Rust
Swift
Kotlin
Arduino
TypeScript
Perl
Autohotkey
Lua
SQF
R
Scala
Haskell
Groovy
Dart
Clojure
VB.NET
Objective-C
PowerShell
Bash
CoffeeScript
Verilog
//By: π§ πππππ πππ ππππππ π§ //Canal: https://whatsapp.com/channel/0029Vb69bDnAe5VmzSMwBH11 const axios = require('axios'); const cheerio = require('cheerio'); async function baixarSpotify(url) { try { if (!url.includes('open.spotify.com')) throw new Error('URL invΓ‘lida.'); const respostaRynn = await axios.get('https://spotmate.online/', { headers: { 'user-agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36' } }); const $ = cheerio.load(respostaRynn.data); const api = axios.create({ baseURL: 'https://spotmate.online', headers: { cookie: respostaRynn.headers['set-cookie'].join('; '), 'content-type': 'application/json', 'user-agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36', 'x-csrf-token': $('meta[name="csrf-token"]').attr('content') } }); const [{ data: metadados }, { data: download }] = await Promise.all([ api.post('/getTrackData', { spotify_url: url }), api.post('/convert', { urls: url }) ]); return { ...metadados, url_download: download.url }; } catch (erro) { throw new Error(erro.message); } } module.exports = baixarSpotify // Exemplo de uso: // baixarSpotify('https://open.spotify.com/track/6yID3RbYKiwn2p2LPz0OkK') // .then(console.log) // .catch(console.error);
Mark as private (unlisted)
for 30 minutes
for 6 hours
for 1 day
for 1 week
for 1 month
for 1 year
everlasting (like CCCP)