---
title: "Text To Speech"
method: POST
path: "/api/tts"
tags: ["tts"]
---

# Text To Speech

`POST /api/tts`

Convert text to speech using the user's preferred TTS provider.

Args:
    request: TTS request containing text
    current_user: Authenticated user

Returns:
    TTSResponse containing base64 encoded audio data

## Headers

- `x-user-id` string, nullable

## Request body

- TTSRequest
  - `text` string, required — Text to convert to speech (max 400 words)

## Response `200`

Successful Response

- TTSResponse
  - `audio_base64` string, required — Base64 encoded audio data
  - `mime_type` string, required — MIME type of the audio
  - `format` string, required — Audio format

## Other responses

- `422` — Validation Error

---

[API](https://skmtc.net/usecreed/apis/creed-api.md) · [All operations](https://skmtc.net/usecreed/apis/creed-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/usecreed/creed-api/revisions/523833f9e819/schema)
