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

# 프로젝트 삭제

> 번역 프로젝트를 영구적으로 삭제합니다

# 프로젝트 삭제

번역 프로젝트와 관련 자산을 영구적으로 삭제합니다.

이 정리 작업은 프로젝트를 위해 생성된 저장된 음성 복제 미리보기 예제 파일도 제거합니다.

삭제가 완료되기 전에 일부 내부 생성 파일이나 세그먼트 기록이 이미 제거된 경우, 정리는 최선 노력 모드로 계속되며 프로젝트 삭제를 마무리합니다.

<Warning>
  이 작업은 되돌릴 수 없습니다. 프로젝트, 작업물, 생성된 미디어 자산 및 저장된 음성 복제 미리보기 예제 파일이 삭제됩니다.
</Warning>

## 요청

### 헤더

<ParamField header="x-api-key" type="string" required>
  귀하의 VoiceCheap API 키입니다. [app.voicecheap.ai/page-api](https://app.voicecheap.ai/page-api)에서 키를 받으세요.
</ParamField>

### 경로 매개변수

<ParamField path="projectId" type="string" required>
  삭제할 번역 프로젝트의 고유 식별자입니다.
</ParamField>

## 응답

<ResponseField name="success" type="boolean" required>
  삭제 작업이 성공적으로 완료되었음을 나타냅니다.
</ResponseField>

<ResponseField name="message" type="string" required>
  사람이 읽을 수 있는 확인 메시지입니다.
</ResponseField>

<ResponseField name="projectId" type="string" required>
  삭제된 프로젝트의 ID입니다.
</ResponseField>

## 예시

<CodeGroup>
  ```bash cURL theme={null}
  curl -X DELETE "https://api.voicecheap.ai/v1/translate/abc123-def456-ghi789" \
    -H "x-api-key: vc_your-api-key"
  ```

  ```typescript TypeScript theme={null}
  interface DeleteProjectResponse {
    success: true;
    message: string;
    projectId: string;
  }

  async function deleteProject(projectId: string): Promise<DeleteProjectResponse> {
    const response = await fetch(
      `https://api.voicecheap.ai/v1/translate/${projectId}`,
      {
        method: 'DELETE',
        headers: {
          'x-api-key': 'vc_your-api-key',
        },
      },
    );

    if (!response.ok) {
      const error = await response.json();
      throw new Error(error.message || 'Failed to delete project');
    }

    return response.json();
  }

  // Usage
  deleteProject('abc123-def456-ghi789')
    .then((result) => console.log('Deleted:', result.projectId))
    .catch((error) => console.error('Error:', error));
  ```

  ```python Python theme={null}
  import requests

  project_id = 'abc123-def456-ghi789'
  headers = {'x-api-key': 'vc_your-api-key'}

  response = requests.delete(
      f'https://api.voicecheap.ai/v1/translate/{project_id}',
      headers=headers
  )

  if not response.ok:
      error = response.json()
      raise Exception(error.get('message', 'Failed to delete project'))

  result = response.json()
  print(f"Deleted: {result['projectId']}")
  ```

  ```php PHP theme={null}
  <?php
  $apiKey = 'vc_your-api-key';
  $projectId = 'abc123-def456-ghi789';

  $curl = curl_init();

  curl_setopt_array($curl, [
      CURLOPT_URL => "https://api.voicecheap.ai/v1/translate/{$projectId}",
      CURLOPT_RETURNTRANSFER => true,
      CURLOPT_CUSTOMREQUEST => 'DELETE',
      CURLOPT_HTTPHEADER => [
          "x-api-key: {$apiKey}"
      ]
  ]);

  $response = curl_exec($curl);
  $result = json_decode($response, true);

  if (!isset($result['success'])) {
      $message = $result['message'] ?? 'Failed to delete project';
      throw new Exception($message);
  }

  echo "Deleted: " . $result['projectId'];
  ```
</CodeGroup>

## 오류

| 상태  | 코드                    | 설명                          |
| --- | --------------------- | --------------------------- |
| 401 | `INVALID_API_KEY`     | 제공된 API 키가 유효하지 않습니다        |
| 403 | `FORBIDDEN`           | 이 프로젝트를 삭제할 권한이 없습니다        |
| 404 | `PROJECT_NOT_FOUND`   | 지정된 프로젝트가 존재하지 않습니다         |
| 429 | `RATE_LIMIT_EXCEEDED` | 요청이 너무 많습니다 (제한: 분당 10회 요청) |
| 500 | `INTERNAL_ERROR`      | 예기치 않은 서버 오류                |
