Fish Model Query API 对接说明
本接口基于 Fish Audio 官方 Model API,用于分页检索 Fish 公共音色库或当前账号下的克隆音色。地址为 GET https://api.yxai-tech.top/fish/model。
创建音色请参考 Fish Model Create API;按
_id查询单个音色详情请参考 Fish Model Get API。
¶ 申请流程
要使用 Fish Model API,首先到 AI 聚合控制台 获取您的 API Token,留作备用。

如果你尚未登录或注册,会自动跳转到登录页面邀请你注册和登录,完成后会自动返回当前页面。
通用应用的 API Key 可用于账号已开放的服务;专用应用的 Key 按该应用的服务范围使用。请检查 Key 的权限、有效期和限额,并确认应用余额足以支付本次请求。可用试用额度以账号显示为准,余额不足时点击「充值」按钮即可。
📘 完整文档:Fish Model API →
¶ 查询参数
| 参数 | 类型 | 默认 | 说明 |
|---|---|---|---|
page_size |
integer | 10 | 每页条数。 |
page_number |
integer | 1 | 1 起的页码。 |
title |
string | — | 按标题模糊搜索。 |
tag |
string | — | 按单个标签过滤。 |
self |
boolean | — | true 时仅返回当前调用账号通过本平台创建并保存的音色。 |
author_id |
string | — | 按音色作者 ID 过滤。 |
language |
string | — | 按音色语种过滤,如 en、zh、es。 |
title_language |
string | — | 在公共音色库中按标题语种过滤。 |
sort_by |
string | — | 排序字段;self=true 时支持 created_at、task_count。 |
¶ 示例 1:默认翻页(按 page_size)
curl -G 'https://api.yxai-tech.top/fish/model' \
-H 'authorization: Bearer {token}' \
--data-urlencode 'page_size=2'
返回(实测,公共库总量约 180 万条;为可读性下例省略了部分长字段):
{
"total": 1829200,
"items": [
{
"_id": "8d2c17a9b26d4d83888ea67a1ee565b2",
"type": "tts",
"title": "Valentino Narración Biblica Fer",
"description": "A mature and authoritative male voice with a calm, spiritual tone...",
"cover_image": "coverimage/8d2c17a9b26d4d83888ea67a1ee565b2",
"train_mode": "fast",
"state": "trained",
"tags": ["male", "old", "narration", "calm", "Spanish"],
"samples": [
{
"title": "Default Sample",
"text": "Hermanos míos, recordemos las palabras del Señor...",
"task_id": "59ce7df6935c42249759327ddf70f37b",
"audio": "https://platform.r2.fish.audio/task/59ce7df6935c42249759327ddf70f37b.mp3"
}
],
"languages": ["es"],
"visibility": "public",
"like_count": 4344,
"task_count": 708461,
"author": {
"_id": "1b82fb6a329c4462b67aa9ee0a42046f",
"nickname": "Fernando Caicedo"
}
},
{
"_id": "90e65eaaf50e4470b8e6d43ee6afd7d5",
"type": "tts",
"title": "Super Smash Bros. 4/Ultimate Announcer",
"tags": ["male", "old", "announcer", "gaming", "cinematic"],
"languages": ["en"],
"visibility": "public"
}
],
"has_more": null
}
¶ 示例 2:按标题模糊搜索(title)
curl -G 'https://api.yxai-tech.top/fish/model' \
-H 'authorization: Bearer {token}' \
--data-urlencode 'title=narration' \
--data-urlencode 'page_size=2'
返回(实测):
{
"total": 161,
"items": [
{
"_id": "fb8fe4a94658429d9be70efd4eec35a2",
"type": "tts",
"title": "Miles Morales ( Narration Paw )",
"tags": ["male", "middle-aged", "entertainment", "storytelling", "Children's Content"],
"languages": ["en"],
"visibility": "public",
"task_count": 770
},
{
"_id": "76b55591c758444cb95253708696dfad",
"type": "tts",
"title": "Joe NARRATION",
"tags": ["male", "middle-aged", "narration", "deep", "raspy"],
"languages": ["en"],
"visibility": "public"
}
],
"has_more": null
}
注意 title 是「全局模糊匹配」,会同时命中 Fish 公共库的所有音色(不仅是自己的)。
¶ 示例 3:只列出自己创建的音色(self=true)
curl -G 'https://api.yxai-tech.top/fish/model' \
-H 'authorization: Bearer {token}' \
--data-urlencode 'self=true' \
--data-urlencode 'page_size=5'
返回示例:
{
"total": 1,
"items": [
{
"_id": "e5c6db52c3ed417f9cb2e5a33fb04667",
"type": "tts",
"title": "copilot-smoke-test",
"description": "smoke test from api.acedata.cloud",
"state": "trained",
"languages": ["zh"],
"visibility": "public",
"samples": [
{
"title": "Default Sample",
"text": "师父,[语气坚定]我真的受够了这山上的清冷日子!...",
"task_id": "6a1bf398dfae49dca0e23159214342a0",
"audio": "https://platform.r2.fish.audio/task/6a1bf398dfae49dca0e23159214342a0.mp3"
}
],
"created_at": "2026-05-10T03:52:55.601000Z",
"author": {
"_id": "780f2b2f862d41a08c0507bbbda77eb6",
"nickname": "Penny Conrad"
}
}
],
"has_more": false
}
self=true 按实际调用账号列出通过本平台创建并保存的音色;同一账号使用不同 API Token 创建的音色也会一起列出。结果按创建时间倒序分页,author_id 可进一步筛选这些音色的作者 ID。此参数只筛选列表,音色仍公开可用。
self=true 不支持 title_language;如需按标题语种搜索,请查询公共音色库。
¶ 示例 4:按语种 + 标签过滤
curl -G 'https://api.yxai-tech.top/fish/model' \
-H 'authorization: Bearer {token}' \
--data-urlencode 'language=zh' \
--data-urlencode 'tag=narration' \
--data-urlencode 'page_size=5'
tag匹配较宽松;如果命中数为 0,建议改用title模糊匹配。
¶ 响应字段
items[] 中的每一项是一个完整 ModelEntity 对象,常用字段:
| 字段 | 类型 | 说明 |
|---|---|---|
_id |
string | 音色 ID,作为 /fish/tts 中 reference_id 的值。 |
type |
string | 模型类型,通常为 tts。 |
title |
string | 音色名称。 |
description |
string | 音色描述。 |
state |
string | 训练状态:trained 表示可用。 |
tags |
string[] | 公共库标签。 |
languages |
string[] | 音色擅长的语种。 |
visibility |
string | public 或 private。 |
samples |
object[] | 预置样本(含 audio 直链)。 |
like_count |
integer | 公共库点赞数。 |
task_count |
integer | 历史合成次数。 |
author |
object | 音色作者信息:_id / nickname / avatar。 |
total(顶层) |
integer | 满足条件的总条数。 |
has_more |
boolean? | self=true 时为布尔值;公共音色库查询可能为 null。 |
¶ 计费说明
本接口不计费——分页查询音色列表是免费操作。创建音色(Fish Model Create)同样免费,费用仅在调用 Fish TTS 合成语音时按用量产生。
¶ 错误处理
400 token_mismatched:请求参数缺失或不合法。401 invalid_token:鉴权 token 不存在或无效。429 too_many_requests:触发账号速率限制。500 api_error:服务器内部错误。
错误响应示例:
{
"success": false,
"error": {
"code": "api_error",
"message": "fetch failed"
},
"trace_id": "2cf86e86-22a4-46e1-ac2f-032c0f2a4e89"
}
¶ 结论
要从 Fish 公共库挑选音色喂给 /fish/tts 的 reference_id,先用本接口配合 title / tag / language 检索,定位到目标 _id,再用 Fish Model Get 拿样本试听。要列出自己创建的音色,传 self=true 即可。

