Saltar al contenido principal
POST
/
api
/
v1
/
llm
/
speech
/
tts
Python (SDK)
from mka1 import SDK


with SDK(
    bearer_auth="<YOUR_BEARER_TOKEN_HERE>",
) as sdk:

    res = sdk.llm.speech.speak(text="Hello, welcome to our text-to-speech service.", language="en", model="auto")

    # Handle response
    print(res)
"(binary)"

Documentation Index

Fetch the complete documentation index at: https://docs.mka1.com/llms.txt

Use this file to discover all available pages before exploring further.

Autorizaciones

Authorization
string
header
requerido

Gateway auth: send Authorization: Bearer <mka1-api-key>. For multi-user server-side integrations, you can also send X-On-Behalf-Of: <external-user-id>.

Encabezados

X-On-Behalf-Of
string

Optional external end-user identifier forwarded by the API gateway.

Cuerpo

application/json

Parámetros de solicitud para la conversión de texto a voz con selección de idioma.

text
string
requerido

Texto de entrada para convertir a voz

Minimum string length: 1
language
enum<string>
predeterminado:auto

Código de idioma: 'auto' para detección automática, o códigos de idioma ISO 639-1.

Opciones disponibles:
auto,
en,
zh,
hi,
es,
ar,
bn,
pt,
ru,
ja,
pa,
de,
ko,
fr,
tr,
it,
th,
pl,
nl,
id,
vi,
ur
model
string
predeterminado:auto

Identificador del modelo TTS. Por defecto es 'auto', que selecciona el proveedor predeterminado. Los IDs resolubles en el registro envían al proveedor correspondiente.

Ejemplo:

"auto"

Respuesta

200 - audio/wav

Archivo de audio en formato WAV con encabezado de código de idioma.

The response is of type file.