优化内容

This commit is contained in:
liuwei
2025-06-03 13:56:43 +08:00
parent 7b01beb6e4
commit 9c80ea05eb

View File

@@ -306,7 +306,7 @@ class GuessSongPlugin(MessagePluginInterface):
# 构建API请求URL - 使用抖音音乐API
if singer_name:
# 如果指定了歌手,搜索该歌手的歌曲
api_url = f"https://hhlqilongzhu.cn/api/dg_douyinmusic.php?msg={singer_name}&type=json"
api_url = f"https://www.hhlqilongzhu.cn/api/joox/juhe_music.php?msg={singer_name}&type=json"
else:
# 如果没有指定歌手,使用热门歌手列表
popular_singers = [
@@ -315,7 +315,7 @@ class GuessSongPlugin(MessagePluginInterface):
"王菲", "张惠妹", "孙燕姿", "蔡依林", "五月天"
]
random_singer = random.choice(popular_singers)
api_url = f"https://hhlqilongzhu.cn/api/dg_douyinmusic.php?msg={random_singer}&type=json"
api_url = f"https://www.hhlqilongzhu.cn/api/joox/juhe_music.php?msg={random_singer}&type=json"
# 发送请求获取歌曲列表
response = requests.get(api_url)