> ## Documentation Index
> Fetch the complete documentation index at: https://dev.docs.inworld.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Delete a PVC voice

> Deletes a PVC voice and all of its uploaded samples. Only allowed while the voice is `PVC_VOICE_STATE_DRAFT` or `PVC_VOICE_STATE_FAILED`. A `PVC_VOICE_STATE_READY` voice cannot be deleted through this API; its slot is released when the trained voice it produced is deleted via the Voices API.

Deletes the voice and every sample uploaded to it. Only allowed while the voice is `PVC_VOICE_STATE_DRAFT` or `PVC_VOICE_STATE_FAILED`.

<Warning>
  A `PVC_VOICE_STATE_READY` voice **cannot** be deleted through this API — this endpoint returns `409` and the PVC record is permanent. Its slot is released when the trained voice it produced is deleted, via the Portal voice library or `DELETE /voices/v1/workspaces/{workspace}/voices/{voice}`.
</Warning>


## OpenAPI

````yaml delete /voices/v1/pvcVoices/{voiceId}
openapi: 3.0.0
info:
  title: Inworld Professional Voice Cloning API
  version: v1
  contact:
    name: Inworld AI
    url: https://inworld.ai
    email: support@inworld.ai
servers:
  - url: https://api.inworld.ai
security:
  - inworld_basic: []
tags:
  - name: PvcVoiceService
paths:
  /voices/v1/pvcVoices/{voiceId}:
    delete:
      tags:
        - PvcVoiceService
      summary: Delete a PVC voice
      description: >-
        Deletes a PVC voice and all of its uploaded samples. Only allowed while
        the voice is `PVC_VOICE_STATE_DRAFT` or `PVC_VOICE_STATE_FAILED`. A
        `PVC_VOICE_STATE_READY` voice cannot be deleted through this API; its
        slot is released when the trained voice it produced is deleted via the
        Voices API.
      operationId: PvcVoiceService_DeletePvcVoice
      parameters:
        - name: voiceId
          description: Voice ID of the PVC voice to delete.
          in: path
          required: true
          schema:
            type: string
      responses:
        '200':
          description: A successful response.
          content:
            application/json:
              schema:
                type: object
                properties: {}
              examples:
                deleted:
                  summary: Deleted voice (empty response body)
                  value: {}
        '409':
          description: >-
            The voice is ready (or queued/training) and cannot be deleted
            through this API.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/rpcStatus'
              examples:
                not_deletable:
                  summary: Ready voices cannot be deleted
                  value:
                    code: 9
                    message: >-
                      pvc voice 'my-professional-voice' cannot be deleted while
                      in state PVC_VOICE_STATE_READY
                    details: []
        default:
          description: An unexpected error response.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/rpcStatus'
      x-codeSamples:
        - lang: bash
          label: cURL
          source: >-
            curl --location --request DELETE
            'https://api.inworld.ai/voices/v1/pvcVoices/<voice-id>' \

            --header "Authorization: Basic $INWORLD_API_KEY"
        - lang: python
          label: Python
          source: |-
            import requests

            voice_id = "<voice-id>"
            url = f"https://api.inworld.ai/voices/v1/pvcVoices/{voice_id}"
            headers = {"Authorization": "Basic <api-key>"}

            response = requests.delete(url, headers=headers)
            print(response.json())
        - lang: javascript
          label: JavaScript
          source: |-
            const voiceId = '<voice-id>';
            const url = `https://api.inworld.ai/voices/v1/pvcVoices/${voiceId}`;

            const response = await fetch(url, {
              method: 'DELETE',
              headers: { 'Authorization': 'Basic <api-key>' },
            });

            const data = await response.json();
            console.log(data);
components:
  schemas:
    rpcStatus:
      type: object
      properties:
        code:
          type: integer
          format: int32
          description: >-
            The status code, which should be an enum value of
            [google.rpc.Code][google.rpc.Code].
        message:
          type: string
          description: >-
            A developer-facing error message, which should be in English. Any
            user-facing error message should be localized and sent in the
            [google.rpc.Status.details][google.rpc.Status.details] field, or
            localized by the client.
        details:
          type: array
          items:
            $ref: '#/components/schemas/protobufAny'
          description: >-
            A list of messages that carry the error details. There is a common
            set of message types for APIs to use.
      description: >-
        The `Status` type defines a logical error model that is suitable for
        different programming environments, including REST APIs and RPC APIs.
    protobufAny:
      type: object
      properties:
        '@type':
          type: string
          description: >-
            A URL/resource name that uniquely identifies the type of the
            serialized protocol buffer message.
      additionalProperties: {}
      description: >-
        `Any` contains an arbitrary serialized protocol buffer message along
        with a URL that describes the type of the serialized message.
  securitySchemes:
    inworld_basic:
      type: apiKey
      in: header
      name: Authorization
      description: >-
        Your [API key](../../../api-reference/introduction). Read permissions
        are required for GET endpoints. Write permissions are required for POST,
        PATCH, and DELETE endpoints.

         For Basic authentication, please populate `Basic $INWORLD_API_KEY`. You can create a key in one command with the [Inworld CLI](../../../tts/resources/inworld-cli): `inworld workspace add-key`.

````