audio

Convert speech to a target voice

Changed on

Creates an asynchronous speech-to-speech voice conversion task (elevenlabs-sts-v2 or auto, 1 second to 5 minutes, up to 50 MiB) using a voice with supports_speech_to_speech=true from GET /v1/voices. Supports optional voice expressiveness controls (stability, similarity_boost, style, use_speaker_boost). Charged per started input audio minute. When the task succeeds, output contains {type: "speech_to_speech", model, voice_id, audio: {url, artifact_id, duration_seconds, mime_type, size_bytes}}.

post/v1/audio/speech-to-speech

Request

  • Base URL
    https://api.beatra.ai (the document declares no server; this is the origin it was published from)
  • Auth
    none declared. Required headers: Idempotency-Key

Headers

x-request-id, string nullable
Idempotency-Key, string required
authorization, string nullable

Request body

SpeechToSpeechCreateRequest required

POST /v1/audio/speech-to-speech request body.

metadata, object nullable

Caller-supplied metadata; ≤16 keys, key ≤64 chars, value ≤512 chars

callback_url, string nullable

HTTPS URL beatra will POST the final Task envelope to when the Task reaches a terminal state

callback_signing_key_id, string nullable

Optional standalone callback signing key. Omit for unsigned callback delivery; requires callback_url when provided.

audio, union required

Source speech audio (artifact_id or HTTPS url; 1.0-300.0 seconds, <= 50 MB). Accepts audio or source.

voice, string required

Target Beatra voice_id supporting speech_to_speech (supports_speech_to_speech=true or model=elevenlabs-sts-v2 in voices list). Accepts voice or voice_id.

model, 'auto' | 'elevenlabs-sts-v2'

Speech-to-speech model identifier, or 'auto' for automatic selection.

remove_background_noise, boolean

Strip ambient noise from the source recording before voice conversion.

format, 'mp3' | 'wav' | 'opus' | 'pcm'

Output audio container/encoding format.

seed, integer nullable

Optional deterministic seed (0..4294967295).

stability, number nullable

Optional target voice stability (0.0-1.0; lower is more expressive, higher is steadier).

similarity_boost, number nullable

Optional target voice similarity boost (0.0-1.0).

style, number nullable

Optional target voice style exaggeration (0.0-1.0).

use_speaker_boost, boolean nullable

Optional speaker clarity boost on the target voice.

model_options, object nullable

Optional model-family-specific options (for example, {"elevenlabs": {...}}). Unrecognized keys emit an option_ignored warning.

Response

Task accepted

TaskEnvelope required

Standard Task envelope.

Returned by every async-creation endpoint, GET /v1/tasks/{id}, and the body of customer callback POSTs.

object, 'task'
task_id, string required
status, 'queued' | 'running' | 'succeeded' | 'failed' | 'canceled' required
capability, string required
workload_type, 'model' | 'social_operation'
model, string nullable

Caller-requested model verbatim (may be 'auto'). Null for social_operation tasks.

resolved_model, string nullable

Actual model that ran (null until execution starts; equals model for explicit-model calls)

model_selection_reason, unknown
social, SocialTaskIdentity nullable
metadata, object nullable
input, object nullable
progress, AppApiV1SchemasCommonTaskProgress nullable
output, object nullable
warnings, TaskWarning[]
error, AppApiV1SchemasCommonTaskError nullable
usage, UsageObject nullable
billing, TaskBilling nullable
callback, TaskCallback nullable
created_at, string date-time required
started_at, string date-time nullable
deadline_at, string date-time nullable
completed_at, string date-time nullable
cancel_requested_at, string date-time nullable
links, TaskLinks required

Changes