From 50e9aa12e4229c0152e69ddaded63992aafe3f46 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=94=D0=B5=D0=BD=D0=B8=D1=81=20=D0=9A=D1=80=D0=B8=D0=B2?= =?UTF-8?q?=D0=BE=D1=87=D0=B5=D0=BD=D0=BA=D0=BE?= Date: Wed, 15 Jul 2026 22:40:55 +0700 Subject: [PATCH] fix: use template instead of request_template for SD API --- service_desk/handlers.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/service_desk/handlers.py b/service_desk/handlers.py index bb21792..4d4e715 100644 --- a/service_desk/handlers.py +++ b/service_desk/handlers.py @@ -176,7 +176,7 @@ async def create_ticket_in_sd(requester_email: str, subject: str, description: s async def _send_req(email, current_city): req_payload = {"request": {"subject": subject, "description": html_desc, "requester": {"email_id": email}, "udf_fields": {"udf_pick_301": current_city}}} if template_id: - req_payload["request"]["request_template"] = {"id": template_id} + req_payload["request"]["template"] = {"id": template_id} async with httpx.AsyncClient(verify=False) as client: resp = await client.post(endpoint, headers=headers, params={"input_data": json.dumps(req_payload)}, timeout=15.0) if resp.status_code not in [200, 201]: