Skip to content

Commit 246e134

Browse files
committed
fix: update LinkSocks API endpoint in async and sync clients
Updated the LinkSocks API endpoint in both the asynchronous and synchronous clients to remove the redundant '/api' prefix for consistency and correctness.
1 parent ee39ce6 commit 246e134

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

cfsolver/async_client.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -224,7 +224,7 @@ def _normalize_ws_url(url: str) -> str:
224224
return url
225225

226226
async def _get_linksocks_config(self) -> Dict[str, Any]:
227-
url = f"{self.api_base}/api/linksocks/getLinkSocks"
227+
url = f"{self.api_base}/getLinkSocks"
228228
headers = {"Authorization": f"Bearer {self.api_key}"} if self.api_key else {}
229229
resp = await self._api_client.post(url, headers=headers)
230230
if resp.status_code != 200:

cfsolver/client.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -223,7 +223,7 @@ def _normalize_ws_url(url: str) -> str:
223223
return url
224224

225225
def _get_linksocks_config(self) -> Dict[str, Any]:
226-
url = f"{self.api_base}/api/linksocks/getLinkSocks"
226+
url = f"{self.api_base}/getLinkSocks"
227227
headers = {"Authorization": f"Bearer {self.api_key}"} if self.api_key else {}
228228
with Session(verify=False, proxy=self.api_proxy) as s:
229229
resp = s.post(url, headers=headers)

0 commit comments

Comments
 (0)