mirror of
https://gitlab.com/bignutty/labscore.git
synced 2025-06-07 13:43:06 -04:00
use songlink api key
This commit is contained in:
parent
9967194bc8
commit
6062476fd0
1 changed files with 4 additions and 0 deletions
|
@ -32,6 +32,10 @@ module.exports = {
|
|||
let urls = msg.content.match(urlr)
|
||||
if (urls) {
|
||||
let songlink = await superagent.get(`https://api.song.link/v1-alpha.1/links?url=${encodeURIComponent(urls[0])}`)
|
||||
.query({
|
||||
url: urls[0],
|
||||
key: process.env.SONGLINK_KEY
|
||||
})
|
||||
let song = songlink.body.entitiesByUniqueId[songlink.body.entityUniqueId]
|
||||
|
||||
let btns = renderMusicButtons(songlink.body.linksByPlatform)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue