Subspace Institute

Fish Audio API

Generates speech audio from the provided text using Fish Audio Text-to-Speech service

POST
/tts-fishaudio
/tts-fishaudio

Request Body

application/jsonOptional

text
Required
string

Minimum length: 1Maximum length: 150

chunk_lengthinteger

Chunk length to be used for the speech

Default: 200Minimum: 100Maximum: 300

formatstring

Output audio format

Default: "opus"Value in: "wav" | "pcm" | "mp3" | "opus"

mp3_bitratenumber

MP3 Bitrate to be used for the speech

Default: 128

opus_bitratenumber

Opus Bitrate to be used for the speech

Default: 64

referencesarray<object>

References to be used for the speech, this requires MessagePack serialization, this will override reference_voices and reference_texts

voicestring

Reference ID of the reference model o be used for the speech

normalizeboolean

Whether to normalize the speech, this will reduce the latency but may reduce performance on numbers and dates

Default: true

latencystring

Latency to be used for the speech, balanced will reduce the latency but may lead to performance degradation

Default: "normal"Value in: "normal" | "balanced"

token
Required
string

Fish Audio API key for authentication

Minimum length: 1
curl -X POST "https://tts-relay.laplace.cn/api/laplace/tts-fishaudio" \
  -H "Content-Type: application/json" \
  -d '{
    "text": "感谢ドラゴンラプラスWeChat的SC:一发sc没被念到我就冷汗直流心跳加速头皮发麻双手痉挛两腿打颤,还不好意思刷弹幕说你漏了,我好怕你看到了装作没看到。我的sc通常很短只有一小时,只有短短的3600秒,但它存在的时候,我会用心跳来为它倒数。私のBANを解除してください。もう二度とスパムしません😭",
    "chunk_length": 200,
    "format": "wav",
    "mp3_bitrate": 128,
    "opus_bitrate": 64,
    "references": [
      {
        "audio": "string",
        "text": "string"
      }
    ],
    "voice": "string",
    "normalize": true,
    "latency": "normal",
    "token": "string"
  }'

Audio file containing the generated speech

null