動画生成モデルを2つ目に増やすとき、「model の名前を変えれば動くだろう」と思うと、だいたい何か所かでつまずきます。
この記事では、BeatAPI の同じエンドポイント(POST /v1/videos/tasks)で Seedance 2 と MiniMax H3 を切り替えるときに、値が違う項目と、それを送信前に検出するチェック関数をまとめます。
仕様は 2026年10月28日時点の公開 API ドキュメントで確認しています。
共通しているところ
- エンドポイント:
POST /v1/videos/tasksで作成、GET /v1/tasks/{task_id}で確認 - 状態:
queued→processing→succeeded/failed - 出力:
data.output.media[]にtype・url・mime_type - 入力項目の名前:
prompt、duration(4〜15秒)、aspect_ratio、resolution、images、reference_imagesなど
つまり、作成・確認・保存のコードは1本で済みます。違うのは「各項目に入れてよい値」です。
値が違うところ
| 項目 | Seedance 2(seedance-2) |
MiniMax H3(minimax-h3) |
|---|---|---|
| 解像度 |
480p 720p 1080p 4K(既定 720p) |
768P 2K(既定 768P) |
| 比率の既定値 | adaptive |
テキストモードは 16:9、adaptive は不可 |
開始・終了フレーム images
|
reference_* と併用不可 |
同じく併用不可。フレームモードは常に adaptive
|
| 参照画像と高解像度 |
reference_images があると 1080p 不可 |
reference_videos は 768P・2K のみ |
| 音声 |
generate_audio(既定 true) |
指定する項目なし |
特に解像度は表記が違います。Seedance は小文字の 720p、H3 は大文字の 768P です。720p を H3 に送ると、そのまま弾かれます。
送信前チェック関数
モデルごとの許可値を1か所にまとめ、送る前に検証します。
type Spec = {
resolutions: string[];
textAspect: string[];
rejectWithReferenceImages?: string[];
};
const SPECS: Record<string, Spec> = {
"seedance-2": {
resolutions: ["480p", "720p", "1080p", "4K"],
textAspect: ["adaptive", "21:9", "16:9", "4:3", "1:1", "3:4", "9:16"],
rejectWithReferenceImages: ["1080p"],
},
"minimax-h3": {
resolutions: ["768P", "2K"],
textAspect: ["21:9", "16:9", "4:3", "1:1", "3:4", "9:16"],
},
};
export function validate(req: {
model: string;
resolution?: string;
aspect_ratio?: string;
images?: string[];
reference_images?: string[];
}): string | null {
const spec = SPECS[req.model];
if (!spec) return `unknown model: ${req.model}`;
if (req.resolution && !spec.resolutions.includes(req.resolution))
return `${req.model} は解像度 ${req.resolution} に対応していません`;
if (req.images?.length && req.reference_images?.length)
return "images(開始・終了フレーム)と reference_* は同時に使えません";
const textMode = !req.images?.length && !req.reference_images?.length;
if (textMode && req.aspect_ratio && !spec.textAspect.includes(req.aspect_ratio))
return `${req.model} のテキストモードは比率 ${req.aspect_ratio} を受け付けません`;
if (req.reference_images?.length && spec.rejectWithReferenceImages?.includes(req.resolution ?? ""))
return `${req.model} は reference_images と ${req.resolution} を併用できません`;
return null;
}
使い方はこうです。
const req = { model: "minimax-h3", prompt: "...", duration: 8, resolution: "720p" };
const err = validate(req);
if (err) throw new Error(err); // → minimax-h3 は解像度 720p に対応していません
自動で読み替えない理由
720p を 768P に自動で置き換える実装も考えられます。でも私はおすすめしません。
- 解像度が変わると料金が変わる(8秒で Seedance 2 の 720p は \$0.99、MiniMax H3 の 768P は \$0.24)
- 出力の大きさも変わり、後工程(編集・配信)の前提が崩れる
黙って置き換えるより、送る前にはっきりエラーにして、呼び出し側に選ばせる方が安全です。
比べるときは条件を固定する
2つのモデルを比べるなら、プロンプト・尺・比率は同じにして、解像度だけは各モデルの近い値(720p と 768P)にそろえます。品質や処理時間はモデルごとに違うので、自分の用途で1本ずつ測ってから使い分けを決めます。
出典・確認日
- BeatAPI 公開 API ドキュメント(
docs/openapiの Seedance2VideoRequest / MinimaxH3VideoRequest):2026年10月28日確認 - 料金:beatapi.io 料金ページ、2026年11月3日確認
