Skip to main content

Delete Voice API

Remove unused custom voices in the current API key's organization using a project-scoped API key and immediately free organization voice slots. This endpoint deletes custom voices created through the Voice Cloning API, the Voice Design API, or the console.

Use cases​

Free voice slotsRemove old or test voices to immediately release voice-slot capacity for your organization.
Lifecycle managementProgrammatically retire custom voices for completed projects or temporary campaigns.
Unified custom-voice cleanupManage both cloned and designed custom voices in your organization through one endpoint.
Safe organization boundariesOnly deletes custom voices owned by your organization; system voices and other organizations’ voices are never removed.

Quick start​

Set your API base URL and API key first. If you do not have a key, see Get your API key.

This endpoint uses the X-API-Key request header and requires Voice Cloning to be enabled for the project along with active organization access for the key’s member. To look up custom voices visible in the API key's organization, call the List Voices API with source=personal.

export VUILABS_API_BASE_URL="https://api.vuilabs.ai"
export VUILABS_API_KEY="your-api-key"

Replace my_support_voice with the custom voice_id you want to remove and call DELETE /v1/voice/{voice_id}:

curl --request DELETE \
--url "$VUILABS_API_BASE_URL/v1/voice/my_support_voice" \
--header "X-API-Key: $VUILABS_API_KEY"
  • Immediate slot release: When deletion succeeds, the organization’s used voice slots decrease immediately and the voice is removed from the List Voices API (source=personal). If the voice was published, it is also unpublished.
  • No ID reuse: Once deleted, the same voice_id cannot be reused to create a new voice in the organization.
  • Scope boundary: Only custom voices belonging to the API key’s organization can be deleted. System voices and other organizations’ voices are protected.

API details​

Endpoint: DELETE /v1/voice/{voice_id}

Requires active organization access for the member associated with the API key (a deactivated or removed member returns HTTP 403 with error_code: 10004).

Request headers​

HeaderRequiredDescription
X-API-KeyYesProject API key with Voice Cloning enabled.
Accept-LanguageNoControls the language of error_message: en (default) or zh-CN.

Path parameters​

ParameterTypeRequiredDescription
voice_idstringYesCustom voice ID to delete (including IDs returned by Voice Cloning and Voice Design). Pass the ID returned by the API as-is; leading/trailing whitespace is trimmed and ASCII letters are lowercased.

Response format​

Successful deletion returns HTTP 200 with the standard JSON envelope:

{
"error_code": 0,
"error_message": "",
"succeed": true,
"data": {}
}
  • Repeated requests: Replaying the delete request for the same voice_id by the same member returns HTTP 200 with the same successful envelope.
  • Missing or non-deletable voices: Deleting a nonexistent voice_id, a system voice, another organization’s voice, or a voice already removed via the console or another member returns HTTP 400 with error_code: 12950:
{
"error_code": 12950,
"error_message": "Voice is unavailable.",
"succeed": false,
"data": null
}

Common error codes​

error_codeMeaningWhat to do
10001Path parameter voice_id is missing or empty (HTTP 400)Pass a valid custom voice_id and retry
10003API key is missing or invalid, or the organization/project is disabled (HTTP 401)Check X-API-Key and organization/project status
10004Member has no active organization access, or Voice Cloning is disabled for the project (HTTP 403)Restore member access or enable Voice Cloning for the project before retrying
12950Voice does not exist, was already deleted through another path, or is not a custom voice in your organization (for example, a system voice) (HTTP 400)Call the List Voices API with source=personal to verify existing custom voice_id values
10005Request rate exceeded for the project space (HTTP 429)Reduce request frequency and retry
10000Unexpected service error (HTTP 500)Try again later; contact support if the error persists

For authentication, rate-limit, billing, timeout, service, and other common errors, see Errors. For voice-slot rules, see Pricing.