Fish Tts
curl --request POST \
--url https://api.acedata.cloud/fish/tts \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"text": "Hello, this is a Fish-Audio-compatible test."
}
'import requests
url = "https://api.acedata.cloud/fish/tts"
payload = { "text": "Hello, this is a Fish-Audio-compatible test." }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({text: 'Hello, this is a Fish-Audio-compatible test.'})
};
fetch('https://api.acedata.cloud/fish/tts', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"audio_url": "https://platform.r2.fish.audio/task/8a72ff9840234006a9f74cb2fa04f978.mp3"
}{
"error": {
"code": "token_mismatched",
"message": "The specified token is not matched with API."
},
"trace_id": "2efa9340-b21b-4e26-9e14-4aac95f343ab"
}{
"error": {
"code": "invalid_token",
"message": "The specified token is invalid or wrong."
},
"trace_id": "2efa9340-b21b-4e26-9e14-4aac95f343ab"
}{
"error": {
"code": "used_up",
"message": "Your balance is not sufficient for current request, please buy more in Ace Data Cloud."
},
"trace_id": "2efa9340-b21b-4e26-9e14-4aac95f343ab"
}{
"error": {
"code": "no_api",
"message": "API does not exist, please make sure url is correct."
},
"trace_id": "2efa9340-b21b-4e26-9e14-4aac95f343ab"
}{
"error": {
"code": "too_many_requests",
"message": "You have exceeded the rate limit."
},
"trace_id": "2efa9340-b21b-4e26-9e14-4aac95f343ab"
}{
"error": {
"code": "api_error",
"message": "Internal server error."
},
"trace_id": "2efa9340-b21b-4e26-9e14-4aac95f343ab"
}API Reference
Fish Tts
POST
/
fish
/
tts
Fish Tts
curl --request POST \
--url https://api.acedata.cloud/fish/tts \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"text": "Hello, this is a Fish-Audio-compatible test."
}
'import requests
url = "https://api.acedata.cloud/fish/tts"
payload = { "text": "Hello, this is a Fish-Audio-compatible test." }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({text: 'Hello, this is a Fish-Audio-compatible test.'})
};
fetch('https://api.acedata.cloud/fish/tts', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"audio_url": "https://platform.r2.fish.audio/task/8a72ff9840234006a9f74cb2fa04f978.mp3"
}{
"error": {
"code": "token_mismatched",
"message": "The specified token is not matched with API."
},
"trace_id": "2efa9340-b21b-4e26-9e14-4aac95f343ab"
}{
"error": {
"code": "invalid_token",
"message": "The specified token is invalid or wrong."
},
"trace_id": "2efa9340-b21b-4e26-9e14-4aac95f343ab"
}{
"error": {
"code": "used_up",
"message": "Your balance is not sufficient for current request, please buy more in Ace Data Cloud."
},
"trace_id": "2efa9340-b21b-4e26-9e14-4aac95f343ab"
}{
"error": {
"code": "no_api",
"message": "API does not exist, please make sure url is correct."
},
"trace_id": "2efa9340-b21b-4e26-9e14-4aac95f343ab"
}{
"error": {
"code": "too_many_requests",
"message": "You have exceeded the rate limit."
},
"trace_id": "2efa9340-b21b-4e26-9e14-4aac95f343ab"
}{
"error": {
"code": "api_error",
"message": "Internal server error."
},
"trace_id": "2efa9340-b21b-4e26-9e14-4aac95f343ab"
}授权
API token from https://platform.acedata.cloud
请求头
Fish Tts Param Accept
可用选项:
application/json Fish Tts Param Model
可用选项:
s1, s2-pro 请求体
application/json
Fish Tts Text
示例:
"Hello, this is a Fish-Audio-compatible test."
Fish Tts Reference Id
示例:
"d7900c21663f485ab63ebdb7e5905036"
Fish Tts Format
可用选项:
mp3, wav, pcm, opus Fish Tts Sample Rate
Fish Tts Mp3 Bitrate
可用选项:
64, 128, 192 Fish Tts Opus Bitrate
Fish Tts Latency
可用选项:
normal, balanced Fish Tts Chunk Length
Fish Tts Min Chunk Length
Fish Tts Temperature
Fish Tts Top P
Fish Tts Repetition Penalty
Fish Tts Max New Tokens
Fish Tts Normalize
Fish Tts Prosody
Fish Tts References
Fish Tts Callback Url
Fish Tts Async
响应
Fish Tts Response 200
Fish Tts Response 200 Audio Url

