使用原生登录 access_token 与 multipart/form-data(model、file)调用标准音频转写,返回原生 JSON、文本或字幕。支持稳定 Idempotency-Key 恢复。
POST
/pg/audio/transcriptionsAuthorizations
AuthorizationstringrequiredUse a native login access_token (required access: Native access token) with owner isolation and trusted browser Origin; generation writes use wallet billing while reads do not precharge; inference API Keys (sk-…) and PATs (nap_…) are rejected.
Authorization: Bearer $ONEASTER_ACCESS_TOKEN
Parameters
Idempotency-Keystringheader · 每次新发起的 /pg 生成提交建议由前端生成并持久化稳定的 1–100 位无空格可打印 ASCII 标识(推荐 UUID),断线重试保持原标识与原请求字节。同账号跨所有 /pg POST 协议共用一个命名空间;省略时后端兼容生成并通过 X-OneAster-Intent-ID 返回,但若响应头丢失将无法按意图恢复。
Body · multipart/form-data
modelstringrequiredfilestringrequiredresponse_formatstringlanguagestringpromptstringtemperaturenumberJSON Schema
{
"type": "object",
"required": [
"model",
"file"
],
"properties": {
"model": {
"type": "string"
},
"file": {
"type": "string",
"format": "binary"
},
"response_format": {
"type": "string"
},
"language": {
"type": "string"
},
"prompt": {
"type": "string"
},
"temperature": {
"type": "number"
}
},
"additionalProperties": true
}