API 參考
取得短時檔案下載地址
GET
/v1/files/{file_id}/download-url同賬戶同 Key 歷史檔案;允許耗盡但有效的 Key,撤銷/過期仍拒絕。下載需 ready,引用中刪除 409;retry 只重試儲存原結果,非重新生成。普通 API 按保留天數,持久任務保護引用,expires_at=0 不定時過期。
播放與下載
先讀取檔案狀態,再請求短時下載地址;儲存未 ready 時,獲取地址不能讓檔案提前可用。原 Key 只發到 GloopAPI,向返回的 HTTPS 地址下載時不要附帶它。
持久影片使用短時物件儲存 URL 支援原生 Range 播放;普通影片 content 路徑的完整 GET 與這一播放器傳輸不同。連結過期後重新獲取地址,檔案過期或被刪除則不能靠重新整理連結恢復。
鑑權與許可權
使用當前 GloopAPI Key。模型、功能與許可權以當前 Key 的目錄及介面說明為準。
Authorization: Bearer $GLOOP_API_KEY鑑權方案: BearerAuth
請求
路徑引數
file_idstring必填同 Key 的託管檔案公開 ID。
響應與錯誤
HTTP 200
取得短時檔案下載地址成功
application/json
- 型別
- object
- 必填欄位
urlexpires_at
urlstring必填短時簽名下載地址,請勿洩露或長期儲存。
- 格式
"uri"
expires_atinteger必填Unix 秒。
HTTP 400
請求欄位或引數無效。
application/json
- 型別
- object
- 必填欄位
error
errorobject必填error 子欄位(4)
codestring選填messagestring選填typestring選填request_idstring選填
HTTP 401
Key 缺失、無效、過期或已撤銷。
application/json
- 型別
- object
- 必填欄位
error
errorobject必填error 子欄位(4)
codestring選填messagestring選填typestring選填request_idstring選填
HTTP 403
IP、賬戶、模型或工具許可權不足。
application/json
- 型別
- object
- 必填欄位
error
errorobject必填error 子欄位(4)
codestring選填messagestring選填typestring選填request_idstring選填
HTTP 404
物件/能力不可用,或功能開關關閉。
application/json
- 型別
- object
- 必填欄位
error
errorobject必填error 子欄位(4)
codestring選填messagestring選填typestring選填request_idstring選填
HTTP 409
冪等/報價衝突、物件未準備或仍被引用。
application/json
- 型別
- object
- 必填欄位
error
errorobject必填error 子欄位(4)
codestring選填messagestring選填typestring選填request_idstring選填
HTTP 429
請求/佇列限流。
application/json
- 型別
- object
- 必填欄位
error
errorobject必填error 子欄位(4)
codestring選填messagestring選填typestring選填request_idstring選填
HTTP 500
鑑權或資料儲存內部失敗。
application/json
- 型別
- object
- 必填欄位
error
errorobject必填error 子欄位(4)
codestring選填messagestring選填typestring選填request_idstring選填
HTTP 503
服務、定價或儲存不可用。
application/json
- 型別
- object
- 必填欄位
error
errorobject必填error 子欄位(4)
codestring選填messagestring選填typestring選填request_idstring選填