From 763e041a8bf93232e07dd3b1246f78f69d81a589 Mon Sep 17 00:00:00 2001 From: hexdev Date: Sun, 31 May 2026 14:14:17 +0700 Subject: [PATCH] fix(api): change pally webhook endpoint from /success to /result --- api/routes/pally.py | 2 +- tests/send_pally_webhook.py | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/api/routes/pally.py b/api/routes/pally.py index 06c5d2f..3f5655e 100644 --- a/api/routes/pally.py +++ b/api/routes/pally.py @@ -20,7 +20,7 @@ router = APIRouter(prefix="/pally") logger = logging.getLogger(__name__) -@router.post("/success") +@router.post("/result") async def pally_callback( id: str = Form(...), bill_id: str = Form(...), diff --git a/tests/send_pally_webhook.py b/tests/send_pally_webhook.py index 8ba5d1c..b452f40 100644 --- a/tests/send_pally_webhook.py +++ b/tests/send_pally_webhook.py @@ -19,6 +19,7 @@ from dotenv import load_dotenv load_dotenv() +ENDPOINT = "/pally/result" def calculate_signature( payment_id: str, @@ -70,9 +71,9 @@ def main(): "signature": signature, } - print(f"{args.host}/checkout/pally/callback") + print(f"{args.host}{ENDPOINT}") print(f"Отправляю вебхук: {payload}\n") - response = httpx.post(f"{args.host}/checkout/pally/callback", data=payload) + response = httpx.post(f"{args.host}{ENDPOINT}", data=payload) print(f"Статус ответа: {response.status_code}") print(f"Тело ответа: {response.text}")