This commit is contained in:
Lev 2026-04-17 23:11:41 +03:00
parent 89651a8e81
commit 11a84f4926

View file

@ -123,6 +123,7 @@ class XUIClient:
resp.raise_for_status() resp.raise_for_status()
if self.version == "legacy": if self.version == "legacy":
resp = await self.session.post(f"{self.base_url}/panel/inbound/addClient", json=configs.legacy_payload(resp.json())) resp = await self.session.post(f"{self.base_url}/panel/inbound/addClient", json=configs.legacy_payload(resp.json()))
#New configs here
else: else:
raise HTTPException( raise HTTPException(
status_code=500, status_code=500,
@ -133,6 +134,7 @@ class XUIClient:
resp.raise_for_status() resp.raise_for_status()
if self.version == "legacy": if self.version == "legacy":
return configs.legacy_config(resp.json()) return configs.legacy_config(resp.json())
#New configs here
else: else:
raise HTTPException( raise HTTPException(
status_code=500, status_code=500,