Text to Speech

Let the phone speak out the provided text using the built in text to speech engine. The language parameter is ignored for now and the system language is used.

const onTextToSpeechCallback = (response: TextToSpeechContent, timestamp?: Date) => {
    console.log(response, timestamp);
};


const request: TextToSpeechContent = {
    content: 'Hello World',
    language: 'en-US'
};

COBI.app.textToSpeech.write(request, onTextToSpeechCallback);
pageTextToSpeechContent
Example Response
{
    "content": "Hello World",
    "language": "en-US"
}

Last updated