From 49ddc36b447f9c191bf1b0cf4529a8199e605db3 Mon Sep 17 00:00:00 2001 From: dieperdev <140034404+dieperdev@users.noreply.github.com> Date: Wed, 31 Jan 2024 06:39:43 -0500 Subject: [PATCH] Update streamlabs_polly.py --- TTS/streamlabs_polly.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/TTS/streamlabs_polly.py b/TTS/streamlabs_polly.py index dc80dc9..aca1fe3 100644 --- a/TTS/streamlabs_polly.py +++ b/TTS/streamlabs_polly.py @@ -43,8 +43,9 @@ class StreamlabsPolly: f"Please set the config variable STREAMLABS_POLLY_VOICE to a valid voice. options are: {voices}" ) voice = str(settings.config["settings"]["tts"]["streamlabs_polly_voice"]).capitalize() + headers = {"referer": "https://streamlabs.com"} body = {"voice": voice, "text": text, "service": "polly"} - response = requests.post(self.url, data=body) + response = requests.post(self.url, headers=headers, data=body) if not check_ratelimit(response): self.run(text, filepath, random_voice)