{"uid":"cap_czbPmSzkKk5uYfri6UN38","slug":"stablevoice-text-to-speech-api-78ec5c66","name":"StableVoice Text-to-Speech API","description":"Text-to-speech on Modal via x402 and MPP. Generate Chatterbox Turbo, Chatterbox, and multilingual Chatterbox speech into StableUpload audio slots.","url":"https://stablevoice.dev/api/speech","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"text":{"type":"string","maxLength":2500,"minLength":1,"description":"Text to synthesize, max 2500 characters."},"type":{"type":"string","const":"stablevoice-speech","default":"stablevoice-speech"},"model":{"enum":["chatterbox-turbo","chatterbox","chatterbox-multilingual","f5-tts","voxcpm2","qwen3-tts-1.7b"],"type":"string","default":"chatterbox-turbo","description":"Self-hosted Modal model. chatterbox-turbo is fastest; chatterbox adds expressive controls; chatterbox-multilingual supports 23 languages."},"voice":{"enum":["Aaron","Abigail","Anaya","Andy","Archer","Brian","Chloe","Dylan","Emmanuel","Ethan","Evelyn","Gavin","Gordon","Ivan","Laura","Lucy","Madison","Marisol","Meera","Walter"],"type":"string","default":"Lucy","description":"Bundled reference voice. Match to the character's identity using `voiceGuide` from /api/voices — each voice carries an accent/ethnicity tag (Indian, Australian, Slavic, Black, Latina, American, older country) and a casting cue. Default Lucy is a neutral North American female. Ignored only when referenceAudioUrl is supplied."},"format":{"enum":["wav","mp3"],"type":"string","default":"wav"},"output":{"type":"object","required":["publicUrl"],"properties":{"postUrl":{"type":"string","format":"uri","description":"Presigned POST URL from StableUpload. Pair with postFields."},"publicUrl":{"type":"string","format":"uri","description":"StableUpload public URL where the generated audio will land."},"uploadUrl":{"type":"string","format":"uri","description":"Presigned PUT URL from StableUpload. Do not pass a POST slot's bare S3 postUrl here."},"postFields":{"type":"object","description":"Required form fields when posting to postUrl.","propertyNames":{"type":"string"},"additionalProperties":{"type":"string"}}},"description":"Reserved StableUpload output slot for the generated audio.","additionalProperties":false},"options":{"type":"object","required":["temperature","topP","topK","minP","repetitionPenalty","exaggeration","cfgWeight","normalizeReferenceLoudness"],"properties":{"minP":{"type":"number","default":0.05,"maximum":0.5,"minimum":0},"topK":{"type":"integer","default":1000,"maximum":1000,"minimum":1},"topP":{"type":"number","default":0.95,"maximum":1,"minimum":0.05},"speed":{"type":"number","maximum":2,"minimum":0.5},"nfeStep":{"type":"integer","maximum":64,"minimum":8},"cfgValue":{"type":"number","maximum":5,"minimum":0},"cfgWeight":{"type":"number","default":0.5,"maximum":1.5,"minimum":0},"cloneMode":{"enum":["standard","controllable","ultimate","voice-design"],"type":"string"},"cfgStrength":{"type":"number","maximum":5,"minimum":0},"stylePrompt":{"type":"string","maxLength":200,"minLength":1,"description":"VoxCPM2 style instruction, wrapped into the generated text as `(instruction)...`."},"temperature":{"type":"number","default":0.8,"maximum":2,"minimum":0.05},"exaggeration":{"type":"number","default":0.5,"maximum":1.5,"minimum":0},"xVectorOnlyMode":{"type":"boolean","description":"Qwen3-TTS clone mode that skips reference transcript use; faster but lower similarity."},"voiceDescription":{"type":"string","maxLength":200,"minLength":1,"description":"VoxCPM2 voice-design description. Use without referenceAudioUrl."},"repetitionPenalty":{"type":"number","default":1.2,"maximum":3,"minimum":1},"inferenceTimesteps":{"type":"integer","maximum":32,"minimum":4},"normalizeReferenceLoudness":{"type":"boolean","default":true}},"additionalProperties":false},"language":{"enum":["ar","da","de","el","en","es","fi","fr","he","hi","it","ja","ko","ms","nl","no","pl","pt","ru","sv","sw","tr","zh"],"type":"string","default":"en","description":"Language ID. Required for chatterbox-multilingual."},"referenceText":{"type":"string","maxLength":1000,"minLength":1,"description":"Optional exact transcript of referenceAudioUrl. Used by f5-tts, voxcpm2, and qwen3-tts-1.7b to skip on-worker Whisper transcription. Omit it if uncertain. Ignored by chatterbox-*."},"clientRequestId":{"type":"string","maxLength":128,"minLength":1},"referenceAudioUrl":{"type":"string","format":"uri","description":"Optional StableUpload URL for a custom voice reference. WAV/MP3/M4A. Required reference duration depends on the model: voxcpm2 and qwen3-tts-1.7b take 3-10s, f5-tts takes 10-15s, chatterbox-* takes 5-15s."}}},"responseSchema":null,"example":{"request":{"text":"Hello, this is a test of the speech synthesis system. The weather today is sunny and pleasant.","type":"stablevoice-speech","model":"chatterbox-turbo","voice":"Lucy","format":"wav","output":{"publicUrl":"https://stableupload.example.com/audio/test-output-12345.wav","uploadUrl":"https://stableupload.example.com/upload/test-output-12345"},"language":"en","clientRequestId":"qa-test-001"},"response":{"type":"stablevoice-speech","jobId":"cmqki0djh000004lby79bdmte","price":"0.02","status":"queued"}},"exampleRequest":{"text":"Hello, this is a test of the speech synthesis system. The weather today is sunny and pleasant.","type":"stablevoice-speech","model":"chatterbox-turbo","voice":"Lucy","format":"wav","output":{"publicUrl":"https://stableupload.example.com/audio/test-output-12345.wav","uploadUrl":"https://stableupload.example.com/upload/test-output-12345"},"language":"en","clientRequestId":"qa-test-001"},"tags":["x402"],"displayCostAmount":"1","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"settled","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$1/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"1","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"1","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_OzlFTZqSWffQYlkFzgkYY","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"1","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Generates speech audio from text using Chatterbox Turbo, Chatterbox, or multilingual Chatterbox models, delivering output into StableUpload audio slots via x402 micropayment protocol","exampleAgentPrompt":"Generate spoken audio for the text 'Welcome to our platform, we're glad you're here.' using the Chatterbox Turbo model and store it in a StableUpload audio slot.","exampleUseCases":null,"resultDescription":"A reference or URL to a StableUpload audio slot containing the synthesized speech audio generated from the provided text using the selected Chatterbox model.","failureModes":["Payment failure — x402 micropayment of $1 USDC not authorized or insufficient funds","Invalid model selection — unsupported Chatterbox model variant specified","Text input too long — exceeds maximum character limit for synthesis","Unsupported language — requested language not available in multilingual model","StableUpload slot unavailable — storage destination cannot be allocated","Server error on Modal compute infrastructure"],"whenToPreferThis":"Choose this endpoint when you need high-quality Chatterbox-model TTS (including Turbo and multilingual variants) with automatic audio storage via StableUpload, and are operating in a pay-per-call x402 micropayment environment. Prefer over generic TTS APIs when you want Chatterbox-specific voice quality or need direct integration with the StableUpload storage ecosystem.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-13T18:34:37.803Z","isFirstParty":false}