import { type SpeechCreateParams } from "https://deno.land/x/openai@v4.28.4/resources/audio/speech.ts";
Properties
One of the available TTS models:
tts-1
or tts-1-hd
The voice to use when generating the audio. Supported voices are alloy
,
echo
, fable
, onyx
, nova
, and shimmer
. Previews of the voices are
available in the
Text to speech guide.
The format to return audio in. Supported formats are mp3
, opus
, aac
,
flac
, pcm
, and wav
.
The pcm
audio format, similar to wav
but without a header, utilizes a 24kHz
sample rate, mono channel, and 16-bit depth in signed little-endian format.