diff --git a/app/discord.py b/app/discord.py index 496702e2..de66c3cc 100644 --- a/app/discord.py +++ b/app/discord.py @@ -4,6 +4,7 @@ from typing import Any +import orjson from tenacity import retry from tenacity import stop_after_attempt from tenacity import wait_exponential @@ -168,7 +169,7 @@ def json(self) -> Any: payload["embeds"].append(embed_payload) - return payload + return orjson.dumps(payload, default=str).decode() @retry( stop=stop_after_attempt(10), @@ -181,7 +182,7 @@ async def post(self) -> None: headers = {"Content-Type": "application/json"} response = await services.http_client.post( self.url, - json=self.json, + content=self.json, headers=headers, ) response.raise_for_status()