ヘッドスワップ – 生成 API の使い方:character swap統合ガイド(2026)

2 min · 更新 2026-07-11 · NamiFusion チーム

NamiFusion で ヘッドスワップ – 生成 API を呼び出す方法:パラメータ、料金、そのまま実行できるコード例、Playground で試用可能。

ヘッドスワップ – 生成 は NamiFusion のcharacter swapモデルです:Replace selected heads in the video with your reference images using Wan2.2-Animate. Keeps the original audio track.NamiFusion では Playground で試してから(送信前に見積もり表示)、統一 REST API で呼び出せます(1 回あたり約 $0.750)。

TL;DR

· タスク種別:character swap(提供:NamiFusion)

· 料金:1 回あたり約 $0.750($1 = 100 クレジット)、従量課金

· 始め方:Playground で試用(送信前に見積もり)→ API キー作成 → POST 一発で統合

· 調整可能パラメータ:4 個(下表参照)

· プラットフォーム透かしなし。商用利用可(利用規約に従う)

ヘッドスワップ – 生成 で何が作れる?

コンテンツ制作の自動化:このモデルをワークフローに組み込み、統一 API で従量課金呼び出し。

この API はどう呼び出す?

1. NamiFusion に登録し、API Keys ページでキーを作成(登録特典クレジットは指定モデルのみ対象)。

2. 下記の cURL 例でタスクを送信。Bearer トークンにキーを指定。

3. 返された task_uuid でステータスをポーリングし、完了後に出力 URL を取得。

タスクを送信
# 1) Submit — returns { "task_uuid": "..." }
curl -X POST "https://www.namifusion.com/api/v1/marketplace/run/namifusion/head-swap/generate" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "input": {
    "track_manifest_url": "value",
    "mappings": [
      {
        "obj_id": 1,
        "img_urls": [
          "https://example.com/input.jpg"
        ]
      }
    ],
    "resolution": "720p"
  }
}'

# 2) Poll until status is "completed", then read the output URLs
curl "https://www.namifusion.com/api/v1/marketplace/run/tasks/TASK_UUID" \
  -H "Authorization: Bearer YOUR_API_KEY"

どんなパラメータがある?

track_manifest_url(Track manifest URL):必須

mappings(Head mappings):必須

resolution(Resolution):任意、デフォルト "720p"

seed(Seed):任意

料金はいくら?

従量課金(クレジット制)。1 回あたり約 $0.750($1 = 100 クレジット)。解像度や長さなどで変動し、Playground では送信前に正確な見積もりが表示されます。

ヘッドスワップ – 生成

Head Swap – Generate

Step 2 of the head swap pipeline. Replaces the selected heads in the video with your reference images using Wan2.2-Animate. Keeps the original audio track.

Input

FieldTypeRequiredNotes
video_urlstring (video URL)yesSame video as the analyze step; up to 30 seconds
track_manifest_urlstringyesReturned by namifusion/head-swap/analyze
mappingsarray of {obj_id, img_urls}yesobj_id from analyze output; 1-3 reference image URLs per head
resolution"480p" | "720p"noDefault 720p; must match the analyze step
seednumbernoRandom seed

Output

  • videos[0]: the finished video URL (original audio track preserved)

Typical flow

  1. Run namifusion/head-swap/analyze on your video
  2. Pick the obj_id(s) to replace from the analyze output
  3. POST /run/namifusion/head-swap/generate with track_manifest_url + mappings
  4. Poll GET /run/tasks/{task_uuid} until completed

Pricing: 720p: 75 credits per 5s unit; 480p: 40 credits per 5s unit; videos are capped at 30s.

FAQ

無料で試せますか?+

登録特典クレジットは指定モデルでのみ利用でき、対象範囲は随時更新されます。Playground では送信前に正確な見積もりを確認できます。

生成物は商用利用できますか?ウォーターマークは?+

商用利用できます。NamiFusion はプラットフォームのウォーターマークを付けません。利用規約と適用法に従ってください。

コンテンツポリシーは?+

NamiFusion は無検閲エンジンで恣意的な制限はなく NSFW にも対応しますが、違法コンテンツと本人の同意のない実在人物素材は禁止です。詳細は利用規約へ。

ヘッドスワップ – 生成 のタスクはどれくらいかかる?+

パラメータ次第で、画像は数秒〜数十秒、動画は数十秒〜数分。API は task_uuid を返すのでポーリングできます。

解像度・長さの上限は?+

上のパラメータ表を参照してください。各モデルの解像度・長さの選択肢はパラメータ説明と Playground に記載されています。