API 參考

Create durable speech

POST/v1/audio-runs

Versioned public durable speech extension using an ordinary API Key. Input follows the non-streaming OpenAI speech subset. A signed speech cost quote binds identity, exact original input and immutable character pricing. Full maximum is reserved before dispatch. One user/Key/request_id owns one dispatch; retries return the original record and changed input conflicts. Query the original request after uncertainty; never replay a generation to recover. Inline audio is exposed only after authoritative settlement, retained for seven days in the durable record and never automatically downloaded or copied to object storage. Deleted or expired content stays succeeded with result_deleted=true; billing and identity remain.

鑑權與許可權

使用當前 GloopAPI Key。模型、功能與許可權以當前 Key 的目錄及介面說明為準。

Authorization: Bearer $GLOOP_API_KEY

鑑權方案: BearerAuth

請求

請求體 · application/json

型別
object
額外屬性
false
必填欄位
request_idmodelquote_idinput

請求體必填

  • request_idstring必填
    最長長度
    128
    匹配規則
    "^[A-Za-z0-9_-]+$"
  • modelstring必填
  • quote_idstring必填

    The signed quote_token from a speech cost quote, not its display ID.

  • inputobject必填
    額外屬性
    false
    input 子欄位(5)
    • modelstring必填
    • inputstring必填

      Original text, including whitespace. No instructions are added.

      最長長度
      4096
    • voicestring必填

      An explicitly configured voice from model audio metadata.

    • response_formatstring必填
      列舉
      ["mp3","opus","aac","flac","wav","pcm"]
    • speednumber選填
      最小值
      0.25
      最大值
      4

響應與錯誤

HTTP 200

Authoritative current execution or quote. Unknown retains its hold.

application/json

型別
object
必填欄位
idrequest_idmodelstateversioncreated_atexpires_atresult_deleted

HTTP 202

Authoritative current execution or quote. Unknown retains its hold.

application/json

型別
object
必填欄位
idrequest_idmodelstateversioncreated_atexpires_atresult_deleted

HTTP 400

輸入無效。

application/json

型別
object
必填欄位
error

HTTP 401

Key 缺失、無效、過期或已撤銷。

application/json

型別
object
必填欄位
error

HTTP 403

IP、賬戶、模型或工具許可權不足。

application/json

型別
object
必填欄位
error

HTTP 404

未找到本人執行;不能據此判斷未知生成沒有計費。

application/json

型別
object
必填欄位
error

HTTP 409

請求 ID 內容衝突,或在途執行不能刪除。

application/json

型別
object
必填欄位
error

HTTP 429

請求/佇列限流。

application/json

型別
object
必填欄位
error

HTTP 500

鑑權或資料儲存內部失敗。

application/json

型別
object
必填欄位
error

HTTP 503

暫不可用;已提交結果不確定時查詢原請求。

application/json

型別
object
必填欄位
error