PopNowAPI ドキュメント
本文

MiniMax H3 Character Swap API リファレンス

動画内の人物をキャラクター画像に差し替え、演技はそのまま

PopNow の API キー 1 つで、MiniMax H3 Character Swap を自分のコードから呼び出せます。送るモデル ID、受け付ける入力フィールド、1 回あたりの料金(USD)、ターミナルに貼ってそのまま動くリクエストをこのページにまとめました。

パラメーターの説明はモデルの入力 schema から取っているため、英語のみです。

概要

開発元
MiniMax
出力
動画
最安
$0.06 USD 出力 1 秒あたり
目安の所要時間
約 116 秒

料金は USD で表示され、PopNow の残高から差し引かれます。受付時に最大料金を確保し、完了後に実際の使用量で精算して差額を返却します。失敗したタスクは課金されません。実行前の正確な見積もりは POST /api/v1/jobs/quote で取得できます。

動画の顔交換

minimax/h3-character-swap/video-edit

料金

オプションUSD
480p$0.06 出力 1 秒あたり
540p$0.09 出力 1 秒あたり
768p$0.12 出力 1 秒あたり
1080p$0.24 出力 1 秒あたり

パラメーター

フィールド型既定値指定できる値説明
video_url必須string (uri)——Source clip whose performance is kept. Up to 15 seconds are used; one continuous shot works best.
image_url必須string (uri)——One image of the new character: a photo, a 3D render or a drawing. Full body works best.
prompt任意string—7,000 文字までFull character-swap instruction passed through verbatim to the model (use <Video 1> for the source clip and <Picture 1> for the character image). Leave empty to use the default main-person replacement template.
aspect_ratio任意string16:916:9, 9:16, 1:1, 4:3, 3:4, 21:9, 9:21Output aspect ratio; match your source clip.
resolution任意string480p480p, 540p, 768p, 1080pOutput resolution.
duration_seconds任意integer53〜15Output length in whole seconds, from 3 to 15; match your source clip.
seed任意integer—0〜2147483647Random seed for controlled comparisons, not a frame-identical guarantee.

リクエスト例

このリクエストはそのまま実行できます。省略したフィールドには既定値が入ります。先にキーを環境変数 POPNOW_API_KEY に設定してください。

例の image_url, video_url には PopNow のサンプル素材を使っています。自分の公開 HTTPS リンク、アップロードしたファイル、保存済みアセットに置き換えてください。

POST /api/v1/jobs/createTask
curl -X POST "https://api.popnow.ai/api/v1/jobs/createTask" \
  -H "Authorization: Bearer $POPNOW_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{
  "model": "minimax/h3-character-swap/video-edit",
  "input": {
    "prompt": "Replace the main person in <Video 1> with the character in <Picture 1>. Keep the reference character'\''s face, hair and clothing. Follow the source performance'\''s pose, gaze, expression and movement. Preserve the scene and the other people.",
    "video_url": "https://media.popnow.ai/effects/flower-bloom-1abd6efb.mp4",
    "image_url": "https://media.popnow.ai/influencer/examples/marco.webp",
    "duration_seconds": 5,
    "resolution": "480p"
  }
}'

レスポンスにはすぐに taskId が入ります。結果は GET /api/v1/jobs/recordInfo で取得するか、callBackUrl を付けて通知を受け取ります。

GET /api/v1/jobs/recordInfo
curl "https://api.popnow.ai/api/v1/jobs/recordInfo?taskId=TASK_ID_FROM_CREATE_TASK" \
  -H "Authorization: Bearer $POPNOW_API_KEY"

次に読む

このページの内容