Simli Compose - API Reference
/textToVideoStream
Get Started
- Get Started
- Create Simli Agent
- Javascript SDK
- Python SDK
- Create Avatar
- WebRTC Guides
Simli Compose - API Reference
Simli Auto - API Reference
Face ID Creation API Reference
Simli Compose - API Reference
/textToVideoStream
This endpoint returns a url of an HLS .m3u8 playlist file along with an mp4 file.
POST
/
textToVideoStream
Copy
curl --request POST \
--url https://api.simli.ai/textToVideoStream \
--header 'Content-Type: application/json' \
--data '{
"ttsAPIKey": "<string>",
"simliAPIKey": "<string>",
"faceId": "<string>",
"user_id": "<string>",
"requestBody": {
"audioProvider": "<string>",
"text": "<string>",
"voice": "<string>",
"quality": "<string>",
"speed": 123,
"sample_rate": 123,
"voice_engine": "<string>",
"output_format": "<string>",
"emotion": "<string>",
"voice_guidance": 123,
"style_guidance": 123,
"text_guidance": 123
}
}'
Copy
"<string>"
Sample Input with elevenlabs audio provider
Copy
{
"ttsAPIKey": "", // Your Elevenlabs api Key
"simliAPIKey": "",
"faceId": "tmp9i8bbq7c",
"requestBody": {
"audioProvider": "ElevenLabs",
"text": "Tell me a joke will you. How many cakes can you eat?",
"voiceName": "pMsXgVXv3BLzUgSXRplE",
"model_id": "eleven_turbo_v2",
"voice_settings": {
"stability": 0.1,
"similarity_boost": 0.3,
"style": 0.2
}
}
}
Sample Input with PlayHT audio provider
Copy
{
"ttsAPIKey": "", // Your playht_authorization key
"simliAPIKey": "",
"faceId": "tmp9i8bbq7c",
"user_id": "", // Your playht user id
"requestBody": {
"audioProvider": "PlayHT",
"text": "Hello, my name is John Doe. Tell me a joke.",
"voice": "s3://voice-cloning-zero-shot/d9ff78ba-d016-47f6-b0ef-dd630f59414e/female-cs/manifest.json",
"quality": "draft",
"speed": 1,
"sample_rate": 24000,
"voice_engine": "PlayHT2.0-turbo",
"output_format": "mp3",
"emotion": "female_happy",
"voice_guidance": 3,
"style_guidance": 20,
"text_guidance": 1
}
}
Sample Response Body
Copy
{
"hls_url": "http://api.simli.ai/hls/path-to-file/output.m3u8",
"mp4_url": "http://api.simli.ai/mp4/path-to-file/output.mp4"
}
Body
application/json
Response
200 - application/json
Successful response
URL of the HLS .m3u8 playlist file
Copy
curl --request POST \
--url https://api.simli.ai/textToVideoStream \
--header 'Content-Type: application/json' \
--data '{
"ttsAPIKey": "<string>",
"simliAPIKey": "<string>",
"faceId": "<string>",
"user_id": "<string>",
"requestBody": {
"audioProvider": "<string>",
"text": "<string>",
"voice": "<string>",
"quality": "<string>",
"speed": 123,
"sample_rate": 123,
"voice_engine": "<string>",
"output_format": "<string>",
"emotion": "<string>",
"voice_guidance": 123,
"style_guidance": 123,
"text_guidance": 123
}
}'
Copy
"<string>"