Public API v1

Prepare a clone reference: denoise + auto-transcribe

Denoises a reference clip and transcribes it with Whisper, returning a cleaned 44.1 kHz WAV (stored as a new fileId) plus the transcript. Run this BEFORE POST /v1/voices or /v1/clone and pass the returned fileId + transcript on: V4 uses refText as a continuation prompt, so a transcript that does not match the clip degrades EVERY generation with that voice, not just enrolment. Review the transcript before enrolling — warnings and languageProbability flag clips Whisper struggled with. Costs no tokens.

post/api/v1/prepare

Response

The cleaned clip and its transcript. Review the transcript before enrolling.

fileIdstring required

S3 key of the cleaned 44.1 kHz WAV — pass it as refFileId to POST /v1/clone, or download it via url to enrol with POST /v1/voices.

transcriptstring required

Whisper transcript of the cleaned clip — use it as refText after reviewing it (on V4 every generation aligns against this text).

secondsnumber required

Duration of the cleaned clip (seconds).

languageProbabilitynumber nullable required

Whisper language-detection confidence (0–1); null when unknown. A low value usually means the clip is noisy or not Vietnamese.

warningsstring[] required

Non-fatal quality warnings, e.g. denoiser_unavailable, empty_transcript, low_language_probability, clip_short_for_engine, clip_long_for_engine.

urlstring required

Presigned S3 download URL for the cleaned WAV.

urlExpiresInnumber required

Seconds until url expires.

Example response

{
  "fileId": "uploads/user-123/prepared_1716000000000_abc123.wav",
  "transcript": "Xin chào, đây là giọng nói của tôi.",
  "seconds": 11.4,
  "languageProbability": 0.93,
  "warnings": [
    "clip_long_for_engine"
  ],
  "url": "https://s3.amazonaws.com/bucket/uploads/user-123/prepared_….wav?X-Amz-Expires=86400",
  "urlExpiresIn": 86400
}

Changes

No recorded changes to this endpoint across all 1 revision of this API.