---
title: Text to speech
---

# Text to speech
POST *https://api.turing.sh/audio/tts*

## Parameters


- **model**
  - Type: string
  - Required: true
  - Options: google, elevenlabs
  - Default: google

- **voice**
  - Type: string
  - Required: true
  - Description: Voice to use (elevenlabs only)
  - Default: adam

- **text**
  - Type: string
  - Required: true
  - Description: Text to convert to speech

- **language**
  - Type: string
  - Required: true
  - Description: Language code to use (google only)
  - Default: en

- **slow**
  - Type: boolean
  - Required: false
  - Description: Speak slowly (google only)

- **stream**
  - Type: boolean
  - Required: false

## Response

<Error>Response not defined yet</Error>


## Examples

<CodeGroup title="Text to speech example">
  ```typescript
  import axios from "axios";
  (async () => {
    let response = await axios({
      method: "post",
      url: 'https://api.turing.sh/audio/tts',
      headers: {
        "Content-Type": "application/json",
        Authorization: "Bearer YOUR_API_KEY",
        "x-captcha-token": "Captcha key"
      },
      data: {
  "model": "google",
  "voice": "adam",
  "text": "string",
  "language": "en"
},
    })
  })();
  ```
  ```python
  import requests
  import json
  response = requests.post(
    "https://api.turing.sh/audio/tts",
    headers={
      "Content-Type": "application/json",
      "Authorization": "Bearer YOUR_API_KEY",
      "x-captcha-token": "Captcha key"
    },
    data=json.dumps({
  "model": "google",
  "voice": "adam",
  "text": "string",
  "language": "en"
}),
  )
  ```
</CodeGroup>