lordofgaming
Initial VoiceForge deployment (clean)
673435a
import requests
import json
def test_api():
base_url = "http://localhost:8000/api/v1"
print("Testing TTS Voices endpoint...")
try:
response = requests.get(f"{base_url}/tts/voices")
print(f"Status Code: {response.status_code}")
if response.status_code == 200:
data = response.json()
print(f"Total Voices: {data.get('total', 0)}")
print("First 3 voices:")
for v in data.get("voices", [])[:3]:
print(f"- {v['name']} ({v['language_code']})")
else:
print("Error:", response.text)
except Exception as e:
print(f"Connection failed: {e}")
if __name__ == "__main__":
test_api()