From e81a88938a2208478ac12347ec1f941651c16eb2 Mon Sep 17 00:00:00 2001 From: erew123 <35898566+erew123@users.noreply.github.com> Date: Fri, 29 Dec 2023 10:11:01 +0000 Subject: [PATCH] Completed built-in documentation update For the new API endpoints --- tts_server.py | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/tts_server.py b/tts_server.py index 6e3db2a..c92b87d 100644 --- a/tts_server.py +++ b/tts_server.py @@ -1720,6 +1720,33 @@ simple_webpage = """

curl -X POST "http://127.0.0.1:7851/api/lowvramsetting?new_low_vram_value=True"

Replace True with False to disable Low VRAM mode.

JSON return {"status": "lowvram-success"}

+

Ready Endpoint

+

Check if the Text-to-Speech (TTS) service is ready to accept requests.

+ +

curl -X GET "http://127.0.0.1:7851/api/ready"

+

Voices List Endpoint

+

Retrieve a list of available voices for generating speech.

+ +

curl -X GET "http://127.0.0.1:7851/api/voices"

+

JSON return: {"voices": ["voice1.wav", "voice2.wav", "voice3.wav"]}

+

Preview Voice Endpoint

+

Generate a preview of a specified voice with hardcoded settings.

+ +

curl -X POST "http://127.0.0.1:7851/api/previewvoice/" -F "voice=female_01.wav"

+

Replace female_01.wav with the name of the voice sample you want to hear.

+

JSON return: {"status": "generate-success", "output_file_path": "/path/to/outputs/api_preview_voice.wav", "output_file_url": "http://127.0.0.1:7851/audio/api_preview_voice.wav"}

+

Back to top of page

Debugging and TTS Generation Information