PixAI Platform
API v2 ドキュメントメディア

動画・音声ファイルの情報の取得

動画または音声のメディアアイテムの長さ、サイズ、コンテナ、コーデックを返します。参照動画タスクを作成する前に、参照ファイルがモデルの制限を満たしているか確認できます。

GET
/media/{mediaId}/info

Authorization

bearerAuth
AuthorizationBearer <token>

認証が必要なすべてのリクエストでは、HTTP ヘッダーに次を追加してください

In: header

Path Parameters

mediaId*string

動画または音声のメディア ID です。

Response Body

application/json

application/json

application/json

application/json

curl -X GET "https://api.pixai.art/v2/media/string/info"
{
  "mediaId": "string",
  "durationSeconds": 0,
  "sizeBytes": "string",
  "containers": [
    "string"
  ],
  "videoStreams": [
    {
      "codec": "string",
      "width": 0,
      "height": 0,
      "averageFrameRate": 0
    }
  ],
  "audioStreams": [
    {
      "codec": "string"
    }
  ]
}
{
  "code": "string",
  "status": 0,
  "message": "string",
  "data": {},
  "defined": true
}
{
  "code": "string",
  "status": 0,
  "message": "string",
  "data": {},
  "defined": true
}
{
  "code": "string",
  "status": 0,
  "message": "string",
  "data": {},
  "defined": true
}