AI model APIAudioNative OpenAI format
Text-to-speech
Convert text into audio
Authorization
BearerAuth AuthorizationBearer <token>
Authenticate with a Bearer token: Authorization: Bearer sk-xxxxxx.
In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
audio/mpeg
curl -X POST "https://example.com/v1/audio/speech" \ -H "Content-Type: application/json" \ -d '{ "model": "tts-1", "input": "string", "voice": "alloy" }'"string"