curl --request POST \
--url https://api.apimart.ai/v1/videos/generations \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"model": "pixverse-v6-max",
"prompt": "A blue glass marble rolls across a clean white table in morning light",
"duration": 5,
"resolution": "720p",
"aspect_ratio": "16:9",
"audio": true
}'
import requests
response = requests.post(
"https://api.apimart.ai/v1/videos/generations",
headers={"Authorization": "Bearer <token>"},
json={
"model": "pixverse-v6-max",
"prompt": "A blue glass marble rolls across a clean white table in morning light",
"duration": 5,
"resolution": "720p",
"aspect_ratio": "16:9",
"audio": True
}
)
response.raise_for_status()
print(response.json())
const response = await fetch("https://api.apimart.ai/v1/videos/generations", {
method: "POST",
headers: {
Authorization: "Bearer <token>",
"Content-Type": "application/json"
},
body: JSON.stringify({
model: "pixverse-v6-max",
prompt: "A blue glass marble rolls across a clean white table in morning light",
duration: 5,
resolution: "720p",
aspect_ratio: "16:9",
audio: true
})
});
if (!response.ok) throw new Error(await response.text());
console.log(await response.json());
PixVerse V6 Max
PixVerse V6 Max 動画生成
テキストおよび単一画像からの動画生成に対応。360p / 540p / 720p / 1080p、1~15 秒で出力し、ネイティブ音声を追加できます。
POST
/
v1
/
videos
/
generations
curl --request POST \
--url https://api.apimart.ai/v1/videos/generations \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"model": "pixverse-v6-max",
"prompt": "A blue glass marble rolls across a clean white table in morning light",
"duration": 5,
"resolution": "720p",
"aspect_ratio": "16:9",
"audio": true
}'
import requests
response = requests.post(
"https://api.apimart.ai/v1/videos/generations",
headers={"Authorization": "Bearer <token>"},
json={
"model": "pixverse-v6-max",
"prompt": "A blue glass marble rolls across a clean white table in morning light",
"duration": 5,
"resolution": "720p",
"aspect_ratio": "16:9",
"audio": True
}
)
response.raise_for_status()
print(response.json())
const response = await fetch("https://api.apimart.ai/v1/videos/generations", {
method: "POST",
headers: {
Authorization: "Bearer <token>",
"Content-Type": "application/json"
},
body: JSON.stringify({
model: "pixverse-v6-max",
prompt: "A blue glass marble rolls across a clean white table in morning light",
duration: 5,
resolution: "720p",
aspect_ratio: "16:9",
audio: true
})
});
if (!response.ok) throw new Error(await response.text());
console.log(await response.json());
このエンドポイントは非同期で処理されます。送信後、返された
task_id を使い、GET /v1/videos/generations/{task_id} でタスクの状態と結果を取得してください。curl --request POST \
--url https://api.apimart.ai/v1/videos/generations \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"model": "pixverse-v6-max",
"prompt": "A blue glass marble rolls across a clean white table in morning light",
"duration": 5,
"resolution": "720p",
"aspect_ratio": "16:9",
"audio": true
}'
import requests
response = requests.post(
"https://api.apimart.ai/v1/videos/generations",
headers={"Authorization": "Bearer <token>"},
json={
"model": "pixverse-v6-max",
"prompt": "A blue glass marble rolls across a clean white table in morning light",
"duration": 5,
"resolution": "720p",
"aspect_ratio": "16:9",
"audio": True
}
)
response.raise_for_status()
print(response.json())
const response = await fetch("https://api.apimart.ai/v1/videos/generations", {
method: "POST",
headers: {
Authorization: "Bearer <token>",
"Content-Type": "application/json"
},
body: JSON.stringify({
model: "pixverse-v6-max",
prompt: "A blue glass marble rolls across a clean white table in morning light",
duration: 5,
resolution: "720p",
aspect_ratio: "16:9",
audio: true
})
});
if (!response.ok) throw new Error(await response.text());
console.log(await response.json());
モデルの機能
PixVerse V6 Max は PixVerse V6 の高画質版です。テキストおよび単一画像からの動画生成のみをサポートし、どちらもモデル名pixverse-v6-max を使用します。
| モード | 入力方法 | アスペクト比 |
|---|---|---|
| テキストから動画 | image_urls を省略。prompt は必須 | aspect_ratio を使用。デフォルトは 16:9 |
| 画像から動画 | image_urls に画像を 1 枚指定。prompt は任意 | 入力画像に従い、aspect_ratio は無効 |
リクエストヘッダー
string
必須
Bearer 認証:
Bearer <token>。<token> は APIMart API Key です。リクエストパラメータ
string
必須
pixverse-v6-max を指定してください。string
生成する内容の説明。テキストから動画では必須で最大 5000 文字、画像から動画では省略可能で最大 2048 文字です。
string[]
入力画像 URL のリスト。画像から動画では画像を 1 枚のみ指定できます。2 枚以上を渡すと同期的に HTTP 400 が返されます。テキストから動画ではこのフィールドを省略してください。画像は HTTP(S) で外部からアクセス可能である必要があります。JPEG、PNG、WebP に対応し、ファイルは 20 MB 未満、各辺は 10000 ピクセル以下です。
integer
デフォルト:"5"
出力の長さ(秒)。
1~15 に対応し、デフォルトは 5 です。string
デフォルト:"540p"
出力解像度は
360p、540p、720p、1080p に対応し、デフォルトは 540p です。出力には上流モデルのネイティブサイズが使用され、実際に返されたサイズを基準とします。実測された代表例は 640×360、1108×832(幅 × 高さ、単位はピクセル)です。quality フィールドも使用できます。両方を指定した場合は resolution が優先されます。string
解像度の互換フィールドで、指定可能な値は
resolution と同じです。resolution がない場合のみ使用し、両方とも省略すると 540p になります。string
デフォルト:"16:9"
テキストから動画でのみ有効です。
16:9、9:16、4:3、3:4、1:1、2:3、3:2、21:9 に対応し、デフォルトは 16:9 です。画像から動画では常に入力画像のアスペクト比に従うため、このフィールドは無効です。boolean
デフォルト:"false"
true でネイティブ音声を生成します。デフォルトは無音です。音声付き生成は秒単価が高くなります。リクエスト本文のトップレベルにある audio のみを認識します。metadata.generate_audio_switch では音声は有効にならず、音声付き料金も適用されません。integer
ランダムシード。範囲は
0~2147483647 です。画像から動画の例
{
"model": "pixverse-v6-max",
"prompt": "Make the subject walk forward slowly",
"image_urls": ["https://example.com/start.png"],
"duration": 5,
"resolution": "1080p"
}
タスクの照会
以下のリクエストのタスク ID を、送信時に返されたtask_id に置き換えてください。
curl --request GET \
--url 'https://api.apimart.ai/v1/videos/generations/<task_id>' \
--header 'Authorization: Bearer <token>'
料金
料金は、出力秒数に解像度と音声設定に応じた秒単価を掛けて計算します。音声付きと無音では単価が異なり、音声付きの方が高くなります。resolution と quality のどちらも指定しない場合、出力・課金ともに 540p を使用します。
現在の単価はモデル料金照会エンドポイントで確認できます。
| 音声設定 | 価格フィールド |
|---|---|
| 無音 | resolution_paid_prices 内の該当する解像度の価格 |
| 音声付き | billing_tier_paid_prices 内の該当する <resolution>-audio 区分 |
非対応の機能とパラメータエラー
以下のリクエストは同期的に HTTP 400 を返し、タスクは作成されず、課金もされません。| リクエスト | エラーメッセージ |
|---|---|
extend_from_task_id を指定 | pixverse-v6-max does not support video extend …; use pixverse-v6 instead |
img_references を指定 | pixverse-v6-max does not support multi-image reference … |
first_frame_image または last_frame_image を指定 | pixverse-v6-max does not support first/last frame transition … |
image_urls に 2 枚以上を指定 | pixverse-v6-max image-to-video takes exactly 1 image in image_urls (got N) |
resolution が上記 4 種類以外 | invalid resolution … |
duration が 15 秒を超える | invalid duration … |
テキストから動画の aspect_ratio が上記 8 種類以外 | invalid aspect_ratio … |