---
title: "音色复刻"
method: POST
path: "/paas/v4/voice/clone"
tags: ["模型 API"]
---

# 音色复刻

`POST /paas/v4/voice/clone`

使用音色复刻技术，基于示例音频生成指定音色、文本内容的语音合成。点击 **Try it** 按钮可快速试用。

## Request body

- VoiceCloneRequest
  - `model` 'glm-tts-clone', required — 模型
  - `voice_name` string, required — 指定唯一的音色名称
  - `text` string — 示例音频的文本内容，选填
  - `input` string, required — 生成试听音频的目标文本内容
  - `file_id` string, required — 示例音频的file_id，通过文件接口上传获取。大小限制不超过10M，建议音频时长在3秒到30秒之间。
  - `request_id` string — 请求唯一标识符。由用户端传递，`ID`长度要求：最少`6`个字符，最多`64`个字符，建议使用`UUID`格式确保唯一性，若未提供平台将自动生成。

## Response `200`

业务处理成功

- VoiceCloneResponse
  - `voice` string — 音色
  - `file_id` string — 音频试听文件ID
  - `file_purpose` string — 文件 purpose，固定为voice-clone-output
  - `request_id` string — 请求 ID

## Other responses

- `default` — 请求失败。

---

[API](https://skmtc.net/bigmodel/apis/zhipu-ai-api.md) · [All operations](https://skmtc.net/bigmodel/apis/zhipu-ai-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/bigmodel/zhipu-ai-api/revisions/37de2d7b73de/schema)
