> ## AI Agent Context
> - Full documentation index: https://aistudio.google.com/llms.txt
> - Gemini Docs MCP server (consistent live info): https://gemini-api-docs-mcp.dev
> - Coding agent skills & setup guide: https://aistudio.google.com/docs/coding-agents.md

# Deleting a voice

{% callout type="note" %}
  This API is in Beta. Endpoints are under `/v1beta/`.

{% /callout %}

{% mark class="http-delete" %}{% icon name="close" /%}`DELETE`{% /mark %} `https://generativelanguage.googleapis.com/v1beta/voices/{voicesId}`

Deletes a custom stored voice (`store = true`) by resource name.
Prebuilt catalog voices (`VOICE_TYPE_PREBUILT`) cannot be deleted.

{% two-column-layout %}
  {% left-column %}
## Parameters  {% class="hide-from-toc" id="parameters" %}

  {% section class="api-ref-property-list" %}
  **voicesId**: {% mark %}required{% /mark %} `string`

  The resource name of the custom stored voice to delete (for example, `voices/voice_abc123def456`).

  {% /section %}

  {% /left-column %}

  {% right-column class="sticky" %}
  **Example request** {% class="example-heading" %}

  {% tabs %}
  {% tab label="REST" %}
  ```sh
  curl -X DELETE https://generativelanguage.googleapis.com/v1beta/voices/voice_abc123 \
    -H "x-goog-api-key: $GEMINI_API_KEY"
  ```

  {% /tab %}

  {% tab label="Python" %}
  ```python
  from google import genai
  
  client = genai.Client(http_options={"api_version": "v1beta"})
  client.voices.delete(id="voice_abc123")
  ```

  {% /tab %}

  {% tab label="JavaScript" %}
  ```javascript
  import {GoogleGenAI} from '@google/genai';
  
  const ai = new GoogleGenAI({apiVersion: 'v1beta'});
  await ai.voices.delete('voice_abc123');
  ```

  {% /tab %}

  {% tab label="Go" %}
  ```go
  package main
  
  import (
      "context"
      "log"
      "google.golang.org/genai"
      "google.golang.org/genai/interactions/models/operations"
  )
  
  func main() {
      ctx := context.Background()
      client, err := genai.NewClient(ctx, &genai.ClientConfig{
          HTTPOptions: genai.HTTPOptions{APIVersion: "v1beta"},
      })
      if err != nil {
          log.Fatal(err)
      }
  
      _, err = client.Voices.Delete(ctx, operations.DeleteVoiceRequest{
          ID: "voice_abc123",
      })
      if err != nil {
          log.Fatal(err)
      }
  }
  ```

  {% /tab %}

  {% /tabs %}

  {% /right-column %}

{% /two-column-layout %}

## Response  {% class="hide-from-toc" id="response" %}

{% section class="api-ref-property-list" /%}

