Public API v1

Dub a Vietnamese audio file with a new voice

Changed on

Transcribes the uploaded Vietnamese audio (Whisper STT), then re-synthesizes it with the chosen preset voice. Tokens are billed by the OUTPUT audio duration (same rate as the app, × the engine multiplier), charged only on success. Max file size: 10 MB.

post/api/v1/dub

Request

  • Base URL
    https://api.vieneu.io
  • Auth
    • API key in header X-API-Key
    • or HTTP bearer

Request body multipart/form-data

audiostring binary required
voiceIdstring required
emotionstring
temperaturenumber
engine'v4'

TTS engine — each billed at its own multiplier. Omit it for the configured default, which GET /v1/engines reports as isDefault. The voice must belong to the engine that runs; the two catalogues share no ids.

Example request

{
  "voiceId": "Ngọc Lan",
  "emotion": "natural",
  "temperature": 1,
  "engine": "v4"
}

Response

The re-voiced audio plus the transcript it was built from.

successboolean required
transcriptstring required

Vietnamese text transcribed from the uploaded audio.

voiceUsedstring required

Voice the audio was re-synthesized with.

audioUrlstring required

Presigned S3 download URL for the dubbed WAV.

audioUrlExpiresInnumber required

Seconds until audioUrl expires.

durationnumber required

Duration of the dubbed audio (seconds).

tokenCostnumber required

Tokens deducted (computed from the transcript).

Example response

{
  "success": true,
  "transcript": "Xin chào, đây là nội dung được phiên âm.",
  "voiceUsed": "Tuyen",
  "audioUrl": "https://s3.amazonaws.com/bucket/dub/job.wav?X-Amz-Expires=3600&...",
  "audioUrlExpiresIn": 3600,
  "duration": 5.2,
  "tokenCost": 80
}

Changes

    • breaking

      removed the enum value v3 of the request property

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status