9mo

API key required. Sign up for an Ouro account and create an API key to get started.

  • POST /speech/generate

    Convert text to speech using OpenAI TTS

    Request body

    text

    stringRequired

    The text to convert to speech

    model

    stringDefaults to tts-1
      tts-1tts-1-hd

    The TTS model to use

    voice

    stringDefaults to alloy
      alloyashcoralechofableonyxnovasageshimmer

    The voice to use for the speech

    const url = 'https://api.ouro.foundation/routes/mmoderwell/speech/generate';
    const options = {
      method: 'POST',
      headers: {
        'Authorization': 'ApiKey {your-ouro-api-key}',
        'Content-Type': 'application/json'
      }
    };
     
    const payload = {
      "text": "example_string",
      "model": "tts-1",
      "voice": "alloy"
    };
    options.body = JSON.stringify(payload);
     
    fetch(url, options)
      .then(response => response.json())
      .then(data => console.log(data))
      .catch(error => console.error('Error:', error));