From abf449673be0309376f9d45ef91b0ee9f18e1cf0 Mon Sep 17 00:00:00 2001 From: hisatri Date: Tue, 21 Jan 2025 23:28:09 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BD=BF=E7=94=A8Cloudflare=E4=BB=A3=E7=90=86?= =?UTF-8?q?=E7=9A=84API=E7=AB=AF=E7=82=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- mod/searchx/api.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mod/searchx/api.py b/mod/searchx/api.py index 31858d5..fb99808 100644 --- a/mod/searchx/api.py +++ b/mod/searchx/api.py @@ -3,13 +3,13 @@ headers = { "Host": "127.0.0.1", - "User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/" + "User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 LrcAPI" } def search(title='', artist='', album='') -> list: try: - url = f"http://cn.lrc.cx:880/jsonapi?title={title}&artist={artist}&album={album}&path=None&limit=1&api=lrcapi" + url = f"https://api.lrc.cx/jsonapi?title={title}&artist={artist}&album={album}&path=None&limit=1&api=lrcapi" response = requests.get(url, headers=headers) return response.json() except Exception as e: