OpenAPI/V1/Audio
TTS文本转语音服务
OpenAI 最新款的文本转语音(TTS)模型
效果非常棒,媲美真实人声,一个声音就原生支持多国语言,站长觉得它的效果比Azure的神经网络语音引擎还要牛x,对于语言学习类、AI对话交流类、AI朗读(听书、网页阅读)等方面的应用应该很有帮助。
Authorization
Authorization
RequiredBearer <token>In: header
Request Body
application/x-www-form-urlencoded
Optionalmodel
Requiredstring可用的 TTS 模型之一:tts-1 或 tts-1-hd
input
Requiredstring要为其生成音频的文本。 最大长度为 4096 个字符。(string.length)
voice
Requiredstring生成音频时使用的语音。 支持的声音有: alloy, echo, fable, onyx, nova, shimmer
response_format
string返回音频格式,支持mp3, opus, aac, and flac.
speed
string语速,范围:[0.25, 4.0]
Response Body
TypeScript Definitions
Use the response body type in TypeScript.