MiniMax 语音合成(原生同步)
API Configuration
After saving, the Try It panel below sends real requests with this key.
Base: api.xrtoken.ai
使用 MiniMax T2A 原生同步 HTTP 请求格式。传入 XRToken 密钥,model 可使用 minimax/speech-2.8-hd 或 minimax/speech-2.8-turbo,可用性以模型列表为准。
支持 voice_setting、audio_setting 等原生参数;output_format 可选 hex 或 url。仅支持 stream: false,流式接口尚未接入。单次文本少于 10,000 字符。
仅支持官方系统音色,暂不支持复刻或设计的自定义音色。
Authorization
BearerAuth AuthorizationBearer <token>
API 密钥认证(OpenAI 格式)。在 Authorization 请求头中传入:
Authorization: Bearer tr-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
curl -X post "https://api.xrtoken.net/v1/t2a_v2" \ -H "Content-Type: application/json" \ -d '{ "model": "minimax/speech-2.8-hd", "text": "Hello from XRToken.", "voice_setting": {} }'{}{
"error": "model field is required",
"type": "invalid_request_error"
}{
"error": "invalid or missing API key",
"type": "auth_error"
}{
"error": "insufficient balance -- please top up or upgrade your plan",
"type": "billing_error"
}{
"error": "upstream provider error",
"type": "server_error"
}