From 694922f627c1aae476ed10ddcdc43e74f4138171 Mon Sep 17 00:00:00 2001 From: hankehly Date: Sat, 2 Aug 2025 15:29:16 +0900 Subject: [PATCH] Fix PiperTTSService to send TTS input as JSON object --- src/pipecat/services/piper/tts.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/pipecat/services/piper/tts.py b/src/pipecat/services/piper/tts.py index 7892e15fa..8c7743d32 100644 --- a/src/pipecat/services/piper/tts.py +++ b/src/pipecat/services/piper/tts.py @@ -84,7 +84,8 @@ class PiperTTSService(TTSService): try: await self.start_ttfb_metrics() - async with self._session.post(self._base_url, json=text, headers=headers) as response: + payload = {"text": text} + async with self._session.post(self._base_url, json=payload, headers=headers) as response: if response.status != 200: error = await response.text() logger.error(