fix: content= вместо data= для raw JSON body

This commit is contained in:
2026-07-15 16:51:28 +07:00
parent d4dde34d90
commit eb35fcec82
+1 -1
View File
@@ -178,7 +178,7 @@ async def create_ticket_in_sd(requester_email: str, subject: str, description: s
if template_id:
req_payload["request"]["request_template"] = {"id": template_id}
async with httpx.AsyncClient(verify=False) as client:
resp = await client.post(endpoint, headers=headers, data=json.dumps({"input_data": req_payload}), timeout=15.0)
resp = await client.post(endpoint, headers=headers, content=json.dumps({"input_data": req_payload}), timeout=15.0)
if resp.status_code not in [200, 201]:
sd_workflow_logger.error(f"API Error: status={resp.status_code} body={resp.text}")
return resp