> ## 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.

# 导出项目转录

> 以 JSON、SRT 或 VTT 格式检索原始或已翻译的项目转录

# 导出项目转录

在不使用内部 Web 应用端点的情况下，从现有的 VoiceCheap 项目中检索转录。该端点支持源转录和所有可用的目标语言转录。
成功的请求将返回 HTTP `200`。

## 请求

<ParamField header="x-api-key" type="string" required>
  您的 VoiceCheap API 密钥。
</ParamField>

<ParamField path="projectId" type="string" required>
  由 [创建项目](/docs/zh/api-reference/create-project) 或 [开始翻译](/docs/zh/api-reference/translate) 返回的项目标识符。
</ParamField>

<ParamField body="source" type="string" required>
  `original` 或 `translated`。
</ParamField>

<ParamField body="targetLanguage" type="string">
  当 `source` 为 `translated` 时必需。请使用存储在项目上的目标语言名称，例如 `french`。
</ParamField>

<ParamField body="outputFormat" type="string" default="json">
  `json`、`srt` 或 `vtt`。
</ParamField>

<ParamField body="includeSpeakerLabels" type="boolean" default="false">
  在 SRT 或 VTT 中包含可见的发言者标签。JSON 始终包含发言者编号。
</ParamField>

## 示例

```bash cURL — Original JSON theme={null}
curl -X POST "https://api.voicecheap.ai/v1/projects/project_123/transcript" \
  -H "x-api-key: vc_your-api-key" \
  -H "Content-Type: application/json" \
  -d '{
    "source": "original",
    "outputFormat": "json"
  }'
```

```bash cURL — Translated SRT theme={null}
curl -X POST "https://api.voicecheap.ai/v1/projects/project_123/transcript" \
  -H "x-api-key: vc_your-api-key" \
  -H "Content-Type: application/json" \
  -d '{
    "source": "translated",
    "targetLanguage": "french",
    "outputFormat": "srt",
    "includeSpeakerLabels": true
  }' \
  --output project_123-fr.srt
```

JSON 响应使用 [转录媒体](/docs/zh/api-reference/transcribe) 中记录的相同标准化转录结构。存储的项目转录包括片段时间戳、发言者、语言、可用时的置信度数据，以及用于已翻译输出的 `workId`。

## 错误

| 状态  | 代码                         | 描述             |
| --- | -------------------------- | -------------- |
| 400 | `TARGET_LANGUAGE_REQUIRED` | 请求了已翻译输出但未指定语言 |
| 401 | `INVALID_API_KEY`          | API 密钥缺失或无效    |
| 403 | `FORBIDDEN`                | API 密钥无法访问此项目  |
| 404 | `PROJECT_NOT_FOUND`        | 项目不存在          |
| 404 | `TRANSCRIPT_NOT_FOUND`     | 请求的源转录或翻译转录不存在 |
| 409 | `TRANSCRIPT_NOT_READY`     | 请求的转录仍在处理中     |
