From 24c57f143e75a97b9207cff1545be15f0530ace5 Mon Sep 17 00:00:00 2001 From: lin-bot23 Date: Fri, 18 Sep 2026 19:16:22 +0800 Subject: [PATCH 1/2] chore: remove translations whose English source was deleted Eleven pages lost their English source upstream, so their ja/zh/ko translations became dead pages that the sidebar still linked: - comfy-router model pages retired in #1687: kling-v1, kling-v1-5, kling-v1-6, kling-v2-1, kling-v2-1-master, kling-v2-master, byteplus seedance-1-0-lite-i2v and -t2v-250428, seededit-3-0-i2i-250628, seedream-3-0-t2i-250415 - development/api-development/overview, dropped in the #1534 API docs reorg The redirects for these paths already exist, so inbound links keep working. The only edit outside the deletions is removing the 33 matching navigation entries (11 paths x 3 locales) from docs.json; no other navigation entry, redirect or page is touched. --- docs.json | 33 -- ja/development/api-development/overview.mdx | 72 --- .../seedance-1-0-lite-i2v-250428/code.mdx | 436 ---------------- .../seedance-1-0-lite-t2v-250428/code.mdx | 435 ---------------- .../byteplus/seededit-3-0-i2i-250628/code.mdx | 391 --------------- .../byteplus/seedream-3-0-t2i-250415/code.mdx | 390 --------------- .../models/kling/kling-v1-5/code.mdx | 466 ----------------- .../models/kling/kling-v1-6/code.mdx | 420 ---------------- .../models/kling/kling-v1/code.mdx | 421 ---------------- .../models/kling/kling-v2-1-master/code.mdx | 421 ---------------- .../models/kling/kling-v2-1/code.mdx | 467 ----------------- .../models/kling/kling-v2-master/code.mdx | 421 ---------------- ko/development/api-development/overview.mdx | 70 --- .../seedance-1-0-lite-i2v-250428/code.mdx | 435 ---------------- .../seedance-1-0-lite-t2v-250428/code.mdx | 435 ---------------- .../byteplus/seededit-3-0-i2i-250628/code.mdx | 391 --------------- .../byteplus/seedream-3-0-t2i-250415/code.mdx | 391 --------------- .../models/kling/kling-v1-5/code.mdx | 467 ----------------- .../models/kling/kling-v1-6/code.mdx | 422 ---------------- .../models/kling/kling-v1/code.mdx | 421 ---------------- .../models/kling/kling-v2-1-master/code.mdx | 421 ---------------- .../models/kling/kling-v2-1/code.mdx | 467 ----------------- .../models/kling/kling-v2-master/code.mdx | 420 ---------------- zh/development/api-development/overview.mdx | 70 --- .../seedance-1-0-lite-i2v-250428/code.mdx | 434 ---------------- .../seedance-1-0-lite-t2v-250428/code.mdx | 435 ---------------- .../byteplus/seededit-3-0-i2i-250628/code.mdx | 391 --------------- .../byteplus/seedream-3-0-t2i-250415/code.mdx | 388 --------------- .../models/kling/kling-v1-5/code.mdx | 468 ------------------ .../models/kling/kling-v1-6/code.mdx | 421 ---------------- .../models/kling/kling-v1/code.mdx | 421 ---------------- .../models/kling/kling-v2-1-master/code.mdx | 422 ---------------- .../models/kling/kling-v2-1/code.mdx | 468 ------------------ .../models/kling/kling-v2-master/code.mdx | 421 ---------------- 34 files changed, 13052 deletions(-) delete mode 100644 ja/development/api-development/overview.mdx delete mode 100644 ja/development/comfy-router/models/byteplus/seedance-1-0-lite-i2v-250428/code.mdx delete mode 100644 ja/development/comfy-router/models/byteplus/seedance-1-0-lite-t2v-250428/code.mdx delete mode 100644 ja/development/comfy-router/models/byteplus/seededit-3-0-i2i-250628/code.mdx delete mode 100644 ja/development/comfy-router/models/byteplus/seedream-3-0-t2i-250415/code.mdx delete mode 100644 ja/development/comfy-router/models/kling/kling-v1-5/code.mdx delete mode 100644 ja/development/comfy-router/models/kling/kling-v1-6/code.mdx delete mode 100644 ja/development/comfy-router/models/kling/kling-v1/code.mdx delete mode 100644 ja/development/comfy-router/models/kling/kling-v2-1-master/code.mdx delete mode 100644 ja/development/comfy-router/models/kling/kling-v2-1/code.mdx delete mode 100644 ja/development/comfy-router/models/kling/kling-v2-master/code.mdx delete mode 100644 ko/development/api-development/overview.mdx delete mode 100644 ko/development/comfy-router/models/byteplus/seedance-1-0-lite-i2v-250428/code.mdx delete mode 100644 ko/development/comfy-router/models/byteplus/seedance-1-0-lite-t2v-250428/code.mdx delete mode 100644 ko/development/comfy-router/models/byteplus/seededit-3-0-i2i-250628/code.mdx delete mode 100644 ko/development/comfy-router/models/byteplus/seedream-3-0-t2i-250415/code.mdx delete mode 100644 ko/development/comfy-router/models/kling/kling-v1-5/code.mdx delete mode 100644 ko/development/comfy-router/models/kling/kling-v1-6/code.mdx delete mode 100644 ko/development/comfy-router/models/kling/kling-v1/code.mdx delete mode 100644 ko/development/comfy-router/models/kling/kling-v2-1-master/code.mdx delete mode 100644 ko/development/comfy-router/models/kling/kling-v2-1/code.mdx delete mode 100644 ko/development/comfy-router/models/kling/kling-v2-master/code.mdx delete mode 100644 zh/development/api-development/overview.mdx delete mode 100644 zh/development/comfy-router/models/byteplus/seedance-1-0-lite-i2v-250428/code.mdx delete mode 100644 zh/development/comfy-router/models/byteplus/seedance-1-0-lite-t2v-250428/code.mdx delete mode 100644 zh/development/comfy-router/models/byteplus/seededit-3-0-i2i-250628/code.mdx delete mode 100644 zh/development/comfy-router/models/byteplus/seedream-3-0-t2i-250415/code.mdx delete mode 100644 zh/development/comfy-router/models/kling/kling-v1-5/code.mdx delete mode 100644 zh/development/comfy-router/models/kling/kling-v1-6/code.mdx delete mode 100644 zh/development/comfy-router/models/kling/kling-v1/code.mdx delete mode 100644 zh/development/comfy-router/models/kling/kling-v2-1-master/code.mdx delete mode 100644 zh/development/comfy-router/models/kling/kling-v2-1/code.mdx delete mode 100644 zh/development/comfy-router/models/kling/kling-v2-master/code.mdx diff --git a/docs.json b/docs.json index a00c3a23b7..78c16cb192 100644 --- a/docs.json +++ b/docs.json @@ -6812,7 +6812,6 @@ "zh/development/api-development/sdks", "zh/development/serverless/overview", "zh/development/api-development/getting-an-api-key", - "zh/development/api-development/overview", "zh/api-reference/v2/overview", { "group": "Comfy API v2 参考文档", @@ -6906,13 +6905,9 @@ "zh/development/comfy-router/models/byteplus/seed-2-0-pro-260328/code", "zh/development/comfy-router/models/byteplus/seed-audio-1-0-multilingual/code", "zh/development/comfy-router/models/byteplus/seed-audio-1-0/code", - "zh/development/comfy-router/models/byteplus/seedance-1-0-lite-i2v-250428/code", - "zh/development/comfy-router/models/byteplus/seedance-1-0-lite-t2v-250428/code", "zh/development/comfy-router/models/byteplus/seedance-1-0-pro-250528/code", "zh/development/comfy-router/models/byteplus/seedance-1-0-pro-fast-251015/code", "zh/development/comfy-router/models/byteplus/seedance-1-5-pro-251215/code", - "zh/development/comfy-router/models/byteplus/seededit-3-0-i2i-250628/code", - "zh/development/comfy-router/models/byteplus/seedream-3-0-t2i-250415/code", "zh/development/comfy-router/models/byteplus/seedream-4-0-250828/code", "zh/development/comfy-router/models/byteplus/seedream-4-5-251128/code", "zh/development/comfy-router/models/byteplus/seedream-5-0-260128/code", @@ -6985,14 +6980,8 @@ "pages": [ "zh/development/comfy-router/models/kling/kling-3-0-turbo/code", "zh/development/comfy-router/models/kling/kling-image-o1/code", - "zh/development/comfy-router/models/kling/kling-v1-5/code", - "zh/development/comfy-router/models/kling/kling-v1-6/code", - "zh/development/comfy-router/models/kling/kling-v1/code", - "zh/development/comfy-router/models/kling/kling-v2-1-master/code", - "zh/development/comfy-router/models/kling/kling-v2-1/code", "zh/development/comfy-router/models/kling/kling-v2-5-turbo/code", "zh/development/comfy-router/models/kling/kling-v2-6/code", - "zh/development/comfy-router/models/kling/kling-v2-master/code", "zh/development/comfy-router/models/kling/kling-v3-omni/code", "zh/development/comfy-router/models/kling/kling-v3/code", "zh/development/comfy-router/models/kling/kling-video-o1/code", @@ -10556,7 +10545,6 @@ "ja/development/api-development/sdks", "ja/development/serverless/overview", "ja/development/api-development/getting-an-api-key", - "ja/development/api-development/overview", "ja/api-reference/v2/overview", { "group": "Comfy API v2リファレンス", @@ -10650,13 +10638,9 @@ "ja/development/comfy-router/models/byteplus/seed-2-0-pro-260328/code", "ja/development/comfy-router/models/byteplus/seed-audio-1-0-multilingual/code", "ja/development/comfy-router/models/byteplus/seed-audio-1-0/code", - "ja/development/comfy-router/models/byteplus/seedance-1-0-lite-i2v-250428/code", - "ja/development/comfy-router/models/byteplus/seedance-1-0-lite-t2v-250428/code", "ja/development/comfy-router/models/byteplus/seedance-1-0-pro-250528/code", "ja/development/comfy-router/models/byteplus/seedance-1-0-pro-fast-251015/code", "ja/development/comfy-router/models/byteplus/seedance-1-5-pro-251215/code", - "ja/development/comfy-router/models/byteplus/seededit-3-0-i2i-250628/code", - "ja/development/comfy-router/models/byteplus/seedream-3-0-t2i-250415/code", "ja/development/comfy-router/models/byteplus/seedream-4-0-250828/code", "ja/development/comfy-router/models/byteplus/seedream-4-5-251128/code", "ja/development/comfy-router/models/byteplus/seedream-5-0-260128/code", @@ -10729,14 +10713,8 @@ "pages": [ "ja/development/comfy-router/models/kling/kling-3-0-turbo/code", "ja/development/comfy-router/models/kling/kling-image-o1/code", - "ja/development/comfy-router/models/kling/kling-v1-5/code", - "ja/development/comfy-router/models/kling/kling-v1-6/code", - "ja/development/comfy-router/models/kling/kling-v1/code", - "ja/development/comfy-router/models/kling/kling-v2-1-master/code", - "ja/development/comfy-router/models/kling/kling-v2-1/code", "ja/development/comfy-router/models/kling/kling-v2-5-turbo/code", "ja/development/comfy-router/models/kling/kling-v2-6/code", - "ja/development/comfy-router/models/kling/kling-v2-master/code", "ja/development/comfy-router/models/kling/kling-v3-omni/code", "ja/development/comfy-router/models/kling/kling-v3/code", "ja/development/comfy-router/models/kling/kling-video-o1/code", @@ -14213,7 +14191,6 @@ "ko/development/api-development/sdks", "ko/development/serverless/overview", "ko/development/api-development/getting-an-api-key", - "ko/development/api-development/overview", "ko/api-reference/v2/overview", { "group": "Comfy API v2 참조", @@ -14307,13 +14284,9 @@ "ko/development/comfy-router/models/byteplus/seed-2-0-pro-260328/code", "ko/development/comfy-router/models/byteplus/seed-audio-1-0-multilingual/code", "ko/development/comfy-router/models/byteplus/seed-audio-1-0/code", - "ko/development/comfy-router/models/byteplus/seedance-1-0-lite-i2v-250428/code", - "ko/development/comfy-router/models/byteplus/seedance-1-0-lite-t2v-250428/code", "ko/development/comfy-router/models/byteplus/seedance-1-0-pro-250528/code", "ko/development/comfy-router/models/byteplus/seedance-1-0-pro-fast-251015/code", "ko/development/comfy-router/models/byteplus/seedance-1-5-pro-251215/code", - "ko/development/comfy-router/models/byteplus/seededit-3-0-i2i-250628/code", - "ko/development/comfy-router/models/byteplus/seedream-3-0-t2i-250415/code", "ko/development/comfy-router/models/byteplus/seedream-4-0-250828/code", "ko/development/comfy-router/models/byteplus/seedream-4-5-251128/code", "ko/development/comfy-router/models/byteplus/seedream-5-0-260128/code", @@ -14386,14 +14359,8 @@ "pages": [ "ko/development/comfy-router/models/kling/kling-3-0-turbo/code", "ko/development/comfy-router/models/kling/kling-image-o1/code", - "ko/development/comfy-router/models/kling/kling-v1-5/code", - "ko/development/comfy-router/models/kling/kling-v1-6/code", - "ko/development/comfy-router/models/kling/kling-v1/code", - "ko/development/comfy-router/models/kling/kling-v2-1-master/code", - "ko/development/comfy-router/models/kling/kling-v2-1/code", "ko/development/comfy-router/models/kling/kling-v2-5-turbo/code", "ko/development/comfy-router/models/kling/kling-v2-6/code", - "ko/development/comfy-router/models/kling/kling-v2-master/code", "ko/development/comfy-router/models/kling/kling-v3-omni/code", "ko/development/comfy-router/models/kling/kling-v3/code", "ko/development/comfy-router/models/kling/kling-video-o1/code", diff --git a/ja/development/api-development/overview.mdx b/ja/development/api-development/overview.mdx deleted file mode 100644 index 8bfff0e311..0000000000 --- a/ja/development/api-development/overview.mdx +++ /dev/null @@ -1,72 +0,0 @@ ---- -title: "API 概要" -description: "ComfyUI をプログラムから操作するための様々な方法の概要" -icon: "list" -translationSourceHash: 852ff6ab -translationFrom: development/api-development/overview.mdx -translationBlockHashes: - "_intro": 838d6d8e - "Start Here": cf5c79f3 - "Which API Should I Use?": 40998626 - "Getting Started": 41b19127 - "Prerequisites": 4ba1cc15 ---- -ComfyUIでは、ワークフローを実行する場所と管理するインフラストラクチャの量に応じて、複数のAPIオプションが用意されています。このページは、最適なアプローチを選択するのに役立ちます。 - ---- - -## はじめに - -新しい統合には、**Comfy SDKs** と、それらが呼び出す Comfy API v2 を使用してください。v2 は新しいバージョン管理された HTTP インターフェースであり、既存の Cloud API および ComfyUI Server API と共存します。[Comfy API v2 の概要](/ja/api-reference/v2/overview) を参照してください。同じコードが Comfy Cloud と自分のマシンの両方に対して動作します。 - - - 独自アプリケーションからワークフローを実行するための公式の Python および TypeScript SDK。現在ベータ版です。 - - -以下の他の API も引き続き完全にサポートされており、SDK がまだ対応していない領域をカバーしています。ここにあるものはどれも非推奨ではありません。 - ---- - -## どのAPIを使うべきか? - -| | Comfy API v2 + SDKs | Cloud API | ComfyUI Server API | -|---|---|---|---| -| **実行場所** | Comfy Cloud、またはローカルプロキシ経由の自分のマシン | Comfy Cloud(管理されたGPU) | 自分のマシン | -| **互換性** | バージョン管理されており、v2内での追加変更のみ | 実験的、予告なく変更される場合があります | リリース間での保証はありません | -| **GPU管理** | 接続先によって異なります | 代わりに管理されます | 自分のハードウェアを管理します | -| **モデル** | 接続先によって異なります | Comfyによってインストール済みであり、管理されています | ローカルでダウンロードして管理します | -| **認証** | クラウドでは`Authorization: Bearer`。セルフホストはデフォルトでなし、オプションで静的ベアラートークン | `X-API-Key`ヘッダー(Comfy Cloudアカウント) | なし(ローカル)またはパートナーノード用のAPIキー | -| **ベースURL** | `https://cloud.comfy.org` または `http://127.0.0.1:8189` | `https://cloud.comfy.org` | 自分のサーバーURL(例:`http://localhost:8188`) | -| **公式クライアント** | PythonおよびTypeScript SDK | なし、HTTPで直接呼び出し | なし、HTTPで直接呼び出し | -| **プロトコル** | REST + SSE | REST + WebSocket | REST + WebSocket | -| **スコープ** | ワークフローを実行して結果を取得 | モデルとアカウントを含むクラウドの全機能 | キューとノード情報を含むローカルの全機能 | -| **最適な用途** | 継続的に動作する必要がある新規インテグレーション | SDKがまだカバーしていないクラウド機能 | フルコントロール、カスタムハードウェア&モデル | - -これらのAPIはすべて同じワークフロー形式([API形式](/ja/development/api-development/workflow-api-format))を使用しているため、ワークフローをローカルで開発・テストし、変更なしでクラウドに移行できます。 - ---- - -## 開始方法 - - - - PythonまたはTypeScriptから、クラウドまたは自分のマシンに対してワークフローを実行します。 - - - Comfyのマネージドインフラストラクチャ上でワークフローを実行します。GPUのセットアップは必須ではありません。 - - - ComfyUIを自分のマシンでサーバーとして実行し、API経由で呼び出します。 - - - ヘッドレスまたはAPI駆動のワークフローで有料のパートナーノードを使用します。 - - - ---- - -## 前提条件 - -APIを使用する前に、以下のものが必要です: - -- Comfy Cloudまたはパートナーノードに関わるすべてのものにはAPIキーが必要です([APIキーの取得](/ja/development/api-development/getting-an-api-key) を参照)。完全にローカルなComfyUIには必要ありません。 diff --git a/ja/development/comfy-router/models/byteplus/seedance-1-0-lite-i2v-250428/code.mdx b/ja/development/comfy-router/models/byteplus/seedance-1-0-lite-i2v-250428/code.mdx deleted file mode 100644 index 4565a85c4a..0000000000 --- a/ja/development/comfy-router/models/byteplus/seedance-1-0-lite-i2v-250428/code.mdx +++ /dev/null @@ -1,436 +0,0 @@ ---- -title: "Comfy Router で Seedance 1.0 Lite I2V 250428 を使用する" -description: "Comfy Router 経由で byteplus/seedance-1-0-lite-i2v-250428 を呼び出します: エンドポイント、リクエスト形状、Router が返すレスポンス。" -sidebarTitle: "Seedance 1.0 Lite I2V 250428" -translationSourceHash: 0f64abdd -translationFrom: development/comfy-router/models/byteplus/seedance-1-0-lite-i2v-250428/code.mdx -translationBlockHashes: - "_intro": 66c320e8 - "Quick start": a84cd948 - "Schema": 0dd61406 - "Examples": d126be96 ---- -{/* GENERATED FILE. Generated from router-schemas/byteplus/seedance-1-0-lite-i2v-250428.json by `pnpm code-pages:gen`. */} - -import RouterCodeFooter from "/snippets/ja/comfy-router/model-code-footer.mdx"; - -`byteplus/seedance-1-0-lite-i2v-250428` の API リファレンスです。このモデルは Comfy Router が BytePlus から提供しています。 - -## クイックスタート - -[Comfy ワークスペース](https://platform.comfy.org/profile/api-keys)でキーを作成し、`COMFY_API_KEY` としてエクスポートします。Python と TypeScript のスニペットは Comfy SDK(`pip install comfy-sdk`、`npm install @comfyorg/sdk`)を使用します。cURL のスニペットは、同じ呼び出しを生の HTTP で実行するものです。 - -**モデル ID:** `byteplus/seedance-1-0-lite-i2v-250428` - -**エンドポイント:** `POST https://api.comfy.org/v2/models/byteplus/seedance-1-0-lite-i2v-250428` - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# The SDK automatically creates an idempotency key and reuses it for automatic retries. -with Comfy() as client: - result = client.models.run( - "byteplus/seedance-1-0-lite-i2v-250428", - { - "content": [ - { - "text": "A red fox trotting through a snowy pine forest", - "type": "text", - }, - ], - "duration": 5, - "ratio": "16:9", - "resolution": "720p", - }, - ) - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// The SDK automatically creates an idempotency key and reuses it for automatic retries. -const { data } = await comfy.models.run("byteplus/seedance-1-0-lite-i2v-250428", { - content: [ - { - text: "A red fox trotting through a snowy pine forest", - type: "text", - }, - ], - duration: 5, - ratio: "16:9", - resolution: "720p", -}); - -console.log(data); -``` - -```bash cURL -curl https://api.comfy.org/v2/models/byteplus/seedance-1-0-lite-i2v-250428 \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"content\": [{\"text\":\"A red fox trotting through a snowy pine forest\",\"type\":\"text\"}], \"duration\": 5, \"ratio\": \"16:9\", \"resolution\": \"720p\"}" -``` - - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -with Comfy() as client: - handle = client.models.submit( - "byteplus/seedance-1-0-lite-i2v-250428", - { - "content": [ - { - "text": "A red fox trotting through a snowy pine forest", - "type": "text", - }, - ], - "duration": 5, - "ratio": "16:9", - "resolution": "720p", - }, - ) - print("request_id:", handle.request_id) # with the model ID, all another process needs - - # Poll until the request completes, waiting the Retry-After the server names. - for update in handle.iter_events(): - print(update.status, update.queue_position) - - # The provider's own payload, the same value models.run() returns. - # A request that failed or was cancelled raises the typed Router error here. - result = handle.get() - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -const handle = await comfy.models.submit("byteplus/seedance-1-0-lite-i2v-250428", { - content: [ - { - text: "A red fox trotting through a snowy pine forest", - type: "text", - }, - ], - duration: 5, - ratio: "16:9", - resolution: "720p", -}); -console.log("requestId:", handle.requestId); // with the model ID, all another process needs - -// Poll until the request completes, waiting the Retry-After the server names. -for await (const update of handle.events()) { - console.log(update.status, update.queuePosition); -} - -// The same result models.run() returns. A request that failed or was cancelled rejects here. -const result = await handle.get(); - -console.log(result.data); -``` - -```bash cURL -# 1. Submit. Router answers 201 with request_id, status_url, response_url and cancel_url. -curl https://api.comfy.org/v2/models/byteplus/seedance-1-0-lite-i2v-250428/requests \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"content\": [{\"text\":\"A red fox trotting through a snowy pine forest\",\"type\":\"text\"}], \"duration\": 5, \"ratio\": \"16:9\", \"resolution\": \"720p\"}" - -# 2. Poll until status is COMPLETED, waiting the Retry-After seconds each response names. -REQUEST_ID="" -curl -i https://api.comfy.org/v2/models/byteplus/seedance-1-0-lite-i2v-250428/requests/$REQUEST_ID/status \ - -H "X-API-Key: $COMFY_API_KEY" - -# 3. Collect. 200 with the model's native output, 202 with the status body while it is still running. -curl https://api.comfy.org/v2/models/byteplus/seedance-1-0-lite-i2v-250428/requests/$REQUEST_ID \ - -H "X-API-Key: $COMFY_API_KEY" -``` - - - - - -## スキーマ - -### 入力 - - - この生成タスクの結果を受け取るコールバック通知先 - - 形式: `uri` - - - - モデルがビデオを生成するための入力コンテンツ - - - - 入力オーディオオブジェクト。オーディオ入力に対応しているのは Seedance 2.5、2.0、2.0 fast のみです。Seedance 2.0 と 2.0 fast はオーディオ単体では使用できません。少なくとも 1 つの画像またはビデオを含める必要があります。Seedance 2.5 はオーディオのみの入力に対応しています。 - - - - オーディオ URL、Base64 エンコーディング、またはアセット ID。 -オーディオ URL: オーディオの公開 URL (wav、mp3)。 -Base64: 形式 data:audio/\;base64,\ -アセット ID: 形式 asset://\ - - - - - - - - 画像から動画への生成のための画像コンテンツ (type が "image_url" の場合) -画像URL: 画像URLにアクセスできることを確認してください。 -Base64 エンコードされたコンテンツ: 形式は data:image/\;base64,\ である必要があります -アセット ID: 形式 asset://\ - - - - コンテンツ項目の役割/位置。 -画像の場合: first_frame、last_frame、または reference_image。 -ビデオの場合: reference_video (Seedance 2.5、2.0、2.0 fast のみ)。 -オーディオの場合: reference_audio (Seedance 2.5、2.0、2.0 fast のみ)。 - - 取り得る値: `first_frame`, `last_frame`, `reference_image`, `reference_video`, `reference_audio` - - - - モデルへの入力テキスト情報。テキストプロンプトと任意のパラメータを含みます。 - -テキストプロンプト (必須): 中国語および英語の文字を使用して生成するビデオの説明。 - -パラメータ (任意): テキストプロンプトの後に --[パラメータ] を追加してビデオの仕様を制御します: -- --resolution (--rs): 480p、720p、1080p (デフォルト: 720p) -- --ratio (--rt): 21:9、16:9、4:3、1:1、3:4、9:16、9:21、adaptive (デフォルト: 16:9 または adaptive) -- --duration (--dur): 3~12 秒 (デフォルト: 5) -- --framepersecond (--fps): 24 (デフォルト: 24) -- --watermark (--wm): true/false (デフォルト: false) -- --seed (--seed): -1 ~ 2^32-1 (デフォルト: -1) -- --camerafixed (--cf): true/false (デフォルト: false) - -例: "A beautiful landscape --ratio 16:9 --resolution 720p --duration 5" - - - - 入力コンテンツの種類 - - 取り得る値: `text`, `image_url`, `video_url`, `audio_url` - - - - 入力ビデオオブジェクト。ビデオ入力に対応しているのは Seedance 2.5、2.0、2.0 fast のみです。 - - - - ビデオ URL またはアセット ID。 -ビデオ URL: ビデオの公開 URL (mp4、mov)。 -アセット ID: 形式 asset://\ - - - - ビデオの再生時間 (秒)。Seedance 2.5: [4,30] または -1 (自動。ビデオ編集タスクは -1 のみ対応)。Seedance 2.0 と 2.0 fast: [4,15] または -1 (自動)。Seedance 1.5 pro: [4,12] または -1。Seedance 1.0: [2,12]。 - - 範囲: `2` ~ `30` - - - - タスクのタイムアウトしきい値 (秒)。デフォルト 172800 (48h)。範囲: [3600, 259200]。 - - 範囲: `3600` ~ `259200` - - - - Seedance 2.5、2.0、2.0 fast、1.5 pro でサポートされています。生成されるビデオに映像と同期したオーディオを含めるかどうか。 -true: モデルは同期したオーディオ付きのビデオを出力します。 -false: モデルは無音のビデオを出力します。 - - - - 呼び出すモデルの ID。サポートされているモデル: seedance-1-5-pro-251215、seedance-1-0-pro-250528、seedance-1-0-pro-fast-251015、seedance-1-0-lite-t2v-250428、seedance-1-0-lite-i2v-250428、dreamina-seedance-2-0-260128、dreamina-seedance-2-0-fast-260128、dreamina-seedance-2-0-mini、dreamina-seedance-2-5-260628。直接 v1 で POST /proxy/byteplus/api/v3/contents/generations/tasks を呼び出す場合は必ずこれを指定する必要があります。proxy は他の値や省略された値を受け付けず、400 を返します。これはこのスキーマの `required` リストには含まれていません。Comfy Router が /v2/models/byteplus/\{model} の `{model}` パスセグメントからこれを設定するため、Router の呼び出し元は省略します。 - - - - Seedance 2.5 のみ。出力ビデオのコンテナ形式。 -mp4: 汎用コンテナ (H.264/AAC、yuv420p) で、幅広い互換性とより小さいファイルサイズ。 -mov: プロフェッショナル向けコンテナ (H.264 High 4:4:4 Predictive/PCM、yuv444p) で高い色精度を持ち、ポストプロダクションに適しています。ファイルサイズはより大きくなります。 - - 取り得る値: `mp4`, `mov` - - - - 生成されるビデオの比率。Seedance 2.0 と 2.0 fast、1.5 pro のデフォルト: adaptive。 - - 取り得る値: `16:9`, `4:3`, `1:1`, `3:4`, `9:16`, `21:9`, `9:21`, `adaptive` - - - - ビデオの解像度。Seedance 2.5、2.0 と 2.0 fast、1.5 pro、1.0 lite のデフォルト: 720p。Seedance 1.0 pro と pro-fast のデフォルト: 1080p。 -注: Seedance 2.0 と 2.0 fast は 1080p をサポートしていません。Seedance 2.5 は 480p、720p、1080p をサポートしています。 - - 取り得る値: `480p`, `720p`, `1080p`, `4k` - - - - 生成されたビデオの最後のフレーム画像を返すかどうか。 -true: 生成済みビデオの最終フレーム画像を返します。このパラメータを true に設定すると、ビデオ生成タスクの情報をクエリすることで最終フレーム画像を取得できます。最終フレーム画像は PNG 形式で、ピクセル幅と高さは生成済みビデオと一致し、ウォーターマークは含まれません。このパラメータを使用すると、複数の連続したビデオを生成できます。先に生成したビデオの最終フレームを次のビデオタスクの最初のフレームとして使用することで、複数の連続したビデオを素早く生成できます。 -false: 生成済みビデオの最終フレーム画像を返しません。 - - - - ランダム性を制御するシード整数。範囲: [-1, 2^32-1]。-1 はランダムシードを使用します。 - - 範囲: `-1` から `4294967295` - - - - 処理のためのサービステア。Seedance 2.5、2.0、2.0 fast は flex(オフライン推論)をサポートしていません。 - - 指定可能な値: `default`, `flex` - - - - 生成済みビデオにウォーターマークが含まれるかどうか。 - - -`GET /v2/models/byteplus/seedance-1-0-lite-i2v-250428/openapi.json` で Router が提供するスキーマから生成されています。これは、リクエストがプロバイダーに到達する前に Router が呼び出しを検証する際に使用するドキュメントと同じものです。 -### 出力 - - - ビデオ生成タスクの完了後の出力です。出力ビデオのダウンロード URL と、BytePlus が返す場合はそのラストフレームのダウンロード URL を含みます。`video_url` と `last_frame_url` はどちらも Comfy ストレージに再ホストされます。ここにあるその他のフィールドはすべて BytePlus 自身のものです。null 許容です: BytePlus はタスクの 24 時間後に URL をクリアするため、その後ポーリングした成功済みドキュメントでは `content` が存在しないか null である可能性があります。 - - - - 生成済みビデオのラストフレームのダウンロード URL です。リクエストで `return_last_frame` を設定した場合に返されます。この URL から画像フォーマットを推測しないでください: BytePlus はリクエスト側でラストフレームを PNG としてドキュメント化していますが、Router は渡されたバイト列をそのまま再ホストし、上流の Content-Type またはコンテンツスニッフィングから型を判定します。`image/jpeg` はそのどちらも失敗した場合の最後の手段のフォールバックにすぎません。Router はラストフレームを Comfy ストレージに再ホストしてこのフィールドを書き換えるため、通常は最大 24 時間有効な Comfy 署名付き URL になります。発行時に 24 時間で署名され、23 時間のメモから再生されるため、後でポーリングすると残り 1 時間しかないものが返る可能性があります。再ホストを実行できなかった場合、このフィールドは代わりに BytePlus 自身の URL を保持しますが、BytePlus はタスクの 24 時間後にそれをクリアします。いずれにせよリンクは期限切れになるため、URL を保存するのではなくフレームをダウンロードしてください。 - - - - 生成済みビデオのコンテナフォーマット(mp4 または mov)です。BytePlus が `content` の内部にネストする場合に返されます。Seedance モデルではこれを `content` のトップレベルの兄弟として返すことがより一般的です(トップレベルの `output_format` フィールドを参照)。Router は存在するほうを読み取ります。 - - - - 出力ビデオのダウンロード URL です。Router はビデオを Comfy ストレージに再ホストしてこのフィールドを書き換えるため、通常は最大 24 時間有効な Comfy 署名付き URL になります。発行時に 24 時間で署名され、23 時間のメモから再生されるため、後でポーリングすると残り 1 時間しかないものが返る可能性があります。再ホストを実行できなかった場合、このフィールドは代わりに BytePlus 自身の URL を保持しますが、BytePlus はタスクの 24 時間後にそれをクリアし、一部のモデルでは 100 回のダウンロードに制限しています。いずれにせよリンクは期限切れになるため、URL を保存するのではなくビデオをダウンロードしてください。 - - - - タスクが作成された時間です。値は秒単位の UNIX タイムスタンプです。 - - - - 生成済みビデオの再生時間(秒)です。BytePlus がこれを一貫して扱っていないため、整数ではなく数値として宣言されています。ビデオタスクでは整数秒が返される一方、BytePlus の他のサーフェスでは小数の再生時間が報告されることが観察されているため、クライアントは整数値を前提にしてはいけません。BytePlus 自身のフィールドで、成功したビデオタスクで返され、そのまま転送されます。 - - - - エラー情報です。タスクが成功した場合は null が返されます。タスクが失敗した場合はエラー情報が返されます。 - - - - エラーコード - - - - エラーメッセージ - - - - ビデオ生成タスクの ID - - - - タスクで使用されたモデルの名前とバージョン - - - - 生成済みビデオのコンテナフォーマット(mp4 または mov)です。`content` の兄弟としてトップレベルで返されます。Seedance のビデオタスククエリはここでこれを返します。BytePlus 自身のフィールドで、そのまま転送されます。 - - - - 生成済みビデオの解像度(例: `1080p`)です。BytePlus 自身のフィールドで、成功したビデオタスクで返され、そのまま転送されます。 - - - - タスクで実際に使用された生成シードです。BytePlus 自身のフィールドで、成功したビデオタスクで返され、そのまま転送されます。 - - フォーマット: `int64` - - - - タスクの状態 - - 取り得る値: `queued`、`running`、`cancelled`、`succeeded`、`failed`、`expired` - - - - タスクが最後に更新された時間です。値は秒単位の UNIX タイムスタンプです。 - - - - リクエストのトークン使用量 - - - - モデルによって生成されたトークン数 - - - - ビデオ生成モデルでは、入力トークン数は計算されず、デフォルトで 0 になります。したがって、total_tokens = completion_tokens です。 - - -## 例 - -### 入力 - -```json -{ - "content": [ - { - "text": "A red fox trotting through a snowy pine forest", - "type": "text" - } - ], - "duration": 5, - "ratio": "16:9", - "resolution": "720p" -} -``` - -### 出力 - -```json -{ - "content": { - "last_frame_url": "https://example.invalid/byteplus/seedance-1-0-lite-t2v-250428/last-frame", - "video_url": "https://example.invalid/byteplus/seedance-1-0-lite-t2v-250428/generated.mp4" - }, - "created_at": 1767225600, - "duration": 5, - "error": null, - "id": "3f7a1b28-5c0d-4e91-8a6f-1b2c3d4e5f60", - "model": "seedance-1-0-lite-i2v-250428", - "output_format": "mp4", - "resolution": "1080p", - "seed": 1234567890123, - "status": "succeeded", - "updated_at": 1767225730 -} -``` - - - diff --git a/ja/development/comfy-router/models/byteplus/seedance-1-0-lite-t2v-250428/code.mdx b/ja/development/comfy-router/models/byteplus/seedance-1-0-lite-t2v-250428/code.mdx deleted file mode 100644 index 73b0e49e4d..0000000000 --- a/ja/development/comfy-router/models/byteplus/seedance-1-0-lite-t2v-250428/code.mdx +++ /dev/null @@ -1,435 +0,0 @@ ---- -title: "Comfy Router で Seedance 1.0 Lite T2V 250428 を使用する" -description: "Comfy Router 経由で byteplus/seedance-1-0-lite-t2v-250428 を呼び出します: エンドポイント、リクエストの形状、Router が返すレスポンスについて説明します。" -sidebarTitle: "Seedance 1.0 Lite T2V 250428" -translationSourceHash: 6065cd55 -translationFrom: development/comfy-router/models/byteplus/seedance-1-0-lite-t2v-250428/code.mdx -translationBlockHashes: - "_intro": a1ec32a9 - "Quick start": bf8ec8dc - "Schema": 060399d4 - "Examples": 7c3591f8 ---- -{/* 生成済みファイル。`pnpm code-pages:gen` により router-schemas/byteplus/seedance-1-0-lite-t2v-250428.json から生成。 */} - -import RouterCodeFooter from "/snippets/ja/comfy-router/model-code-footer.mdx"; - -`byteplus/seedance-1-0-lite-t2v-250428` の API リファレンスです。Comfy Router が BytePlus から提供しています。 - -## クイックスタート - -[Comfy ワークスペース](https://platform.comfy.org/profile/api-keys)でキーを作成し、`COMFY_API_KEY` としてエクスポートします。Python と TypeScript のスニペットは Comfy SDK を使用します(`pip install comfy-sdk`、`npm install @comfyorg/sdk`)。cURL のスニペットは生の HTTP 経由で同じ呼び出しを行います。 - -**Model ID:** `byteplus/seedance-1-0-lite-t2v-250428` - -**Endpoint:** `POST https://api.comfy.org/v2/models/byteplus/seedance-1-0-lite-t2v-250428` - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# The SDK automatically creates an idempotency key and reuses it for automatic retries. -with Comfy() as client: - result = client.models.run( - "byteplus/seedance-1-0-lite-t2v-250428", - { - "content": [ - { - "text": "A red fox trotting through a snowy pine forest", - "type": "text", - }, - ], - "duration": 5, - "ratio": "16:9", - "resolution": "720p", - }, - ) - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// The SDK automatically creates an idempotency key and reuses it for automatic retries. -const { data } = await comfy.models.run("byteplus/seedance-1-0-lite-t2v-250428", { - content: [ - { - text: "A red fox trotting through a snowy pine forest", - type: "text", - }, - ], - duration: 5, - ratio: "16:9", - resolution: "720p", -}); - -console.log(data); -``` - -```bash cURL -curl https://api.comfy.org/v2/models/byteplus/seedance-1-0-lite-t2v-250428 \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"content\": [{\"text\":\"A red fox trotting through a snowy pine forest\",\"type\":\"text\"}], \"duration\": 5, \"ratio\": \"16:9\", \"resolution\": \"720p\"}" -``` - - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -with Comfy() as client: - handle = client.models.submit( - "byteplus/seedance-1-0-lite-t2v-250428", - { - "content": [ - { - "text": "A red fox trotting through a snowy pine forest", - "type": "text", - }, - ], - "duration": 5, - "ratio": "16:9", - "resolution": "720p", - }, - ) - print("request_id:", handle.request_id) # with the model ID, all another process needs - - # Poll until the request completes, waiting the Retry-After the server names. - for update in handle.iter_events(): - print(update.status, update.queue_position) - - # The provider's own payload, the same value models.run() returns. - # A request that failed or was cancelled raises the typed Router error here. - result = handle.get() - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -const handle = await comfy.models.submit("byteplus/seedance-1-0-lite-t2v-250428", { - content: [ - { - text: "A red fox trotting through a snowy pine forest", - type: "text", - }, - ], - duration: 5, - ratio: "16:9", - resolution: "720p", -}); -console.log("requestId:", handle.requestId); // with the model ID, all another process needs - -// Poll until the request completes, waiting the Retry-After the server names. -for await (const update of handle.events()) { - console.log(update.status, update.queuePosition); -} - -// The same result models.run() returns. A request that failed or was cancelled rejects here. -const result = await handle.get(); - -console.log(result.data); -``` - -```bash cURL -# 1. Submit. Router answers 201 with request_id, status_url, response_url and cancel_url. -curl https://api.comfy.org/v2/models/byteplus/seedance-1-0-lite-t2v-250428/requests \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"content\": [{\"text\":\"A red fox trotting through a snowy pine forest\",\"type\":\"text\"}], \"duration\": 5, \"ratio\": \"16:9\", \"resolution\": \"720p\"}" - -# 2. Poll until status is COMPLETED, waiting the Retry-After seconds each response names. -REQUEST_ID="" -curl -i https://api.comfy.org/v2/models/byteplus/seedance-1-0-lite-t2v-250428/requests/$REQUEST_ID/status \ - -H "X-API-Key: $COMFY_API_KEY" - -# 3. Collect. 200 with the model's native output, 202 with the status body while it is still running. -curl https://api.comfy.org/v2/models/byteplus/seedance-1-0-lite-t2v-250428/requests/$REQUEST_ID \ - -H "X-API-Key: $COMFY_API_KEY" -``` - - - - - -## スキーマ - -### 入力 - - - この生成タスクの結果を受け取るコールバック通知先 - - 形式: `uri` - - - - モデルがビデオを生成するための入力コンテンツ - - - - 入力オーディオオブジェクト。オーディオ入力に対応するのは Seedance 2.5、2.0、2.0 fast のみです。Seedance 2.0 と 2.0 fast はオーディオ単体では使用できず、少なくとも 1 つの画像またはビデオを含める必要があります。Seedance 2.5 はオーディオのみの入力に対応しています。 - - - - オーディオ URL、Base64 エンコード、またはアセット ID。 -オーディオ URL: オーディオの公開 URL(wav、mp3)。 -Base64: 形式 data:audio/\;base64,\ -アセット ID: 形式 asset://\ - - - - - - - - 画像から動画を生成するための画像コンテンツ(type が "image_url" の場合) -画像 URL: 画像 URL にアクセスできることを確認してください。 -Base64 エンコードされたコンテンツ: 形式は data:image/\;base64,\ である必要があります -アセット ID: 形式 asset://\ - - - - コンテンツ項目の役割/位置。 -画像の場合: first_frame、last_frame、または reference_image。 -ビデオの場合: reference_video(Seedance 2.5、2.0、2.0 fast のみ)。 -オーディオの場合: reference_audio(Seedance 2.5、2.0、2.0 fast のみ)。 - - 指定可能な値: `first_frame`、`last_frame`、`reference_image`、`reference_video`、`reference_audio` - - - - モデルへの入力テキスト情報。テキストプロンプトと任意のパラメータを含みます。 - -テキストプロンプト(必須): 中国語および英語の文字を使用して生成するビデオを記述します。 - -パラメータ(任意): テキストプロンプトの後に --[parameters] を追加すると、ビデオの仕様を制御できます: -- --resolution (--rs): 480p、720p、1080p(デフォルト: 720p) -- --ratio (--rt): 21:9、16:9、4:3、1:1、3:4、9:16、9:21、adaptive(デフォルト: 16:9 または adaptive) -- --duration (--dur): 3~12 秒(デフォルト: 5) -- --framepersecond (--fps): 24(デフォルト: 24) -- --watermark (--wm): true/false(デフォルト: false) -- --seed (--seed): -1~2^32-1(デフォルト: -1) -- --camerafixed (--cf): true/false(デフォルト: false) - -例: "A beautiful landscape --ratio 16:9 --resolution 720p --duration 5" - - - - 入力コンテンツの種類 - - 指定可能な値: `text`、`image_url`、`video_url`、`audio_url` - - - - 入力ビデオオブジェクト。ビデオ入力に対応するのは Seedance 2.5、2.0、2.0 fast のみです。 - - - - ビデオ URL またはアセット ID。 -ビデオ URL: ビデオの公開 URL(mp4、mov)。 -アセット ID: 形式 asset://\ - - - - ビデオの長さ(秒)。Seedance 2.5: [4,30] または -1(自動。ビデオ編集タスクは -1 のみ対応)。Seedance 2.0 と 2.0 fast: [4,15] または -1(自動)。Seedance 1.5 pro: [4,12] または -1。Seedance 1.0: [2,12]。 - - 範囲: `2`~`30` - - - - タスクのタイムアウトしきい値(秒)。デフォルトは 172800(48 時間)。範囲: [3600, 259200]。 - - 範囲: `3600`~`259200` - - - - Seedance 2.5、2.0、2.0 fast、1.5 pro でサポートされています。生成されるビデオに映像と同期したオーディオを含めるかどうか。 -true: モデルは同期したオーディオ付きのビデオを出力します。 -false: モデルは無音のビデオを出力します。 - - - - 呼び出すモデルの ID。サポートされているモデル: seedance-1-5-pro-251215、seedance-1-0-pro-250528、seedance-1-0-pro-fast-251015、seedance-1-0-lite-t2v-250428、seedance-1-0-lite-i2v-250428、dreamina-seedance-2-0-260128、dreamina-seedance-2-0-fast-260128、dreamina-seedance-2-0-mini、dreamina-seedance-2-5-260628。POST /proxy/byteplus/api/v3/contents/generations/tasks への v1 直接呼び出しでは必ず指定する必要があります。プロキシはそれ以外の値や省略された値を 400 で拒否します。このスキーマの `required` リストに含まれていないのは、Comfy Router が /v2/models/byteplus/\{model} の `{model}` パスセグメントから設定するためであり、Router の呼び出し元は省略します。 - - - - Seedance 2.5 のみ。出力ビデオのコンテナ形式。 -mp4: 汎用コンテナ(H.264/AAC、yuv420p)。幅広い互換性があり、ファイルサイズも小さくなります。 -mov: プロフェッショナル向けコンテナ(H.264 High 4:4:4 Predictive/PCM、yuv444p)。色精度が高くポストプロダクションに適しますが、ファイルサイズは大きくなります。 - - 指定可能な値: `mp4`、`mov` - - - - 生成されるビデオのアスペクト比。Seedance 2.0 と 2.0 fast、1.5 pro のデフォルト: adaptive。 - - 指定可能な値: `16:9`、`4:3`、`1:1`、`3:4`、`9:16`、`21:9`、`9:21`、`adaptive` - - - - ビデオの解像度。Seedance 2.5、2.0 と 2.0 fast、1.5 pro、1.0 lite のデフォルト: 720p。Seedance 1.0 pro と pro-fast のデフォルト: 1080p。 -注: Seedance 2.0 と 2.0 fast は 1080p に対応していません。Seedance 2.5 は 480p、720p、1080p に対応しています。 - - 指定可能な値: `480p`、`720p`、`1080p`、`4k` - - - - 生成されたビデオの最後のフレーム画像を返すかどうか。true: 生成済みビデオの最後のフレーム画像を返します。このパラメータを true に設定すると、「ビデオ生成タスクの情報を照会する」を呼び出すことで最後のフレーム画像を取得できます。最後のフレーム画像は PNG 形式で、ピクセル単位の幅と高さは生成済みビデオと一致し、ウォーターマークは含まれません。このパラメータを使用すると、複数の連続したビデオを生成できます。先に生成したビデオの最後のフレームを次のビデオタスクの最初のフレームとして使用することで、複数の連続したビデオをすばやく生成できます。 -false: 生成済みビデオの最後のフレーム画像を返しません。 - - - - ランダム性を制御するためのシード整数。範囲: [-1, 2^32-1]。-1 はランダムなシードを使用します。 - - 範囲: `-1` から `4294967295` - - - - 処理のサービス階層。Seedance 2.5、2.0 & 2.0 fast は flex(オフライン推論)をサポートしていません。 - - 指定可能な値: `default`、`flex` - - - - 生成済みビデオにウォーターマークを含めるかどうか。 - - -Router が `GET /v2/models/byteplus/seedance-1-0-lite-t2v-250428/openapi.json` で提供するスキーマから生成されています。これは、リクエストがプロバイダーに到達する前に呼び出しを検証する際に使用される同一のドキュメントです。 -### 出力 - - - ビデオ生成タスク完了後の出力。出力ビデオのダウンロード URL と、BytePlus が返す場合は最後のフレームのダウンロード URL を含みます。`video_url` と `last_frame_url` はどちらも Comfy ストレージに再ホストされており、その他のフィールドはすべて BytePlus 独自のものです。null 許容です。BytePlus はタスクの 24 時間後に URL をクリアするため、その後ポーリングされた succeeded ドキュメントでは `content` が存在しないか null になる可能性があります。 - - - - 生成されたビデオの最後のフレームのダウンロード URL。リクエストで `return_last_frame` を設定した場合に返されます。この URL から画像形式を推測しないでください。BytePlus はリクエスト側で最後のフレームを PNG としてドキュメント化しており、Router は提供されたバイト列をそのまま再ホストし、上流の Content-Type またはコンテンツスニッフィングから型を決定します。`image/jpeg` は両方失敗した場合の最後のフォールバックにすぎません。Router は最後のフレームを Comfy ストレージに再ホストしてこのフィールドを書き換えるため、通常は最大 24 時間有効な Comfy 署名付き URL になります。発行時に 24 時間署名され、23 時間のメモから再生されるため、後でポーリングすると残り 1 時間程度のものが返される可能性があります。再ホストを実行できなかった場合、このフィールドは BytePlus 独自の URL を保持します。これは BytePlus がタスクの 24 時間後にクリアします。いずれにしてもリンクは期限切れになるため、URL を保存するのではなくフレームをダウンロードしてください。 - - - - 生成されたビデオのコンテナ形式(mp4 または mov)。BytePlus が `content` 内にネストした場合に返されます。Seedance モデルでは、`content` のトップレベルの兄弟フィールドとして返されることがより一般的です。トップレベルの `output_format` フィールドを参照してください。Router は存在する方のいずれかを読み取ります。 - - - - 出力ビデオのダウンロード URL。Router はビデオを Comfy ストレージに再ホストしてこのフィールドを書き換えるため、通常は最大 24 時間有効な Comfy 署名付き URL になります。発行時に 24 時間署名され、23 時間のメモから再生されるため、後でポーリングすると残り 1 時間程度のものが返される可能性があります。再ホストを実行できなかった場合、このフィールドは BytePlus 独自の URL を保持します。BytePlus はタスクの 24 時間後にこれをクリアし、一部のモデルでは 100 ダウンロードに制限しています。いずれにしてもリンクは期限切れになるため、URL を保存するのではなくビデオをダウンロードしてください。 - - - - タスクが作成された時間。値は UNIX タイムスタンプ(秒)です。 - - - - 生成されたビデオの再生時間(秒)。BytePlus がこの点で一貫性がないため、整数ではなく数値として宣言されています。ビデオタスクでは秒単位の整数値が返されることが観測されており、兄弟の BytePlus サーフェスでは小数の再生時間が報告されています。そのためクライアントは整数値を仮定してはいけません。BytePlus 独自のフィールドで、成功したビデオタスクで返され、変更されずに転送されます。 - - - - エラー情報。タスクが成功した場合は null が返されます。タスクが失敗した場合はエラー情報が返されます。 - - - - エラーコード - - - - エラーメッセージ - - - - ビデオ生成タスクの ID - - - - タスクで使用されたモデルの名前とバージョン - - - - 生成されたビデオのコンテナ形式(mp4 または mov)。`content` の兄弟としてトップレベルで返されます。これは Seedance ビデオタスククエリが返す場所です。BytePlus 独自のフィールドで、変更されずに転送されます。 - - - - 生成されたビデオの解像度。例:`1080p`。BytePlus 独自のフィールドで、成功したビデオタスクで返され、変更されずに転送されます。 - - - - タスクで実際に使用された生成シード。BytePlus 独自のフィールドで、成功したビデオタスクで返され、変更されずに転送されます。 - - 形式:`int64` - - - - タスクの状態 - - 可能な値:`queued`、`running`、`cancelled`、`succeeded`、`failed`、`expired` - - - - タスクが最後に更新された時間。値は UNIX タイムスタンプ(秒)です。 - - - - リクエストのトークン使用量 - - - - モデルによって生成されたトークン数 - - - - ビデオ生成モデルの場合、入力トークン数は計算されず、デフォルトで 0 になります。したがって、total_tokens = completion_tokens となります。 - - -## 例 - -### 入力 - -```json -{ - "content": [ - { - "text": "A red fox trotting through a snowy pine forest", - "type": "text" - } - ], - "duration": 5, - "ratio": "16:9", - "resolution": "720p" -} -``` - -### 出力 - -```json -{ - "content": { - "last_frame_url": "https://example.invalid/byteplus/seedance-1-0-lite-t2v-250428/last-frame", - "video_url": "https://example.invalid/byteplus/seedance-1-0-lite-t2v-250428/generated.mp4" - }, - "created_at": 1767225600, - "duration": 5, - "error": null, - "id": "3f7a1b28-5c0d-4e91-8a6f-1b2c3d4e5f60", - "model": "seedance-1-0-lite-t2v-250428", - "output_format": "mp4", - "resolution": "1080p", - "seed": 1234567890123, - "status": "succeeded", - "updated_at": 1767225730 -} -``` - - - diff --git a/ja/development/comfy-router/models/byteplus/seededit-3-0-i2i-250628/code.mdx b/ja/development/comfy-router/models/byteplus/seededit-3-0-i2i-250628/code.mdx deleted file mode 100644 index abf08f6ce0..0000000000 --- a/ja/development/comfy-router/models/byteplus/seededit-3-0-i2i-250628/code.mdx +++ /dev/null @@ -1,391 +0,0 @@ ---- -title: "Comfy Router で Seededit 3.0 I2I 250628 を使用する" -description: "Comfy Router 経由で byteplus/seededit-3-0-i2i-250628 を呼び出します: エンドポイント、リクエストの形状、Router が返すレスポンスについて説明します。" -sidebarTitle: "Seededit 3.0 I2I 250628" -translationSourceHash: cfe4b48a -translationFrom: development/comfy-router/models/byteplus/seededit-3-0-i2i-250628/code.mdx -translationBlockHashes: - "_intro": b2e7faed - "Quick start": 0aef594c - "Schema": fe63d102 - "Examples": 130ffbde ---- -{/* GENERATED FILE. Generated from router-schemas/byteplus/seededit-3-0-i2i-250628.json by `pnpm code-pages:gen`. */} - -import RouterCodeFooter from "/snippets/ja/comfy-router/model-code-footer.mdx"; - -`byteplus/seededit-3-0-i2i-250628` の API リファレンスです。Comfy Router が BytePlus から提供します。 - -## クイックスタート - -[Comfy ワークスペース](https://platform.comfy.org/profile/api-keys)でキーを作成し、`COMFY_API_KEY` としてエクスポートします。Python と TypeScript のスニペットは Comfy SDK(`pip install comfy-sdk`、`npm install @comfyorg/sdk`)を使用しています。cURL のスニペットは、生の HTTP で同じ呼び出しを行います。 - -**モデル ID:** `byteplus/seededit-3-0-i2i-250628` - -**エンドポイント:** `POST https://api.comfy.org/v2/models/byteplus/seededit-3-0-i2i-250628` - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# The SDK automatically creates an idempotency key and reuses it for automatic retries. -with Comfy() as client: - result = client.models.run( - "byteplus/seededit-3-0-i2i-250628", - { - "prompt": "A red fox trotting through a snowy pine forest, cinematic lighting", - "response_format": "url", - "watermark": False, - }, - ) - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// The SDK automatically creates an idempotency key and reuses it for automatic retries. -const { data } = await comfy.models.run("byteplus/seededit-3-0-i2i-250628", { - prompt: "A red fox trotting through a snowy pine forest, cinematic lighting", - response_format: "url", - watermark: false, -}); - -console.log(data); -``` - -```bash cURL -curl https://api.comfy.org/v2/models/byteplus/seededit-3-0-i2i-250628 \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"prompt\": \"A red fox trotting through a snowy pine forest, cinematic lighting\", \"response_format\": \"url\", \"watermark\": false}" -``` - - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -with Comfy() as client: - handle = client.models.submit( - "byteplus/seededit-3-0-i2i-250628", - { - "prompt": "A red fox trotting through a snowy pine forest, cinematic lighting", - "response_format": "url", - "watermark": False, - }, - ) - print("request_id:", handle.request_id) # with the model ID, all another process needs - - # Poll until the request completes, waiting the Retry-After the server names. - for update in handle.iter_events(): - print(update.status, update.queue_position) - - # The provider's own payload, the same value models.run() returns. - # A request that failed or was cancelled raises the typed Router error here. - result = handle.get() - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -const handle = await comfy.models.submit("byteplus/seededit-3-0-i2i-250628", { - prompt: "A red fox trotting through a snowy pine forest, cinematic lighting", - response_format: "url", - watermark: false, -}); -console.log("requestId:", handle.requestId); // with the model ID, all another process needs - -// Poll until the request completes, waiting the Retry-After the server names. -for await (const update of handle.events()) { - console.log(update.status, update.queuePosition); -} - -// The same result models.run() returns. A request that failed or was cancelled rejects here. -const result = await handle.get(); - -console.log(result.data); -``` - -```bash cURL -# 1. Submit. Router answers 201 with request_id, status_url, response_url and cancel_url. -curl https://api.comfy.org/v2/models/byteplus/seededit-3-0-i2i-250628/requests \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"prompt\": \"A red fox trotting through a snowy pine forest, cinematic lighting\", \"response_format\": \"url\", \"watermark\": false}" - -# 2. Poll until status is COMPLETED, waiting the Retry-After seconds each response names. -REQUEST_ID="" -curl -i https://api.comfy.org/v2/models/byteplus/seededit-3-0-i2i-250628/requests/$REQUEST_ID/status \ - -H "X-API-Key: $COMFY_API_KEY" - -# 3. Collect. 200 with the model's native output, 202 with the status body while it is still running. -curl https://api.comfy.org/v2/models/byteplus/seededit-3-0-i2i-250628/requests/$REQUEST_ID \ - -H "X-API-Key: $COMFY_API_KEY" -``` - - - - - -## スキーマ - -### 入力 - - - 出力画像が入力プロンプトにどれだけ忠実に従うかを制御します。範囲は [1, 10] です。値が大きいほどプロンプトへの追従性が強くなります。デフォルトは seedream-3-0-t2i-250415 では 2.5、seededit-3-0-i2i-250628 では 5.5 です。seedream-5.0-pro、5.0-lite、4.5、4.0 ではサポートされません。 - - 範囲: `1` から `10` - - フォーマット: `float` - - - - Seedream-5.0-pro、5.0-lite、4.5、4.0、および seededit-3.0-i2i はこのパラメータをサポートします。 - -編集する画像の Base64 エンコーディングまたはアクセス可能な URL を入力します。Seedream-5.0-pro、5.0-lite、4.5、4.0 は単一の画像または複数の画像の入力に対応しています(複数画像のブレンド例を参照)。一方、seededit-3.0-i2i は単一画像の入力のみをサポートします。 - -• 画像URL: 画像URLがアクセス可能であることを確認してください。 -• Base64 エンコーディング: 形式は data:image/\;base64,\ である必要があります。注: \ は小文字である必要があります(例: data:image/png;base64,\)。 - -Comfy Router は、base64 の展開とすべての参照画像を含め、JSON リクエスト全体を 10 MiB に制限します。この転送制限を超える入力には URL を使用してください。 - -入力画像は次の要件を満たす必要があります: -• 画像フォーマット: jpeg、png(seedream-5.0-pro、5.0-lite、4.5、4.0 は webp、bmp、tiff、gif もサポート。seedream-5.0-pro はさらに heic、heif もサポート) -• アスペクト比(幅/高さ): seedream-5.0-pro、5.0-lite、4.5、4.0 では [1/16, 16] の範囲。seededit-3.0-i2i では [1/3, 3] -• 幅と高さ(px): > 14 -• サイズ: 10 MB 以下(seedream-5.0-pro は 30 MB) -• 総ピクセル数: seedream-5.0-pro では 6000x6000(36,000,000 px)以下 -• 参照画像は最大 14 枚(seedream-5.0-pro は 10 枚) - -レイヤー分離シナリオ(layer_decomposition が有効)では、image は必須で、単一の入力画像のみがサポートされます(複数の画像を渡すとエラーが返ります)。入力画像は png、jpeg、webp、bmp、tiff、gif のいずれかである必要があり(heic と heif はサポートされません)、最大 30 MB、総ピクセル数は [512x512, 6000x6000] の範囲、アスペクト比は [1/16, 16] の範囲である必要があります。 - - - - レイヤー分離を有効にするかどうかを制御します。このパラメータは seedream-5.0-pro のみがサポートします。 -true: レイヤー分離モード。モデルは単一の入力画像を 1 枚のベース画像と複数のレイヤー(最大 16)に分解し、生成された各レイヤーの位置とコンテンツ情報(重なり順(z_index)、バウンディングボックス(bounding_box)、名前(name)、説明(description))を返します。 -false: 標準の画像生成モード。レイヤー分離は実行されません。 -レイヤー分離モードに関する注意: 単一の入力画像のみがサポートされます(複数の画像を渡すとエラーが返ります)。いずれか 1 つのレイヤーの生成に失敗すると、リクエスト全体が失敗します。部分的な成功はサポートされません。返される画像は最大 17 枚(ベース画像 1 枚 + レイヤー 16 枚)です。sequential_image_generation、sequential_image_generation_options、tools、stream を渡すとエラーが返ります。 - - - - モデル識別子。サポートされるモデル: seedream-3-0-t2i-250415、seededit-3-0-i2i-250628、seedream-4-0-250828、seedream-4-5-251128、seedream-5-0-260128、seedream-5-0-pro-260628。直接の v1 呼び出し POST /proxy/byteplus/api/v3/images/generations では必ずこれを指定する必要があります。プロキシはそれ以外の値や省略された値を 400 で拒否します。これがこのスキーマの `required` リストに含まれていないのは、Comfy Router が /v2/models/byteplus/\{model} の `{model}` パスセグメントからこれを補完するためで、Router の呼び出し元は省略します。 - - - - プロンプト最適化機能の設定です。このパラメータは seedream-5.0-pro/5.0-lite/4.5(スタンダードモードのみサポート)および seedream-4.0 のみがサポートします。 - - - - プロンプト最適化機能のモードを設定します。standard = より高品質ですが生成時間が長くなります。fast = より高速ですが品質は平均的です。 - - 指定可能な値: `standard`、`fast` - - - - 出力画像のフォーマットを指定します。このパラメータは seedream-5.0-pro と 5.0-lite のみがサポートします。レイヤー分離シナリオでは、output_format はベース画像のフォーマットのみを制御し、各レイヤーは常に png で出力されます。 - - 指定可能な値: `png`、`jpeg` - - - - 画像の生成または変換のためのテキスト記述。 -レイヤー分離シナリオ(layer_decomposition を有効にした seedream-5.0-pro)では任意です。プロンプトを指定した場合、モデルはプロンプトの意図に従って指定された要素を認識して分離します。プロンプトを指定しない場合、モデルは画像内の主要な要素をすべて自動的に検出し、独立したレイヤーに分離します。 - - - - レスポンスで返される生成画像のフォーマットを指定します - - 指定可能な値: `url`、`b64_json` - - - - 画像生成のランダム性を制御するシードです。範囲: [-1, 2147483647]。指定しない場合はシードが自動的に生成されます。同じ出力を再現するには、同じシード値を使用してください。 - - 範囲: `-1` から `2147483647` - - - - バッチ生成機能を無効にするかどうかを制御します。このパラメータは seedream-5.0-lite、4.5、4.0 のみでサポートされます(seedream-5.0-pro ではサポートされません)。有効な値: -auto: 自動モードでは、モデルはユーザーのプロンプトに基づいて、複数の画像を返すかどうか、および何枚の画像を含めるかを自動的に判断します。 -disabled: バッチ生成機能を無効にします。モデルは 1 枚の画像のみを生成します。 - - 指定可能な値: `auto`、`disabled` - - - - seedream-5.0-lite、4.5、4.0 のみがこのパラメータをサポートします(seedream-5.0-pro ではサポートされません)。 -バッチ画像生成機能の設定です。このパラメータは sequential_image_generation が auto に設定されている場合にのみ有効です。 - - - - このリクエストで生成する画像の最大数を指定します。入力参照画像数 + 生成画像数 ≤ 15。 - - 範囲: `1` から `15` - - - - "seedream-3-0-t2i-250415": 生成画像の寸法(幅 x 高さ、ピクセル単位)を指定します。[512x512, 2048x2048] の範囲である必要があります。 -"seededit-3-0-i2i-250628": 生成画像の幅と高さのピクセルです。現在は adaptive のみをサポートします。 -"seedream-4-0-250828": 生成画像の仕様を設定します。2 つの方法が利用可能ですが、併用はできません。 - 方法 1 | 解像度を指定します。指定可能な値: 1K、2K、4K - 方法 2 | 幅と高さをピクセルで指定します。デフォルト: 2048x2048、総ピクセル数: [1024x1024, 4096x4096]、アスペクト比: [1/16, 16] -"seedream-4-5-251128": 2 つの方法が利用可能です。 - 方法 1 | 解像度を指定します。指定可能な値: 2K、4K - 方法 2 | 幅と高さをピクセルで指定します。デフォルト: 2048x2048、総ピクセル数: [2560x1440, 4096x4096]、アスペクト比: [1/16, 16] -"seedream-5-0-260128": 2 つの方法が利用可能です。 - 方法 1 | 解像度を指定します。指定可能な値: 2K、3K - 方法 2 | 幅と高さをピクセルで指定します。デフォルト: 2048x2048、総ピクセル数: [2560x1440, ~3072x3072]、アスペクト比: [1/16, 16] -"seedream-5-0-pro-260628": 2 つの方法が利用可能です(併用はできません)。 - 方法 1 | 解像度を指定し、プロンプトで画像のアスペクト比、形状、用途を記述します。最終的なサイズはモデルが決定します。指定可能な値: 1K、2K - 方法 2 | 幅と高さをピクセルで指定します。デフォルト: 1024x1024、総ピクセル数: [1024x1024 (1048576), 2048x2048 (4194304)]、アスペクト比: [1/16, 16] -layer_decomposition を有効にした "seedream-5-0-pro-260628": 解像度レベルの方法のみをサポートします。指定可能な値: 1K、1.5K、2K、auto。デフォルト: auto。 - ベース画像は、元の入力画像のアスペクト比を保ちながら、指定された解像度で出力されます。各レイヤーは指定された解像度に近いサイズで出力され、元の画像におけるアスペクト比を維持します。 - auto: 入力画像のサイズとアスペクト比に基づいて出力されます。[1280x720, ~2048x2048] の範囲内の入力は元の入力サイズで出力され、1K より小さい入力は 1K で出力され、2K より大きい入力は 2K で出力されます。 - - - - Comfy Router は完全な JSON 結果を取得するため、明示的に指定された stream フラグを false に固定します。v1 プロキシでは、このフィールドはストリーミング出力モードを有効にするかどうかを制御します。seedream-5.0-lite、4.5、4.0 のみがこのパラメータをサポートします(seedream-5.0-pro ではサポートされません)。false = すべての出力画像が一度に返されます。true = 各出力画像が生成後すぐに返されます。 - - - - 生成画像にウォーターマークを追加するかどうかを指定します。false = ウォーターマークなし、true = 「AI generated」ラベル付きのウォーターマークを追加 - - -Router が `GET /v2/models/byteplus/seededit-3-0-i2i-250628/openapi.json` で提供する schema から生成されています。これは、リクエストがプロバイダーに到達する前に呼び出しを検証する際に使用するドキュメントと同じものです。 -### 出力 - - - リクエストが作成された時刻を示す Unix タイムスタンプ(秒単位) - - - - 生成された画像の情報を含みます。 -レイヤー分離のシナリオでは、配列の最初の要素がベース画像(z_index=0)であり、以降の要素がレイヤーで、z_index の昇順で並びます。 - - - - Base64 エンコードされた画像データ(response_format が "b64_json" の場合) - - - - 現在のレイヤーがベース画像内で占める領域のバウンディングボックス情報。このフィールドを返すのはレイヤーのみで、ベース画像はキャンバス全体を覆うため bounding_box を返しません。layer_decomposition が true の場合にのみ返されます。 - - - - レイヤーのバウンディングボックスの絶対ピクセル座標。出力ベース画像の座標系で、左上隅が (0, 0) となります。座標の形式: [left, top, right, bottom]。 - - - - レイヤーのバウンディングボックスのパーミル量子化(正規化)座標。ベース画像のサイズに基づいて [0, 1000] の離散的な整数範囲に比例マッピングされ、最大 1000 で打ち切られます。座標の形式: [left, top, right, bottom]。 - - - - 現在の分離された要素の詳細な説明。name よりも豊富なレイヤーの特徴(色、状態、マテリアルなど)を提供します。このフィールドを返すのはレイヤーのみで、ベース画像は返しません。layer_decomposition が true の場合にのみ返されます。 - - - - 現在の分離された要素の名前/ラベル。分離された被写体の特徴からモデルが自動的に生成します。このフィールドを返すのはレイヤーのみで、ベース画像は返しません。layer_decomposition が true の場合にのみ返されます。 - - - - 出力画像のファイル形式。このフィールドをサポートするのは seedream-5.0-pro のみです。 - - - - 画像の幅と高さ(ピクセル単位)。形式は \x\ です。このパラメータをサポートするのは seedream-5.0-pro、5.0-lite、4.5、4.0 のみです。 - - - - 画像ダウンロード用の URL(response_format が "url" の場合) - - 形式: `uri` - - - - レイヤーの重ね順。下から上に向かって増加します。0 が最下層のレイヤー(ベース画像)で、値が大きいほど上に位置します。レイヤーを正しい重ね順で完全な画像に再構成するために使用します。layer_decomposition が true の場合にのみ返されます。 - - - - エラー情報(存在する場合) - - - - エラーコード - - - - エラーメッセージ - - - - リクエストに使用されたモデル ID - - - - - - - - モデルが生成した画像の数 - - - - モデルに入力された画像の数。このフィールドをサポートするのは seedream-5.0-pro のみです。 - - - - モデルが生成した画像に使用されたトークン数。 - - - - このリクエストで消費されたトークンの総数。 - - -## 例 - -### 入力 - -```json -{ - "prompt": "A red fox trotting through a snowy pine forest, cinematic lighting", - "response_format": "url", - "watermark": false -} -``` - -### 出力 - -```json -{ - "created": 1767225600, - "data": [ - { - "size": "1024x1024", - "url": "https://example.invalid/byteplus/seedream-3-0-t2i-250415/generated.png" - } - ], - "model": "seededit-3-0-i2i-250628", - "usage": { - "generated_images": 1 - } -} -``` - - - diff --git a/ja/development/comfy-router/models/byteplus/seedream-3-0-t2i-250415/code.mdx b/ja/development/comfy-router/models/byteplus/seedream-3-0-t2i-250415/code.mdx deleted file mode 100644 index 70b8a124bb..0000000000 --- a/ja/development/comfy-router/models/byteplus/seedream-3-0-t2i-250415/code.mdx +++ /dev/null @@ -1,390 +0,0 @@ ---- -title: "Comfy Router で Seedream 3.0 T2I 250415 を使用する" -description: "Comfy Router 経由で byteplus/seedream-3-0-t2i-250415 を呼び出します: エンドポイント、リクエスト形状、Router が返すレスポンスについて説明します。" -sidebarTitle: "Seedream 3.0 T2I 250415" -translationSourceHash: 18f23e78 -translationFrom: development/comfy-router/models/byteplus/seedream-3-0-t2i-250415/code.mdx -translationBlockHashes: - "_intro": dafe6167 - "Quick start": 16428856 - "Schema": c6abe2a5 - "Examples": 61ceb30b ---- -{/* GENERATED FILE. Generated from router-schemas/byteplus/seedream-3-0-t2i-250415.json by `pnpm code-pages:gen`. */} - -import RouterCodeFooter from "/snippets/ja/comfy-router/model-code-footer.mdx"; - -`byteplus/seedream-3-0-t2i-250415` の API リファレンスです。このモデルは BytePlus から Comfy Router によって提供されます。 - -## クイックスタート - -[Comfy ワークスペース](https://platform.comfy.org/profile/api-keys)でキーを作成し、`COMFY_API_KEY` としてエクスポートします。Python と TypeScript のスニペットは Comfy SDK(`pip install comfy-sdk`、`npm install @comfyorg/sdk`)を使用しています。cURL スニペットは同じ呼び出しを生の HTTP で行います。 - -**モデル ID:** `byteplus/seedream-3-0-t2i-250415` - -**エンドポイント:** `POST https://api.comfy.org/v2/models/byteplus/seedream-3-0-t2i-250415` - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# The SDK automatically creates an idempotency key and reuses it for automatic retries. -with Comfy() as client: - result = client.models.run( - "byteplus/seedream-3-0-t2i-250415", - { - "prompt": "A red fox trotting through a snowy pine forest, cinematic lighting", - "response_format": "url", - "watermark": False, - }, - ) - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// The SDK automatically creates an idempotency key and reuses it for automatic retries. -const { data } = await comfy.models.run("byteplus/seedream-3-0-t2i-250415", { - prompt: "A red fox trotting through a snowy pine forest, cinematic lighting", - response_format: "url", - watermark: false, -}); - -console.log(data); -``` - -```bash cURL -curl https://api.comfy.org/v2/models/byteplus/seedream-3-0-t2i-250415 \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"prompt\": \"A red fox trotting through a snowy pine forest, cinematic lighting\", \"response_format\": \"url\", \"watermark\": false}" -``` - - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -with Comfy() as client: - handle = client.models.submit( - "byteplus/seedream-3-0-t2i-250415", - { - "prompt": "A red fox trotting through a snowy pine forest, cinematic lighting", - "response_format": "url", - "watermark": False, - }, - ) - print("request_id:", handle.request_id) # with the model ID, all another process needs - - # Poll until the request completes, waiting the Retry-After the server names. - for update in handle.iter_events(): - print(update.status, update.queue_position) - - # The provider's own payload, the same value models.run() returns. - # A request that failed or was cancelled raises the typed Router error here. - result = handle.get() - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -const handle = await comfy.models.submit("byteplus/seedream-3-0-t2i-250415", { - prompt: "A red fox trotting through a snowy pine forest, cinematic lighting", - response_format: "url", - watermark: false, -}); -console.log("requestId:", handle.requestId); // with the model ID, all another process needs - -// Poll until the request completes, waiting the Retry-After the server names. -for await (const update of handle.events()) { - console.log(update.status, update.queuePosition); -} - -// The same result models.run() returns. A request that failed or was cancelled rejects here. -const result = await handle.get(); - -console.log(result.data); -``` - -```bash cURL -# 1. Submit. Router answers 201 with request_id, status_url, response_url and cancel_url. -curl https://api.comfy.org/v2/models/byteplus/seedream-3-0-t2i-250415/requests \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"prompt\": \"A red fox trotting through a snowy pine forest, cinematic lighting\", \"response_format\": \"url\", \"watermark\": false}" - -# 2. Poll until status is COMPLETED, waiting the Retry-After seconds each response names. -REQUEST_ID="" -curl -i https://api.comfy.org/v2/models/byteplus/seedream-3-0-t2i-250415/requests/$REQUEST_ID/status \ - -H "X-API-Key: $COMFY_API_KEY" - -# 3. Collect. 200 with the model's native output, 202 with the status body while it is still running. -curl https://api.comfy.org/v2/models/byteplus/seedream-3-0-t2i-250415/requests/$REQUEST_ID \ - -H "X-API-Key: $COMFY_API_KEY" -``` - - - - - -## スキーマ - -### 入力 - - - 出力画像が入力プロンプトにどれだけ忠実に従うかを制御します。範囲は [1, 10]。値が大きいほどプロンプトへの追従性が強くなります。seedream-3-0-t2i-250415 ではデフォルト 2.5、seededit-3-0-i2i-250628 では 5.5 です。seedream-5.0-pro、5.0-lite、4.5、4.0 ではサポートされません。 - - 範囲: `1` から `10` - - 形式: `float` - - - - seedream-5.0-pro、5.0-lite、4.5、4.0、および seededit-3.0-i2i がこのパラメータをサポートします。 - -編集する画像の Base64 エンコーディングまたはアクセス可能な URL を入力します。seedream-5.0-pro、5.0-lite、4.5、4.0 は単一画像または複数画像の入力に対応しています(複数画像のブレンド例を参照)。一方、seededit-3.0-i2i は単一画像の入力のみをサポートします。 - -• 画像URL: 画像URLがアクセス可能であることを確認してください。 -• Base64 エンコーディング: 形式は data:image/\;base64,\ でなければなりません。注意: \ は小文字である必要があります(例: data:image/png;base64,\)。 - -Comfy Router は base64 への展開やすべての参照画像を含め、JSON リクエスト全体を 10 MiB に制限します。この転送上限を超える入力には URL を使用してください。 - -入力画像は次の要件を満たす必要があります: -• 画像形式: jpeg、png(seedream-5.0-pro、5.0-lite、4.5、4.0 は webp、bmp、tiff、gif にも対応。seedream-5.0-pro は heic と heif にも対応) -• アスペクト比(幅/高さ): seedream-5.0-pro、5.0-lite、4.5、4.0 では [1/16, 16] の範囲。seededit-3.0-i2i では [1/3, 3] -• 幅と高さ(px): > 14 -• サイズ: 10 MB 以下(seedream-5.0-pro は 30 MB) -• 総ピクセル数: seedream-5.0-pro では 6000x6000(36,000,000 px)以下 -• 参照画像は最大 14 枚(seedream-5.0-pro は 10 枚) - -レイヤー分離シナリオ(layer_decomposition 有効)では、image は必須で、入力画像は 1 枚のみサポートされます(複数画像を渡すとエラーになります)。入力画像は png、jpeg、webp、bmp、tiff、gif のいずれかである必要があり(heic と heif はサポートされません)、最大 30 MB、総ピクセル数が [512x512, 6000x6000] の範囲、アスペクト比が [1/16, 16] の範囲でなければなりません。 - - - - レイヤー分離を有効にするかどうかを制御します。このパラメータは seedream-5.0-pro のみがサポートします。 -true: レイヤー分離モード。モデルは単一の入力画像を 1 枚のベース画像と複数のレイヤー(最大 16)に分解し、生成された各レイヤーの位置とコンテンツ情報を返します。これにはスタッキング順序(z_index)、バウンディングボックス(bounding_box)、名前(name)、説明(description)が含まれます。 -false: 標準の画像生成モード。レイヤー分離は実行されません。 -レイヤー分離モードに関する注意: 入力画像は 1 枚のみサポートされます(複数画像を渡すとエラーになります)。いずれかのレイヤーの生成が失敗すると、リクエスト全体が失敗します。部分的な成功はサポートされません。返される画像は最大 17 枚(ベース画像 1 枚 + レイヤー 16 枚)です。sequential_image_generation、sequential_image_generation_options、tools、stream を渡すとエラーになります。 - - - - モデル識別子。サポートされるモデル: seedream-3-0-t2i-250415、seededit-3-0-i2i-250628、seedream-4-0-250828、seedream-4-5-251128、seedream-5-0-260128、seedream-5-0-pro-260628。POST /proxy/byteplus/api/v3/images/generations への直接の v1 呼び出しでは必ずこれを指定する必要があります。プロキシはそれ以外の値や省略された値を 400 で拒否します。このスキーマの `required` リストに含まれていないのは、Comfy Router が /v2/models/byteplus/\{model} の `{model}` パスセグメントからこれを設定するためであり、Router の呼び出し元は省略します。 - - - - プロンプト最適化機能の設定。このパラメータは seedream-5.0-pro/5.0-lite/4.5(スタンダードモードのみをサポート)および seedream-4.0 のみがサポートします。 - - - - プロンプト最適化機能のモードを設定します。standard = より高品質ですが生成時間が長くなります。fast = 高速ですが品質は平均的です。 - - 取り得る値: `standard`, `fast` - - - - 出力画像の形式を指定します。このパラメータは seedream-5.0-pro と 5.0-lite のみがサポートします。レイヤー分離シナリオでは、output_format はベース画像の形式のみを制御し、すべてのレイヤーは常に png で出力されます。 - - 取り得る値: `png`, `jpeg` - - - - 画像生成または変換のためのテキスト記述。 -レイヤー分離シナリオ(layer_decomposition を有効にした seedream-5.0-pro)では省略可能です。プロンプトを指定した場合、モデルはプロンプトの意図に従って指定された要素を認識して分離します。プロンプトを指定しない場合、モデルは画像内の主要な要素をすべて自動的に検出し、独立したレイヤーに分離します。 - - - - レスポンスで返される生成画像の形式を指定します - - 取り得る値: `url`, `b64_json` - - - - 画像生成の確率性を制御するランダムシード。範囲: [-1, 2147483647]。指定しない場合、シードは自動的に生成されます。同じ出力を再現するには、同じシード値を使用してください。 - - 範囲: `-1` から `2147483647` - - - - バッチ生成機能を無効にするかどうかを制御します。このパラメータは seedream-5.0-lite、4.5、4.0 のみがサポートします(seedream-5.0-pro はサポートしません)。有効な値: -auto: 自動モードでは、モデルがユーザーのプロンプトに基づいて複数の画像を返すかどうか、および何枚の画像を含めるかを自動的に判断します。 -disabled: バッチ生成機能を無効にします。モデルは 1 枚の画像のみを生成します。 - - 取り得る値: `auto`, `disabled` - - - - このパラメータをサポートするのは seedream-5.0-lite、4.5、4.0 のみです(seedream-5.0-pro は非サポート)。 -バッチ画像生成機能の設定です。このパラメータは sequential_image_generation が auto に設定されている場合にのみ有効です。 - - - - このリクエストで生成する画像の最大数を指定します。入力参照画像数 + 生成画像数 ≤ 15。 - - 範囲: `1` から `15` - - - - "seedream-3-0-t2i-250415": 生成画像の寸法(幅 x 高さ、ピクセル単位)を指定します。[512x512, 2048x2048] の範囲内である必要があります -"seededit-3-0-i2i-250628": 生成画像の幅と高さのピクセル。現在は adaptive のみをサポートします。 -"seedream-4-0-250828": 生成画像の仕様を設定します。2 つの方法が利用できますが、併用はできません。 - 方法 1 | 解像度を指定します。指定可能な値: 1K、2K、4K - 方法 2 | 幅と高さをピクセルで指定します。デフォルト: 2048x2048、総ピクセル数: [1024x1024, 4096x4096]、アスペクト比: [1/16, 16] -"seedream-4-5-251128": 2 つの方法が利用できます。 - 方法 1 | 解像度を指定します。指定可能な値: 2K、4K - 方法 2 | 幅と高さをピクセルで指定します。デフォルト: 2048x2048、総ピクセル数: [2560x1440, 4096x4096]、アスペクト比: [1/16, 16] -"seedream-5-0-260128": 2 つの方法が利用できます。 - 方法 1 | 解像度を指定します。指定可能な値: 2K、3K - 方法 2 | 幅と高さをピクセルで指定します。デフォルト: 2048x2048、総ピクセル数: [2560x1440, ~3072x3072]、アスペクト比: [1/16, 16] -"seedream-5-0-pro-260628": 2 つの方法が利用できます(併用はできません)。 - 方法 1 | 解像度を指定し、画像のアスペクト比、形状、用途をプロンプトで記述します。最終的なサイズはモデルが決定します。指定可能な値: 1K、2K - 方法 2 | 幅と高さをピクセルで指定します。デフォルト: 1024x1024、総ピクセル数: [1024x1024 (1048576), 2048x2048 (4194304)]、アスペクト比: [1/16, 16] -"seedream-5-0-pro-260628" で layer_decomposition を有効にした場合: 解像度レベルの方法のみをサポートします。指定可能な値: 1K、1.5K、2K、auto。デフォルト: auto。 - ベース画像は、元の入力画像のアスペクト比で、指定された解像度で出力されます。各レイヤーは、元の画像でのアスペクト比を保ちながら、指定された解像度に近いサイズで出力されます。 - auto: 入力画像のサイズとアスペクト比に基づいて出力されます。[1280x720, ~2048x2048] 内の入力は元の入力サイズで出力され、1K より小さい入力は 1K で出力され、2K より大きい入力は 2K で出力されます。 - - - - Comfy Router は完全な JSON 結果を取得するため、明示的に指定された stream フラグを false に固定します。v1 プロキシでは、このフィールドはストリーミング出力モードを有効にするかどうかを制御します。このパラメータをサポートするのは seedream-5.0-lite、4.5、4.0 のみです(seedream-5.0-pro は非サポート)。false = すべての出力画像が一度に返されます。true = 各出力画像は生成され次第すぐに返されます。 - - - - 生成画像にウォーターマークを追加するかどうかを指定します。false = ウォーターマークなし、true = 'AI generated' ラベル付きのウォーターマークを追加 - - -Router が `GET /v2/models/byteplus/seedream-3-0-t2i-250415/openapi.json` で提供するスキーマから生成されています。これは、リクエストがプロバイダーに到達する前に Router が呼び出しを検証する際に使用するドキュメントと同じものです。 -### 出力 - - - リクエストが作成された時刻を示す Unix タイムスタンプ(秒単位) - - - - 生成された画像に関する情報を含みます。 -レイヤー分離のシナリオでは、配列の最初の要素がベース画像(z_index=0)で、以降の要素は z_index の昇順で並んだレイヤーです。 - - - - Base64 エンコードされた画像データ(response_format が "b64_json" の場合) - - - - 現在のレイヤーがベース画像内で占める領域のバウンディングボックス情報。このフィールドを返すのはレイヤーのみで、ベース画像はキャンバス全体を覆うため bounding_box を返しません。layer_decomposition が true の場合にのみ返されます。 - - - - レイヤーのバウンディングボックスの絶対ピクセル座標。出力ベース画像の座標系で、左上隅が (0, 0) です。座標形式: [left, top, right, bottom]。 - - - - レイヤーのバウンディングボックスのパーミル量子化(正規化)座標。ベース画像サイズに基づいて [0, 1000] の離散整数範囲に比例マッピングされ、最大 1000 で切り捨てられます。座標形式: [left, top, right, bottom]。 - - - - 現在の分離要素の詳細な説明。name よりも豊富なレイヤー特性(色、状態、マテリアルなど)を提供します。このフィールドを返すのはレイヤーのみで、ベース画像は返しません。layer_decomposition が true の場合にのみ返されます。 - - - - 現在の分離要素の名前/ラベル。分離された被写体の特徴からモデルが自動生成します。このフィールドを返すのはレイヤーのみで、ベース画像は返しません。layer_decomposition が true の場合にのみ返されます。 - - - - 出力画像のファイル形式。このフィールドをサポートするのは seedream-5.0-pro のみです。 - - - - 画像の幅と高さ(ピクセル単位)。形式は \x\。このパラメータをサポートするのは seedream-5.0-pro、5.0-lite、4.5、4.0 のみです。 - - - - 画像ダウンロード用の URL(response_format が "url" の場合) - - 形式: `uri` - - - - レイヤーの重なり順。下から上へ増加し、0 が最下層のレイヤー(ベース画像)で、値が大きいほど上に位置します。レイヤーを正しい重なり順で完全な画像に再構成するために使用します。layer_decomposition が true の場合にのみ返されます。 - - - - エラー情報(存在する場合) - - - - エラーコード - - - - エラーメッセージ - - - - リクエストに使用されたモデル ID - - - - - - - - モデルが生成した画像の数 - - - - モデルに入力された画像の数。このフィールドをサポートするのは seedream-5.0-pro のみです。 - - - - モデルが生成した画像に使用されたトークン数。 - - - - このリクエストで消費されたトークンの総数。 - - -## 例 - -### 入力 - -```json -{ - "prompt": "A red fox trotting through a snowy pine forest, cinematic lighting", - "response_format": "url", - "watermark": false -} -``` - -### 出力 - -```json -{ - "created": 1767225600, - "data": [ - { - "size": "1024x1024", - "url": "https://example.invalid/byteplus/seedream-3-0-t2i-250415/generated.png" - } - ], - "model": "seedream-3-0-t2i-250415", - "usage": { - "generated_images": 1 - } -} -``` - - diff --git a/ja/development/comfy-router/models/kling/kling-v1-5/code.mdx b/ja/development/comfy-router/models/kling/kling-v1-5/code.mdx deleted file mode 100644 index 407cf3ea8f..0000000000 --- a/ja/development/comfy-router/models/kling/kling-v1-5/code.mdx +++ /dev/null @@ -1,466 +0,0 @@ ---- -title: "Comfy Router で Kling V1.5 を使用する" -description: "Comfy Router 経由で kling/kling-v1-5 を呼び出します。endpoint、リクエスト形状、Router が返すレスポンスについて説明します。" -sidebarTitle: "Kling V1.5" -translationSourceHash: 7447a97c -translationFrom: development/comfy-router/models/kling/kling-v1-5/code.mdx -translationBlockHashes: - "_intro": f02fc14d - "Quick start": 31463fb0 - "Schema": d81409e3 - "Examples": e835e733 ---- -{/* 生成済みファイル。router-schemas/kling/kling-v1-5.json から `pnpm code-pages:gen` によって生成されています。 */} - -import RouterCodeFooter from "/snippets/ja/comfy-router/model-code-footer.mdx"; - -`kling/kling-v1-5` の API リファレンス。Comfy Router が Kling から提供しています。 - -## クイックスタート - -[Comfy ワークスペース](https://platform.comfy.org/profile/api-keys)でキーを作成し、`COMFY_API_KEY` としてエクスポートします。Python と TypeScript のスニペットは Comfy SDK(`pip install comfy-sdk`、`npm install @comfyorg/sdk`)を使用します。cURL のスニペットは、生の HTTP で同じ呼び出しを行います。 - -**モデル ID:** `kling/kling-v1-5` - -**エンドポイント:** `POST https://api.comfy.org/v2/models/kling/kling-v1-5` - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# The SDK automatically creates an idempotency key and reuses it for automatic retries. -with Comfy() as client: - result = client.models.run( - "kling/kling-v1-5", - { - "duration": "5", - "image": "https://example.invalid/kling/reference.png", - "mode": "std", - "prompt": "The fox turns its head towards the camera.", - }, - ) - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// The SDK automatically creates an idempotency key and reuses it for automatic retries. -const { data } = await comfy.models.run("kling/kling-v1-5", { - duration: "5", - image: "https://example.invalid/kling/reference.png", - mode: "std", - prompt: "The fox turns its head towards the camera.", -}); - -console.log(data); -``` - -```bash cURL -curl https://api.comfy.org/v2/models/kling/kling-v1-5 \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"duration\": \"5\", \"image\": \"https://example.invalid/kling/reference.png\", \"mode\": \"std\", \"prompt\": \"The fox turns its head towards the camera.\"}" -``` - - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -with Comfy() as client: - handle = client.models.submit( - "kling/kling-v1-5", - { - "duration": "5", - "image": "https://example.invalid/kling/reference.png", - "mode": "std", - "prompt": "The fox turns its head towards the camera.", - }, - ) - print("request_id:", handle.request_id) # with the model ID, all another process needs - - # Poll until the request completes, waiting the Retry-After the server names. - for update in handle.iter_events(): - print(update.status, update.queue_position) - - # The provider's own payload, the same value models.run() returns. - # A request that failed or was cancelled raises the typed Router error here. - result = handle.get() - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -const handle = await comfy.models.submit("kling/kling-v1-5", { - duration: "5", - image: "https://example.invalid/kling/reference.png", - mode: "std", - prompt: "The fox turns its head towards the camera.", -}); -console.log("requestId:", handle.requestId); // with the model ID, all another process needs - -// Poll until the request completes, waiting the Retry-After the server names. -for await (const update of handle.events()) { - console.log(update.status, update.queuePosition); -} - -// The same result models.run() returns. A request that failed or was cancelled rejects here. -const result = await handle.get(); - -console.log(result.data); -``` - -```bash cURL -# 1. Submit. Router answers 201 with request_id, status_url, response_url and cancel_url. -curl https://api.comfy.org/v2/models/kling/kling-v1-5/requests \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"duration\": \"5\", \"image\": \"https://example.invalid/kling/reference.png\", \"mode\": \"std\", \"prompt\": \"The fox turns its head towards the camera.\"}" - -# 2. Poll until status is COMPLETED, waiting the Retry-After seconds each response names. -REQUEST_ID="" -curl -i https://api.comfy.org/v2/models/kling/kling-v1-5/requests/$REQUEST_ID/status \ - -H "X-API-Key: $COMFY_API_KEY" - -# 3. Collect. 200 with the model's native output, 202 with the status body while it is still running. -curl https://api.comfy.org/v2/models/kling/kling-v1-5/requests/$REQUEST_ID \ - -H "X-API-Key: $COMFY_API_KEY" -``` - - - - - -## スキーマ - -### 入力 - - - コールバック通知アドレス。タスクのステータスが変化したときにサーバーが通知します。 - - 形式: `uri` - - - - - - - - - - - - カメラの水平軸(x軸)に沿った移動を制御します。負の値は左、正の値は右を示します。 - - 範囲: `-10` から `10` - - - - 垂直面内でのカメラの回転(x軸)を制御します。負の値は下向きの回転、正の値は上向きの回転を示します。 - - 範囲: `-10` から `10` - - - - カメラのロール量(z軸)を制御します。負の値は反時計回り、正の値は時計回りを示します。 - - 範囲: `-10` から `10` - - - - 水平面内でのカメラの回転(y軸)を制御します。負の値は左への回転、正の値は右への回転を示します。 - - 範囲: `-10` から `10` - - - - カメラの垂直軸(y軸)に沿った移動を制御します。負の値は下、正の値は上を示します。 - - 範囲: `-10` から `10` - - - - カメラの焦点距離の変化を制御します。負の値は画角が狭くなること、正の値は画角が広くなることを示します。 - - 範囲: `-10` から `10` - - - - 定義済みのカメラ動作タイプ。simple: カスタマイズ可能なカメラ動作。down_back: カメラが下降して後方に移動します。forward_up: カメラが前方に移動して上にチルトします。right_turn_forward: 右に回転して前方に移動します。left_turn_forward: 左に回転して前方に移動します。 - - 指定可能な値: `simple`、`down_back`、`forward_up`、`right_turn_forward`、`left_turn_forward` - - - - ビデオ生成における柔軟性。値が高いほど、モデルの柔軟性が低くなり、ユーザーのプロンプトとの関連性が強くなります。 - - 範囲: `0` から `1` - - 形式: `float` - - - - ビデオの長さ(秒) - - 指定可能な値: `3`、`4`、`5`、`6`、`7`、`8`、`9`、`10`、`11`、`12`、`13`、`14`、`15` - - - - 動的ブラシ設定リスト(最大6グループ)。5秒のビデオの場合、軌跡の長さは77座標を超えてはなりません。 - - - - 動的ブラシの適用領域(ユーザーがモーションブラシで作成したマスク画像)。アスペクト比は入力画像と一致している必要があります。 - - 形式: `uri` - - - - - - - - 軌跡ポイントの水平座標。画像の左下隅を原点(0,0)とします。 - - - - 軌跡ポイントの垂直座標。画像の左下隅を原点(0,0)とします。 - - - - 要素IDの設定に基づく参照要素リスト。最大3つの参照要素をサポートします。element_list パラメータと voice_list パラメータは同時に使用できません。 - - - - 要素ID - - 形式: `int64` - - - - カスタマイズされたタスクID。単一のユーザーアカウント内で一意である必要があります。 - - - - 参照画像 - URL または Base64 エンコード文字列。10MB を超えることはできず、解像度は 300*300px 以上、アスペクト比は 1:2.5 ~ 2.5:1 の範囲である必要があります。Base64 には data:image プレフィックスを含めないでください。 - - - - 参照画像 - 終了フレーム制御。URL または Base64 エンコード文字列。10MB を超えることはできず、解像度は 300*300px 以上である必要があります。Base64 には data:image プレフィックスを含めないでください。dynamic_masks/static_mask または camera_control と同時に使用することはできません。 - - - - ビデオ生成モード。std: スタンダードモード。コスト効率に優れています。pro: プロフェッショナルモード。より長い再生時間のビデオを生成しますが、出力品質は高くなります。 - - 指定可能な値: `std`、`pro` - - - - モデル名。Comfy Router を使用する場合は省略するか null を送信してください。モデルはリクエストパスによって選択されます。名前を指定する場合はそのパスと一致している必要があります。 - - - - 各ストーリーボードに関する情報(プロンプトや再生時間など)。最大6つのストーリーボードをサポートし、最低1つ必要です。multi_shot が true かつ shot_type が customize の場合に必須です。 - - - - このストーリーボードの再生時間(秒)。タスク全体の再生時間を超えてはならず、1未満であってはなりません。すべてのストーリーボードの再生時間の合計は、タスク全体の再生時間と等しくなります。 - - - - ショットの連番 - - - - このストーリーボードのプロンプトワード。最大長は512文字です。 - - - - マルチショットビデオを生成するかどうか。true の場合、prompt パラメータは無効になります。false の場合、shot_type および multi_prompt パラメータは無効になります。 - - - - Negative text prompt. It is recommended to supplement negative prompt information through negative sentences directly within positive prompts. - - - - Positive text prompt. Use \<\<\>> to specify a voice matching the voice_list parameter order. A task can reference up to 2 tones. When specifying a tone, the sound parameter value must be on. - - - - Storyboard method. Required when the multi_shot parameter is set to true. - - Possible values: `customize`, `intelligence` - - - - Whether to generate sound simultaneously when generating videos. Only V2.6 and subsequent versions of the model support this parameter. - - Possible values: `on`, `off` - - - - Static Brush Application Area (Mask image created by users using the motion brush). The aspect ratio must match the input image. - - - - List of voices referenced when generating videos. Supports up to 2 voices. The element_list and voice_list parameters are mutually exclusive. - - - - Voice ID returned through the voice customization API or a system preset voice ID. - - - - Whether to generate watermarked results simultaneously. Custom watermark is not supported at this time. - - - - true means generate watermark, false means do not generate. - - -Generated from the schema Router serves at `GET /v2/models/kling/kling-v1-5/openapi.json`, the same document it validates a call against before the request reaches the provider. -### 出力 - - - エラーコード - - - - - - - - タスク作成時間、Unix タイムスタンプ(ミリ秒) - - - - タスクの控除ユニット数 - - - - タスク ID - - - - - - - - - - - - - - - - - - - - ビデオの合計再生時間(秒) - - - - 生成済みビデオ ID - - - - 生成済みビデオの URL - - 形式: `uri` - - - - ウォーターマーク付きの生成済みビデオの URL、直リンク防止形式 - - 形式: `uri` - - - - タスクステータス - - 取り得る値: `submitted`、`processing`、`succeed`、`failed` - - - - タスクステータス情報。タスク失敗時には失敗理由を表示します - - - - タスク更新時間、Unix タイムスタンプ(ミリ秒) - - - - - - - - - - - - エラーメッセージ - - - - リクエスト ID - - -## 実行例 - -### 入力 - -```json -{ - "duration": "5", - "image": "https://example.invalid/kling/reference.png", - "mode": "std", - "prompt": "The fox turns its head towards the camera." -} -``` - -### 出力 - -```json -{ - "code": 0, - "data": { - "created_at": 1798761600000, - "task_id": "kling-task-1a2b3c4d5e6f", - "task_result": { - "videos": [ - { - "duration": "5", - "id": "kling-video-6f5e4d3c2b1a", - "url": "https://example.invalid/kling/kling-v1/generated.mp4" - } - ] - }, - "task_status": "succeed", - "task_status_msg": "", - "updated_at": 1798761840000 - }, - "message": "SUCCEED", - "request_id": "9f2c1a04-7b6e-4d38-8a51-3c0e7d9b2f46" -} -``` - - diff --git a/ja/development/comfy-router/models/kling/kling-v1-6/code.mdx b/ja/development/comfy-router/models/kling/kling-v1-6/code.mdx deleted file mode 100644 index 44692ac178..0000000000 --- a/ja/development/comfy-router/models/kling/kling-v1-6/code.mdx +++ /dev/null @@ -1,420 +0,0 @@ ---- -title: "Comfy Router で Kling V1.6 を使用する" -description: "Comfy Router 経由で kling/kling-v1-6 を呼び出します: エンドポイント、リクエストの形状、Router が返すレスポンスについて説明します。" -sidebarTitle: "Kling V1.6" -translationSourceHash: 4e28fa7d -translationFrom: development/comfy-router/models/kling/kling-v1-6/code.mdx -translationBlockHashes: - "_intro": e5d8f71a - "Quick start": 77975fae - "Schema": ffd91cca - "Examples": 14429ff8 ---- -{/* GENERATED FILE. Generated from router-schemas/kling/kling-v1-6.json by `pnpm code-pages:gen`. */} - -import RouterCodeFooter from "/snippets/ja/comfy-router/model-code-footer.mdx"; - -Comfy Router が Kling から提供する `kling/kling-v1-6` の API リファレンスです。 - -## クイックスタート - -[Comfy ワークスペース](https://platform.comfy.org/profile/api-keys)でキーを作成し、`COMFY_API_KEY` としてエクスポートします。Python と TypeScript のスニペットは Comfy SDK(`pip install comfy-sdk`、`npm install @comfyorg/sdk`)を使用しており、cURL のスニペットは同じ呼び出しを生の HTTP で行うものです。 - -**モデル ID:** `kling/kling-v1-6` - -**エンドポイント:** `POST https://api.comfy.org/v2/models/kling/kling-v1-6` - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# The SDK automatically creates an idempotency key and reuses it for automatic retries. -with Comfy() as client: - result = client.models.run( - "kling/kling-v1-6", - { - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting.", - }, - ) - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// The SDK automatically creates an idempotency key and reuses it for automatic retries. -const { data } = await comfy.models.run("kling/kling-v1-6", { - aspect_ratio: "16:9", - duration: "5", - mode: "std", - prompt: "A red fox trotting through falling snow, cinematic lighting.", -}); - -console.log(data); -``` - -```bash cURL -curl https://api.comfy.org/v2/models/kling/kling-v1-6 \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"aspect_ratio\": \"16:9\", \"duration\": \"5\", \"mode\": \"std\", \"prompt\": \"A red fox trotting through falling snow, cinematic lighting.\"}" -``` - - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -with Comfy() as client: - handle = client.models.submit( - "kling/kling-v1-6", - { - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting.", - }, - ) - print("request_id:", handle.request_id) # with the model ID, all another process needs - - # Poll until the request completes, waiting the Retry-After the server names. - for update in handle.iter_events(): - print(update.status, update.queue_position) - - # The provider's own payload, the same value models.run() returns. - # A request that failed or was cancelled raises the typed Router error here. - result = handle.get() - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -const handle = await comfy.models.submit("kling/kling-v1-6", { - aspect_ratio: "16:9", - duration: "5", - mode: "std", - prompt: "A red fox trotting through falling snow, cinematic lighting.", -}); -console.log("requestId:", handle.requestId); // with the model ID, all another process needs - -// Poll until the request completes, waiting the Retry-After the server names. -for await (const update of handle.events()) { - console.log(update.status, update.queuePosition); -} - -// The same result models.run() returns. A request that failed or was cancelled rejects here. -const result = await handle.get(); - -console.log(result.data); -``` - -```bash cURL -# 1. Submit. Router answers 201 with request_id, status_url, response_url and cancel_url. -curl https://api.comfy.org/v2/models/kling/kling-v1-6/requests \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"aspect_ratio\": \"16:9\", \"duration\": \"5\", \"mode\": \"std\", \"prompt\": \"A red fox trotting through falling snow, cinematic lighting.\"}" - -# 2. Poll until status is COMPLETED, waiting the Retry-After seconds each response names. -REQUEST_ID="" -curl -i https://api.comfy.org/v2/models/kling/kling-v1-6/requests/$REQUEST_ID/status \ - -H "X-API-Key: $COMFY_API_KEY" - -# 3. Collect. 200 with the model's native output, 202 with the status body while it is still running. -curl https://api.comfy.org/v2/models/kling/kling-v1-6/requests/$REQUEST_ID \ - -H "X-API-Key: $COMFY_API_KEY" -``` - - - - - -## Schema - -### 入力 - - - ビデオのアスペクト比 - - 指定可能な値: `16:9`、`9:16`、`1:1` - - - - コールバック通知先アドレス - - フォーマット: `uri` - - - - - - - - - - - - カメラの水平軸 (x軸) に沿った移動を制御します。負の値は左、正の値は右を示します。 - - 範囲: `-10` から `10` - - - - 垂直面内でのカメラの回転 (x軸) を制御します。負の値は下向きの回転、正の値は上向きの回転を示します。 - - 範囲: `-10` から `10` - - - - カメラのロール量 (z軸) を制御します。負の値は反時計回り、正の値は時計回りを示します。 - - 範囲: `-10` から `10` - - - - 水平面内でのカメラの回転 (y軸) を制御します。負の値は左回転、正の値は右回転を示します。 - - 範囲: `-10` から `10` - - - - カメラの垂直軸 (y軸) に沿った移動を制御します。負の値は下、正の値は上を示します。 - - 範囲: `-10` から `10` - - - - カメラの焦点距離の変化を制御します。負の値は画角が狭くなり、正の値は画角が広くなります。 - - 範囲: `-10` から `10` - - - - 定義済みのカメラムーブメントの種類。simple: カスタマイズ可能なカメラムーブメント。down_back: カメラが下降しながら後退します。forward_up: カメラが前進しながら上にチルトします。right_turn_forward: 右に回転して前進します。left_turn_forward: 左に回転して前進します。 - - 指定可能な値: `simple`、`down_back`、`forward_up`、`right_turn_forward`、`left_turn_forward` - - - - ビデオ生成における柔軟性。値が高いほどモデルの柔軟性が低くなり、ユーザーのプロンプトとの関連性が強くなります。 - - 範囲: `0` から `1` - - フォーマット: `float` - - - - ビデオの長さ (秒) - - 指定可能な値: `3`、`4`、`5`、`6`、`7`、`8`、`9`、`10`、`11`、`12`、`13`、`14`、`15` - - - - カスタムタスク ID - - - - ビデオ生成モード。std: スタンダードモード。コスト効率に優れています。pro: プロフェッショナルモード。より長い再生時間のビデオを生成しますが、出力品質は高くなります。 - - 指定可能な値: `std`、`pro` - - - - モデル名。Comfy Router を使用する場合は省略するか null を送信してください。モデルはリクエストパスによって選択されます。名前を指定する場合は、そのパスと一致している必要があります。 - - - - 各ストーリーボードに関する情報 (プロンプトや再生時間など)。最大 6 つのストーリーボードをサポートし、最小 1 つ必要です。multi_shot が true かつ shot_type が customize の場合に必須です。 - - - - このストーリーボードの再生時間 (秒)。タスク全体の再生時間を超えてはならず、1 未満であってはなりません。すべてのストーリーボードの再生時間の合計は、タスク全体の再生時間と等しくなります。 - - - - ショットの順序番号 - - - - このストーリーボードのプロンプトワード。最大長 512 文字。 - - - - マルチショットビデオを生成するかどうか。true の場合、prompt パラメータは無効です。false の場合、shot_type および multi_prompt パラメータは無効です。 - - - - ネガティブテキストプロンプト。ネガティブプロンプトの情報は、ポジティブプロンプト内に直接ネガティブな文として補足することを推奨します。 - - - - ポジティブテキストプロンプト。voice_list パラメータの順序に対応する音声を指定するには \<\<\>> を使用します。1 つのタスクで参照できるトーンは最大 2 つです。トーンを指定する場合、sound パラメータの値は on にする必要があります。 - - - - ストーリーボードの方法。multi_shot パラメータが true に設定されている場合に必須です。 - - 指定可能な値: `customize`、`intelligence` - - - - ビデオ生成時に同時にサウンドを生成するかどうか。このパラメータをサポートするのはモデルの V2.6 以降のバージョンのみです。 - - 指定可能な値: `on`、`off` - - - - ウォーターマーク付きの結果を同時に生成するかどうか。現時点ではカスタムウォーターマークはサポートされていません。 - - - - true はウォーターマークを生成する、false は生成しないことを示します。 - - -Router が `GET /v2/models/kling/kling-v1-6/openapi.json` で提供するスキーマから生成されています。これは、リクエストがプロバイダーに到達する前に呼び出しを検証する際に使用されるものと同じドキュメントです。 -### 出力 - - - エラーコード - - - - - - - - タスク作成時間、Unix タイムスタンプ(ミリ秒) - - - - タスクの控除ユニット数 - - - - タスク ID - - - - - - - - - - - - - - - - - - - - ビデオの合計再生時間(秒) - - - - 生成済みビデオの ID - - - - 生成済みビデオの URL - - 形式: `uri` - - - - ウォーターマーク付きの生成済みビデオの URL(直リンク防止形式) - - 形式: `uri` - - - - タスクステータス - - 指定可能な値: `submitted`、`processing`、`succeed`、`failed` - - - - タスクステータス情報。タスクが失敗した場合は失敗理由が表示されます - - - - タスク更新時間、Unix タイムスタンプ(ミリ秒) - - - - - - - - - - - - エラーメッセージ - - - - リクエスト ID - - -## 例 - -### 入力 - -```json -{ - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting." -} -``` - -### 出力 - -```json -{ - "code": 0, - "data": { - "created_at": 1798761600000, - "task_id": "kling-task-1a2b3c4d5e6f", - "task_result": { - "videos": [ - { - "duration": "5", - "id": "kling-video-6f5e4d3c2b1a", - "url": "https://example.invalid/kling/kling-v1/generated.mp4" - } - ] - }, - "task_status": "succeed", - "task_status_msg": "", - "updated_at": 1798761840000 - }, - "message": "SUCCEED", - "request_id": "9f2c1a04-7b6e-4d38-8a51-3c0e7d9b2f46" -} -``` - - diff --git a/ja/development/comfy-router/models/kling/kling-v1/code.mdx b/ja/development/comfy-router/models/kling/kling-v1/code.mdx deleted file mode 100644 index c88a5b772e..0000000000 --- a/ja/development/comfy-router/models/kling/kling-v1/code.mdx +++ /dev/null @@ -1,421 +0,0 @@ ---- -title: "Kling V1 を Comfy Router で使用する" -description: "Comfy Router 経由で kling/kling-v1 を呼び出します: エンドポイント、リクエスト形状、Router が返すレスポンスについて説明します。" -sidebarTitle: "Kling V1" -translationSourceHash: 49bc09b7 -translationFrom: development/comfy-router/models/kling/kling-v1/code.mdx -translationBlockHashes: - "_intro": 88237ef1 - "Quick start": 25cc5cf0 - "Schema": 16c4273c - "Examples": 14429ff8 ---- -{/* 生成済みファイル。`pnpm code-pages:gen` により router-schemas/kling/kling-v1.json から生成されました。 */} - -import RouterCodeFooter from "/snippets/ja/comfy-router/model-code-footer.mdx"; - -`kling/kling-v1` の API リファレンス。Comfy Router が Kling から提供しています。 - -## クイックスタート - -[Comfy ワークスペース](https://platform.comfy.org/profile/api-keys)でキーを作成し、`COMFY_API_KEY` としてエクスポートします。Python と TypeScript のスニペットは Comfy SDK(`pip install comfy-sdk`、`npm install @comfyorg/sdk`)を使用しています。cURL のスニペットは、同じ呼び出しを生の HTTP で行うものです。 - -**モデル ID:** `kling/kling-v1` - -**エンドポイント:** `POST https://api.comfy.org/v2/models/kling/kling-v1` - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# The SDK automatically creates an idempotency key and reuses it for automatic retries. -with Comfy() as client: - result = client.models.run( - "kling/kling-v1", - { - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting.", - }, - ) - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// The SDK automatically creates an idempotency key and reuses it for automatic retries. -const { data } = await comfy.models.run("kling/kling-v1", { - aspect_ratio: "16:9", - duration: "5", - mode: "std", - prompt: "A red fox trotting through falling snow, cinematic lighting.", -}); - -console.log(data); -``` - -```bash cURL -curl https://api.comfy.org/v2/models/kling/kling-v1 \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"aspect_ratio\": \"16:9\", \"duration\": \"5\", \"mode\": \"std\", \"prompt\": \"A red fox trotting through falling snow, cinematic lighting.\"}" -``` - - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -with Comfy() as client: - handle = client.models.submit( - "kling/kling-v1", - { - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting.", - }, - ) - print("request_id:", handle.request_id) # with the model ID, all another process needs - - # Poll until the request completes, waiting the Retry-After the server names. - for update in handle.iter_events(): - print(update.status, update.queue_position) - - # The provider's own payload, the same value models.run() returns. - # A request that failed or was cancelled raises the typed Router error here. - result = handle.get() - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -const handle = await comfy.models.submit("kling/kling-v1", { - aspect_ratio: "16:9", - duration: "5", - mode: "std", - prompt: "A red fox trotting through falling snow, cinematic lighting.", -}); -console.log("requestId:", handle.requestId); // with the model ID, all another process needs - -// Poll until the request completes, waiting the Retry-After the server names. -for await (const update of handle.events()) { - console.log(update.status, update.queuePosition); -} - -// The same result models.run() returns. A request that failed or was cancelled rejects here. -const result = await handle.get(); - -console.log(result.data); -``` - -```bash cURL -# 1. Submit. Router answers 201 with request_id, status_url, response_url and cancel_url. -curl https://api.comfy.org/v2/models/kling/kling-v1/requests \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"aspect_ratio\": \"16:9\", \"duration\": \"5\", \"mode\": \"std\", \"prompt\": \"A red fox trotting through falling snow, cinematic lighting.\"}" - -# 2. Poll until status is COMPLETED, waiting the Retry-After seconds each response names. -REQUEST_ID="" -curl -i https://api.comfy.org/v2/models/kling/kling-v1/requests/$REQUEST_ID/status \ - -H "X-API-Key: $COMFY_API_KEY" - -# 3. Collect. 200 with the model's native output, 202 with the status body while it is still running. -curl https://api.comfy.org/v2/models/kling/kling-v1/requests/$REQUEST_ID \ - -H "X-API-Key: $COMFY_API_KEY" -``` - - - - - -## スキーマ - -### 入力 - - - ビデオのアスペクト比 - - 指定可能な値: `16:9`, `9:16`, `1:1` - - - - コールバック通知先アドレス - - フォーマット: `uri` - - - - - - - - - - - - カメラの水平軸(x軸)に沿った動きを制御します。負の値は左、正の値は右を示します。 - - 範囲: `-10` から `10` - - - - 垂直面内でのカメラの回転(x軸)を制御します。負の値は下向きの回転、正の値は上向きの回転を示します。 - - 範囲: `-10` から `10` - - - - カメラのロール量(z軸)を制御します。負の値は反時計回り、正の値は時計回りを示します。 - - 範囲: `-10` から `10` - - - - 水平面内でのカメラの回転(y軸)を制御します。負の値は左回転、正の値は右回転を示します。 - - 範囲: `-10` から `10` - - - - カメラの垂直軸(y軸)に沿った動きを制御します。負の値は下方向、正の値は上方向を示します。 - - 範囲: `-10` から `10` - - - - カメラの焦点距離の変化を制御します。負の値は画角が狭くなること、正の値は画角が広くなることを示します。 - - 範囲: `-10` から `10` - - - - 定義済みのカメラ動作タイプ。simple: カスタマイズ可能なカメラ動作。down_back: カメラが下降して後方へ移動します。forward_up: カメラが前進して上にチルトします。right_turn_forward: 右に回転して前進します。left_turn_forward: 左に回転して前進します。 - - 指定可能な値: `simple`, `down_back`, `forward_up`, `right_turn_forward`, `left_turn_forward` - - - - ビデオ生成における柔軟性。値が高いほどモデルの柔軟性が低くなり、ユーザーのプロンプトとの関連性が強くなります。 - - 範囲: `0` から `1` - - フォーマット: `float` - - - - ビデオの再生時間(秒) - - 指定可能な値: `3`, `4`, `5`, `6`, `7`, `8`, `9`, `10`, `11`, `12`, `13`, `14`, `15` - - - - カスタムタスクID - - - - ビデオ生成モード。std: スタンダードモード。コスト効率が高い。pro: プロフェッショナルモード。より長い再生時間のビデオを生成しますが、出力品質が高くなります。 - - 指定可能な値: `std`, `pro` - - - - モデル名。Comfy Router を使用する場合は省略するか null を送信します。モデルはリクエストパスによって選択されます。名前を指定する場合は、そのパスと一致している必要があります。 - - - - 各ストーリーボードに関する情報(プロンプトや再生時間など)。最大6つのストーリーボードをサポートし、最小1つです。multi_shot が true で shot_type が customize の場合に必須です。 - - - - このストーリーボードの再生時間(秒)。タスク全体の再生時間を超えてはならず、1以上である必要があります。すべてのストーリーボードの再生時間の合計は、タスク全体の再生時間と等しくなります。 - - - - ショットのシーケンス番号 - - - - このストーリーボードのプロンプトワード。最大長は512文字です。 - - - - マルチショットビデオを生成するかどうか。true の場合、prompt パラメータは無効です。false の場合、shot_type と multi_prompt パラメータは無効です。 - - - - ネガティブテキストプロンプト。ネガティブプロンプトの情報は、ポジティブプロンプト内に直接ネガティブな文で補うことを推奨します。 - - - - ポジティブテキストプロンプト。\<\<\>> を使用して、voice_list パラメータの順序に対応する音声を指定します。1つのタスクで参照できるトーンは最大2つです。トーンを指定する場合、sound パラメータの値は on である必要があります。 - - - - ストーリーボード方法。multi_shot パラメータが true に設定されている場合に必須です。 - - 指定可能な値: `customize`, `intelligence` - - - - ビデオ生成時に同時にサウンドを生成するかどうか。このパラメータをサポートするのはモデルの V2.6 以降のバージョンのみです。 - - 指定可能な値: `on`, `off` - - - - 透かし入りの結果を同時に生成するかどうか。現時点ではカスタム透かしはサポートされていません。 - - - - true は透かしを生成する、false は生成しないことを意味します。 - - -`GET /v2/models/kling/kling-v1/openapi.json` で Router が提供するスキーマから生成されています。これは、リクエストがプロバイダーに到達する前に Router が呼び出しを検証する際に使用するドキュメントと同じです。 -### 出力 - - - エラーコード - - - - - - - - タスク作成時間、Unix タイムスタンプ(ミリ秒) - - - - タスクの控除単位 - - - - タスク ID - - - - - - - - - - - - - - - - - - - - ビデオの総再生時間(秒) - - - - 生成済みビデオ ID - - - - 生成済みビデオの URL - - 形式: `uri` - - - - ウォーターマーク付き生成済みビデオの URL、直リンク防止形式 - - 形式: `uri` - - - - タスクステータス - - 取り得る値: `submitted`、`processing`、`succeed`、`failed` - - - - タスクステータス情報。タスク失敗時に失敗理由を表示します - - - - タスク更新時間、Unix タイムスタンプ(ミリ秒) - - - - - - - - - - - - エラーメッセージ - - - - リクエスト ID - - -## 例 - -### 入力 - -```json -{ - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting." -} -``` - -### 出力 - -```json -{ - "code": 0, - "data": { - "created_at": 1798761600000, - "task_id": "kling-task-1a2b3c4d5e6f", - "task_result": { - "videos": [ - { - "duration": "5", - "id": "kling-video-6f5e4d3c2b1a", - "url": "https://example.invalid/kling/kling-v1/generated.mp4" - } - ] - }, - "task_status": "succeed", - "task_status_msg": "", - "updated_at": 1798761840000 - }, - "message": "SUCCEED", - "request_id": "9f2c1a04-7b6e-4d38-8a51-3c0e7d9b2f46" -} -``` - - - diff --git a/ja/development/comfy-router/models/kling/kling-v2-1-master/code.mdx b/ja/development/comfy-router/models/kling/kling-v2-1-master/code.mdx deleted file mode 100644 index 60a5351c1d..0000000000 --- a/ja/development/comfy-router/models/kling/kling-v2-1-master/code.mdx +++ /dev/null @@ -1,421 +0,0 @@ ---- -title: "Comfy Router で Kling V2.1 Master を使用する" -description: "Comfy Router 経由で kling/kling-v2-1-master を呼び出します: エンドポイント、リクエスト形状、Router が返すレスポンスについて説明します。" -sidebarTitle: "Kling V2.1 Master" -translationSourceHash: 4f57933f -translationFrom: development/comfy-router/models/kling/kling-v2-1-master/code.mdx -translationBlockHashes: - "_intro": a94d25f9 - "Quick start": 57640f5d - "Schema": 3d3492a4 - "Examples": 14429ff8 ---- -{/* 生成済みファイル。`pnpm code-pages:gen` により router-schemas/kling/kling-v2-1-master.json から生成されました。 */} - -import RouterCodeFooter from "/snippets/ja/comfy-router/model-code-footer.mdx"; - -`kling/kling-v2-1-master` の API リファレンス。Comfy Router が Kling から提供しています。 - -## クイックスタート - -[Comfy ワークスペース](https://platform.comfy.org/profile/api-keys)でキーを作成し、`COMFY_API_KEY` としてエクスポートします。Python と TypeScript のスニペットは Comfy SDK(`pip install comfy-sdk`、`npm install @comfyorg/sdk`)を使用しています。cURL のスニペットは、同じ呼び出しを生の HTTP で実行するものです。 - -**モデル ID:** `kling/kling-v2-1-master` - -**エンドポイント:** `POST https://api.comfy.org/v2/models/kling/kling-v2-1-master` - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# The SDK automatically creates an idempotency key and reuses it for automatic retries. -with Comfy() as client: - result = client.models.run( - "kling/kling-v2-1-master", - { - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting.", - }, - ) - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// The SDK automatically creates an idempotency key and reuses it for automatic retries. -const { data } = await comfy.models.run("kling/kling-v2-1-master", { - aspect_ratio: "16:9", - duration: "5", - mode: "std", - prompt: "A red fox trotting through falling snow, cinematic lighting.", -}); - -console.log(data); -``` - -```bash cURL -curl https://api.comfy.org/v2/models/kling/kling-v2-1-master \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"aspect_ratio\": \"16:9\", \"duration\": \"5\", \"mode\": \"std\", \"prompt\": \"A red fox trotting through falling snow, cinematic lighting.\"}" -``` - - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -with Comfy() as client: - handle = client.models.submit( - "kling/kling-v2-1-master", - { - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting.", - }, - ) - print("request_id:", handle.request_id) # with the model ID, all another process needs - - # Poll until the request completes, waiting the Retry-After the server names. - for update in handle.iter_events(): - print(update.status, update.queue_position) - - # The provider's own payload, the same value models.run() returns. - # A request that failed or was cancelled raises the typed Router error here. - result = handle.get() - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -const handle = await comfy.models.submit("kling/kling-v2-1-master", { - aspect_ratio: "16:9", - duration: "5", - mode: "std", - prompt: "A red fox trotting through falling snow, cinematic lighting.", -}); -console.log("requestId:", handle.requestId); // with the model ID, all another process needs - -// Poll until the request completes, waiting the Retry-After the server names. -for await (const update of handle.events()) { - console.log(update.status, update.queuePosition); -} - -// The same result models.run() returns. A request that failed or was cancelled rejects here. -const result = await handle.get(); - -console.log(result.data); -``` - -```bash cURL -# 1. Submit. Router answers 201 with request_id, status_url, response_url and cancel_url. -curl https://api.comfy.org/v2/models/kling/kling-v2-1-master/requests \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"aspect_ratio\": \"16:9\", \"duration\": \"5\", \"mode\": \"std\", \"prompt\": \"A red fox trotting through falling snow, cinematic lighting.\"}" - -# 2. Poll until status is COMPLETED, waiting the Retry-After seconds each response names. -REQUEST_ID="" -curl -i https://api.comfy.org/v2/models/kling/kling-v2-1-master/requests/$REQUEST_ID/status \ - -H "X-API-Key: $COMFY_API_KEY" - -# 3. Collect. 200 with the model's native output, 202 with the status body while it is still running. -curl https://api.comfy.org/v2/models/kling/kling-v2-1-master/requests/$REQUEST_ID \ - -H "X-API-Key: $COMFY_API_KEY" -``` - - - - - -## スキーマ - -### 入力 - - - ビデオのアスペクト比 - - 指定可能な値: `16:9`, `9:16`, `1:1` - - - - コールバック通知先アドレス - - フォーマット: `uri` - - - - - - - - - - - - カメラの水平軸(x 軸)に沿った移動を制御します。負の値は左、正の値は右を示します。 - - 範囲: `-10` から `10` - - - - 垂直面内でのカメラの回転(x 軸)を制御します。負の値は下向きの回転、正の値は上向きの回転を示します。 - - 範囲: `-10` から `10` - - - - カメラのロール量(z 軸)を制御します。負の値は反時計回り、正の値は時計回りを示します。 - - 範囲: `-10` から `10` - - - - 水平面内でのカメラの回転(y 軸)を制御します。負の値は左回転、正の値は右回転を示します。 - - 範囲: `-10` から `10` - - - - カメラの垂直軸(y 軸)に沿った移動を制御します。負の値は下、正の値は上を示します。 - - 範囲: `-10` から `10` - - - - カメラの焦点距離の変化を制御します。負の値は画角が狭くなり、正の値は画角が広くなります。 - - 範囲: `-10` から `10` - - - - 定義済みのカメラ動作タイプ。simple: カスタマイズ可能なカメラ動作。down_back: カメラが下降して後方へ移動します。forward_up: カメラが前進して上にチルトします。right_turn_forward: 右に回転して前進します。left_turn_forward: 左に回転して前進します。 - - 指定可能な値: `simple`, `down_back`, `forward_up`, `right_turn_forward`, `left_turn_forward` - - - - ビデオ生成における柔軟性。値が高いほどモデルの柔軟性が低くなり、ユーザーのプロンプトとの関連性が強くなります。 - - 範囲: `0` から `1` - - フォーマット: `float` - - - - ビデオの長さ(秒) - - 指定可能な値: `3`, `4`, `5`, `6`, `7`, `8`, `9`, `10`, `11`, `12`, `13`, `14`, `15` - - - - カスタムタスク ID - - - - ビデオ生成モード。std: スタンダードモード。コスト効率に優れています。pro: プロフェッショナルモード。より長い再生時間のビデオを生成しますが、出力品質は高くなります。 - - 指定可能な値: `std`, `pro` - - - - モデル名。Comfy Router を使用する場合は省略するか null を送信してください。モデルはリクエストパスによって選択されます。名前を指定する場合は、そのパスと一致している必要があります。 - - - - 各ストーリーボードに関する情報(プロンプトや再生時間など)。最大 6 つのストーリーボードをサポートし、最小 1 つです。multi_shot が true で shot_type が customize の場合に必須です。 - - - - このストーリーボードの再生時間(秒)。タスク全体の再生時間を超えてはならず、1 未満にもできません。すべてのストーリーボードの再生時間の合計はタスク全体の再生時間と等しくなります。 - - - - ショットの通し番号 - - - - このストーリーボードのプロンプトワード。最大長は 512 文字です。 - - - - マルチショットビデオを生成するかどうか。true の場合、prompt パラメータは無効です。false の場合、shot_type パラメータと multi_prompt パラメータは無効です。 - - - - ネガティブテキストプロンプト。ネガティブプロンプトの情報は、ポジティブプロンプト内に直接否定的な文で補足することを推奨します。 - - - - ポジティブテキストプロンプト。\<ポジティブテキストプロンプト。\>> を使用します。1 つのタスクで最大 2 つのトーンを参照できます。トーンを指定する場合、sound パラメータの値は on にする必要があります。 - - - - ストーリーボード方法。multi_shot パラメータが true に設定されている場合に必須です。 - - 指定可能な値: `customize`, `intelligence` - - - - ビデオ生成時に同時にサウンドを生成するかどうか。このパラメータをサポートするのは V2.6 以降のバージョンのモデルのみです。 - - 指定可能な値: `on`, `off` - - - - ウォーターマーク付きの結果を同時に生成するかどうか。現時点ではカスタムウォーターマークはサポートされていません。 - - - - true はウォーターマークを生成する、false は生成しないことを示します。 - - -このスキーマは Router が `GET /v2/models/kling/kling-v2-1-master/openapi.json` で提供するスキーマから生成されたもので、リクエストがプロバイダーに到達する前に Router が呼び出しを検証する際に使用するドキュメントと同じものです。 -### 出力 - - - エラーコード - - - - - - - - タスク作成時間。Unixタイムスタンプ(ミリ秒) - - - - タスクの控除単位 - - - - タスクID - - - - - - - - - - - - - - - - - - - - ビデオの合計再生時間(秒) - - - - 生成済みビデオID - - - - 生成済みビデオのURL - - 形式: `uri` - - - - ウォーターマーク付きの生成済みビデオのURL。直リンク保護形式 - - 形式: `uri` - - - - タスクステータス - - 指定可能な値: `submitted`、`processing`、`succeed`、`failed` - - - - タスクステータス情報。タスク失敗時に失敗理由を表示します - - - - タスク更新時間。Unixタイムスタンプ(ミリ秒) - - - - - - - - - - - - エラーメッセージ - - - - リクエストID - - -## 例 - -### 入力 - -```json -{ - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting." -} -``` - -### 出力 - -```json -{ - "code": 0, - "data": { - "created_at": 1798761600000, - "task_id": "kling-task-1a2b3c4d5e6f", - "task_result": { - "videos": [ - { - "duration": "5", - "id": "kling-video-6f5e4d3c2b1a", - "url": "https://example.invalid/kling/kling-v1/generated.mp4" - } - ] - }, - "task_status": "succeed", - "task_status_msg": "", - "updated_at": 1798761840000 - }, - "message": "SUCCEED", - "request_id": "9f2c1a04-7b6e-4d38-8a51-3c0e7d9b2f46" -} -``` - - - diff --git a/ja/development/comfy-router/models/kling/kling-v2-1/code.mdx b/ja/development/comfy-router/models/kling/kling-v2-1/code.mdx deleted file mode 100644 index 7b8ab787e0..0000000000 --- a/ja/development/comfy-router/models/kling/kling-v2-1/code.mdx +++ /dev/null @@ -1,467 +0,0 @@ ---- -title: "Comfy Router で Kling V2.1 を使用する" -description: "Comfy Router 経由で kling/kling-v2-1 を呼び出します。エンドポイント、リクエスト形状、Router が返すレスポンスについて説明します。" -sidebarTitle: "Kling V2.1" -translationSourceHash: 93fbd156 -translationFrom: development/comfy-router/models/kling/kling-v2-1/code.mdx -translationBlockHashes: - "_intro": d015787e - "Quick start": afcb7671 - "Schema": 175b57fe - "Examples": e835e733 ---- -{/* GENERATED FILE. Generated from router-schemas/kling/kling-v2-1.json by `pnpm code-pages:gen`. */} - -import RouterCodeFooter from "/snippets/ja/comfy-router/model-code-footer.mdx"; - -`kling/kling-v2-1` の API リファレンス。Comfy Router が Kling から提供しています。 - -## クイックスタート - -[Comfy ワークスペース](https://platform.comfy.org/profile/api-keys)でキーを作成し、`COMFY_API_KEY` としてエクスポートします。Python と TypeScript のスニペットは Comfy SDK(`pip install comfy-sdk`、`npm install @comfyorg/sdk`)を使用します。cURL スニペットは、生の HTTP 経由で同じ呼び出しを行います。 - -**モデル ID:** `kling/kling-v2-1` - -**エンドポイント:** `POST https://api.comfy.org/v2/models/kling/kling-v2-1` - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# The SDK automatically creates an idempotency key and reuses it for automatic retries. -with Comfy() as client: - result = client.models.run( - "kling/kling-v2-1", - { - "duration": "5", - "image": "https://example.invalid/kling/reference.png", - "mode": "std", - "prompt": "The fox turns its head towards the camera.", - }, - ) - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// The SDK automatically creates an idempotency key and reuses it for automatic retries. -const { data } = await comfy.models.run("kling/kling-v2-1", { - duration: "5", - image: "https://example.invalid/kling/reference.png", - mode: "std", - prompt: "The fox turns its head towards the camera.", -}); - -console.log(data); -``` - -```bash cURL -curl https://api.comfy.org/v2/models/kling/kling-v2-1 \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"duration\": \"5\", \"image\": \"https://example.invalid/kling/reference.png\", \"mode\": \"std\", \"prompt\": \"The fox turns its head towards the camera.\"}" -``` - - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -with Comfy() as client: - handle = client.models.submit( - "kling/kling-v2-1", - { - "duration": "5", - "image": "https://example.invalid/kling/reference.png", - "mode": "std", - "prompt": "The fox turns its head towards the camera.", - }, - ) - print("request_id:", handle.request_id) # with the model ID, all another process needs - - # Poll until the request completes, waiting the Retry-After the server names. - for update in handle.iter_events(): - print(update.status, update.queue_position) - - # The provider's own payload, the same value models.run() returns. - # A request that failed or was cancelled raises the typed Router error here. - result = handle.get() - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -const handle = await comfy.models.submit("kling/kling-v2-1", { - duration: "5", - image: "https://example.invalid/kling/reference.png", - mode: "std", - prompt: "The fox turns its head towards the camera.", -}); -console.log("requestId:", handle.requestId); // with the model ID, all another process needs - -// Poll until the request completes, waiting the Retry-After the server names. -for await (const update of handle.events()) { - console.log(update.status, update.queuePosition); -} - -// The same result models.run() returns. A request that failed or was cancelled rejects here. -const result = await handle.get(); - -console.log(result.data); -``` - -```bash cURL -# 1. Submit. Router answers 201 with request_id, status_url, response_url and cancel_url. -curl https://api.comfy.org/v2/models/kling/kling-v2-1/requests \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"duration\": \"5\", \"image\": \"https://example.invalid/kling/reference.png\", \"mode\": \"std\", \"prompt\": \"The fox turns its head towards the camera.\"}" - -# 2. Poll until status is COMPLETED, waiting the Retry-After seconds each response names. -REQUEST_ID="" -curl -i https://api.comfy.org/v2/models/kling/kling-v2-1/requests/$REQUEST_ID/status \ - -H "X-API-Key: $COMFY_API_KEY" - -# 3. Collect. 200 with the model's native output, 202 with the status body while it is still running. -curl https://api.comfy.org/v2/models/kling/kling-v2-1/requests/$REQUEST_ID \ - -H "X-API-Key: $COMFY_API_KEY" -``` - - - - - -## スキーマ - -### 入力 - - - コールバック通知先のアドレス。タスクのステータスが変更されるとサーバーが通知します。 - - 形式: `uri` - - - - - - - - - - - - カメラの水平軸(x軸)に沿った動きを制御します。負の値は左、正の値は右を示します。 - - 範囲: `-10` から `10` - - - - 垂直面内でのカメラの回転(x軸)を制御します。負の値は下向きの回転、正の値は上向きの回転を示します。 - - 範囲: `-10` から `10` - - - - カメラのロール量(z軸)を制御します。負の値は反時計回り、正の値は時計回りを示します。 - - 範囲: `-10` から `10` - - - - 水平面内でのカメラの回転(y軸)を制御します。負の値は左への回転、正の値は右への回転を示します。 - - 範囲: `-10` から `10` - - - - カメラの垂直軸(y軸)に沿った動きを制御します。負の値は下、正の値は上を示します。 - - 範囲: `-10` から `10` - - - - カメラの焦点距離の変化を制御します。負の値は画角が狭くなること、正の値は画角が広くなることを示します。 - - 範囲: `-10` から `10` - - - - 定義済みのカメラムーブメントタイプ。simple: カスタマイズ可能なカメラムーブメント。down_back: カメラが下降しながら後退します。forward_up: カメラが前進しながら上を向きます。right_turn_forward: 右に回転して前進します。left_turn_forward: 左に回転して前進します。 - - 指定可能な値: `simple`, `down_back`, `forward_up`, `right_turn_forward`, `left_turn_forward` - - - - ビデオ生成における柔軟性。値が高いほどモデルの柔軟性が低くなり、ユーザーのプロンプトとの関連性が強くなります。 - - 範囲: `0` から `1` - - 形式: `float` - - - - ビデオの長さ(秒) - - 指定可能な値: `3`, `4`, `5`, `6`, `7`, `8`, `9`, `10`, `11`, `12`, `13`, `14`, `15` - - - - 動的ブラシ設定リスト(最大6グループ)。5秒のビデオの場合、軌跡の長さは77座標を超えてはなりません。 - - - - 動的ブラシの適用領域(ユーザーがモーションブラシを使用して作成したマスク画像)。アスペクト比は入力画像と一致している必要があります。 - - 形式: `uri` - - - - - - - - 軌跡ポイントの水平座標。画像の左下隅を原点(0,0)とします。 - - - - 軌跡ポイントの垂直座標。画像の左下隅を原点(0,0)とします。 - - - - エレメントID設定に基づく参照エレメントリスト。最大3つの参照エレメントをサポートします。element_list パラメータと voice_list パラメータは同時に使用できません。 - - - - エレメントID - - 形式: `int64` - - - - カスタマイズしたタスクID。単一のユーザーアカウント内で一意である必要があります。 - - - - 参照画像: URL または Base64 エンコード文字列。10MB を超えることはできず、解像度は 300*300px 以上、アスペクト比は 1:2.5 ~ 2.5:1 の範囲である必要があります。Base64 には data:image プレフィックスを含めないでください。 - - - - 参照画像: 終了フレーム制御。URL または Base64 エンコード文字列。10MB を超えることはできず、解像度は 300*300px 以上である必要があります。Base64 には data:image プレフィックスを含めないでください。dynamic_masks/static_mask または camera_control と同時に使用することはできません。 - - - - ビデオ生成モード。std: スタンダードモード。コスト効率に優れています。pro: プロフェッショナルモード。より長い再生時間のビデオを生成しますが、出力品質が高くなります。 - - 指定可能な値: `std`, `pro` - - - - モデル名。Comfy Router を使用する場合は省略するか null を送信してください。モデルはリクエストパスによって選択されます。名前を指定する場合は、そのパスと一致している必要があります。 - - - - 各ストーリーボードに関する情報(プロンプトや再生時間など)。最大6つのストーリーボードをサポートし、最低1つ必要です。multi_shot が true で shot_type が customize の場合に必須です。 - - - - このストーリーボードの再生時間(秒)。タスクの合計再生時間を超えてはならず、1未満であってもなりません。すべてのストーリーボードの再生時間の合計がタスクの合計再生時間と等しくなります。 - - - - ショットの連番 - - - - このストーリーボードのプロンプトワード。最大長512文字。 - - - - マルチショットビデオを生成するかどうか。true の場合、prompt パラメータは無効です。false の場合、shot_type パラメータと multi_prompt パラメータは無効です。 - - - - Negative text prompt. It is recommended to supplement negative prompt information through negative sentences directly within positive prompts. - - - - ポジティブテキストプロンプト。\> を使用して、voice_list パラメータの順序に対応する音声を指定します。1つのタスクで最大2つのトーンを参照できます。トーンを指定する場合、sound パラメータの値は on である必要があります。 - - - - 絵コンテ方式。multi_shot パラメータが true に設定されている場合に必須です。 - - 取り得る値: `customize`、`intelligence` - - - - 動画生成時に同時にサウンドを生成するかどうか。このパラメータをサポートするのは V2.6 以降のバージョンのモデルのみです。 - - 取り得る値: `on`、`off` - - - - 静的ブラシ適用領域(ユーザーがモーションブラシを使用して作成するマスク画像)。アスペクト比は入力画像と一致する必要があります。 - - - - 動画生成時に参照する音声のリスト。最大2つの音声をサポートします。element_list パラメータと voice_list パラメータは相互に排他的です。 - - - - 音声カスタマイズ API を通じて返される音声 ID、またはシステムプリセットの音声 ID。 - - - - ウォーターマーク付きの結果を同時に生成するかどうか。現時点ではカスタムウォーターマークはサポートされていません。 - - - - true はウォーターマークを生成する、false は生成しないことを意味します。 - - -スキーマから生成されています。Router は `GET /v2/models/kling/kling-v2-1/openapi.json` でこのスキーマを提供しており、リクエストがプロバイダーに到達する前に、呼び出しを検証する際に使用するドキュメントと同じものです。 -### 出力 - - - エラーコード - - - - - - - - タスク作成時間、Unix タイムスタンプ(ミリ秒) - - - - タスクの控除ユニット数 - - - - タスク ID - - - - - - - - - - - - - - - - - - - - ビデオの合計再生時間(秒) - - - - 生成済みビデオ ID - - - - 生成済みビデオの URL - - フォーマット: `uri` - - - - ウォーターマーク付きの生成済みビデオの URL、直リンク保護フォーマット - - フォーマット: `uri` - - - - タスクステータス - - 指定可能な値: `submitted`、`processing`、`succeed`、`failed` - - - - タスクステータス情報。タスクが失敗した場合は失敗理由を表示します - - - - タスク更新時間、Unix タイムスタンプ(ミリ秒) - - - - - - - - - - - - エラーメッセージ - - - - リクエスト ID - - -## 例 - -### 入力 - -```json -{ - "duration": "5", - "image": "https://example.invalid/kling/reference.png", - "mode": "std", - "prompt": "The fox turns its head towards the camera." -} -``` - -### 出力 - -```json -{ - "code": 0, - "data": { - "created_at": 1798761600000, - "task_id": "kling-task-1a2b3c4d5e6f", - "task_result": { - "videos": [ - { - "duration": "5", - "id": "kling-video-6f5e4d3c2b1a", - "url": "https://example.invalid/kling/kling-v1/generated.mp4" - } - ] - }, - "task_status": "succeed", - "task_status_msg": "", - "updated_at": 1798761840000 - }, - "message": "SUCCEED", - "request_id": "9f2c1a04-7b6e-4d38-8a51-3c0e7d9b2f46" -} -``` - - - diff --git a/ja/development/comfy-router/models/kling/kling-v2-master/code.mdx b/ja/development/comfy-router/models/kling/kling-v2-master/code.mdx deleted file mode 100644 index 53a550336d..0000000000 --- a/ja/development/comfy-router/models/kling/kling-v2-master/code.mdx +++ /dev/null @@ -1,421 +0,0 @@ ---- -title: "Kling V2 Master を Comfy Router で使用する" -description: "Comfy Router 経由で kling/kling-v2-master を呼び出します: endpoint、リクエスト形状、Router が返すレスポンスについて説明します。" -sidebarTitle: "Kling V2 Master" -translationSourceHash: f9334f9e -translationFrom: development/comfy-router/models/kling/kling-v2-master/code.mdx -translationBlockHashes: - "_intro": c470eb90 - "Quick start": 1369e080 - "Schema": 769d8e31 - "Examples": 14429ff8 ---- -{/* 生成済みファイル。router-schemas/kling/kling-v2-master.json から `pnpm code-pages:gen` によって生成されます。 */} - -import RouterCodeFooter from "/snippets/ja/comfy-router/model-code-footer.mdx"; - -`kling/kling-v2-master` の API リファレンスです。Comfy Router が Kling から提供しています。 - -## クイックスタート - -[Comfy ワークスペース](https://platform.comfy.org/profile/api-keys)でキーを作成し、`COMFY_API_KEY` としてエクスポートします。Python と TypeScript のスニペットは Comfy SDK(`pip install comfy-sdk`、`npm install @comfyorg/sdk`)を使用しています。cURL のスニペットは、同じ呼び出しを生の HTTP で実行するものです。 - -**モデルID:** `kling/kling-v2-master` - -**エンドポイント:** `POST https://api.comfy.org/v2/models/kling/kling-v2-master` - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# The SDK automatically creates an idempotency key and reuses it for automatic retries. -with Comfy() as client: - result = client.models.run( - "kling/kling-v2-master", - { - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting.", - }, - ) - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// The SDK automatically creates an idempotency key and reuses it for automatic retries. -const { data } = await comfy.models.run("kling/kling-v2-master", { - aspect_ratio: "16:9", - duration: "5", - mode: "std", - prompt: "A red fox trotting through falling snow, cinematic lighting.", -}); - -console.log(data); -``` - -```bash cURL -curl https://api.comfy.org/v2/models/kling/kling-v2-master \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"aspect_ratio\": \"16:9\", \"duration\": \"5\", \"mode\": \"std\", \"prompt\": \"A red fox trotting through falling snow, cinematic lighting.\"}" -``` - - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -with Comfy() as client: - handle = client.models.submit( - "kling/kling-v2-master", - { - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting.", - }, - ) - print("request_id:", handle.request_id) # with the model ID, all another process needs - - # Poll until the request completes, waiting the Retry-After the server names. - for update in handle.iter_events(): - print(update.status, update.queue_position) - - # The provider's own payload, the same value models.run() returns. - # A request that failed or was cancelled raises the typed Router error here. - result = handle.get() - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -const handle = await comfy.models.submit("kling/kling-v2-master", { - aspect_ratio: "16:9", - duration: "5", - mode: "std", - prompt: "A red fox trotting through falling snow, cinematic lighting.", -}); -console.log("requestId:", handle.requestId); // with the model ID, all another process needs - -// Poll until the request completes, waiting the Retry-After the server names. -for await (const update of handle.events()) { - console.log(update.status, update.queuePosition); -} - -// The same result models.run() returns. A request that failed or was cancelled rejects here. -const result = await handle.get(); - -console.log(result.data); -``` - -```bash cURL -# 1. Submit. Router answers 201 with request_id, status_url, response_url and cancel_url. -curl https://api.comfy.org/v2/models/kling/kling-v2-master/requests \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"aspect_ratio\": \"16:9\", \"duration\": \"5\", \"mode\": \"std\", \"prompt\": \"A red fox trotting through falling snow, cinematic lighting.\"}" - -# 2. Poll until status is COMPLETED, waiting the Retry-After seconds each response names. -REQUEST_ID="" -curl -i https://api.comfy.org/v2/models/kling/kling-v2-master/requests/$REQUEST_ID/status \ - -H "X-API-Key: $COMFY_API_KEY" - -# 3. Collect. 200 with the model's native output, 202 with the status body while it is still running. -curl https://api.comfy.org/v2/models/kling/kling-v2-master/requests/$REQUEST_ID \ - -H "X-API-Key: $COMFY_API_KEY" -``` - - - - - -## スキーマ - -### 入力 - - - ビデオのアスペクト比 - - 指定可能な値: `16:9`, `9:16`, `1:1` - - - - コールバック通知先アドレス - - 形式: `uri` - - - - - - - - - - - - カメラの水平軸(x軸)に沿った移動を制御します。負の値は左、正の値は右を示します。 - - 範囲: `-10` から `10` - - - - 垂直面内でのカメラの回転(x軸)を制御します。負の値は下向きの回転、正の値は上向きの回転を示します。 - - 範囲: `-10` から `10` - - - - カメラのロール量(z軸)を制御します。負の値は反時計回り、正の値は時計回りを示します。 - - 範囲: `-10` から `10` - - - - 水平面内でのカメラの回転(y軸)を制御します。負の値は左への回転、正の値は右への回転を示します。 - - 範囲: `-10` から `10` - - - - カメラの垂直軸(y軸)に沿った移動を制御します。負の値は下方向、正の値は上方向を示します。 - - 範囲: `-10` から `10` - - - - カメラの焦点距離の変化を制御します。負の値は画角が狭くなること、正の値は画角が広がることを示します。 - - 範囲: `-10` から `10` - - - - 定義済みのカメラ動作タイプ。simple: カスタマイズ可能なカメラ動作。down_back: カメラが下降しながら後退します。forward_up: カメラが前進しながら上にチルトします。right_turn_forward: 右に回転して前進します。left_turn_forward: 左に回転して前進します。 - - 指定可能な値: `simple`, `down_back`, `forward_up`, `right_turn_forward`, `left_turn_forward` - - - - ビデオ生成における自由度。値が高いほどモデルの自由度が低くなり、ユーザーのプロンプトとの関連性が強くなります。 - - 範囲: `0` から `1` - - 形式: `float` - - - - ビデオの長さ(秒) - - 指定可能な値: `3`, `4`, `5`, `6`, `7`, `8`, `9`, `10`, `11`, `12`, `13`, `14`, `15` - - - - カスタマイズされたタスクID - - - - ビデオ生成モード。std: スタンダードモード。コスト効率に優れています。pro: プロフェッショナルモード。より長い再生時間のビデオを生成しますが、出力品質が高くなります。 - - 指定可能な値: `std`, `pro` - - - - モデル名。Comfy Router を使用する場合は省略するか null を送信してください。モデルはリクエストパスによって選択されます。名前を指定する場合はそのパスと一致している必要があります。 - - - - 各ストーリーボードに関する情報(プロンプトや再生時間など)。最大 6 つのストーリーボードをサポートし、最小は 1 です。multi_shot が true かつ shot_type が customize の場合に必須です。 - - - - このストーリーボードの再生時間(秒)。タスク全体の再生時間を超えてはならず、1 未満にもできません。すべてのストーリーボードの再生時間の合計がタスク全体の再生時間と等しくなります。 - - - - ショットの連番 - - - - このストーリーボードのプロンプト。最大長 512 文字。 - - - - マルチショットビデオを生成するかどうか。true の場合、prompt パラメータは無効です。false の場合、shot_type および multi_prompt パラメータは無効です。 - - - - ネガティブテキストプロンプト。ネガティブプロンプトの情報は、ポジティブプロンプト内に直接ネガティブな文を記述して補うことが推奨されます。 - - - - ポジティブテキストプロンプト。voice_list パラメータの順序に対応する音声を指定するには \<\<\>> を使用します。1 つのタスクで最大 2 つの音声を参照できます。音声を指定する場合、sound パラメータの値は on である必要があります。 - - - - ストーリーボード方法。multi_shot パラメータが true に設定されている場合に必須です。 - - 指定可能な値: `customize`, `intelligence` - - - - ビデオ生成時に同時にサウンドを生成するかどうか。モデルの V2.6 以降のバージョンのみがこのパラメータをサポートします。 - - 指定可能な値: `on`, `off` - - - - 透かし入りの結果を同時に生成するかどうか。現時点ではカスタム透かしはサポートされていません。 - - - - true の場合は透かしを生成し、false の場合は生成しません。 - - -Router が `GET /v2/models/kling/kling-v2-master/openapi.json` で提供するスキーマから生成されています。これは、リクエストがプロバイダーに到達する前に呼び出しを検証する際に使用される同一のドキュメントです。 -### 出力 - - - エラーコード - - - - - - - - タスク作成時間、Unix タイムスタンプ(ミリ秒) - - - - タスクの控除単位 - - - - タスク ID - - - - - - - - - - - - - - - - - - - - ビデオの合計再生時間(秒) - - - - 生成済みビデオ ID - - - - 生成済みビデオの URL - - 形式: `uri` - - - - ウォーターマーク付きの生成済みビデオの URL、直リンク保護形式 - - 形式: `uri` - - - - タスクステータス - - 取り得る値: `submitted`、`processing`、`succeed`、`failed` - - - - タスクステータス情報。タスクが失敗した場合は失敗理由を表示します - - - - タスク更新時間、Unix タイムスタンプ(ミリ秒) - - - - - - - - - - - - エラーメッセージ - - - - リクエスト ID - - -## 例 - -### 入力 - -```json -{ - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting." -} -``` - -### 出力 - -```json -{ - "code": 0, - "data": { - "created_at": 1798761600000, - "task_id": "kling-task-1a2b3c4d5e6f", - "task_result": { - "videos": [ - { - "duration": "5", - "id": "kling-video-6f5e4d3c2b1a", - "url": "https://example.invalid/kling/kling-v1/generated.mp4" - } - ] - }, - "task_status": "succeed", - "task_status_msg": "", - "updated_at": 1798761840000 - }, - "message": "SUCCEED", - "request_id": "9f2c1a04-7b6e-4d38-8a51-3c0e7d9b2f46" -} -``` - - - diff --git a/ko/development/api-development/overview.mdx b/ko/development/api-development/overview.mdx deleted file mode 100644 index 28562a9671..0000000000 --- a/ko/development/api-development/overview.mdx +++ /dev/null @@ -1,70 +0,0 @@ ---- -title: "API 개요" -description: "ComfyUI와 프로그래밍 방식으로 상호작용하는 다양한 방법에 대한 개요" -icon: "list" -translationSourceHash: 852ff6ab -translationFrom: development/api-development/overview.mdx -translationBlockHashes: - "_intro": 838d6d8e - "Start Here": cf5c79f3 - "Which API Should I Use?": 40998626 - "Getting Started": 41b19127 - "Prerequisites": 4ba1cc15 ---- - - -ComfyUI는 워크플로를 어디에서 실행하고 인프라를 얼마나 관리할지에 따라 여러 API 옵션을 제공합니다. 이 페이지는 올바른 접근 방식을 선택하는 데 도움이 됩니다. - ---- - -## 여기서 시작 - -새로운 통합을 위해서는 **Comfy SDKs**와 SDK가 호출하는 Comfy API v2를 사용하세요. v2는 새로운 버전 관리 HTTP 인터페이스이며, 기존의 Cloud API 및 ComfyUI Server API와 함께 존재합니다. [Comfy API v2 개요](/ko/api-reference/v2/overview)를 참조하세요. 동일한 코드가 Comfy Cloud와 자신의 머신에서 모두 실행됩니다. - - - 자체 애플리케이션에서 워크플로를 실행하기 위한 공식 Python 및 TypeScript SDK입니다. 현재 베타 버전입니다. - - -아래의 다른 API는 여전히 완전히 지원되며, SDK가 아직 다루지 못하는 영역을 다룹니다. 여기에 있는 어떤 것도 지원 중단되지 않습니다. - -## 어떤 API를 사용해야 하나요? - -| | Comfy API v2 + SDKs | Cloud API | ComfyUI Server API | -|---|---|---|---| -| **실행 위치** | Comfy Cloud 또는 로컬 프록시를 통한 자체 머신 | Comfy Cloud(관리형 GPU) | 자체 머신 | -| **호환성** | 버전이 지정되며 v2 내에서는 추가적인 변경만 이루어짐 | 실험적이며 예고 없이 변경될 수 있음 | 릴리스 간 호환성 보장 없음 | -| **GPU 관리** | 연결하는 대상에 따라 다름 | 자동으로 처리됨 | 하드웨어를 직접 관리 | -| **모델** | 연결하는 대상에 따라 다름 | Comfy에서 사전 설치 및 관리 | 직접 다운로드하여 로컬에서 관리 | -| **인증** | Cloud에서는 `Authorization: Bearer`. 자체 호스팅은 기본적으로 없음, 선택적 정적 Bearer 토큰 | `X-API-Key` 헤더(Comfy Cloud 계정) | 없음(로컬) 또는 파트너 노드용 API 키 | -| **기본 URL** | `https://cloud.comfy.org` 또는 `http://127.0.0.1:8189` | `https://cloud.comfy.org` | 자체 서버 URL(예: `http://localhost:8188`) | -| **공식 클라이언트** | Python 및 TypeScript SDK | 없음, HTTP로 호출 | 없음, HTTP로 호출 | -| **프로토콜** | REST + SSE | REST + WebSocket | REST + WebSocket | -| **범위** | 워크플로 실행 및 결과 획득 | 모델 및 계정을 포함한 전체 Cloud 기능 | 실행 대기열 및 노드 정보를 포함한 전체 로컬 기능 | -| **적합한 경우** | 계속 작동해야 하는 새로운 통합 | SDK가 아직 지원하지 않는 Cloud 기능 | 전체 제어, 사용자 지정 하드웨어 및 모델 | - -모두 동일한 워크플로 형식([API 형식](/ko/development/api-development/workflow-api-format))을 사용하므로, 워크플로를 로컬에서 개발하고 테스트한 다음 변경 없이 클라우드로 이동할 수 있습니다. - -## 시작하기 - - - - Python 또는 TypeScript에서 클라우드 또는 자체 머신을 대상으로 워크플로를 실행하세요. - - - Comfy의 관리형 인프라에서 워크플로를 실행하세요. GPU 설정이 필요 없습니다. - - - 자체 머신에서 ComfyUI를 서버로 실행하고 API를 통해 호출하세요. - - - 헤드리스 또는 API 기반 워크플로에서 유료 파트너 노드를 사용하세요. - - - ---- - -## 사전 준비 사항 - -API를 사용하기 전에 다음이 필요합니다: - -- Comfy Cloud 또는 파트너 노드와 관련된 모든 작업에는 API 키가 필요합니다([API 키 받기](/ko/development/api-development/getting-an-api-key) 참조). 완전히 로컬에서 실행되는 ComfyUI는 API 키가 필요하지 않습니다. diff --git a/ko/development/comfy-router/models/byteplus/seedance-1-0-lite-i2v-250428/code.mdx b/ko/development/comfy-router/models/byteplus/seedance-1-0-lite-i2v-250428/code.mdx deleted file mode 100644 index b2272ba15d..0000000000 --- a/ko/development/comfy-router/models/byteplus/seedance-1-0-lite-i2v-250428/code.mdx +++ /dev/null @@ -1,435 +0,0 @@ ---- -title: "Comfy Router로 Seedance 1.0 Lite I2V 250428 사용하기" -description: "Comfy Router를 통해 byteplus/seedance-1-0-lite-i2v-250428을 호출합니다: endpoint, 요청 형태, 그리고 Router가 반환하는 응답을 설명합니다." -sidebarTitle: "Seedance 1.0 Lite I2V 250428" -translationSourceHash: 0f64abdd -translationFrom: development/comfy-router/models/byteplus/seedance-1-0-lite-i2v-250428/code.mdx -translationBlockHashes: - "_intro": 66c320e8 - "Quick start": a84cd948 - "Schema": 0dd61406 - "Examples": d126be96 ---- -{/* GENERATED FILE. Generated from router-schemas/byteplus/seedance-1-0-lite-i2v-250428.json by `pnpm code-pages:gen`. */} - -import RouterCodeFooter from "/snippets/ko/comfy-router/model-code-footer.mdx"; - -BytePlus에서 Comfy Router를 통해 제공하는 `byteplus/seedance-1-0-lite-i2v-250428`의 API 레퍼런스입니다. - -## 빠른 시작 - -[Comfy 워크스페이스](https://platform.comfy.org/profile/api-keys)에서 키를 생성하고 `COMFY_API_KEY`로 내보내세요. Python 및 TypeScript 스니펫은 Comfy SDK(`pip install comfy-sdk`, `npm install @comfyorg/sdk`)를 사용하며, cURL 스니펫은 동일한 호출을 raw HTTP로 수행한 것입니다. - -**Model ID:** `byteplus/seedance-1-0-lite-i2v-250428` - -**Endpoint:** `POST https://api.comfy.org/v2/models/byteplus/seedance-1-0-lite-i2v-250428` - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# The SDK automatically creates an idempotency key and reuses it for automatic retries. -with Comfy() as client: - result = client.models.run( - "byteplus/seedance-1-0-lite-i2v-250428", - { - "content": [ - { - "text": "A red fox trotting through a snowy pine forest", - "type": "text", - }, - ], - "duration": 5, - "ratio": "16:9", - "resolution": "720p", - }, - ) - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// The SDK automatically creates an idempotency key and reuses it for automatic retries. -const { data } = await comfy.models.run("byteplus/seedance-1-0-lite-i2v-250428", { - content: [ - { - text: "A red fox trotting through a snowy pine forest", - type: "text", - }, - ], - duration: 5, - ratio: "16:9", - resolution: "720p", -}); - -console.log(data); -``` - -```bash cURL -curl https://api.comfy.org/v2/models/byteplus/seedance-1-0-lite-i2v-250428 \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"content\": [{\"text\":\"A red fox trotting through a snowy pine forest\",\"type\":\"text\"}], \"duration\": 5, \"ratio\": \"16:9\", \"resolution\": \"720p\"}" -``` - - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -with Comfy() as client: - handle = client.models.submit( - "byteplus/seedance-1-0-lite-i2v-250428", - { - "content": [ - { - "text": "A red fox trotting through a snowy pine forest", - "type": "text", - }, - ], - "duration": 5, - "ratio": "16:9", - "resolution": "720p", - }, - ) - print("request_id:", handle.request_id) # with the model ID, all another process needs - - # Poll until the request completes, waiting the Retry-After the server names. - for update in handle.iter_events(): - print(update.status, update.queue_position) - - # The provider's own payload, the same value models.run() returns. - # A request that failed or was cancelled raises the typed Router error here. - result = handle.get() - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -const handle = await comfy.models.submit("byteplus/seedance-1-0-lite-i2v-250428", { - content: [ - { - text: "A red fox trotting through a snowy pine forest", - type: "text", - }, - ], - duration: 5, - ratio: "16:9", - resolution: "720p", -}); -console.log("requestId:", handle.requestId); // with the model ID, all another process needs - -// Poll until the request completes, waiting the Retry-After the server names. -for await (const update of handle.events()) { - console.log(update.status, update.queuePosition); -} - -// The same result models.run() returns. A request that failed or was cancelled rejects here. -const result = await handle.get(); - -console.log(result.data); -``` - -```bash cURL -# 1. Submit. Router answers 201 with request_id, status_url, response_url and cancel_url. -curl https://api.comfy.org/v2/models/byteplus/seedance-1-0-lite-i2v-250428/requests \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"content\": [{\"text\":\"A red fox trotting through a snowy pine forest\",\"type\":\"text\"}], \"duration\": 5, \"ratio\": \"16:9\", \"resolution\": \"720p\"}" - -# 2. Poll until status is COMPLETED, waiting the Retry-After seconds each response names. -REQUEST_ID="" -curl -i https://api.comfy.org/v2/models/byteplus/seedance-1-0-lite-i2v-250428/requests/$REQUEST_ID/status \ - -H "X-API-Key: $COMFY_API_KEY" - -# 3. Collect. 200 with the model's native output, 202 with the status body while it is still running. -curl https://api.comfy.org/v2/models/byteplus/seedance-1-0-lite-i2v-250428/requests/$REQUEST_ID \ - -H "X-API-Key: $COMFY_API_KEY" -``` - - - - - -## Schema - -### 입력 - - - 이 생성 작업의 결과를 받을 콜백 알림 주소 - - 형식: `uri` - - - - 모델이 비디오를 생성하는 데 사용할 입력 콘텐츠 - - - - 입력 오디오 객체입니다. Seedance 2.5, 2.0 및 2.0 fast만 오디오 입력을 지원합니다. Seedance 2.0 및 2.0 fast는 오디오만 단독으로 사용할 수 없으며, 최소 1개의 이미지 또는 비디오를 포함해야 합니다. Seedance 2.5는 오디오만 입력하는 것을 지원합니다. - - - - 오디오 URL, Base64 인코딩 또는 Asset ID. -오디오 URL: 오디오의 공개 URL(wav, mp3). -Base64: 형식 data:audio/\;base64,\ -Asset ID: 형식 asset://\ - - - - - - - - 이미지 기반 비디오 생성을 위한 이미지 콘텐츠(type이 "image_url"인 경우) -이미지 URL: 이미지 URL에 접근할 수 있는지 확인하세요. -Base64 인코딩 콘텐츠: 형식은 data:image/\;base64,\여야 합니다. -Asset ID: 형식 asset://\ - - - - 콘텐츠 항목의 역할/위치입니다. -이미지의 경우: first_frame, last_frame 또는 reference_image. -비디오의 경우: reference_video (Seedance 2.5, 2.0 및 2.0 fast 전용). -오디오의 경우: reference_audio (Seedance 2.5, 2.0 및 2.0 fast 전용). - - 가능한 값: `first_frame`, `last_frame`, `reference_image`, `reference_video`, `reference_audio` - - - - 모델의 입력 텍스트 정보입니다. 텍스트 프롬프트와 선택적 파라미터를 포함합니다. - -텍스트 프롬프트(필수): 중국어 및 영어 문자를 사용한 생성할 비디오에 대한 설명입니다. - -파라미터(선택): 텍스트 프롬프트 뒤에 --[파라미터]를 추가하여 비디오 사양을 제어합니다. -- --resolution (--rs): 480p, 720p, 1080p (기본값: 720p) -- --ratio (--rt): 21:9, 16:9, 4:3, 1:1, 3:4, 9:16, 9:21, adaptive (기본값: 16:9 또는 adaptive) -- --duration (--dur): 3~12초 (기본값: 5) -- --framepersecond (--fps): 24 (기본값: 24) -- --watermark (--wm): true/false (기본값: false) -- --seed (--seed): -1 ~ 2^32-1 (기본값: -1) -- --camerafixed (--cf): true/false (기본값: false) - -예시: "A beautiful landscape --ratio 16:9 --resolution 720p --duration 5" - - - - 입력 콘텐츠의 유형 - - 가능한 값: `text`, `image_url`, `video_url`, `audio_url` - - - - 입력 비디오 객체입니다. Seedance 2.5, 2.0 및 2.0 fast만 비디오 입력을 지원합니다. - - - - 비디오 URL 또는 Asset ID. -비디오 URL: 비디오의 공개 URL(mp4, mov). -Asset ID: 형식 asset://\ - - - - 비디오 재생 시간(초)입니다. Seedance 2.5: [4,30] 또는 -1(자동, 비디오 편집 작업은 -1만 지원). Seedance 2.0 및 2.0 fast: [4,15] 또는 -1(자동). Seedance 1.5 pro: [4,12] 또는 -1. Seedance 1.0: [2,12]. - - 범위: `2` ~ `30` - - - - 작업 제한 시간 임계값(초)입니다. 기본값 172800(48시간). 범위: [3600, 259200]. - - 범위: `3600` ~ `259200` - - - - Seedance 2.5, 2.0, 2.0 fast 및 1.5 pro에서 지원됩니다. 생성된 비디오에 화면과 동기화된 오디오가 포함되는지 여부입니다. -true: 모델이 동기화된 오디오가 있는 비디오를 출력합니다. -false: 모델이 무음 비디오를 출력합니다. - - - - 호출할 모델의 ID입니다. 지원되는 모델: seedance-1-5-pro-251215, seedance-1-0-pro-250528, seedance-1-0-pro-fast-251015, seedance-1-0-lite-t2v-250428, seedance-1-0-lite-i2v-250428, dreamina-seedance-2-0-260128, dreamina-seedance-2-0-fast-260128, dreamina-seedance-2-0-mini 및 dreamina-seedance-2-5-260628. POST /proxy/byteplus/api/v3/contents/generations/tasks에 대한 직접 v1 호출은 반드시 이를 제공해야 합니다. 프록시는 다른 값이나 누락된 값을 400으로 거부합니다. 이 스키마의 `required` 목록에 없는 이유는 Comfy Router가 /v2/models/byteplus/\{model}의 `{model}` 경로 세그먼트에서 이 값을 채우므로 Router 호출자는 이를 생략하기 때문입니다. - - - - Seedance 2.5 전용입니다. 출력 비디오의 컨테이너 형식입니다. -mp4: 범용 컨테이너(H.264/AAC, yuv420p)로 호환성이 넓고 파일 크기가 더 작습니다. -mov: 전문가용 컨테이너(H.264 High 4:4:4 Predictive/PCM, yuv444p)로 색상 정밀도가 높아 후반 작업에 적합하지만 파일 크기가 더 큽니다. - - 가능한 값: `mp4`, `mov` - - - - 생성된 비디오의 화면 비율입니다. Seedance 2.0 및 2.0 fast, 1.5 pro 기본값: adaptive. - - 가능한 값: `16:9`, `4:3`, `1:1`, `3:4`, `9:16`, `21:9`, `9:21`, `adaptive` - - - - 비디오 해상도입니다. Seedance 2.5, 2.0 및 2.0 fast, 1.5 pro, 1.0 lite 기본값: 720p. Seedance 1.0 pro 및 pro-fast 기본값: 1080p. -참고: Seedance 2.0 및 2.0 fast는 1080p를 지원하지 않습니다. Seedance 2.5는 480p, 720p 및 1080p를 지원합니다. - - 가능한 값: `480p`, `720p`, `1080p`, `4k` - - - - 생성된 비디오의 마지막 프레임 이미지를 반환할지 여부입니다.true: 생성된 비디오의 마지막 프레임 이미지를 반환합니다. 이 매개변수를 true로 설정하면 비디오 생성 작업 정보 조회를 호출하여 마지막 프레임 이미지를 얻을 수 있습니다. 마지막 프레임 이미지는 PNG 형식이며, 픽셀 너비와 높이는 생성된 비디오와 동일하고 워터마크가 포함되지 않습니다. 이 매개변수를 사용하면 여러 개의 연속된 비디오를 생성할 수 있습니다. 이전에 생성된 비디오의 마지막 프레임이 다음 비디오 작업의 첫 프레임으로 사용되므로 여러 개의 연속된 비디오를 빠르게 생성할 수 있습니다. -false: 생성된 비디오의 마지막 프레임 이미지를 반환하지 않습니다. - - - - 무작위성을 제어하기 위한 시드 정수입니다. 범위: [-1, 2^32-1]. -1은 무작위 시드를 사용합니다. - - 범위: `-1` ~ `4294967295` - - - - 처리를 위한 서비스 티어입니다. Seedance 2.5, 2.0 및 2.0 fast는 flex(오프라인 추론)를 지원하지 않습니다. - - 가능한 값: `default`, `flex` - - - - 생성된 비디오에 워터마크가 포함되는지 여부입니다. - - -Router가 `GET /v2/models/byteplus/seedance-1-0-lite-i2v-250428/openapi.json`에서 제공하는 스키마에서 생성되었으며, 이는 요청이 공급자에게 도달하기 이전에 호출을 검증하는 데 사용하는 것과 동일한 문서입니다. -### 출력 - - - 비디오 생성 작업이 완료된 후의 출력으로, 출력 비디오의 다운로드 URL과 BytePlus가 반환하는 경우 마지막 프레임의 다운로드 URL을 포함합니다. `video_url`과 `last_frame_url`은 모두 Comfy storage로 다시 호스팅되며, 여기의 다른 모든 필드는 BytePlus의 것입니다. Nullable: BytePlus는 작업 후 24시간 뒤에 URL을 지우므로, 그 이후에 폴링된 성공 문서는 `content`가 없거나 null일 수 있습니다. - - - - 생성된 비디오의 마지막 프레임에 대한 다운로드 URL로, 요청에서 `return_last_frame`을 설정한 경우 반환됩니다. 이 URL에서 이미지 형식을 추론하지 마세요. BytePlus는 요청 측에서 마지막 프레임을 PNG로 문서화하고, Router는 제공받은 바이트를 그대로 다시 호스팅하며 업스트림 Content-Type이나 콘텐츠 스니핑으로 타입을 지정합니다. `image/jpeg`는 둘 다 실패했을 때의 최후 수단 폴백일 뿐입니다. Router는 마지막 프레임을 Comfy storage로 다시 호스팅하고 이 필드를 재작성하므로, 일반적으로 최대 24시간 동안 유효한 Comfy 서명 URL입니다. 발급 시 24시간으로 서명되고 23시간 메모에서 재생되므로, 나중에 폴링하면 남은 시간이 한 시간도 안 되는 URL을 돌려받을 수 있습니다. 다시 호스팅을 수행할 수 없었던 경우에는 이 필드가 BytePlus 자체 URL을 대신 유지하며, BytePlus는 작업 후 24시간 뒤에 이를 지웁니다. 어느 쪽이든 링크는 만료되므로 URL을 저장하지 말고 프레임을 다운로드하세요. - - - - 생성된 비디오의 컨테이너 형식(mp4 또는 mov)으로, BytePlus가 이를 `content` 안에 중첩할 때 사용됩니다. Seedance 모델은 더 흔히 `content`의 TOP-LEVEL 형제로 반환하며(최상위 `output_format` 필드 참조), Router는 둘 중 존재하는 것을 읽습니다. - - - - 출력 비디오의 다운로드 URL입니다. Router는 비디오를 Comfy storage로 다시 호스팅하고 이 필드를 재작성하므로, 일반적으로 최대 24시간 동안 유효한 Comfy 서명 URL입니다. 발급 시 24시간으로 서명되고 23시간 메모에서 재생되므로, 나중에 폴링하면 남은 시간이 한 시간도 안 되는 URL을 돌려받을 수 있습니다. 다시 호스팅을 수행할 수 없었던 경우에는 이 필드가 BytePlus 자체 URL을 대신 유지하며, BytePlus는 작업 후 24시간 뒤에 이를 지우고 일부 모델에서는 다운로드를 100회로 제한합니다. 어느 쪽이든 링크는 만료되므로 URL을 저장하지 말고 비디오를 다운로드하세요. - - - - 작업이 생성된 시간입니다. 값은 초 단위의 UNIX 타임스탬프입니다. - - - - 생성된 비디오의 재생 시간(초)입니다. BytePlus가 이 값에 일관성이 없기 때문에 정수가 아닌 숫자로 선언되었습니다. 비디오 작업은 정수 초를 반환하는 것이 관찰되었고, 인접한 BytePlus 표면은 소수 재생 시간을 보고하므로, 클라이언트는 정수 값을 가정해서는 안 됩니다. BytePlus 자체 필드로, 성공한 비디오 작업에서 반환되며 변경 없이 전달됩니다. - - - - 오류 정보입니다. 작업이 성공하면 null이 반환됩니다. 작업이 실패하면 오류 정보가 반환됩니다. - - - - 오류 코드 - - - - 오류 메시지 - - - - 비디오 생성 작업의 ID - - - - 작업에서 사용한 모델의 이름과 버전 - - - - 생성된 비디오의 컨테이너 형식(mp4 또는 mov)으로, `content`의 형제로서 TOP LEVEL에서 반환됩니다. Seedance 비디오 작업 쿼리가 반환하는 위치가 바로 여기입니다. BytePlus 자체 필드로, 변경 없이 전달됩니다. - - - - 생성된 비디오의 해상도로, 예를 들어 `1080p`입니다. BytePlus 자체 필드로, 성공한 비디오 작업에서 반환되며 변경 없이 전달됩니다. - - - - 작업에 실제로 사용된 생성 시드입니다. BytePlus 자체 필드로, 성공한 비디오 작업에서 반환되며 변경 없이 전달됩니다. - - 형식: `int64` - - - - 작업의 상태 - - 가능한 값: `queued`, `running`, `cancelled`, `succeeded`, `failed`, `expired` - - - - 작업이 마지막으로 업데이트된 시간입니다. 값은 초 단위의 UNIX 타임스탬프입니다. - - - - 요청의 토큰 사용량 - - - - 모델이 생성한 토큰 수 - - - - 비디오 생성 모델의 경우 입력 토큰 수는 계산되지 않고 0으로 기본 설정됩니다. 따라서 total_tokens = completion_tokens입니다. - - -## 예시 - -### 입력 - -```json -{ - "content": [ - { - "text": "A red fox trotting through a snowy pine forest", - "type": "text" - } - ], - "duration": 5, - "ratio": "16:9", - "resolution": "720p" -} -``` - -### 출력 - -```json -{ - "content": { - "last_frame_url": "https://example.invalid/byteplus/seedance-1-0-lite-t2v-250428/last-frame", - "video_url": "https://example.invalid/byteplus/seedance-1-0-lite-t2v-250428/generated.mp4" - }, - "created_at": 1767225600, - "duration": 5, - "error": null, - "id": "3f7a1b28-5c0d-4e91-8a6f-1b2c3d4e5f60", - "model": "seedance-1-0-lite-i2v-250428", - "output_format": "mp4", - "resolution": "1080p", - "seed": 1234567890123, - "status": "succeeded", - "updated_at": 1767225730 -} -``` - - - diff --git a/ko/development/comfy-router/models/byteplus/seedance-1-0-lite-t2v-250428/code.mdx b/ko/development/comfy-router/models/byteplus/seedance-1-0-lite-t2v-250428/code.mdx deleted file mode 100644 index 7e208a7ec1..0000000000 --- a/ko/development/comfy-router/models/byteplus/seedance-1-0-lite-t2v-250428/code.mdx +++ /dev/null @@ -1,435 +0,0 @@ ---- -title: "Comfy Router로 Seedance 1.0 Lite T2V 250428 사용하기" -description: "Comfy Router를 통해 byteplus/seedance-1-0-lite-t2v-250428을 호출합니다. 엔드포인트, 요청 형태, 그리고 Router가 반환하는 응답을 다룹니다." -sidebarTitle: "Seedance 1.0 Lite T2V 250428" -translationSourceHash: 6065cd55 -translationFrom: development/comfy-router/models/byteplus/seedance-1-0-lite-t2v-250428/code.mdx -translationBlockHashes: - "_intro": a1ec32a9 - "Quick start": bf8ec8dc - "Schema": 060399d4 - "Examples": 7c3591f8 ---- -{/* 생성된 파일. router-schemas/byteplus/seedance-1-0-lite-t2v-250428.json에서 `pnpm code-pages:gen`으로 생성됨. */} - -import RouterCodeFooter from "/snippets/ko/comfy-router/model-code-footer.mdx"; - -Comfy Router가 BytePlus에서 제공하는 `byteplus/seedance-1-0-lite-t2v-250428`의 API 레퍼런스입니다. - -## 빠른 시작 - -[내 Comfy 워크스페이스](https://platform.comfy.org/profile/api-keys)에서 키를 생성하고 `COMFY_API_KEY`로 내보내세요. Python 및 TypeScript 스니펫은 Comfy SDK(`pip install comfy-sdk`, `npm install @comfyorg/sdk`)를 사용하며, cURL 스니펫은 동일한 호출을 raw HTTP로 수행한 것입니다. - -**모델 ID:** `byteplus/seedance-1-0-lite-t2v-250428` - -**엔드포인트:** `POST https://api.comfy.org/v2/models/byteplus/seedance-1-0-lite-t2v-250428` - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# The SDK automatically creates an idempotency key and reuses it for automatic retries. -with Comfy() as client: - result = client.models.run( - "byteplus/seedance-1-0-lite-t2v-250428", - { - "content": [ - { - "text": "A red fox trotting through a snowy pine forest", - "type": "text", - }, - ], - "duration": 5, - "ratio": "16:9", - "resolution": "720p", - }, - ) - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// The SDK automatically creates an idempotency key and reuses it for automatic retries. -const { data } = await comfy.models.run("byteplus/seedance-1-0-lite-t2v-250428", { - content: [ - { - text: "A red fox trotting through a snowy pine forest", - type: "text", - }, - ], - duration: 5, - ratio: "16:9", - resolution: "720p", -}); - -console.log(data); -``` - -```bash cURL -curl https://api.comfy.org/v2/models/byteplus/seedance-1-0-lite-t2v-250428 \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"content\": [{\"text\":\"A red fox trotting through a snowy pine forest\",\"type\":\"text\"}], \"duration\": 5, \"ratio\": \"16:9\", \"resolution\": \"720p\"}" -``` - - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -with Comfy() as client: - handle = client.models.submit( - "byteplus/seedance-1-0-lite-t2v-250428", - { - "content": [ - { - "text": "A red fox trotting through a snowy pine forest", - "type": "text", - }, - ], - "duration": 5, - "ratio": "16:9", - "resolution": "720p", - }, - ) - print("request_id:", handle.request_id) # with the model ID, all another process needs - - # Poll until the request completes, waiting the Retry-After the server names. - for update in handle.iter_events(): - print(update.status, update.queue_position) - - # The provider's own payload, the same value models.run() returns. - # A request that failed or was cancelled raises the typed Router error here. - result = handle.get() - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -const handle = await comfy.models.submit("byteplus/seedance-1-0-lite-t2v-250428", { - content: [ - { - text: "A red fox trotting through a snowy pine forest", - type: "text", - }, - ], - duration: 5, - ratio: "16:9", - resolution: "720p", -}); -console.log("requestId:", handle.requestId); // with the model ID, all another process needs - -// Poll until the request completes, waiting the Retry-After the server names. -for await (const update of handle.events()) { - console.log(update.status, update.queuePosition); -} - -// The same result models.run() returns. A request that failed or was cancelled rejects here. -const result = await handle.get(); - -console.log(result.data); -``` - -```bash cURL -# 1. Submit. Router answers 201 with request_id, status_url, response_url and cancel_url. -curl https://api.comfy.org/v2/models/byteplus/seedance-1-0-lite-t2v-250428/requests \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"content\": [{\"text\":\"A red fox trotting through a snowy pine forest\",\"type\":\"text\"}], \"duration\": 5, \"ratio\": \"16:9\", \"resolution\": \"720p\"}" - -# 2. Poll until status is COMPLETED, waiting the Retry-After seconds each response names. -REQUEST_ID="" -curl -i https://api.comfy.org/v2/models/byteplus/seedance-1-0-lite-t2v-250428/requests/$REQUEST_ID/status \ - -H "X-API-Key: $COMFY_API_KEY" - -# 3. Collect. 200 with the model's native output, 202 with the status body while it is still running. -curl https://api.comfy.org/v2/models/byteplus/seedance-1-0-lite-t2v-250428/requests/$REQUEST_ID \ - -H "X-API-Key: $COMFY_API_KEY" -``` - - - - - -## 스키마 - -### 입력 - - - 이 생성 작업 결과에 대한 콜백 알림 주소 - - 형식: `uri` - - - - 모델이 비디오를 생성하기 위한 입력 콘텐츠 - - - - 입력 오디오 객체. Seedance 2.5, 2.0 및 2.0 fast만 오디오 입력을 지원합니다. Seedance 2.0 및 2.0 fast는 오디오만 단독으로 사용할 수 없으며, 최소 1개의 이미지 또는 비디오를 포함해야 합니다. Seedance 2.5는 오디오만 입력하는 것을 지원합니다. - - - - 오디오 URL, Base64 인코딩 또는 Asset ID. -오디오 URL: 오디오의 공개 URL (wav, mp3). -Base64: 형식 data:audio/\;base64,\ -Asset ID: 형식 asset://\ - - - - - - - - 이미지 기반 비디오 생성을 위한 이미지 콘텐츠 (type이 "image_url"인 경우) -이미지 URL: 이미지 URL에 접근 가능한지 확인하세요. -Base64 인코딩 콘텐츠: 형식은 data:image/\;base64,\여야 합니다. -Asset ID: 형식 asset://\ - - - - 콘텐츠 항목의 역할/위치. -이미지의 경우: first_frame, last_frame 또는 reference_image. -비디오의 경우: reference_video (Seedance 2.5, 2.0 및 2.0 fast 전용). -오디오의 경우: reference_audio (Seedance 2.5, 2.0 및 2.0 fast 전용). - - 가능한 값: `first_frame`, `last_frame`, `reference_image`, `reference_video`, `reference_audio` - - - - 모델에 대한 입력 텍스트 정보. 텍스트 프롬프트와 선택적 파라미터를 포함합니다. - -텍스트 프롬프트(필수): 중국어 및 영어 문자를 사용한 생성할 비디오에 대한 설명. - -파라미터(선택): 텍스트 프롬프트 뒤에 --[parameters]를 추가하여 비디오 사양을 제어합니다: -- --resolution (--rs): 480p, 720p, 1080p (기본값: 720p) -- --ratio (--rt): 21:9, 16:9, 4:3, 1:1, 3:4, 9:16, 9:21, adaptive (기본값: 16:9 또는 adaptive) -- --duration (--dur): 3-12초 (기본값: 5) -- --framepersecond (--fps): 24 (기본값: 24) -- --watermark (--wm): true/false (기본값: false) -- --seed (--seed): -1 ~ 2^32-1 (기본값: -1) -- --camerafixed (--cf): true/false (기본값: false) - -예시: "A beautiful landscape --ratio 16:9 --resolution 720p --duration 5" - - - - 입력 콘텐츠의 유형 - - 가능한 값: `text`, `image_url`, `video_url`, `audio_url` - - - - 입력 비디오 객체. Seedance 2.5, 2.0 및 2.0 fast만 비디오 입력을 지원합니다. - - - - 비디오 URL 또는 Asset ID. -비디오 URL: 비디오의 공개 URL (mp4, mov). -Asset ID: 형식 asset://\ - - - - 비디오 재생 시간(초). Seedance 2.5: [4,30] 또는 -1 (자동, 비디오 편집 작업은 -1만 지원). Seedance 2.0 및 2.0 fast: [4,15] 또는 -1 (자동). Seedance 1.5 pro: [4,12] 또는 -1. Seedance 1.0: [2,12]. - - 범위: `2` ~ `30` - - - - 작업 타임아웃 임계값(초). 기본값 172800 (48시간). 범위: [3600, 259200]. - - 범위: `3600` ~ `259200` - - - - Seedance 2.5, 2.0, 2.0 fast 및 1.5 pro에서 지원됩니다. 생성된 비디오에 화면과 동기화된 오디오가 포함되는지 여부. -true: 모델이 동기화된 오디오가 포함된 비디오를 출력합니다. -false: 모델이 무음 비디오를 출력합니다. - - - - 호출할 모델의 ID. 지원되는 모델: seedance-1-5-pro-251215, seedance-1-0-pro-250528, seedance-1-0-pro-fast-251015, seedance-1-0-lite-t2v-250428, seedance-1-0-lite-i2v-250428, dreamina-seedance-2-0-260128, dreamina-seedance-2-0-fast-260128, dreamina-seedance-2-0-mini 및 dreamina-seedance-2-5-260628. POST /proxy/byteplus/api/v3/contents/generations/tasks에 대한 직접 v1 호출은 반드시 이를 제공해야 하며, 프록시는 다른 값이나 누락된 값에 대해 400으로 거부합니다. 이 스키마의 `required` 목록에 없는 이유는 Comfy Router가 /v2/models/byteplus/\{model}의 `{model}` 경로 세그먼트에서 이를 채우므로 Router 호출자는 이를 생략하기 때문입니다. - - - - Seedance 2.5 전용. 출력 비디오의 컨테이너 형식. -mp4: 범용 컨테이너(H.264/AAC, yuv420p)로 호환성이 넓고 파일 크기가 더 작습니다. -mov: 전문가용 컨테이너(H.264 High 4:4:4 Predictive/PCM, yuv444p)로 색상 정밀도가 높아 후반 작업에 적합하지만 파일 크기가 더 큽니다. - - 가능한 값: `mp4`, `mov` - - - - 생성된 비디오의 비율. Seedance 2.0 및 2.0 fast, 1.5 pro 기본값: adaptive. - - 가능한 값: `16:9`, `4:3`, `1:1`, `3:4`, `9:16`, `21:9`, `9:21`, `adaptive` - - - - 비디오 해상도. Seedance 2.5, 2.0 및 2.0 fast, 1.5 pro, 1.0 lite 기본값: 720p. Seedance 1.0 pro 및 pro-fast 기본값: 1080p. -참고: Seedance 2.0 및 2.0 fast는 1080p를 지원하지 않습니다. Seedance 2.5는 480p, 720p 및 1080p를 지원합니다. - - 가능한 값: `480p`, `720p`, `1080p`, `4k` - - - - 생성된 비디오의 마지막 프레임 이미지를 반환할지 여부.참: 생성된 비디오의 마지막 프레임 이미지를 반환합니다. 이 매개변수를 참으로 설정하면 비디오 생성 작업 정보 조회를 호출하여 마지막 프레임 이미지를 얻을 수 있습니다. 마지막 프레임 이미지는 PNG 형식이며, 픽셀 너비와 높이는 생성된 비디오와 동일하고 워터마크가 포함되지 않습니다. 이 매개변수를 사용하면 여러 개의 연속된 비디오를 생성할 수 있습니다. 이전에 생성된 비디오의 마지막 프레임이 다음 비디오 작업의 첫 번째 프레임으로 사용되므로 여러 개의 연속된 비디오를 빠르게 생성할 수 있습니다. -거짓: 생성된 비디오의 마지막 프레임 이미지를 반환하지 않습니다. - - - - 무작위성을 제어하는 시드 정수입니다. 범위: [-1, 2^32-1]. -1은 무작위 시드를 사용합니다. - - 범위: `-1` ~ `4294967295` - - - - 처리에 사용할 서비스 등급입니다. Seedance 2.5, 2.0 & 2.0 fast는 flex(오프라인 추론)를 지원하지 않습니다. - - 가능한 값: `default`, `flex` - - - - 생성된 비디오에 워터마크가 포함되는지 여부입니다. - - -Router가 `GET /v2/models/byteplus/seedance-1-0-lite-t2v-250428/openapi.json`에서 제공하는 스키마에서 생성되었으며, 이는 요청이 공급자에게 도달하기 이전에 호출을 검증할 때 사용하는 것과 동일한 문서입니다. -### 출력 - - - 비디오 생성 작업이 완료된 후의 출력으로, 출력 비디오의 다운로드 URL과 BytePlus가 반환하는 경우 마지막 프레임의 다운로드 URL을 포함합니다. `video_url`과 `last_frame_url`은 모두 Comfy 스토리지로 재호스팅되며, 여기의 다른 모든 필드는 BytePlus 자체 필드입니다. null을 허용합니다. BytePlus는 작업 후 24시간이 지나면 URL을 지우므로, 그 이후에 폴링한 succeeded 문서에는 `content`가 없거나 null일 수 있습니다. - - - - 생성된 비디오의 마지막 프레임에 대한 다운로드 URL로, 요청에서 `return_last_frame`을 설정한 경우 반환됩니다. 이 URL로부터 이미지 형식을 추론하지 마십시오. BytePlus는 요청 측에서 마지막 프레임을 PNG로 문서화하지만, Router는 전달받은 바이트를 그대로 재호스팅하고 업스트림 Content-Type 또는 콘텐츠 스니핑을 통해 타입을 지정하며, `image/jpeg`는 둘 다 실패했을 때의 최후 수단 폴백일 뿐입니다. Router는 마지막 프레임을 Comfy 스토리지로 재호스팅하고 이 필드를 다시 쓰므로, 일반적으로 최대 24시간 동안 유효한 Comfy 서명 URL입니다. 발급 시 24시간으로 서명되고 23시간 메모에서 재생되므로, 나중에 폴링하면 남은 시간이 1시간도 안 되는 URL을 돌려받을 수 있습니다. 재호스팅을 수행할 수 없었던 경우 이 필드는 대신 BytePlus 자체 URL을 유지하며, BytePlus는 작업 후 24시간이 지나면 이를 지웁니다. 어느 쪽이든 링크는 만료되므로 URL을 저장하지 말고 프레임을 다운로드하십시오. - - - - 생성된 비디오의 컨테이너 형식(mp4 또는 mov)으로, BytePlus가 이를 `content` 안에 중첩해 넣는 경우에 해당합니다. Seedance 모델은 이를 `content`의 최상위 형제 필드로 반환하는 경우가 더 많습니다(최상위 `output_format` 필드 참조). Router는 둘 중 존재하는 쪽을 읽습니다. - - - - 출력 비디오의 다운로드 URL입니다. Router는 비디오를 Comfy 스토리지로 재호스팅하고 이 필드를 다시 쓰므로, 일반적으로 최대 24시간 동안 유효한 Comfy 서명 URL입니다. 발급 시 24시간으로 서명되고 23시간 메모에서 재생되므로, 나중에 폴링하면 남은 시간이 1시간도 안 되는 URL을 돌려받을 수 있습니다. 재호스팅을 수행할 수 없었던 경우 이 필드는 대신 BytePlus 자체 URL을 유지하며, BytePlus는 작업 후 24시간이 지나면 이를 지우고 일부 모델에서는 다운로드 횟수를 100회로 제한합니다. 어느 쪽이든 링크는 만료되므로 URL을 저장하지 말고 비디오를 다운로드하십시오. - - - - 작업이 생성된 시간입니다. 값은 초 단위의 UNIX 타임스탬프입니다. - - - - 생성된 비디오의 재생 시간(초)입니다. BytePlus가 이를 일관되게 처리하지 않기 때문에 정수(integer)가 아닌 숫자(number)로 선언되었습니다. 비디오 작업에서는 정수 초를 반환하는 것이 관찰되었고, 인접한 BytePlus 인터페이스에서는 소수 재생 시간을 보고하기도 하므로, 클라이언트는 값이 정수라고 가정해서는 안 됩니다. BytePlus 자체 필드로, 성공한 비디오 작업에서 반환되며 변경 없이 전달됩니다. - - - - 오류 정보입니다. 작업이 성공하면 null이 반환됩니다. 작업이 실패하면 오류 정보가 반환됩니다. - - - - 오류 코드 - - - - 오류 메시지 - - - - 비디오 생성 작업의 ID - - - - 작업에 사용된 모델의 이름과 버전 - - - - 생성된 비디오의 컨테이너 형식(mp4 또는 mov)으로, `content`의 형제로 최상위 레벨에 반환됩니다. Seedance 비디오 작업 쿼리가 반환하는 위치가 바로 여기입니다. BytePlus 자체 필드로, 변경 없이 전달됩니다. - - - - 생성된 비디오의 해상도로, 예를 들어 `1080p`입니다. BytePlus 자체 필드로, 성공한 비디오 작업에서 반환되며 변경 없이 전달됩니다. - - - - 작업에 실제로 사용된 생성 시드입니다. BytePlus 자체 필드로, 성공한 비디오 작업에서 반환되며 변경 없이 전달됩니다. - - 형식: `int64` - - - - 작업의 상태 - - 가능한 값: `queued`, `running`, `cancelled`, `succeeded`, `failed`, `expired` - - - - 작업이 마지막으로 업데이트된 시간입니다. 값은 초 단위의 UNIX 타임스탬프입니다. - - - - 요청의 토큰 사용량 - - - - 모델이 생성한 토큰 수 - - - - 비디오 생성 모델의 경우 입력 토큰 수는 계산되지 않고 0으로 기본 설정됩니다. 따라서 total_tokens = completion_tokens입니다. - - -## 예시 - -### 입력 - -```json -{ - "content": [ - { - "text": "A red fox trotting through a snowy pine forest", - "type": "text" - } - ], - "duration": 5, - "ratio": "16:9", - "resolution": "720p" -} -``` - -### 출력 - -```json -{ - "content": { - "last_frame_url": "https://example.invalid/byteplus/seedance-1-0-lite-t2v-250428/last-frame", - "video_url": "https://example.invalid/byteplus/seedance-1-0-lite-t2v-250428/generated.mp4" - }, - "created_at": 1767225600, - "duration": 5, - "error": null, - "id": "3f7a1b28-5c0d-4e91-8a6f-1b2c3d4e5f60", - "model": "seedance-1-0-lite-t2v-250428", - "output_format": "mp4", - "resolution": "1080p", - "seed": 1234567890123, - "status": "succeeded", - "updated_at": 1767225730 -} -``` - - - diff --git a/ko/development/comfy-router/models/byteplus/seededit-3-0-i2i-250628/code.mdx b/ko/development/comfy-router/models/byteplus/seededit-3-0-i2i-250628/code.mdx deleted file mode 100644 index 019861d2b4..0000000000 --- a/ko/development/comfy-router/models/byteplus/seededit-3-0-i2i-250628/code.mdx +++ /dev/null @@ -1,391 +0,0 @@ ---- -title: "Comfy Router로 Seededit 3.0 I2I 250628 사용하기" -description: "Comfy Router를 통해 byteplus/seededit-3-0-i2i-250628을 호출합니다: 엔드포인트, 요청 형태, 그리고 Router가 반환하는 응답." -sidebarTitle: "Seededit 3.0 I2I 250628" -translationSourceHash: cfe4b48a -translationFrom: development/comfy-router/models/byteplus/seededit-3-0-i2i-250628/code.mdx -translationBlockHashes: - "_intro": b2e7faed - "Quick start": 0aef594c - "Schema": fe63d102 - "Examples": 130ffbde ---- -{/* GENERATED FILE. Generated from router-schemas/byteplus/seededit-3-0-i2i-250628.json by `pnpm code-pages:gen`. */} - -import RouterCodeFooter from "/snippets/ko/comfy-router/model-code-footer.mdx"; - -`byteplus/seededit-3-0-i2i-250628`의 API 레퍼런스입니다. 이 모델은 BytePlus에서 제공하며 Comfy Router를 통해 서비스됩니다. - -## 빠른 시작 - -[Comfy 워크스페이스](https://platform.comfy.org/profile/api-keys)에서 키를 생성하고 `COMFY_API_KEY`로 내보내기 하세요. Python 및 TypeScript 스니펫은 Comfy SDK(`pip install comfy-sdk`, `npm install @comfyorg/sdk`)를 사용하며, cURL 스니펫은 동일한 호출을 raw HTTP로 수행합니다. - -**모델 ID:** `byteplus/seededit-3-0-i2i-250628` - -**엔드포인트:** `POST https://api.comfy.org/v2/models/byteplus/seededit-3-0-i2i-250628` - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# The SDK automatically creates an idempotency key and reuses it for automatic retries. -with Comfy() as client: - result = client.models.run( - "byteplus/seededit-3-0-i2i-250628", - { - "prompt": "A red fox trotting through a snowy pine forest, cinematic lighting", - "response_format": "url", - "watermark": False, - }, - ) - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// The SDK automatically creates an idempotency key and reuses it for automatic retries. -const { data } = await comfy.models.run("byteplus/seededit-3-0-i2i-250628", { - prompt: "A red fox trotting through a snowy pine forest, cinematic lighting", - response_format: "url", - watermark: false, -}); - -console.log(data); -``` - -```bash cURL -curl https://api.comfy.org/v2/models/byteplus/seededit-3-0-i2i-250628 \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"prompt\": \"A red fox trotting through a snowy pine forest, cinematic lighting\", \"response_format\": \"url\", \"watermark\": false}" -``` - - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -with Comfy() as client: - handle = client.models.submit( - "byteplus/seededit-3-0-i2i-250628", - { - "prompt": "A red fox trotting through a snowy pine forest, cinematic lighting", - "response_format": "url", - "watermark": False, - }, - ) - print("request_id:", handle.request_id) # with the model ID, all another process needs - - # Poll until the request completes, waiting the Retry-After the server names. - for update in handle.iter_events(): - print(update.status, update.queue_position) - - # The provider's own payload, the same value models.run() returns. - # A request that failed or was cancelled raises the typed Router error here. - result = handle.get() - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -const handle = await comfy.models.submit("byteplus/seededit-3-0-i2i-250628", { - prompt: "A red fox trotting through a snowy pine forest, cinematic lighting", - response_format: "url", - watermark: false, -}); -console.log("requestId:", handle.requestId); // with the model ID, all another process needs - -// Poll until the request completes, waiting the Retry-After the server names. -for await (const update of handle.events()) { - console.log(update.status, update.queuePosition); -} - -// The same result models.run() returns. A request that failed or was cancelled rejects here. -const result = await handle.get(); - -console.log(result.data); -``` - -```bash cURL -# 1. Submit. Router answers 201 with request_id, status_url, response_url and cancel_url. -curl https://api.comfy.org/v2/models/byteplus/seededit-3-0-i2i-250628/requests \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"prompt\": \"A red fox trotting through a snowy pine forest, cinematic lighting\", \"response_format\": \"url\", \"watermark\": false}" - -# 2. Poll until status is COMPLETED, waiting the Retry-After seconds each response names. -REQUEST_ID="" -curl -i https://api.comfy.org/v2/models/byteplus/seededit-3-0-i2i-250628/requests/$REQUEST_ID/status \ - -H "X-API-Key: $COMFY_API_KEY" - -# 3. Collect. 200 with the model's native output, 202 with the status body while it is still running. -curl https://api.comfy.org/v2/models/byteplus/seededit-3-0-i2i-250628/requests/$REQUEST_ID \ - -H "X-API-Key: $COMFY_API_KEY" -``` - - - - - -## 스키마 - -### 입력 - - - 출력 이미지가 입력 프롬프트에 얼마나 밀접하게 부합하는지 제어합니다. 범위 [1, 10]. 값이 높을수록 프롬프트 준수가 강해집니다. seedream-3-0-t2i-250415의 기본값은 2.5, seededit-3-0-i2i-250628의 기본값은 5.5입니다. seedream-5.0-pro, 5.0-lite, 4.5 및 4.0에서는 지원되지 않습니다. - - 범위: `1` ~ `10` - - 형식: `float` - - - - Seedream-5.0-pro, 5.0-lite, 4.5 및 4.0과 seededit-3.0-i2i가 이 매개변수를 지원합니다. - -편집할 이미지의 Base64 인코딩 또는 접근 가능한 URL을 입력하세요. Seedream-5.0-pro, 5.0-lite, 4.5 및 4.0은 단일 이미지 또는 여러 이미지 입력을 지원하며(멀티 이미지 블렌딩 예시 참조), seededit-3.0-i2i는 단일 이미지 입력만 지원합니다. - -• 이미지 URL: 이미지 URL에 접근할 수 있는지 확인하세요. -• Base64 인코딩: 형식은 data:image/\;base64,\이어야 합니다. 참고: \은 소문자여야 합니다(예: data:image/png;base64,\). - -Comfy Router는 base64 확장과 모든 참조 이미지를 포함하여 전체 JSON 요청을 10 MiB로 제한합니다. 이 전송 제한을 초과할 수 있는 입력에는 URL을 사용하세요. - -입력 이미지는 다음 요구 사항을 충족해야 합니다: -• 이미지 형식: jpeg, png (seedream-5.0-pro, 5.0-lite, 4.5 및 4.0은 webp, bmp, tiff, gif도 지원하며, seedream-5.0-pro는 heic와 heif도 지원합니다) -• 가로세로 비율(너비/높이): seedream-5.0-pro, 5.0-lite, 4.5 및 4.0의 경우 [1/16, 16] 범위, seededit-3.0-i2i의 경우 [1/3, 3] 범위 -• 너비와 높이(px): > 14 -• 크기: 10 MB 이하(seedream-5.0-pro의 경우 30 MB) -• 총 픽셀: seedream-5.0-pro의 경우 6000x6000(36,000,000 px) 이하 -• 참조 이미지 최대 14개(seedream-5.0-pro의 경우 10개) - -레이어 분리 시나리오에서는(layer_decomposition 활성화) image가 필수이며 단일 입력 이미지만 지원합니다(여러 이미지를 전달하면 오류가 반환됩니다). 입력 이미지는 png, jpeg, webp, bmp, tiff 또는 gif여야 하며(heic와 heif는 지원되지 않음), 최대 30 MB이고, 총 픽셀이 [512x512, 6000x6000] 범위이며 가로세로 비율이 [1/16, 16] 범위여야 합니다. - - - - 레이어 분리를 활성화할지 여부를 제어합니다. seedream-5.0-pro만 이 매개변수를 지원합니다. -true: 레이어 분리 모드입니다. 모델은 단일 입력 이미지를 하나의 기본 이미지와 여러 레이어(최대 16개)로 분해하고, 생성된 각 레이어의 위치와 콘텐츠 정보를 반환합니다. 여기에는 쌓임 순서(z_index), 바운딩 박스(bounding_box), 이름(name) 및 설명(description)이 포함됩니다. -false: 표준 이미지 생성 모드이며 레이어 분리를 수행하지 않습니다. -레이어 분리 모드 관련 참고 사항: 단일 입력 이미지만 지원합니다(여러 이미지를 전달하면 오류가 반환됩니다). 단일 레이어라도 생성에 실패하면 전체 요청이 실패합니다. 부분 성공은 지원되지 않습니다. 반환되는 이미지는 최대 17개(기본 이미지 1개 + 레이어 16개)입니다. sequential_image_generation, sequential_image_generation_options, tools 및 stream을 전달하면 오류가 반환됩니다. - - - - 모델 식별자입니다. 지원되는 모델: seedream-3-0-t2i-250415, seededit-3-0-i2i-250628, seedream-4-0-250828, seedream-4-5-251128, seedream-5-0-260128 및 seedream-5-0-pro-260628. POST /proxy/byteplus/api/v3/images/generations에 대한 직접 v1 호출은 반드시 이를 제공해야 합니다. 프록시는 다른 값이나 값이 누락된 경우 400으로 거부합니다. 이 스키마의 `required` 목록에 없는 이유는 Comfy Router가 /v2/models/byteplus/\{model}의 `{model}` 경로 세그먼트에서 이 값을 채우므로 Router 호출자는 이를 생략하기 때문입니다. - - - - 프롬프트 최적화 기능에 대한 구성입니다. seedream-5.0-pro/5.0-lite/4.5(표준 모드만 지원)와 seedream-4.0만 이 매개변수를 지원합니다. - - - - 프롬프트 최적화 기능의 모드를 설정합니다. standard = 더 높은 품질, 더 긴 생성 시간. fast = 더 빠르지만 평균적인 품질. - - 가능한 값: `standard`, `fast` - - - - 출력 이미지의 형식을 지정합니다. seedream-5.0-pro와 5.0-lite만 이 매개변수를 지원합니다. 레이어 분리 시나리오에서 output_format은 기본 이미지의 형식만 제어하며, 모든 레이어는 항상 png로 출력됩니다. - - 가능한 값: `png`, `jpeg` - - - - 이미지 생성 또는 변환을 위한 텍스트 설명입니다. -레이어 분리 시나리오(layer_decomposition이 활성화된 seedream-5.0-pro)에서는 선택 사항입니다. 프롬프트를 제공하면 모델이 프롬프트 의도에 따라 지정한 요소를 인식하고 분리합니다. 프롬프트를 제공하지 않으면 모델이 이미지의 모든 주요 요소를 자동으로 감지하여 독립적인 레이어로 분리합니다. - - - - 응답에 반환되는 생성된 이미지의 형식을 지정합니다 - - 가능한 값: `url`, `b64_json` - - - - 이미지 생성의 무작위성을 제어하는 시드입니다. 범위: [-1, 2147483647]. 지정하지 않으면 시드가 자동으로 생성됩니다. 동일한 출력을 재현하려면 동일한 시드 값을 사용하세요. - - 범위: `-1` ~ `2147483647` - - - - 배치 생성 기능을 비활성화할지 여부를 제어합니다. 이 매개변수는 seedream-5.0-lite, 4.5 및 4.0에서만 지원됩니다(seedream-5.0-pro에서는 지원되지 않음). 유효한 값: -auto: 자동 모드에서는 사용자의 프롬프트를 기반으로 모델이 여러 이미지를 반환할지 여부와 포함할 이미지 수를 자동으로 결정합니다. -disabled: 배치 생성 기능을 비활성화합니다. 모델은 하나의 이미지만 생성합니다. - - 가능한 값: `auto`, `disabled` - - - - seedream-5.0-lite, 4.5, 4.0만 이 파라미터를 지원합니다(seedream-5.0-pro는 지원하지 않음). -배치 이미지 생성 기능에 대한 설정입니다. 이 파라미터는 sequential_image_generation이 auto로 설정된 경우에만 적용됩니다. - - - - 이 요청에서 생성할 최대 이미지 수를 지정합니다. 입력 참조 이미지 수 + 생성된 이미지 수 ≤ 15. - - 범위: `1` ~ `15` - - - - "seedream-3-0-t2i-250415": 생성된 이미지의 크기(픽셀 단위의 너비 x 높이)를 지정합니다. [512x512, 2048x2048] 사이여야 합니다. -"seededit-3-0-i2i-250628": 생성된 이미지의 너비와 높이 픽셀입니다. 현재는 adaptive만 지원합니다. -"seedream-4-0-250828": 생성할 이미지의 규격을 설정합니다. 두 가지 방법을 사용할 수 있지만 함께 사용할 수는 없습니다. - 방법 1 | 해상도를 지정합니다. 선택 가능한 값: 1K, 2K, 4K - 방법 2 | 너비와 높이를 픽셀 단위로 지정합니다. 기본값: 2048x2048, 총 픽셀: [1024x1024, 4096x4096], 가로세로 비율: [1/16, 16] -"seedream-4-5-251128": 두 가지 방법을 사용할 수 있습니다. - 방법 1 | 해상도를 지정합니다. 선택 가능한 값: 2K, 4K - 방법 2 | 너비와 높이를 픽셀 단위로 지정합니다. 기본값: 2048x2048, 총 픽셀: [2560x1440, 4096x4096], 가로세로 비율: [1/16, 16] -"seedream-5-0-260128": 두 가지 방법을 사용할 수 있습니다. - 방법 1 | 해상도를 지정합니다. 선택 가능한 값: 2K, 3K - 방법 2 | 너비와 높이를 픽셀 단위로 지정합니다. 기본값: 2048x2048, 총 픽셀: [2560x1440, ~3072x3072], 가로세로 비율: [1/16, 16] -"seedream-5-0-pro-260628": 두 가지 방법을 사용할 수 있습니다(함께 사용할 수 없음). - 방법 1 | 해상도를 지정하고 프롬프트에 이미지의 가로세로 비율, 형태 또는 용도를 설명합니다. 최종 크기는 모델이 결정합니다. 선택 가능한 값: 1K, 2K - 방법 2 | 너비와 높이를 픽셀 단위로 지정합니다. 기본값: 1024x1024, 총 픽셀: [1024x1024 (1048576), 2048x2048 (4194304)], 가로세로 비율: [1/16, 16] -layer_decomposition이 활성화된 "seedream-5-0-pro-260628": 해상도 수준의 방법만 지원합니다. 선택 가능한 값: 1K, 1.5K, 2K, auto. 기본값: auto. - 기본 이미지는 원본 입력 이미지의 가로세로 비율로 지정된 해상도에 출력되며, 각 레이어는 원본 이미지에서의 가로세로 비율을 유지한 채 지정된 해상도에 가깝게 출력됩니다. - auto: 입력 이미지의 크기와 가로세로 비율을 기준으로 출력합니다. [1280x720, ~2048x2048] 범위의 입력은 원본 입력 크기로 출력되고, 1K보다 작은 입력은 1K로 출력되며, 2K보다 큰 입력은 2K로 출력됩니다. - - - - Comfy Router는 완전한 JSON 결과를 캡처하기 때문에 명시적으로 전달된 stream 플래그를 false로 확정합니다. v1 프록시에서 이 필드는 스트리밍 출력 모드를 활성화할지 여부를 제어합니다. seedream-5.0-lite, 4.5, 4.0만 이 파라미터를 지원합니다(seedream-5.0-pro는 지원하지 않음). false = 모든 출력 이미지가 한 번에 반환됩니다. true = 각 출력 이미지가 생성되는 즉시 반환됩니다. - - - - 생성된 이미지에 워터마크를 추가할지 여부를 지정합니다. false = 워터마크 없음, true = 'AI generated' 라벨이 있는 워터마크 추가 - - -Router가 `GET /v2/models/byteplus/seededit-3-0-i2i-250628/openapi.json`에서 제공하는 스키마에서 생성되었으며, 이는 요청이 공급자에게 도달하기 전에 호출을 검증하는 데 사용하는 것과 동일한 문서입니다. -### 출력 - - - 요청이 생성된 시간을 나타내는 Unix 타임스탬프(초 단위) - - - - 생성된 이미지에 대한 정보를 포함합니다. -레이어 분리 시나리오에서는 배열의 첫 번째 요소가 베이스 이미지(z_index=0)이고, 그다음 요소들은 레이어이며 z_index가 증가하는 순서로 정렬됩니다. - - - - Base64로 인코딩된 이미지 데이터(response_format이 "b64_json"인 경우) - - - - 현재 레이어가 베이스 이미지 내에서 차지하는 영역의 바운딩 박스 정보입니다. 이 필드는 레이어만 반환하며, 베이스 이미지는 캔버스 전체를 덮으므로 bounding_box를 반환하지 않습니다. layer_decomposition이 참인 경우에만 반환됩니다. - - - - 레이어 바운딩 박스의 절대 픽셀 좌표로, 왼쪽 위 모서리가 (0, 0)인 출력 베이스 이미지의 좌표계를 기준으로 합니다. 좌표 형식: [left, top, right, bottom]. - - - - 베이스 이미지 크기를 기준으로 [0, 1000]의 이산 정수 범위에 비례적으로 매핑된, 레이어 바운딩 박스의 천분율(per-mille) 양자화(정규화) 좌표이며, 최대 1000에서 잘립니다. 좌표 형식: [left, top, right, bottom]. - - - - 현재 분리된 요소에 대한 상세 설명으로, name보다 풍부한 레이어 특성(색상, 상태, 재질 등)을 제공합니다. 이 필드는 레이어만 반환하며, 베이스 이미지는 반환하지 않습니다. layer_decomposition이 참인 경우에만 반환됩니다. - - - - 현재 분리된 요소의 이름/레이블로, 분리된 대상의 특성으로부터 모델이 자동으로 생성합니다. 이 필드는 레이어만 반환하며, 베이스 이미지는 반환하지 않습니다. layer_decomposition이 참인 경우에만 반환됩니다. - - - - 출력 이미지의 파일 형식입니다. 이 필드는 seedream-5.0-pro만 지원합니다. - - - - 이미지의 너비와 높이(픽셀)이며, 형식은 \x\입니다. 이 매개변수는 seedream-5.0-pro, 5.0-lite, 4.5, 4.0만 지원합니다. - - - - 이미지 다운로드 URL(response_format이 "url"인 경우) - - 형식: `uri` - - - - 레이어의 적층 순서로, 아래에서 위로 갈수록 증가합니다. 0은 가장 아래 레이어(베이스 이미지)이고, 값이 클수록 위에 위치합니다. 레이어를 올바른 적층 순서로 다시 조합해 완성된 이미지로 만들 때 사용합니다. layer_decomposition이 참인 경우에만 반환됩니다. - - - - 오류 정보(있는 경우) - - - - 오류 코드 - - - - 오류 메시지 - - - - 요청에 사용된 모델 ID - - - - - - - - 모델이 생성한 이미지 수 - - - - 모델에 입력된 이미지 수입니다. 이 필드는 seedream-5.0-pro만 지원합니다. - - - - 모델이 생성한 그림에 사용된 토큰 수입니다. - - - - 이 요청에서 소비된 총 토큰 수입니다. - - -## 예시 - -### 입력 - -```json -{ - "prompt": "A red fox trotting through a snowy pine forest, cinematic lighting", - "response_format": "url", - "watermark": false -} -``` - -### 출력 - -```json -{ - "created": 1767225600, - "data": [ - { - "size": "1024x1024", - "url": "https://example.invalid/byteplus/seedream-3-0-t2i-250415/generated.png" - } - ], - "model": "seededit-3-0-i2i-250628", - "usage": { - "generated_images": 1 - } -} -``` - - - diff --git a/ko/development/comfy-router/models/byteplus/seedream-3-0-t2i-250415/code.mdx b/ko/development/comfy-router/models/byteplus/seedream-3-0-t2i-250415/code.mdx deleted file mode 100644 index 2e67a80703..0000000000 --- a/ko/development/comfy-router/models/byteplus/seedream-3-0-t2i-250415/code.mdx +++ /dev/null @@ -1,391 +0,0 @@ ---- -title: "Comfy Router로 Seedream 3.0 T2I 250415 사용하기" -description: "Comfy Router를 통해 byteplus/seedream-3-0-t2i-250415를 호출합니다: 엔드포인트, 요청 형태, 그리고 Router가 반환하는 응답." -sidebarTitle: "Seedream 3.0 T2I 250415" -translationSourceHash: 18f23e78 -translationFrom: development/comfy-router/models/byteplus/seedream-3-0-t2i-250415/code.mdx -translationBlockHashes: - "_intro": dafe6167 - "Quick start": 16428856 - "Schema": c6abe2a5 - "Examples": 61ceb30b ---- -{/* 생성된 파일. router-schemas/byteplus/seedream-3-0-t2i-250415.json에서 `pnpm code-pages:gen`으로 생성되었습니다. */} - -import RouterCodeFooter from "/snippets/ko/comfy-router/model-code-footer.mdx"; - -Comfy Router가 BytePlus에서 제공하는 `byteplus/seedream-3-0-t2i-250415`에 대한 API 레퍼런스입니다. - -## 빠른 시작 - -[Comfy 워크스페이스](https://platform.comfy.org/profile/api-keys)에서 키를 생성하고 `COMFY_API_KEY`로 내보내세요. Python 및 TypeScript 스니펫은 Comfy SDK(`pip install comfy-sdk`, `npm install @comfyorg/sdk`)를 사용하며, cURL 스니펫은 동일한 호출을 원시 HTTP로 수행합니다. - -**모델 ID:** `byteplus/seedream-3-0-t2i-250415` - -**엔드포인트:** `POST https://api.comfy.org/v2/models/byteplus/seedream-3-0-t2i-250415` - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# The SDK automatically creates an idempotency key and reuses it for automatic retries. -with Comfy() as client: - result = client.models.run( - "byteplus/seedream-3-0-t2i-250415", - { - "prompt": "A red fox trotting through a snowy pine forest, cinematic lighting", - "response_format": "url", - "watermark": False, - }, - ) - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// The SDK automatically creates an idempotency key and reuses it for automatic retries. -const { data } = await comfy.models.run("byteplus/seedream-3-0-t2i-250415", { - prompt: "A red fox trotting through a snowy pine forest, cinematic lighting", - response_format: "url", - watermark: false, -}); - -console.log(data); -``` - -```bash cURL -curl https://api.comfy.org/v2/models/byteplus/seedream-3-0-t2i-250415 \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"prompt\": \"A red fox trotting through a snowy pine forest, cinematic lighting\", \"response_format\": \"url\", \"watermark\": false}" -``` - - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -with Comfy() as client: - handle = client.models.submit( - "byteplus/seedream-3-0-t2i-250415", - { - "prompt": "A red fox trotting through a snowy pine forest, cinematic lighting", - "response_format": "url", - "watermark": False, - }, - ) - print("request_id:", handle.request_id) # with the model ID, all another process needs - - # Poll until the request completes, waiting the Retry-After the server names. - for update in handle.iter_events(): - print(update.status, update.queue_position) - - # The provider's own payload, the same value models.run() returns. - # A request that failed or was cancelled raises the typed Router error here. - result = handle.get() - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -const handle = await comfy.models.submit("byteplus/seedream-3-0-t2i-250415", { - prompt: "A red fox trotting through a snowy pine forest, cinematic lighting", - response_format: "url", - watermark: false, -}); -console.log("requestId:", handle.requestId); // with the model ID, all another process needs - -// Poll until the request completes, waiting the Retry-After the server names. -for await (const update of handle.events()) { - console.log(update.status, update.queuePosition); -} - -// The same result models.run() returns. A request that failed or was cancelled rejects here. -const result = await handle.get(); - -console.log(result.data); -``` - -```bash cURL -# 1. Submit. Router answers 201 with request_id, status_url, response_url and cancel_url. -curl https://api.comfy.org/v2/models/byteplus/seedream-3-0-t2i-250415/requests \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"prompt\": \"A red fox trotting through a snowy pine forest, cinematic lighting\", \"response_format\": \"url\", \"watermark\": false}" - -# 2. Poll until status is COMPLETED, waiting the Retry-After seconds each response names. -REQUEST_ID="" -curl -i https://api.comfy.org/v2/models/byteplus/seedream-3-0-t2i-250415/requests/$REQUEST_ID/status \ - -H "X-API-Key: $COMFY_API_KEY" - -# 3. Collect. 200 with the model's native output, 202 with the status body while it is still running. -curl https://api.comfy.org/v2/models/byteplus/seedream-3-0-t2i-250415/requests/$REQUEST_ID \ - -H "X-API-Key: $COMFY_API_KEY" -``` - - - - - -## 스키마 - -### 입력 - - - 출력 이미지가 입력 프롬프트에 얼마나 밀접하게 부합하는지를 제어합니다. 범위 [1, 10]. 값이 높을수록 프롬프트 준수가 강해집니다. seedream-3-0-t2i-250415의 기본값은 2.5이고 seededit-3-0-i2i-250628의 기본값은 5.5입니다. seedream-5.0-pro, 5.0-lite, 4.5 및 4.0에서는 지원되지 않습니다. - - 범위: `1` ~ `10` - - 형식: `float` - - - - Seedream-5.0-pro, 5.0-lite, 4.5 및 4.0, 그리고 seededit-3.0-i2i가 이 매개변수를 지원합니다. - -편집할 이미지의 Base64 인코딩 또는 접근 가능한 URL을 입력합니다. Seedream-5.0-pro, 5.0-lite, 4.5 및 4.0은 단일 이미지 또는 여러 이미지 입력을 지원하며(다중 이미지 블렌딩 예시 참조), seededit-3.0-i2i는 단일 이미지 입력만 지원합니다. - -• 이미지 URL: 이미지 URL이 접근 가능한지 확인하세요. -• Base64 인코딩: 형식은 data:image/\;base64,\이어야 합니다. 참고: \은 소문자여야 합니다. 예: data:image/png;base64,\. - -Comfy Router는 base64 확장과 모든 참조 이미지를 포함한 전체 JSON 요청을 10 MiB로 제한합니다. 이 전송 한도를 초과하는 입력에는 URL을 사용하세요. - -입력 이미지는 다음 요구 사항을 충족해야 합니다. -• 이미지 형식: jpeg, png (seedream-5.0-pro, 5.0-lite, 4.5 및 4.0은 webp, bmp, tiff, gif도 지원하며, seedream-5.0-pro는 heic와 heif도 지원합니다) -• 가로세로 비율(너비/높이): seedream-5.0-pro, 5.0-lite, 4.5 및 4.0의 경우 [1/16, 16] 범위, seededit-3.0-i2i의 경우 [1/3, 3] 범위 -• 너비와 높이(px): > 14 -• 크기: 10 MB 이하 (seedream-5.0-pro는 30 MB) -• 총 픽셀: seedream-5.0-pro의 경우 6000x6000(36,000,000 px) 이하 -• 참조 이미지 최대 14개 (seedream-5.0-pro는 10개) - -레이어 분리 시나리오(layer_decomposition 활성화)에서는 image가 필수이며 단일 입력 이미지만 지원합니다(여러 이미지를 전달하면 오류가 반환됩니다). 입력 이미지는 png, jpeg, webp, bmp, tiff 또는 gif여야 하며(heic와 heif는 지원되지 않음), 최대 30 MB이고 총 픽셀이 [512x512, 6000x6000] 범위, 가로세로 비율이 [1/16, 16] 범위여야 합니다. - - - - 레이어 분리 활성화 여부를 제어합니다. seedream-5.0-pro만 이 매개변수를 지원합니다. -true: 레이어 분리 모드입니다. 모델이 단일 입력 이미지를 하나의 기본 이미지와 여러 레이어(최대 16개)로 분해하고, 생성된 각 레이어의 위치와 콘텐츠 정보를 반환합니다. 여기에는 스태킹 순서(z_index), 바운딩 박스(bounding_box), 이름(name) 및 설명(description)이 포함됩니다. -false: 표준 이미지 생성 모드이며 레이어 분리를 수행하지 않습니다. -레이어 분리 모드 참고 사항: 단일 입력 이미지만 지원합니다(여러 이미지를 전달하면 오류가 반환됩니다). 개별 레이어 생성이 하나라도 실패하면 전체 요청이 실패하며 부분 성공은 지원되지 않습니다. 최대 17개 이미지(기본 이미지 1개 + 레이어 16개)가 반환됩니다. sequential_image_generation, sequential_image_generation_options, tools 및 stream을 전달하면 오류가 반환됩니다. - - - - 모델 식별자입니다. 지원 모델: seedream-3-0-t2i-250415, seededit-3-0-i2i-250628, seedream-4-0-250828, seedream-4-5-251128, seedream-5-0-260128 및 seedream-5-0-pro-260628. POST /proxy/byteplus/api/v3/images/generations로의 직접 v1 호출은 반드시 이를 제공해야 합니다. 프록시는 다른 값이나 누락된 값을 400으로 거부합니다. 이 스키마의 `required` 목록에 없는 이유는 Comfy Router가 /v2/models/byteplus/\{model}의 `{model}` 경로 세그먼트에서 이를 채우기 때문에 Router 호출자는 생략하기 때문입니다. - - - - 프롬프트 최적화 기능에 대한 설정입니다. seedream-5.0-pro/5.0-lite/4.5(standard 모드만 지원)와 seedream-4.0만 이 매개변수를 지원합니다. - - - - 프롬프트 최적화 기능의 모드를 설정합니다. standard = 더 높은 품질, 더 긴 생성 시간. fast = 더 빠르지만 평균 수준의 품질. - - 가능한 값: `standard`, `fast` - - - - 출력 이미지의 형식을 지정합니다. seedream-5.0-pro와 5.0-lite만 이 매개변수를 지원합니다. 레이어 분리 시나리오에서 output_format은 기본 이미지의 형식만 제어하며, 모든 레이어는 항상 png로 출력됩니다. - - 가능한 값: `png`, `jpeg` - - - - 이미지 생성 또는 변환을 위한 텍스트 설명입니다. -레이어 분리 시나리오(layer_decomposition이 활성화된 seedream-5.0-pro)에서는 선택 사항입니다. 프롬프트를 제공하면 모델이 프롬프트 의도에 따라 지정한 요소를 인식하고 분리합니다. 프롬프트를 제공하지 않으면 모델이 이미지의 모든 주요 요소를 자동으로 감지하여 독립적인 레이어로 분리합니다. - - - - 응답으로 반환되는 생성된 이미지의 형식을 지정합니다 - - 가능한 값: `url`, `b64_json` - - - - 이미지 생성의 무작위성을 제어하는 시드입니다. 범위: [-1, 2147483647]. 지정하지 않으면 시드가 자동으로 생성됩니다. 동일한 출력을 재현하려면 동일한 시드 값을 사용하세요. - - 범위: `-1` ~ `2147483647` - - - - 배치 생성 기능을 비활성화할지 여부를 제어합니다. 이 매개변수는 seedream-5.0-lite, 4.5 및 4.0에서만 지원됩니다(seedream-5.0-pro는 지원되지 않음). 유효한 값: -auto: 자동 모드에서 모델이 사용자의 프롬프트에 따라 여러 이미지를 반환할지와 몇 개의 이미지를 포함할지를 자동으로 결정합니다. -disabled: 배치 생성 기능을 비활성화합니다. 모델은 하나의 이미지만 생성합니다. - - 가능한 값: `auto`, `disabled` - - - - seedream-5.0-lite, 4.5, 4.0에서만 이 매개변수를 지원합니다(seedream-5.0-pro에서는 지원되지 않음). -배치 이미지 생성 기능에 대한 설정입니다. 이 매개변수는 sequential_image_generation이 auto로 설정된 경우에만 적용됩니다. - - - - 이 요청에서 생성할 최대 이미지 수를 지정합니다. 입력 참조 이미지 수 + 생성된 이미지 수 ≤ 15. - - 범위: `1` ~ `15` - - - - "seedream-3-0-t2i-250415": 생성할 이미지의 크기(픽셀 단위 너비 x 높이)를 지정합니다. [512x512, 2048x2048] 사이여야 합니다. -"seededit-3-0-i2i-250628": 생성된 이미지의 너비와 높이(픽셀)입니다. 현재는 adaptive만 지원합니다. -"seedream-4-0-250828": 생성할 이미지의 규격을 설정합니다. 두 가지 방법을 사용할 수 있지만 함께 사용할 수는 없습니다. - 방법 1 | 해상도를 지정합니다. 선택 가능한 값: 1K, 2K, 4K - 방법 2 | 너비와 높이를 픽셀 단위로 지정합니다. 기본값: 2048x2048, 총 픽셀: [1024x1024, 4096x4096], 가로세로 비율: [1/16, 16] -"seedream-4-5-251128": 두 가지 방법을 사용할 수 있습니다. - 방법 1 | 해상도를 지정합니다. 선택 가능한 값: 2K, 4K - 방법 2 | 너비와 높이를 픽셀 단위로 지정합니다. 기본값: 2048x2048, 총 픽셀: [2560x1440, 4096x4096], 가로세로 비율: [1/16, 16] -"seedream-5-0-260128": 두 가지 방법을 사용할 수 있습니다. - 방법 1 | 해상도를 지정합니다. 선택 가능한 값: 2K, 3K - 방법 2 | 너비와 높이를 픽셀 단위로 지정합니다. 기본값: 2048x2048, 총 픽셀: [2560x1440, ~3072x3072], 가로세로 비율: [1/16, 16] -"seedream-5-0-pro-260628": 두 가지 방법을 사용할 수 있습니다(함께 사용할 수는 없습니다). - 방법 1 | 해상도를 지정하고 프롬프트에 이미지의 가로세로 비율, 형태 또는 용도를 설명합니다. 최종 크기는 모델이 결정합니다. 선택 가능한 값: 1K, 2K - 방법 2 | 너비와 높이를 픽셀 단위로 지정합니다. 기본값: 1024x1024, 총 픽셀: [1024x1024 (1048576), 2048x2048 (4194304)], 가로세로 비율: [1/16, 16] -layer_decomposition이 활성화된 "seedream-5-0-pro-260628": 해상도 단위 방법만 지원합니다. 선택 가능한 값: 1K, 1.5K, 2K, auto. 기본값: auto. - 기본 이미지는 원본 입력 이미지의 가로세로 비율로 지정된 해상도로 출력되며, 각 레이어는 원본 이미지에서 가졌던 가로세로 비율을 유지하면서 지정된 해상도에 가깝게 출력됩니다. - auto: 입력 이미지의 크기와 가로세로 비율을 기준으로 출력합니다. [1280x720, ~2048x2048] 범위의 입력은 원본 입력 크기로 출력되고, 1K보다 작은 입력은 1K로, 2K보다 큰 입력은 2K로 출력됩니다. - - - - Comfy Router는 완전한 JSON 결과를 캡처하므로 명시적으로 전달된 stream 플래그를 거짓으로 처리합니다. v1 프록시에서는 이 필드가 스트리밍 출력 모드를 활성화할지 여부를 제어합니다. seedream-5.0-lite, 4.5, 4.0에서만 이 매개변수를 지원합니다(seedream-5.0-pro에서는 지원되지 않음). false = 모든 출력 이미지가 한 번에 반환됩니다. true = 각 출력 이미지가 생성된 직후 즉시 반환됩니다. - - - - 생성된 이미지에 워터마크를 추가할지 여부를 지정합니다. false = 워터마크 없음, true = 'AI generated' 라벨이 포함된 워터마크 추가 - - -Router가 `GET /v2/models/byteplus/seedream-3-0-t2i-250415/openapi.json`에서 제공하는 스키마를 기반으로 생성되었으며, 이는 요청이 공급자에게 도달하기 전에 호출을 검증할 때 사용하는 것과 동일한 문서입니다. -### 출력 - - - 요청이 생성된 시간을 나타내는 Unix 타임스탬프(초 단위) - - - - 생성된 이미지에 대한 정보를 포함합니다. -레이어 분리 시나리오에서 배열의 첫 번째 요소는 기본 이미지(z_index=0)이며, 그 뒤의 요소들은 z_index가 커지는 순서로 정렬된 레이어입니다. - - - - Base64로 인코딩된 이미지 데이터(response_format이 "b64_json"인 경우) - - - - 현재 레이어가 기본 이미지 내에서 차지하는 영역의 바운딩 박스 정보입니다. 레이어만 이 필드를 반환하며, 기본 이미지는 전체 캔버스를 차지하므로 bounding_box를 반환하지 않습니다. layer_decomposition이 참인 경우에만 반환됩니다. - - - - 왼쪽 위 모서리를 (0, 0)으로 하는 출력 기본 이미지의 좌표계를 기준으로 한, 레이어 바운딩 박스의 절대 픽셀 좌표입니다. 좌표 형식: [left, top, right, bottom]. - - - - 기본 이미지 크기를 기준으로 [0, 1000]의 이산 정수 범위에 비례적으로 매핑하고 최대 1000에서 잘라낸, 레이어 바운딩 박스의 천분율로 양자화된(정규화된) 좌표입니다. 좌표 형식: [left, top, right, bottom]. - - - - 현재 분리된 요소에 대한 상세 설명으로, name보다 풍부한 레이어 특성(색상, 상태, 재질 등)을 제공합니다. 레이어만 이 필드를 반환하며 기본 이미지는 반환하지 않습니다. layer_decomposition이 참인 경우에만 반환됩니다. - - - - 현재 분리된 요소의 이름/레이블로, 분리된 대상의 특성으로부터 모델이 자동으로 생성합니다. 레이어만 이 필드를 반환하며 기본 이미지는 반환하지 않습니다. layer_decomposition이 참인 경우에만 반환됩니다. - - - - 출력 이미지의 파일 형식입니다. seedream-5.0-pro만 이 필드를 지원합니다. - - - - 이미지의 너비와 높이(픽셀)이며, 형식은 \x\입니다. seedream-5.0-pro, 5.0-lite, 4.5, 4.0만 이 매개변수를 지원합니다. - - - - 이미지 다운로드용 URL(response_format이 "url"인 경우) - - 형식: `uri` - - - - 레이어의 쌓임 순서로, 아래에서 위로 갈수록 커집니다. 0은 가장 아래 레이어(기본 이미지)이며 값이 클수록 더 위에 놓입니다. 레이어를 올바른 쌓임 순서로 다시 조합해 완전한 이미지로 만들 때 사용합니다. layer_decomposition이 참인 경우에만 반환됩니다. - - - - 오류 정보(있는 경우) - - - - 오류 코드 - - - - 오류 메시지 - - - - 요청에 사용된 모델 ID - - - - - - - - 모델이 생성한 이미지 수 - - - - 모델에 입력된 이미지 수입니다. seedream-5.0-pro만 이 필드를 지원합니다. - - - - 모델이 생성한 그림에 사용된 토큰 수입니다. - - - - 이 요청에서 소비된 총 토큰 수입니다. - - -## 예시 - -### 입력 - -```json -{ - "prompt": "A red fox trotting through a snowy pine forest, cinematic lighting", - "response_format": "url", - "watermark": false -} -``` - -### 출력 - -```json -{ - "created": 1767225600, - "data": [ - { - "size": "1024x1024", - "url": "https://example.invalid/byteplus/seedream-3-0-t2i-250415/generated.png" - } - ], - "model": "seedream-3-0-t2i-250415", - "usage": { - "generated_images": 1 - } -} -``` - - - diff --git a/ko/development/comfy-router/models/kling/kling-v1-5/code.mdx b/ko/development/comfy-router/models/kling/kling-v1-5/code.mdx deleted file mode 100644 index 0a3d5b85db..0000000000 --- a/ko/development/comfy-router/models/kling/kling-v1-5/code.mdx +++ /dev/null @@ -1,467 +0,0 @@ ---- -title: "Comfy Router로 Kling V1.5 사용하기" -description: "Comfy Router를 통해 kling/kling-v1-5를 호출합니다: 엔드포인트, 요청 형태, 그리고 Router가 반환하는 응답입니다." -sidebarTitle: "Kling V1.5" -translationSourceHash: 7447a97c -translationFrom: development/comfy-router/models/kling/kling-v1-5/code.mdx -translationBlockHashes: - "_intro": f02fc14d - "Quick start": 31463fb0 - "Schema": d81409e3 - "Examples": e835e733 ---- -{/* GENERATED FILE. Generated from router-schemas/kling/kling-v1-5.json by `pnpm code-pages:gen`. */} - -import RouterCodeFooter from "/snippets/ko/comfy-router/model-code-footer.mdx"; - -Kling이 제공하고 Comfy Router가 서비스하는 `kling/kling-v1-5`의 API 레퍼런스입니다. - -## 빠른 시작 - -[Comfy 워크스페이스](https://platform.comfy.org/profile/api-keys)에서 키를 생성하고 `COMFY_API_KEY`로 내보내세요. Python 및 TypeScript 스니펫은 Comfy SDK(`pip install comfy-sdk`, `npm install @comfyorg/sdk`)를 사용하며, cURL 스니펫은 동일한 호출을 원시 HTTP로 수행합니다. - -**모델 ID:** `kling/kling-v1-5` - -**엔드포인트:** `POST https://api.comfy.org/v2/models/kling/kling-v1-5` - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# The SDK automatically creates an idempotency key and reuses it for automatic retries. -with Comfy() as client: - result = client.models.run( - "kling/kling-v1-5", - { - "duration": "5", - "image": "https://example.invalid/kling/reference.png", - "mode": "std", - "prompt": "The fox turns its head towards the camera.", - }, - ) - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// The SDK automatically creates an idempotency key and reuses it for automatic retries. -const { data } = await comfy.models.run("kling/kling-v1-5", { - duration: "5", - image: "https://example.invalid/kling/reference.png", - mode: "std", - prompt: "The fox turns its head towards the camera.", -}); - -console.log(data); -``` - -```bash cURL -curl https://api.comfy.org/v2/models/kling/kling-v1-5 \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"duration\": \"5\", \"image\": \"https://example.invalid/kling/reference.png\", \"mode\": \"std\", \"prompt\": \"The fox turns its head towards the camera.\"}" -``` - - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -with Comfy() as client: - handle = client.models.submit( - "kling/kling-v1-5", - { - "duration": "5", - "image": "https://example.invalid/kling/reference.png", - "mode": "std", - "prompt": "The fox turns its head towards the camera.", - }, - ) - print("request_id:", handle.request_id) # with the model ID, all another process needs - - # Poll until the request completes, waiting the Retry-After the server names. - for update in handle.iter_events(): - print(update.status, update.queue_position) - - # The provider's own payload, the same value models.run() returns. - # A request that failed or was cancelled raises the typed Router error here. - result = handle.get() - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -const handle = await comfy.models.submit("kling/kling-v1-5", { - duration: "5", - image: "https://example.invalid/kling/reference.png", - mode: "std", - prompt: "The fox turns its head towards the camera.", -}); -console.log("requestId:", handle.requestId); // with the model ID, all another process needs - -// Poll until the request completes, waiting the Retry-After the server names. -for await (const update of handle.events()) { - console.log(update.status, update.queuePosition); -} - -// The same result models.run() returns. A request that failed or was cancelled rejects here. -const result = await handle.get(); - -console.log(result.data); -``` - -```bash cURL -# 1. Submit. Router answers 201 with request_id, status_url, response_url and cancel_url. -curl https://api.comfy.org/v2/models/kling/kling-v1-5/requests \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"duration\": \"5\", \"image\": \"https://example.invalid/kling/reference.png\", \"mode\": \"std\", \"prompt\": \"The fox turns its head towards the camera.\"}" - -# 2. Poll until status is COMPLETED, waiting the Retry-After seconds each response names. -REQUEST_ID="" -curl -i https://api.comfy.org/v2/models/kling/kling-v1-5/requests/$REQUEST_ID/status \ - -H "X-API-Key: $COMFY_API_KEY" - -# 3. Collect. 200 with the model's native output, 202 with the status body while it is still running. -curl https://api.comfy.org/v2/models/kling/kling-v1-5/requests/$REQUEST_ID \ - -H "X-API-Key: $COMFY_API_KEY" -``` - - - - - -## 스키마 - -### 입력 - - - 콜백 알림 주소입니다. 작업 상태가 변경되면 서버가 알림을 보냅니다. - - 형식: `uri` - - - - - - - - - - - - 카메라의 수평 축(x축) 이동을 제어합니다. 음수는 왼쪽, 양수는 오른쪽을 나타냅니다. - - 범위: `-10` ~ `10` - - - - 수직 평면에서 카메라의 회전(x축)을 제어합니다. 음수는 아래쪽 회전, 양수는 위쪽 회전을 나타냅니다. - - 범위: `-10` ~ `10` - - - - 카메라의 롤링 수량(z축)을 제어합니다. 음수는 반시계 방향, 양수는 시계 방향을 나타냅니다. - - 범위: `-10` ~ `10` - - - - 수평 평면에서 카메라의 회전(y축)을 제어합니다. 음수는 왼쪽 회전, 양수는 오른쪽 회전을 나타냅니다. - - 범위: `-10` ~ `10` - - - - 카메라의 수직 축(y축) 이동을 제어합니다. 음수는 아래쪽, 양수는 위쪽을 나타냅니다. - - 범위: `-10` ~ `10` - - - - 카메라의 초점 거리 변화를 제어합니다. 음수는 좁은 시야각, 양수는 넓은 시야각을 나타냅니다. - - 범위: `-10` ~ `10` - - - - 미리 정의된 카메라 이동 유형입니다. simple: 사용자 정의 가능한 카메라 이동. down_back: 카메라가 하강하며 뒤로 이동합니다. forward_up: 카메라가 앞으로 이동하며 위로 기울어집니다. right_turn_forward: 오른쪽으로 회전하며 앞으로 이동합니다. left_turn_forward: 왼쪽으로 회전하며 앞으로 이동합니다. - - 가능한 값: `simple`, `down_back`, `forward_up`, `right_turn_forward`, `left_turn_forward` - - - - 비디오 생성의 유연성입니다. 값이 높을수록 모델의 유연성 정도가 낮아지고 사용자 프롬프트와의 관련성이 강해집니다. - - 범위: `0` ~ `1` - - 형식: `float` - - - - 비디오 길이(초) - - 가능한 값: `3`, `4`, `5`, `6`, `7`, `8`, `9`, `10`, `11`, `12`, `13`, `14`, `15` - - - - 동적 브러시 구성 목록입니다(최대 6개 그룹). 5초 비디오의 경우 궤적 길이는 77개 좌표를 초과할 수 없습니다. - - - - 동적 브러시 적용 영역입니다(사용자가 모션 브러시를 사용해 만든 마스크 이미지). 가로세로 비율은 입력 이미지와 일치해야 합니다. - - 형식: `uri` - - - - - - - - 궤적 지점의 수평 좌표입니다. 이미지의 왼쪽 아래 모서리를 원점 (0,0)으로 합니다. - - - - 궤적 지점의 수직 좌표입니다. 이미지의 왼쪽 아래 모서리를 원점 (0,0)으로 합니다. - - - - element ID 구성을 기반으로 한 참조 요소 목록입니다. 최대 3개의 참조 요소를 지원합니다. element_list와 voice_list 파라미터는 상호 배타적입니다. - - - - 요소 ID - - 형식: `int64` - - - - 사용자 정의 작업 ID입니다. 단일 사용자 계정 내에서 고유해야 합니다. - - - - 참조 이미지 - URL 또는 Base64 인코딩 문자열이며, 10MB를 초과할 수 없고 해상도는 300*300px 이상, 가로세로 비율은 1:2.5 ~ 2.5:1 사이여야 합니다. Base64에는 data:image 접두사를 포함하지 않아야 합니다. - - - - 참조 이미지 - 종료 프레임 제어입니다. URL 또는 Base64 인코딩 문자열이며, 10MB를 초과할 수 없고 해상도는 300*300px 이상이어야 합니다. Base64에는 data:image 접두사를 포함하지 않아야 합니다. dynamic_masks/static_mask 또는 camera_control과 동시에 사용할 수 없습니다. - - - - 비디오 생성 모드입니다. std: 비용 효율적인 표준 모드입니다. pro: 더 긴 재생 시간의 비디오를 생성하지만 출력 품질이 더 높은 전문가 모드입니다. - - 가능한 값: `std`, `pro` - - - - 모델 이름입니다. Comfy Router를 사용할 때는 이를 생략하거나 null을 전송하세요. 모델은 요청 경로에 의해 선택됩니다. 이름을 제공하는 경우 해당 경로와 일치해야 합니다. - - - - 각 스토리보드에 대한 정보로, 프롬프트와 재생 시간 등을 포함합니다. 최대 6개의 스토리보드를 지원하며 최소 1개가 필요합니다. multi_shot이 true이고 shot_type이 customize인 경우 필수입니다. - - - - 이 스토리보드의 재생 시간(초)입니다. 전체 작업 재생 시간을 초과할 수 없으며 1보다 작을 수 없습니다. 모든 스토리보드 재생 시간의 합은 전체 작업 재생 시간과 같습니다. - - - - 샷 순서 번호 - - - - 이 스토리보드의 프롬프트 단어입니다. 최대 길이는 512자입니다. - - - - 멀티 샷 비디오를 생성할지 여부입니다. true인 경우 prompt 파라미터는 유효하지 않습니다. false인 경우 shot_type 및 multi_prompt 파라미터는 유효하지 않습니다. - - - - 네거티브 텍스트 프롬프트입니다. 네거티브 프롬프트 정보는 긍정 프롬프트 내에 직접 네거티브 문장을 넣어 보완하는 것이 권장됩니다. - - - -긍정 텍스트 프롬프트입니다. voice_list 파라미터 순서에 맞는 음성을 지정하려면 \<\<\>>을 사용하세요. 하나의 작업은 최대 2개의 음색을 참조할 수 있습니다. 음색을 지정할 때는 sound 파라미터 값이 on이어야 합니다. - - - -스토리보드 방법입니다. multi_shot 파라미터가 `true`로 설정된 경우 필수입니다. - -가능한 값: `customize`, `intelligence` - - - -동영상을 생성할 때 사운드도 동시에 생성할지 여부입니다. 모델 V2.6 이후 버전에서만 이 파라미터를 지원합니다. - -가능한 값: `on`, `off` - - - -정적 브러시 적용 영역(사용자가 모션 브러시를 사용해 만든 마스크 이미지)입니다. 가로세로 비율은 입력 이미지와 일치해야 합니다. - - - -동영상 생성 시 참조되는 음성 목록입니다. 최대 2개의 음성을 지원합니다. element_list와 voice_list 파라미터는 상호 배타적입니다. - - - -음성 사용자 정의 API를 통해 반환된 음성 ID 또는 시스템 사전 설정 음성 ID입니다. - - - -워터마크가 포함된 결과를 동시에 생성할지 여부입니다. 현재 사용자 정의 워터마크는 지원되지 않습니다. - - - -true는 워터마크 생성, false는 생성을 하지 않음을 의미합니다. - - -Router가 `GET /v2/models/kling/kling-v1-5/openapi.json`에서 제공하는 스키마에서 생성되었으며, 이는 요청이 공급자에게 도달하기 전에 호출을 검증하는 데 사용하는 것과 동일한 문서입니다. -### 출력 - - - 오류 코드 - - - - - - - - 작업 생성 시간, Unix 타임스탬프(밀리초) - - - - 작업의 차감 단위 - - - - 작업 ID - - - - - - - - - - - - - - - - - - - - 총 비디오 재생 시간(초) - - - - 생성된 비디오 ID - - - - 생성된 비디오의 URL - - 형식: `uri` - - - - 워터마크가 포함된 생성된 비디오의 URL, 핫링크 보호 형식 - - 형식: `uri` - - - - 작업 상태 - - 가능한 값: `submitted`, `processing`, `succeed`, `failed` - - - - 작업 상태 정보, 작업이 실패할 때 실패 이유를 표시합니다 - - - - 작업 업데이트 시간, Unix 타임스탬프(밀리초) - - - - - - - - - - - - 오류 메시지 - - - - 요청 ID - - -## 예시 - -### 입력 - -```json -{ - "duration": "5", - "image": "https://example.invalid/kling/reference.png", - "mode": "std", - "prompt": "The fox turns its head towards the camera." -} -``` - -### 출력 - -```json -{ - "code": 0, - "data": { - "created_at": 1798761600000, - "task_id": "kling-task-1a2b3c4d5e6f", - "task_result": { - "videos": [ - { - "duration": "5", - "id": "kling-video-6f5e4d3c2b1a", - "url": "https://example.invalid/kling/kling-v1/generated.mp4" - } - ] - }, - "task_status": "succeed", - "task_status_msg": "", - "updated_at": 1798761840000 - }, - "message": "SUCCEED", - "request_id": "9f2c1a04-7b6e-4d38-8a51-3c0e7d9b2f46" -} -``` - - - diff --git a/ko/development/comfy-router/models/kling/kling-v1-6/code.mdx b/ko/development/comfy-router/models/kling/kling-v1-6/code.mdx deleted file mode 100644 index 82bb193f3e..0000000000 --- a/ko/development/comfy-router/models/kling/kling-v1-6/code.mdx +++ /dev/null @@ -1,422 +0,0 @@ ---- -title: "Comfy Router로 Kling V1.6 사용하기" -description: "Comfy Router를 통해 kling/kling-v1-6을 호출합니다: 엔드포인트, 요청 형태, 그리고 Router가 반환하는 응답을 설명합니다." -sidebarTitle: "Kling V1.6" -translationSourceHash: 4e28fa7d -translationFrom: development/comfy-router/models/kling/kling-v1-6/code.mdx -translationBlockHashes: - "_intro": e5d8f71a - "Quick start": 77975fae - "Schema": ffd91cca - "Examples": 14429ff8 ---- -{/* 생성된 파일. `pnpm code-pages:gen`에 의해 router-schemas/kling/kling-v1-6.json에서 생성됨. */} - -import RouterCodeFooter from "/snippets/ko/comfy-router/model-code-footer.mdx"; - -`kling/kling-v1-6`에 대한 API 레퍼런스이며, Kling에서 Comfy Router를 통해 제공됩니다. - -## 빠른 시작 - -[Comfy 워크스페이스](https://platform.comfy.org/profile/api-keys)에서 키를 생성하고 `COMFY_API_KEY`로 내보내세요. Python 및 TypeScript 스니펫은 Comfy SDK(`pip install comfy-sdk`, `npm install @comfyorg/sdk`)를 사용하며, cURL 스니펫은 동일한 호출을 원시 HTTP로 보내는 방식입니다. - -**모델 ID:** `kling/kling-v1-6` - -**엔드포인트:** `POST https://api.comfy.org/v2/models/kling/kling-v1-6` - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# The SDK automatically creates an idempotency key and reuses it for automatic retries. -with Comfy() as client: - result = client.models.run( - "kling/kling-v1-6", - { - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting.", - }, - ) - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// The SDK automatically creates an idempotency key and reuses it for automatic retries. -const { data } = await comfy.models.run("kling/kling-v1-6", { - aspect_ratio: "16:9", - duration: "5", - mode: "std", - prompt: "A red fox trotting through falling snow, cinematic lighting.", -}); - -console.log(data); -``` - -```bash cURL -curl https://api.comfy.org/v2/models/kling/kling-v1-6 \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"aspect_ratio\": \"16:9\", \"duration\": \"5\", \"mode\": \"std\", \"prompt\": \"A red fox trotting through falling snow, cinematic lighting.\"}" -``` - - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -with Comfy() as client: - handle = client.models.submit( - "kling/kling-v1-6", - { - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting.", - }, - ) - print("request_id:", handle.request_id) # with the model ID, all another process needs - - # Poll until the request completes, waiting the Retry-After the server names. - for update in handle.iter_events(): - print(update.status, update.queue_position) - - # The provider's own payload, the same value models.run() returns. - # A request that failed or was cancelled raises the typed Router error here. - result = handle.get() - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -const handle = await comfy.models.submit("kling/kling-v1-6", { - aspect_ratio: "16:9", - duration: "5", - mode: "std", - prompt: "A red fox trotting through falling snow, cinematic lighting.", -}); -console.log("requestId:", handle.requestId); // with the model ID, all another process needs - -// Poll until the request completes, waiting the Retry-After the server names. -for await (const update of handle.events()) { - console.log(update.status, update.queuePosition); -} - -// The same result models.run() returns. A request that failed or was cancelled rejects here. -const result = await handle.get(); - -console.log(result.data); -``` - -```bash cURL -# 1. Submit. Router answers 201 with request_id, status_url, response_url and cancel_url. -curl https://api.comfy.org/v2/models/kling/kling-v1-6/requests \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"aspect_ratio\": \"16:9\", \"duration\": \"5\", \"mode\": \"std\", \"prompt\": \"A red fox trotting through falling snow, cinematic lighting.\"}" - -# 2. Poll until status is COMPLETED, waiting the Retry-After seconds each response names. -REQUEST_ID="" -curl -i https://api.comfy.org/v2/models/kling/kling-v1-6/requests/$REQUEST_ID/status \ - -H "X-API-Key: $COMFY_API_KEY" - -# 3. Collect. 200 with the model's native output, 202 with the status body while it is still running. -curl https://api.comfy.org/v2/models/kling/kling-v1-6/requests/$REQUEST_ID \ - -H "X-API-Key: $COMFY_API_KEY" -``` - - - - - - -## 스키마 - -### 입력 - - - 비디오 화면 비율 - - 가능한 값: `16:9`, `9:16`, `1:1` - - - - 콜백 알림 주소 - - 형식: `uri` - - - - - - - - - - - - 카메라의 수평 축(x축) 이동을 제어합니다. 음수는 왼쪽, 양수는 오른쪽을 나타냅니다. - - 범위: `-10` ~ `10` - - - - 수직 평면(x축)에서의 카메라 회전을 제어합니다. 음수는 아래쪽 회전, 양수는 위쪽 회전을 나타냅니다. - - 범위: `-10` ~ `10` - - - - 카메라의 롤링 양(z축)을 제어합니다. 음수는 시계 반대 방향, 양수는 시계 방향을 나타냅니다. - - 범위: `-10` ~ `10` - - - - 수평 평면(y축)에서의 카메라 회전을 제어합니다. 음수는 왼쪽 회전, 양수는 오른쪽 회전을 나타냅니다. - - 범위: `-10` ~ `10` - - - - 카메라의 수직 축(y축) 이동을 제어합니다. 음수는 아래쪽, 양수는 위쪽을 나타냅니다. - - 범위: `-10` ~ `10` - - - - 카메라 초점 거리의 변화를 제어합니다. 음수는 좁은 화각, 양수는 넓은 화각을 나타냅니다. - - 범위: `-10` ~ `10` - - - - 미리 정의된 카메라 움직임 유형입니다. simple: 사용자 정의 가능한 카메라 움직임입니다. down_back: 카메라가 하강하며 뒤로 이동합니다. forward_up: 카메라가 앞으로 이동하며 위로 기울어집니다. right_turn_forward: 오른쪽으로 회전하고 앞으로 이동합니다. left_turn_forward: 왼쪽으로 회전하고 앞으로 이동합니다. - - 가능한 값: `simple`, `down_back`, `forward_up`, `right_turn_forward`, `left_turn_forward` - - - - 비디오 생성 시의 유연성입니다. 값이 높을수록 모델의 유연성 정도가 낮아지고, 사용자 프롬프트와의 관련성이 강해집니다. - - 범위: `0` ~ `1` - - 형식: `float` - - - - 비디오 재생 시간(초) - - 가능한 값: `3`, `4`, `5`, `6`, `7`, `8`, `9`, `10`, `11`, `12`, `13`, `14`, `15` - - - - 사용자 정의 작업 ID - - - - 비디오 생성 모드입니다. std: 비용 효율적인 표준 모드입니다. pro: 전문가 모드로, 더 긴 재생 시간의 비디오를 생성하지만 출력 품질이 더 높습니다. - - 가능한 값: `std`, `pro` - - - - 모델 이름입니다. Comfy Router를 사용할 때는 생략하거나 null을 전송하세요. 모델은 요청 경로에 따라 선택됩니다. 이름을 제공하는 경우 해당 경로와 일치해야 합니다. - - - - 프롬프트와 재생 시간 등 각 스토리보드에 대한 정보입니다. 최대 6개의 스토리보드를 지원하며 최소 1개가 필요합니다. multi_shot이 true이고 shot_type이 customize인 경우 필수입니다. - - - - 이 스토리보드의 재생 시간(초)입니다. 전체 작업 재생 시간을 초과할 수 없으며 1 이상이어야 합니다. 모든 스토리보드 재생 시간의 합은 전체 작업 재생 시간과 같습니다. - - - - 샷 순서 번호 - - - - 이 스토리보드의 프롬프트 단어입니다. 최대 길이는 512자입니다. - - - - 멀티 샷 비디오를 생성할지 여부입니다. true인 경우 prompt 파라미터는 유효하지 않습니다. false인 경우 shot_type 및 multi_prompt 파라미터는 유효하지 않습니다. - - - - 네거티브 텍스트 프롬프트입니다. 네거티브 프롬프트 정보는 긍정 프롬프트 내에 직접 부정 문장으로 보완하는 것을 권장합니다. - - - - 긍정 텍스트 프롬프트입니다. voice_list 파라미터 순서에 맞는 음성을 지정하려면 \<\<\>>을 사용하세요. 하나의 작업은 최대 2개의 톤을 참조할 수 있습니다. 톤을 지정할 때 sound 파라미터 값은 on이어야 합니다. - - - - 스토리보드 방법입니다. multi_shot 파라미터가 true로 설정된 경우 필수입니다. - - 가능한 값: `customize`, `intelligence` - - - - 비디오 생성 시 사운드를 동시에 생성할지 여부입니다. 모델 V2.6 이후 버전에서만 이 파라미터를 지원합니다. - - 가능한 값: `on`, `off` - - - - 워터마크가 표시된 결과를 동시에 생성할지 여부입니다. 현재 사용자 정의 워터마크는 지원되지 않습니다. - - - - true는 워터마크를 생성함을, false는 생성하지 않음을 의미합니다. - - -`GET /v2/models/kling/kling-v1-6/openapi.json`에서 Router가 제공하는 스키마에서 생성되었으며, 이는 요청이 공급자에게 도달하기 전에 호출을 검증하는 데 사용하는 동일한 문서입니다. -### 출력 - - - 오류 코드 - - - - - - - - 작업 생성 시간, 밀리초 단위 Unix 타임스탬프 - - - - 작업의 차감 단위 - - - - 작업 ID - - - - - - - - - - - - - - - - - - - - 총 비디오 재생 시간(초) - - - - 생성된 비디오 ID - - - - 생성된 비디오의 URL - - 형식: `uri` - - - - 워터마크가 포함된 생성된 비디오의 URL, 핫링크 보호 형식 - - 형식: `uri` - - - - 작업 상태 - - 가능한 값: `submitted`, `processing`, `succeed`, `failed` - - - - 작업 상태 정보로, 작업이 실패하면 실패 사유를 표시합니다 - - - - 작업 업데이트 시간, 밀리초 단위 Unix 타임스탬프 - - - - - - - - - - - - 오류 메시지 - - - - 요청 ID - - -## 예시 - -### 입력 - -```json -{ - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting." -} -``` - -### 출력 - -```json -{ - "code": 0, - "data": { - "created_at": 1798761600000, - "task_id": "kling-task-1a2b3c4d5e6f", - "task_result": { - "videos": [ - { - "duration": "5", - "id": "kling-video-6f5e4d3c2b1a", - "url": "https://example.invalid/kling/kling-v1/generated.mp4" - } - ] - }, - "task_status": "succeed", - "task_status_msg": "", - "updated_at": 1798761840000 - }, - "message": "SUCCEED", - "request_id": "9f2c1a04-7b6e-4d38-8a51-3c0e7d9b2f46" -} -``` - - - diff --git a/ko/development/comfy-router/models/kling/kling-v1/code.mdx b/ko/development/comfy-router/models/kling/kling-v1/code.mdx deleted file mode 100644 index a607d272c7..0000000000 --- a/ko/development/comfy-router/models/kling/kling-v1/code.mdx +++ /dev/null @@ -1,421 +0,0 @@ ---- -title: "Comfy Router로 Kling V1 사용하기" -description: "Comfy Router를 통해 kling/kling-v1을 호출합니다: 엔드포인트, 요청 형태, 그리고 Router가 반환하는 응답입니다." -sidebarTitle: "Kling V1" -translationSourceHash: 49bc09b7 -translationFrom: development/comfy-router/models/kling/kling-v1/code.mdx -translationBlockHashes: - "_intro": 88237ef1 - "Quick start": 25cc5cf0 - "Schema": 16c4273c - "Examples": 14429ff8 ---- -{/* GENERATED FILE. Generated from router-schemas/kling/kling-v1.json by `pnpm code-pages:gen`. */} - -import RouterCodeFooter from "/snippets/ko/comfy-router/model-code-footer.mdx"; - -`kling/kling-v1`의 API 레퍼런스이며, Kling에서 Comfy Router를 통해 제공됩니다. - -## 빠른 시작 - -[Comfy 워크스페이스](https://platform.comfy.org/profile/api-keys)에서 키를 생성하고 `COMFY_API_KEY`로 내보내기 하세요. Python 및 TypeScript 스니펫은 Comfy SDK(`pip install comfy-sdk`, `npm install @comfyorg/sdk`)를 사용하며, cURL 스니펫은 동일한 호출을 원시 HTTP로 수행합니다. - -**Model ID:** `kling/kling-v1` - -**Endpoint:** `POST https://api.comfy.org/v2/models/kling/kling-v1` - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# The SDK automatically creates an idempotency key and reuses it for automatic retries. -with Comfy() as client: - result = client.models.run( - "kling/kling-v1", - { - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting.", - }, - ) - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// The SDK automatically creates an idempotency key and reuses it for automatic retries. -const { data } = await comfy.models.run("kling/kling-v1", { - aspect_ratio: "16:9", - duration: "5", - mode: "std", - prompt: "A red fox trotting through falling snow, cinematic lighting.", -}); - -console.log(data); -``` - -```bash cURL -curl https://api.comfy.org/v2/models/kling/kling-v1 \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"aspect_ratio\": \"16:9\", \"duration\": \"5\", \"mode\": \"std\", \"prompt\": \"A red fox trotting through falling snow, cinematic lighting.\"}" -``` - - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -with Comfy() as client: - handle = client.models.submit( - "kling/kling-v1", - { - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting.", - }, - ) - print("request_id:", handle.request_id) # with the model ID, all another process needs - - # Poll until the request completes, waiting the Retry-After the server names. - for update in handle.iter_events(): - print(update.status, update.queue_position) - - # The provider's own payload, the same value models.run() returns. - # A request that failed or was cancelled raises the typed Router error here. - result = handle.get() - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -const handle = await comfy.models.submit("kling/kling-v1", { - aspect_ratio: "16:9", - duration: "5", - mode: "std", - prompt: "A red fox trotting through falling snow, cinematic lighting.", -}); -console.log("requestId:", handle.requestId); // with the model ID, all another process needs - -// Poll until the request completes, waiting the Retry-After the server names. -for await (const update of handle.events()) { - console.log(update.status, update.queuePosition); -} - -// The same result models.run() returns. A request that failed or was cancelled rejects here. -const result = await handle.get(); - -console.log(result.data); -``` - -```bash cURL -# 1. Submit. Router answers 201 with request_id, status_url, response_url and cancel_url. -curl https://api.comfy.org/v2/models/kling/kling-v1/requests \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"aspect_ratio\": \"16:9\", \"duration\": \"5\", \"mode\": \"std\", \"prompt\": \"A red fox trotting through falling snow, cinematic lighting.\"}" - -# 2. Poll until status is COMPLETED, waiting the Retry-After seconds each response names. -REQUEST_ID="" -curl -i https://api.comfy.org/v2/models/kling/kling-v1/requests/$REQUEST_ID/status \ - -H "X-API-Key: $COMFY_API_KEY" - -# 3. Collect. 200 with the model's native output, 202 with the status body while it is still running. -curl https://api.comfy.org/v2/models/kling/kling-v1/requests/$REQUEST_ID \ - -H "X-API-Key: $COMFY_API_KEY" -``` - - - - - -## 스키마 - -### 입력 - - - 비디오 화면 비율 - - 가능한 값: `16:9`, `9:16`, `1:1` - - - - 콜백 알림 주소 - - 형식: `uri` - - - - - - - - - - - - 카메라의 수평 축(x축) 이동을 제어합니다. 음수는 왼쪽, 양수는 오른쪽을 나타냅니다. - - 범위: `-10` ~ `10` - - - - 수직 평면(x축)에서 카메라의 회전을 제어합니다. 음수는 아래쪽 회전, 양수는 위쪽 회전을 나타냅니다. - - 범위: `-10` ~ `10` - - - - 카메라의 롤링 정도(z축)를 제어합니다. 음수는 반시계 방향, 양수는 시계 방향을 나타냅니다. - - 범위: `-10` ~ `10` - - - - 수평 평면(y축)에서 카메라의 회전을 제어합니다. 음수는 왼쪽 회전, 양수는 오른쪽 회전을 나타냅니다. - - 범위: `-10` ~ `10` - - - - 카메라의 수직 축(y축) 이동을 제어합니다. 음수는 아래쪽, 양수는 위쪽을 나타냅니다. - - 범위: `-10` ~ `10` - - - - 카메라의 초점 거리 변화를 제어합니다. 음수는 좁은 화각, 양수는 넓은 화각을 나타냅니다. - - 범위: `-10` ~ `10` - - - - 미리 정의된 카메라 움직임 유형입니다. simple: 사용자 정의 가능한 카메라 움직임. down_back: 카메라가 하강하며 뒤로 이동합니다. forward_up: 카메라가 앞으로 이동하며 위로 기울어집니다. right_turn_forward: 오른쪽으로 회전하며 앞으로 이동합니다. left_turn_forward: 왼쪽으로 회전하며 앞으로 이동합니다. - - 가능한 값: `simple`, `down_back`, `forward_up`, `right_turn_forward`, `left_turn_forward` - - - - 비디오 생성의 유연성입니다. 값이 높을수록 모델의 유연성 정도가 낮아지고 사용자 프롬프트와의 관련성이 강해집니다. - - 범위: `0` ~ `1` - - 형식: `float` - - - - 비디오 길이(초) - - 가능한 값: `3`, `4`, `5`, `6`, `7`, `8`, `9`, `10`, `11`, `12`, `13`, `14`, `15` - - - - 사용자 정의 작업 ID - - - - 비디오 생성 모드입니다. std: 비용 효율적인 표준 모드. pro: 재생 시간이 더 긴 비디오를 생성하지만 품질이 더 높은 출력을 만드는 프로페셔널 모드. - - 가능한 값: `std`, `pro` - - - - 모델 이름입니다. Comfy Router를 사용할 때는 생략하거나 null을 전송하세요. 모델은 요청 경로에 따라 선택됩니다. 이름을 제공하는 경우 해당 경로와 일치해야 합니다. - - - - 프롬프트 및 재생 시간과 같은 각 스토리보드에 대한 정보입니다. 최대 6개의 스토리보드를 지원하며 최소 1개가 필요합니다. multi_shot이 참이고 shot_type이 사용자 정의인 경우 필수입니다. - - - - 이 스토리보드의 재생 시간(초)입니다. 전체 작업 재생 시간을 초과할 수 없으며 1보다 작을 수 없습니다. 모든 스토리보드 재생 시간의 합은 전체 작업 재생 시간과 같습니다. - - - - 샷 순서 번호 - - - - 이 스토리보드의 프롬프트 단어입니다. 최대 길이는 512자입니다. - - - - 멀티 샷 비디오를 생성할지 여부입니다. 참이면 prompt 파라미터가 무효입니다. 거짓이면 shot_type 및 multi_prompt 파라미터가 무효입니다. - - - - 네거티브 텍스트 프롬프트입니다. 네거티브 프롬프트 정보는 포지티브 프롬프트 안에 직접 네거티브 문장으로 보완하는 것을 권장합니다. - - - - 포지티브 텍스트 프롬프트입니다. voice_list 파라미터 순서에 맞는 음성을 지정하려면 \<\<\>>를 사용하세요. 하나의 작업은 최대 2개의 톤을 참조할 수 있습니다. 톤을 지정할 때는 sound 파라미터 값이 on이어야 합니다. - - - - 스토리보드 방법입니다. multi_shot 파라미터가 참으로 설정된 경우 필수입니다. - - 가능한 값: `customize`, `intelligence` - - - - 비디오 생성 시 사운드를 동시에 생성할지 여부입니다. 모델 V2.6 이후 버전에서만 이 파라미터를 지원합니다. - - 가능한 값: `on`, `off` - - - - 워터마크가 포함된 결과를 동시에 생성할지 여부입니다. 현재 사용자 정의 워터마크는 지원되지 않습니다. - - - - 참은 워터마크를 생성함을, 거짓은 생성하지 않음을 의미합니다. - - -`GET /v2/models/kling/kling-v1/openapi.json`에서 Router가 제공하는 스키마에서 생성되었으며, 요청이 공급자에 도달하기 전에 호출을 검증하는 기준으로 사용하는 것과 동일한 문서입니다. -### 출력 - - - 오류 코드 - - - - - - - - 작업 생성 시간, 밀리초 단위의 Unix 타임스탬프 - - - - 작업의 차감 단위 - - - - 작업 ID - - - - - - - - - - - - - - - - - - - - 비디오 총 재생 시간(초) - - - - 생성된 비디오 ID - - - - 생성된 비디오 URL - - 형식: `uri` - - - - 워터마크가 포함된 생성된 비디오 URL, 핫링크 보호 형식 - - 형식: `uri` - - - - 작업 상태 - - 가능한 값: `submitted`, `processing`, `succeed`, `failed` - - - - 작업 상태 정보, 작업 실패 시 실패 이유 표시 - - - - 작업 업데이트 시간, 밀리초 단위의 Unix 타임스탬프 - - - - - - - - - - - - 오류 메시지 - - - - 요청 ID - - -## 예시 - -### 입력 - -```json -{ - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting." -} -``` - -### 출력 - -```json -{ - "code": 0, - "data": { - "created_at": 1798761600000, - "task_id": "kling-task-1a2b3c4d5e6f", - "task_result": { - "videos": [ - { - "duration": "5", - "id": "kling-video-6f5e4d3c2b1a", - "url": "https://example.invalid/kling/kling-v1/generated.mp4" - } - ] - }, - "task_status": "succeed", - "task_status_msg": "", - "updated_at": 1798761840000 - }, - "message": "SUCCEED", - "request_id": "9f2c1a04-7b6e-4d38-8a51-3c0e7d9b2f46" -} -``` - - - diff --git a/ko/development/comfy-router/models/kling/kling-v2-1-master/code.mdx b/ko/development/comfy-router/models/kling/kling-v2-1-master/code.mdx deleted file mode 100644 index 050b38ad91..0000000000 --- a/ko/development/comfy-router/models/kling/kling-v2-1-master/code.mdx +++ /dev/null @@ -1,421 +0,0 @@ ---- -title: "Comfy Router로 Kling V2.1 Master 사용하기" -description: "Comfy Router를 통해 kling/kling-v2-1-master를 호출합니다: endpoint, 요청 형태, 그리고 Router가 반환하는 응답." -sidebarTitle: "Kling V2.1 Master" -translationSourceHash: 4f57933f -translationFrom: development/comfy-router/models/kling/kling-v2-1-master/code.mdx -translationBlockHashes: - "_intro": a94d25f9 - "Quick start": 57640f5d - "Schema": 3d3492a4 - "Examples": 14429ff8 ---- -{/* 생성된 파일. `pnpm code-pages:gen`이 router-schemas/kling/kling-v2-1-master.json에서 생성했습니다. */} - -import RouterCodeFooter from "/snippets/ko/comfy-router/model-code-footer.mdx"; - -`kling/kling-v2-1-master`의 API 레퍼런스이며, Kling에서 Comfy Router를 통해 제공됩니다. - -## 빠른 시작 - -[your Comfy workspace](https://platform.comfy.org/profile/api-keys)에서 키를 생성하고 `COMFY_API_KEY`로 내보내세요. Python 및 TypeScript 스니펫은 Comfy SDK(`pip install comfy-sdk`, `npm install @comfyorg/sdk`)를 사용하며, cURL 스니펫은 동일한 호출을 raw HTTP로 수행합니다. - -**모델 ID:** `kling/kling-v2-1-master` - -**Endpoint:** `POST https://api.comfy.org/v2/models/kling/kling-v2-1-master` - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# The SDK automatically creates an idempotency key and reuses it for automatic retries. -with Comfy() as client: - result = client.models.run( - "kling/kling-v2-1-master", - { - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting.", - }, - ) - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// The SDK automatically creates an idempotency key and reuses it for automatic retries. -const { data } = await comfy.models.run("kling/kling-v2-1-master", { - aspect_ratio: "16:9", - duration: "5", - mode: "std", - prompt: "A red fox trotting through falling snow, cinematic lighting.", -}); - -console.log(data); -``` - -```bash cURL -curl https://api.comfy.org/v2/models/kling/kling-v2-1-master \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"aspect_ratio\": \"16:9\", \"duration\": \"5\", \"mode\": \"std\", \"prompt\": \"A red fox trotting through falling snow, cinematic lighting.\"}" -``` - - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -with Comfy() as client: - handle = client.models.submit( - "kling/kling-v2-1-master", - { - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting.", - }, - ) - print("request_id:", handle.request_id) # with the model ID, all another process needs - - # Poll until the request completes, waiting the Retry-After the server names. - for update in handle.iter_events(): - print(update.status, update.queue_position) - - # The provider's own payload, the same value models.run() returns. - # A request that failed or was cancelled raises the typed Router error here. - result = handle.get() - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -const handle = await comfy.models.submit("kling/kling-v2-1-master", { - aspect_ratio: "16:9", - duration: "5", - mode: "std", - prompt: "A red fox trotting through falling snow, cinematic lighting.", -}); -console.log("requestId:", handle.requestId); // with the model ID, all another process needs - -// Poll until the request completes, waiting the Retry-After the server names. -for await (const update of handle.events()) { - console.log(update.status, update.queuePosition); -} - -// The same result models.run() returns. A request that failed or was cancelled rejects here. -const result = await handle.get(); - -console.log(result.data); -``` - -```bash cURL -# 1. Submit. Router answers 201 with request_id, status_url, response_url and cancel_url. -curl https://api.comfy.org/v2/models/kling/kling-v2-1-master/requests \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"aspect_ratio\": \"16:9\", \"duration\": \"5\", \"mode\": \"std\", \"prompt\": \"A red fox trotting through falling snow, cinematic lighting.\"}" - -# 2. Poll until status is COMPLETED, waiting the Retry-After seconds each response names. -REQUEST_ID="" -curl -i https://api.comfy.org/v2/models/kling/kling-v2-1-master/requests/$REQUEST_ID/status \ - -H "X-API-Key: $COMFY_API_KEY" - -# 3. Collect. 200 with the model's native output, 202 with the status body while it is still running. -curl https://api.comfy.org/v2/models/kling/kling-v2-1-master/requests/$REQUEST_ID \ - -H "X-API-Key: $COMFY_API_KEY" -``` - - - - - -## 스키마 - -### 입력 - - - 비디오 화면 비율 - - 가능한 값: `16:9`, `9:16`, `1:1` - - - - 콜백 알림 주소 - - 형식: `uri` - - - - - - - - - - - - 카메라의 수평 축(x축) 이동을 제어합니다. 음수는 왼쪽, 양수는 오른쪽을 의미합니다. - - 범위: `-10` ~ `10` - - - - 수직 평면(x축)에서의 카메라 회전을 제어합니다. 음수는 아래쪽 회전, 양수는 위쪽 회전을 의미합니다. - - 범위: `-10` ~ `10` - - - - 카메라의 롤링 양(z축)을 제어합니다. 음수는 시계 반대 방향, 양수는 시계 방향을 의미합니다. - - 범위: `-10` ~ `10` - - - - 수평 평면(y축)에서의 카메라 회전을 제어합니다. 음수는 왼쪽으로 회전, 양수는 오른쪽으로 회전을 의미합니다. - - 범위: `-10` ~ `10` - - - - 카메라의 수직 축(y축) 이동을 제어합니다. 음수는 아래쪽, 양수는 위쪽을 의미합니다. - - 범위: `-10` ~ `10` - - - - 카메라 초점 거리의 변화를 제어합니다. 음수는 더 좁은 시야각, 양수는 더 넓은 시야각을 의미합니다. - - 범위: `-10` ~ `10` - - - - 미리 정의된 카메라 이동 유형입니다. simple: 사용자 정의 가능한 카메라 이동입니다. down_back: 카메라가 하강하며 뒤로 이동합니다. forward_up: 카메라가 앞으로 이동하며 위로 기울어집니다. right_turn_forward: 오른쪽으로 회전하며 앞으로 이동합니다. left_turn_forward: 왼쪽으로 회전하며 앞으로 이동합니다. - - 가능한 값: `simple`, `down_back`, `forward_up`, `right_turn_forward`, `left_turn_forward` - - - - 비디오 생성의 유연성입니다. 값이 높을수록 모델의 유연성 정도는 낮아지고, 사용자 프롬프트와의 관련성은 강해집니다. - - 범위: `0` ~ `1` - - 형식: `float` - - - - 비디오 길이(초) - - 가능한 값: `3`, `4`, `5`, `6`, `7`, `8`, `9`, `10`, `11`, `12`, `13`, `14`, `15` - - - - 사용자 정의 작업 ID - - - - 비디오 생성 모드입니다. std: 비용 효율적인 표준 모드입니다. pro: 더 긴 재생 시간의 비디오를 생성하지만 출력 품질이 더 높은 프로페셔널 모드입니다. - - 가능한 값: `std`, `pro` - - - - 모델 이름입니다. Comfy Router를 사용할 때는 생략하거나 null을 전송하세요. 모델은 요청 경로에 따라 선택됩니다. 이름을 제공하는 경우 해당 경로와 일치해야 합니다. - - - - 프롬프트와 재생 시간 등 각 스토리보드에 대한 정보입니다. 최대 6개의 스토리보드를 지원하며 최소 1개가 필요합니다. multi_shot이 true이고 shot_type이 customize일 때 필수입니다. - - - - 이 스토리보드의 재생 시간(초)입니다. 전체 작업 재생 시간을 초과할 수 없으며 1보다 작을 수 없습니다. 모든 스토리보드 재생 시간의 합은 전체 작업 재생 시간과 같습니다. - - - - 샷 순서 번호 - - - - 이 스토리보드의 프롬프트입니다. 최대 길이는 512자입니다. - - - - 멀티 샷 비디오를 생성할지 여부입니다. true이면 prompt 파라미터는 무효입니다. false이면 shot_type 및 multi_prompt 파라미터는 무효입니다. - - - - 네거티브 텍스트 프롬프트입니다. 네거티브 프롬프트 정보는 긍정 프롬프트 안에 직접 네거티브 문장으로 보완하는 것이 권장됩니다. - - - - 긍정 텍스트 프롬프트입니다. \<\<\>>을 사용하면 voice_list 파라미터 순서에 맞는 음성을 지정할 수 있습니다. 작업 하나에서 최대 2개의 음색을 참조할 수 있습니다. 음색을 지정할 때는 sound 파라미터 값이 on이어야 합니다. - - - - 스토리보드 방법입니다. multi_shot 파라미터가 true로 설정된 경우 필수입니다. - - 가능한 값: `customize`, `intelligence` - - - - 비디오를 생성할 때 사운드도 함께 생성할지 여부입니다. 모델 V2.6 및 이후 버전에서만 이 파라미터를 지원합니다. - - 가능한 값: `on`, `off` - - - - 워터마크가 적용된 결과를 함께 생성할지 여부입니다. 현재 사용자 정의 워터마크는 지원되지 않습니다. - - - - true는 워터마크를 생성함, false는 생성하지 않음을 의미합니다. - - -`GET /v2/models/kling/kling-v2-1-master/openapi.json`에서 Router가 제공하는 스키마에서 생성되었으며, 이는 요청이 공급자에 도달하기 전에 호출을 검증하는 데 사용하는 동일한 문서입니다. -### 출력 - - - 오류 코드 - - - - - - - - 작업 생성 시간, 밀리초 단위 Unix timestamp - - - - 작업의 차감 단위 - - - - 작업 ID - - - - - - - - - - - - - - - - - - - - 비디오 총 재생 시간(초) - - - - 생성된 비디오 ID - - - - 생성된 비디오의 URL - - 형식: `uri` - - - - 워터마크가 포함된 생성 비디오의 URL, 핫링크 보호 형식 - - 형식: `uri` - - - - 작업 상태 - - 가능한 값: `submitted`, `processing`, `succeed`, `failed` - - - - 작업 상태 정보로, 작업이 실패할 때 실패 이유를 표시합니다 - - - - 작업 업데이트 시간, 밀리초 단위 Unix timestamp - - - - - - - - - - - - 오류 메시지 - - - - 요청 ID - - -## 예시 - -### 입력 - -```json -{ - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting." -} -``` - -### 출력 - -```json -{ - "code": 0, - "data": { - "created_at": 1798761600000, - "task_id": "kling-task-1a2b3c4d5e6f", - "task_result": { - "videos": [ - { - "duration": "5", - "id": "kling-video-6f5e4d3c2b1a", - "url": "https://example.invalid/kling/kling-v1/generated.mp4" - } - ] - }, - "task_status": "succeed", - "task_status_msg": "", - "updated_at": 1798761840000 - }, - "message": "SUCCEED", - "request_id": "9f2c1a04-7b6e-4d38-8a51-3c0e7d9b2f46" -} -``` - - - diff --git a/ko/development/comfy-router/models/kling/kling-v2-1/code.mdx b/ko/development/comfy-router/models/kling/kling-v2-1/code.mdx deleted file mode 100644 index bdcf1e316b..0000000000 --- a/ko/development/comfy-router/models/kling/kling-v2-1/code.mdx +++ /dev/null @@ -1,467 +0,0 @@ ---- -title: "Comfy Router로 Kling V2.1 사용하기" -description: "Comfy Router를 통해 kling/kling-v2-1을 호출합니다: endpoint, 요청 형태, 그리고 Router가 반환하는 응답." -sidebarTitle: "Kling V2.1" -translationSourceHash: 93fbd156 -translationFrom: development/comfy-router/models/kling/kling-v2-1/code.mdx -translationBlockHashes: - "_intro": d015787e - "Quick start": afcb7671 - "Schema": 175b57fe - "Examples": e835e733 ---- -{/* 생성된 파일. router-schemas/kling/kling-v2-1.json에서 `pnpm code-pages:gen`으로 생성되었습니다. */} - -import RouterCodeFooter from "/snippets/ko/comfy-router/model-code-footer.mdx"; - -`kling/kling-v2-1`에 대한 API 레퍼런스입니다. Kling에서 제공하며 Comfy Router를 통해 서비스됩니다. - -## 빠른 시작 - -[Comfy 워크스페이스](https://platform.comfy.org/profile/api-keys)에서 키를 생성하고 `COMFY_API_KEY`로 내보내세요. Python 및 TypeScript 스니펫은 Comfy SDK(`pip install comfy-sdk`, `npm install @comfyorg/sdk`)를 사용하며, cURL 스니펫은 동일한 호출을 raw HTTP로 수행합니다. - -**모델 ID:** `kling/kling-v2-1` - -**엔드포인트:** `POST https://api.comfy.org/v2/models/kling/kling-v2-1` - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# The SDK automatically creates an idempotency key and reuses it for automatic retries. -with Comfy() as client: - result = client.models.run( - "kling/kling-v2-1", - { - "duration": "5", - "image": "https://example.invalid/kling/reference.png", - "mode": "std", - "prompt": "The fox turns its head towards the camera.", - }, - ) - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// The SDK automatically creates an idempotency key and reuses it for automatic retries. -const { data } = await comfy.models.run("kling/kling-v2-1", { - duration: "5", - image: "https://example.invalid/kling/reference.png", - mode: "std", - prompt: "The fox turns its head towards the camera.", -}); - -console.log(data); -``` - -```bash cURL -curl https://api.comfy.org/v2/models/kling/kling-v2-1 \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"duration\": \"5\", \"image\": \"https://example.invalid/kling/reference.png\", \"mode\": \"std\", \"prompt\": \"The fox turns its head towards the camera.\"}" -``` - - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -with Comfy() as client: - handle = client.models.submit( - "kling/kling-v2-1", - { - "duration": "5", - "image": "https://example.invalid/kling/reference.png", - "mode": "std", - "prompt": "The fox turns its head towards the camera.", - }, - ) - print("request_id:", handle.request_id) # with the model ID, all another process needs - - # Poll until the request completes, waiting the Retry-After the server names. - for update in handle.iter_events(): - print(update.status, update.queue_position) - - # The provider's own payload, the same value models.run() returns. - # A request that failed or was cancelled raises the typed Router error here. - result = handle.get() - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -const handle = await comfy.models.submit("kling/kling-v2-1", { - duration: "5", - image: "https://example.invalid/kling/reference.png", - mode: "std", - prompt: "The fox turns its head towards the camera.", -}); -console.log("requestId:", handle.requestId); // with the model ID, all another process needs - -// Poll until the request completes, waiting the Retry-After the server names. -for await (const update of handle.events()) { - console.log(update.status, update.queuePosition); -} - -// The same result models.run() returns. A request that failed or was cancelled rejects here. -const result = await handle.get(); - -console.log(result.data); -``` - -```bash cURL -# 1. Submit. Router answers 201 with request_id, status_url, response_url and cancel_url. -curl https://api.comfy.org/v2/models/kling/kling-v2-1/requests \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"duration\": \"5\", \"image\": \"https://example.invalid/kling/reference.png\", \"mode\": \"std\", \"prompt\": \"The fox turns its head towards the camera.\"}" - -# 2. Poll until status is COMPLETED, waiting the Retry-After seconds each response names. -REQUEST_ID="" -curl -i https://api.comfy.org/v2/models/kling/kling-v2-1/requests/$REQUEST_ID/status \ - -H "X-API-Key: $COMFY_API_KEY" - -# 3. Collect. 200 with the model's native output, 202 with the status body while it is still running. -curl https://api.comfy.org/v2/models/kling/kling-v2-1/requests/$REQUEST_ID \ - -H "X-API-Key: $COMFY_API_KEY" -``` - - - - - -## 스키마 - -### 입력 - - - 콜백 알림 주소입니다. 작업 상태가 변경되면 서버가 알림을 보냅니다. - - 형식: `uri` - - - - - - - - - - - - 카메라의 수평 축(x축) 이동을 제어합니다. 음수는 왼쪽, 양수는 오른쪽을 나타냅니다. - - 범위: `-10` ~ `10` - - - - 수직 평면에서의 카메라 회전(x축)을 제어합니다. 음수는 아래쪽 회전, 양수는 위쪽 회전을 나타냅니다. - - 범위: `-10` ~ `10` - - - - 카메라의 롤링 정도(z축)를 제어합니다. 음수는 반시계 방향, 양수는 시계 방향을 나타냅니다. - - 범위: `-10` ~ `10` - - - - 수평 평면에서의 카메라 회전(y축)을 제어합니다. 음수는 왼쪽 회전, 양수는 오른쪽 회전을 나타냅니다. - - 범위: `-10` ~ `10` - - - - 카메라의 수직 축(y축) 이동을 제어합니다. 음수는 아래쪽, 양수는 위쪽을 나타냅니다. - - 범위: `-10` ~ `10` - - - - 카메라 초점 거리의 변화를 제어합니다. 음수는 좁은 화각, 양수는 넓은 화각을 나타냅니다. - - 범위: `-10` ~ `10` - - - - 미리 정의된 카메라 움직임 유형입니다. simple: 사용자 정의 가능한 카메라 움직임. down_back: 카메라가 하강하며 뒤로 이동합니다. forward_up: 카메라가 앞으로 이동하며 위로 기울어집니다. right_turn_forward: 오른쪽으로 회전하며 앞으로 이동합니다. left_turn_forward: 왼쪽으로 회전하며 앞으로 이동합니다. - - 가능한 값: `simple`, `down_back`, `forward_up`, `right_turn_forward`, `left_turn_forward` - - - - 비디오 생성의 유연성입니다. 값이 높을수록 모델의 유연성 정도가 낮아지고 사용자의 프롬프트와의 관련성이 강해집니다. - - 범위: `0` ~ `1` - - 형식: `float` - - - - 비디오 재생 시간(초)입니다. - - 가능한 값: `3`, `4`, `5`, `6`, `7`, `8`, `9`, `10`, `11`, `12`, `13`, `14`, `15` - - - - 동적 브러시 구성 목록입니다(최대 6개 그룹). 5초 비디오의 경우 궤적 길이는 77개 좌표를 초과할 수 없습니다. - - - - 동적 브러시 적용 영역입니다(사용자가 모션 브러시로 작성한 마스크 이미지). 가로세로 비율이 입력 이미지와 일치해야 합니다. - - 형식: `uri` - - - - - - - - 궤적 지점의 수평 좌표입니다. 이미지의 왼쪽 아래 모서리를 원점 (0,0)으로 합니다. - - - - 궤적 지점의 수직 좌표입니다. 이미지의 왼쪽 아래 모서리를 원점 (0,0)으로 합니다. - - - - 요소 ID 구성을 기반으로 한 참조 요소 목록입니다. 최대 3개의 참조 요소를 지원합니다. element_list와 voice_list 파라미터는 상호 배타적입니다. - - - - 요소 ID - - 형식: `int64` - - - - 사용자 정의 작업 ID입니다. 단일 사용자 계정 내에서 고유해야 합니다. - - - - 참조 이미지 - URL 또는 Base64로 인코딩된 문자열이며, 10MB를 초과할 수 없고 해상도는 300*300px 이상, 가로세로 비율은 1:2.5 ~ 2.5:1이어야 합니다. Base64에는 data:image 접두사를 포함하지 않아야 합니다. - - - - 참조 이미지 - 종료 프레임 제어입니다. URL 또는 Base64로 인코딩된 문자열이며, 10MB를 초과할 수 없고 해상도는 300*300px 이상이어야 합니다. Base64에는 data:image 접두사를 포함하지 않아야 합니다. dynamic_masks/static_mask 또는 camera_control과 동시에 사용할 수 없습니다. - - - - 비디오 생성 모드입니다. std: 비용 효율적인 표준 모드. pro: 더 긴 재생 시간의 비디오를 생성하지만 출력 품질이 더 높은 전문가 모드. - - 가능한 값: `std`, `pro` - - - - 모델 이름입니다. Comfy Router를 사용할 때는 생략하거나 null을 보내세요. 모델은 요청 경로에 의해 선택됩니다. 이름을 제공하는 경우 해당 경로와 일치해야 합니다. - - - - 프롬프트 및 재생 시간 등 각 스토리보드에 대한 정보입니다. 최대 6개의 스토리보드를 지원하며 최소 1개가 필요합니다. multi_shot이 참이고 shot_type이 customize인 경우 필수입니다. - - - - 이 스토리보드의 재생 시간(초)입니다. 전체 작업 재생 시간을 초과할 수 없고 1보다 작을 수 없습니다. 모든 스토리보드 재생 시간의 합은 전체 작업 재생 시간과 같습니다. - - - - 샷 순서 번호 - - - - 이 스토리보드의 프롬프트 단어입니다. 최대 길이는 512자입니다. - - - - 멀티 샷 비디오를 생성할지 여부입니다. 참인 경우 prompt 파라미터는 유효하지 않습니다. 거짓인 경우 shot_type 및 multi_prompt 파라미터는 유효하지 않습니다. - - - - Negative text prompt. It is recommended to supplement negative prompt information through negative sentences directly within positive prompts. - - - - 긍정 텍스트 프롬프트입니다. \<\<\>>을 사용하여 voice_list 파라미터 순서에 맞는 보이스를 지정하세요. 하나의 작업은 최대 2개의 톤을 참조할 수 있습니다. 톤을 지정할 때는 sound 파라미터 값이 on이어야 합니다. - - - - 스토리보드 방법입니다. multi_shot 파라미터가 참으로 설정된 경우 필수입니다. - - 사용 가능한 값: `customize`, `intelligence` - - - - 비디오를 생성할 때 사운드를 동시에 생성할지 여부입니다. 모델 V2.6 이후 버전에서만 이 파라미터를 지원합니다. - - 사용 가능한 값: `on`, `off` - - - - 정적 브러시 적용 영역(사용자가 모션 브러시를 사용해 작성한 마스크 이미지)입니다. 가로세로 비율은 입력 이미지와 일치해야 합니다. - - - - 비디오를 생성할 때 참조되는 보이스 목록입니다. 최대 2개의 보이스를 지원합니다. element_list와 voice_list 파라미터는 상호 배타적입니다. - - - - 보이스 사용자 정의 API를 통해 반환된 보이스 ID 또는 시스템 프리셋 보이스 ID입니다. - - - - 워터마크가 적용된 결과를 동시에 생성할지 여부입니다. 현재 사용자 정의 워터마크는 지원되지 않습니다. - - - - 참은 워터마크를 생성함을, 거짓은 생성하지 않음을 의미합니다. - - -Router가 `GET /v2/models/kling/kling-v2-1/openapi.json`에서 제공하는 스키마에서 생성되었으며, 이는 요청이 공급자에게 도달하기 전에 호출을 검증하는 데 사용하는 것과 동일한 문서입니다. -### 출력 - - - 오류 코드 - - - - - - - - 작업 생성 시간, 밀리초 단위의 Unix timestamp - - - - 작업의 차감 단위 - - - - 작업 ID - - - - - - - - - - - - - - - - - - - - 총 비디오 재생 시간(초) - - - - 생성된 비디오 ID - - - - 생성된 비디오의 URL - - 형식: `uri` - - - - 워터마크가 포함된 생성 비디오의 URL, 핫링크 보호 형식 - - 형식: `uri` - - - - 작업 상태 - - 가능한 값: `submitted`, `processing`, `succeed`, `failed` - - - - 작업 상태 정보로, 작업 실패 시 실패 이유를 표시합니다 - - - - 작업 업데이트 시간, 밀리초 단위의 Unix timestamp - - - - - - - - - - - - 오류 메시지 - - - - 요청 ID - - -## 예시 - -### 입력 - -```json -{ - "duration": "5", - "image": "https://example.invalid/kling/reference.png", - "mode": "std", - "prompt": "The fox turns its head towards the camera." -} -``` - -### 출력 - -```json -{ - "code": 0, - "data": { - "created_at": 1798761600000, - "task_id": "kling-task-1a2b3c4d5e6f", - "task_result": { - "videos": [ - { - "duration": "5", - "id": "kling-video-6f5e4d3c2b1a", - "url": "https://example.invalid/kling/kling-v1/generated.mp4" - } - ] - }, - "task_status": "succeed", - "task_status_msg": "", - "updated_at": 1798761840000 - }, - "message": "SUCCEED", - "request_id": "9f2c1a04-7b6e-4d38-8a51-3c0e7d9b2f46" -} -``` - - - diff --git a/ko/development/comfy-router/models/kling/kling-v2-master/code.mdx b/ko/development/comfy-router/models/kling/kling-v2-master/code.mdx deleted file mode 100644 index 18c713507f..0000000000 --- a/ko/development/comfy-router/models/kling/kling-v2-master/code.mdx +++ /dev/null @@ -1,420 +0,0 @@ ---- -title: "Comfy Router로 Kling V2 Master 사용하기" -description: "Comfy Router를 통해 kling/kling-v2-master를 호출합니다: endpoint, 요청 형태, 그리고 Router가 반환하는 응답." -sidebarTitle: "Kling V2 Master" -translationSourceHash: f9334f9e -translationFrom: development/comfy-router/models/kling/kling-v2-master/code.mdx -translationBlockHashes: - "_intro": c470eb90 - "Quick start": 1369e080 - "Schema": 769d8e31 - "Examples": 14429ff8 ---- -{/* GENERATED FILE. Generated from router-schemas/kling/kling-v2-master.json by `pnpm code-pages:gen`. */} - -import RouterCodeFooter from "/snippets/ko/comfy-router/model-code-footer.mdx"; - -`kling/kling-v2-master`에 대한 API 레퍼런스입니다. Kling에서 제공하며 Comfy Router를 통해 서빙됩니다. - -## 빠른 시작 - -[Comfy 워크스페이스](https://platform.comfy.org/profile/api-keys)에서 키를 생성하고 `COMFY_API_KEY`로 내보내세요. Python과 TypeScript 스니펫은 Comfy SDK(`pip install comfy-sdk`, `npm install @comfyorg/sdk`)를 사용하며, cURL 스니펫은 동일한 호출을 raw HTTP로 수행합니다. - -**모델 ID:** `kling/kling-v2-master` - -**엔드포인트:** `POST https://api.comfy.org/v2/models/kling/kling-v2-master` - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# The SDK automatically creates an idempotency key and reuses it for automatic retries. -with Comfy() as client: - result = client.models.run( - "kling/kling-v2-master", - { - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting.", - }, - ) - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// The SDK automatically creates an idempotency key and reuses it for automatic retries. -const { data } = await comfy.models.run("kling/kling-v2-master", { - aspect_ratio: "16:9", - duration: "5", - mode: "std", - prompt: "A red fox trotting through falling snow, cinematic lighting.", -}); - -console.log(data); -``` - -```bash cURL -curl https://api.comfy.org/v2/models/kling/kling-v2-master \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"aspect_ratio\": \"16:9\", \"duration\": \"5\", \"mode\": \"std\", \"prompt\": \"A red fox trotting through falling snow, cinematic lighting.\"}" -``` - - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -with Comfy() as client: - handle = client.models.submit( - "kling/kling-v2-master", - { - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting.", - }, - ) - print("request_id:", handle.request_id) # with the model ID, all another process needs - - # Poll until the request completes, waiting the Retry-After the server names. - for update in handle.iter_events(): - print(update.status, update.queue_position) - - # The provider's own payload, the same value models.run() returns. - # A request that failed or was cancelled raises the typed Router error here. - result = handle.get() - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -const handle = await comfy.models.submit("kling/kling-v2-master", { - aspect_ratio: "16:9", - duration: "5", - mode: "std", - prompt: "A red fox trotting through falling snow, cinematic lighting.", -}); -console.log("requestId:", handle.requestId); // with the model ID, all another process needs - -// Poll until the request completes, waiting the Retry-After the server names. -for await (const update of handle.events()) { - console.log(update.status, update.queuePosition); -} - -// The same result models.run() returns. A request that failed or was cancelled rejects here. -const result = await handle.get(); - -console.log(result.data); -``` - -```bash cURL -# 1. Submit. Router answers 201 with request_id, status_url, response_url and cancel_url. -curl https://api.comfy.org/v2/models/kling/kling-v2-master/requests \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"aspect_ratio\": \"16:9\", \"duration\": \"5\", \"mode\": \"std\", \"prompt\": \"A red fox trotting through falling snow, cinematic lighting.\"}" - -# 2. Poll until status is COMPLETED, waiting the Retry-After seconds each response names. -REQUEST_ID="" -curl -i https://api.comfy.org/v2/models/kling/kling-v2-master/requests/$REQUEST_ID/status \ - -H "X-API-Key: $COMFY_API_KEY" - -# 3. Collect. 200 with the model's native output, 202 with the status body while it is still running. -curl https://api.comfy.org/v2/models/kling/kling-v2-master/requests/$REQUEST_ID \ - -H "X-API-Key: $COMFY_API_KEY" -``` - - - - - -## 스키마 - -### 입력 - - - 비디오 화면 비율 - - 가능한 값: `16:9`, `9:16`, `1:1` - - - - 콜백 알림 주소 - - 형식: `uri` - - - - - - - - - - - - 카메라의 수평 축(x축) 이동을 제어합니다. 음수는 왼쪽, 양수는 오른쪽을 나타냅니다. - - 범위: `-10` ~ `10` - - - - 수직 평면에서의 카메라 회전(x축)을 제어합니다. 음수는 아래쪽 회전, 양수는 위쪽 회전을 나타냅니다. - - 범위: `-10` ~ `10` - - - - 카메라의 롤링 양(z축)을 제어합니다. 음수는 반시계 방향, 양수는 시계 방향을 나타냅니다. - - 범위: `-10` ~ `10` - - - - 수평 평면에서의 카메라 회전(y축)을 제어합니다. 음수는 왼쪽 회전, 양수는 오른쪽 회전을 나타냅니다. - - 범위: `-10` ~ `10` - - - - 카메라의 수직 축(y축) 이동을 제어합니다. 음수는 아래쪽, 양수는 위쪽을 나타냅니다. - - 범위: `-10` ~ `10` - - - - 카메라 초점 거리의 변화를 제어합니다. 음수는 좁은 화각, 양수는 넓은 화각을 나타냅니다. - - 범위: `-10` ~ `10` - - - - 미리 정의된 카메라 이동 유형입니다. simple: 사용자 정의 가능한 카메라 이동. down_back: 카메라가 하강하며 뒤로 이동합니다. forward_up: 카메라가 앞으로 이동하며 위로 기울어집니다. right_turn_forward: 오른쪽으로 회전하며 앞으로 이동합니다. left_turn_forward: 왼쪽으로 회전하며 앞으로 이동합니다. - - 가능한 값: `simple`, `down_back`, `forward_up`, `right_turn_forward`, `left_turn_forward` - - - - 비디오 생성의 유연성입니다. 값이 높을수록 모델의 유연성 정도가 낮아지고, 사용자 프롬프트와의 관련성이 강해집니다. - - 범위: `0` ~ `1` - - 형식: `float` - - - - 비디오 길이(초) - - 가능한 값: `3`, `4`, `5`, `6`, `7`, `8`, `9`, `10`, `11`, `12`, `13`, `14`, `15` - - - - 사용자 정의 작업 ID - - - - 비디오 생성 모드입니다. std: 비용 효율적인 표준 모드. pro: 더 긴 재생 시간의 비디오를 생성하지만 품질이 더 높은 출력을 제공하는 프로페셔널 모드. - - 가능한 값: `std`, `pro` - - - - 모델 이름. Comfy Router를 사용할 때는 생략하거나 null을 전송하십시오. 모델은 요청 경로에 의해 선택됩니다. 이름을 제공하는 경우 해당 경로와 일치해야 합니다. - - - - 프롬프트 및 재생 시간 등 각 스토리보드에 대한 정보입니다. 최대 6개의 스토리보드를 지원하며 최소 1개가 필요합니다. multi_shot이 true이고 shot_type이 customize인 경우 필수입니다. - - - - 이 스토리보드의 재생 시간(초)입니다. 전체 작업 재생 시간을 초과할 수 없으며 1보다 작을 수 없습니다. 모든 스토리보드 재생 시간의 합은 전체 작업 재생 시간과 같습니다. - - - - 샷 순서 번호 - - - - 이 스토리보드의 프롬프트 단어입니다. 최대 길이는 512자입니다. - - - - 멀티 샷 비디오를 생성할지 여부입니다. true인 경우 prompt 파라미터는 무효입니다. false인 경우 shot_type 및 multi_prompt 파라미터는 무효입니다. - - - - 네거티브 텍스트 프롬프트입니다. 네거티브 프롬프트 정보는 긍정 프롬프트 내에서 직접 부정 문장을 통해 보완하는 것을 권장합니다. - - - - 긍정 텍스트 프롬프트입니다. voice_list 파라미터 순서와 일치하는 음성을 지정하려면 \<\<\>>를 사용하십시오. 작업은 최대 2개의 톤을 참조할 수 있습니다. 톤을 지정할 때는 sound 파라미터 값이 on이어야 합니다. - - - - 스토리보드 방법입니다. multi_shot 파라미터가 true로 설정된 경우 필수입니다. - - 가능한 값: `customize`, `intelligence` - - - - 비디오 생성 시 사운드를 동시에 생성할지 여부입니다. 모델의 V2.6 및 이후 버전만 이 파라미터를 지원합니다. - - 가능한 값: `on`, `off` - - - - 워터마크가 있는 결과를 동시에 생성할지 여부입니다. 현재 사용자 정의 워터마크는 지원되지 않습니다. - - - - true는 워터마크를 생성함을, false는 생성하지 않음을 의미합니다. - - -`GET /v2/models/kling/kling-v2-master/openapi.json`에서 Router가 제공하는 스키마에서 생성되었으며, 이는 요청이 공급자에게 도달하기 전에 Router가 호출을 검증하는 데 사용하는 것과 동일한 문서입니다. -### 출력 - - - 오류 코드 - - - - - - - - 작업 생성 시간, 밀리초 단위의 Unix 타임스탬프 - - - - 작업의 차감 단위 - - - - 작업 ID - - - - - - - - - - - - - - - - - - - - 비디오 총 재생 시간(초) - - - - 생성된 비디오 ID - - - - 생성된 비디오의 URL - - 형식: `uri` - - - - 워터마크가 포함된 생성된 비디오의 URL, 핫링크 보호 형식 - - 형식: `uri` - - - - 작업 상태 - - 가능한 값: `submitted`, `processing`, `succeed`, `failed` - - - - 작업 상태 정보로, 작업 실패 시 실패 사유를 표시합니다 - - - - 작업 업데이트 시간, 밀리초 단위의 Unix 타임스탬프 - - - - - - - - - - - - 오류 메시지 - - - - 요청 ID - - -## 예제 - -### 입력 - -```json -{ - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting." -} -``` - -### 출력 - -```json -{ - "code": 0, - "data": { - "created_at": 1798761600000, - "task_id": "kling-task-1a2b3c4d5e6f", - "task_result": { - "videos": [ - { - "duration": "5", - "id": "kling-video-6f5e4d3c2b1a", - "url": "https://example.invalid/kling/kling-v1/generated.mp4" - } - ] - }, - "task_status": "succeed", - "task_status_msg": "", - "updated_at": 1798761840000 - }, - "message": "SUCCEED", - "request_id": "9f2c1a04-7b6e-4d38-8a51-3c0e7d9b2f46" -} -``` - - diff --git a/zh/development/api-development/overview.mdx b/zh/development/api-development/overview.mdx deleted file mode 100644 index b35db01e76..0000000000 --- a/zh/development/api-development/overview.mdx +++ /dev/null @@ -1,70 +0,0 @@ ---- -title: "API 总览" -description: "通过不同方式编程调用 ComfyUI 的接口概览" -icon: "list" -translationSourceHash: 852ff6ab -translationFrom: development/api-development/overview.mdx -translationBlockHashes: - "_intro": 838d6d8e - "Start Here": cf5c79f3 - "Which API Should I Use?": 40998626 - "Getting Started": 41b19127 - "Prerequisites": 4ba1cc15 ---- -ComfyUI 提供多种 API 选项,具体取决于您希望在哪里运行工作流,以及希望管理多少基础设施。本页可帮助您选择合适的方法。 - ---- - -## 从这里开始 - -对于新的集成,请使用 **Comfy SDKs** 及其调用的 Comfy API v2。v2 是一套新的、带版本管理的 HTTP 接口,与现有的 Cloud API 和 ComfyUI Server API 并存。详见 [Comfy API v2 概览](/zh/api-reference/v2/overview)。同一套代码既可运行于 Comfy Cloud,也可运行于您自己的机器。 - - - 用于从您自己的应用程序中运行工作流的官方 Python 与 TypeScript SDK。目前处于测试版。 - - -以下其他 API 仍完全受支持,它们涵盖了 SDK 尚未覆盖的范围。此处没有任何内容被弃用。 - ---- - -## 我应该使用哪个 API? - -| | Comfy API v2 + SDKs | Cloud API | ComfyUI Server API | -|---|---|---|---| -| **运行位置** | Comfy Cloud,或通过本地代理在你自己的机器上运行 | Comfy Cloud(托管 GPU) | 你自己的机器 | -| **兼容性** | 有版本控制,v2 内仅做增量更改 | 实验性,可能随时更改,恕不另行通知 | 跨版本不提供保证 | -| **GPU 管理** | 取决于你指向哪个接口 | 为你处理 | 你自行管理自己的硬件 | -| **模型** | 取决于你指向哪个接口 | 由 Comfy 预装和管理 | 你自行下载并在本地管理 | -| **身份验证** | 云端使用 `Authorization: Bearer`。自托管默认无认证,可选静态 bearer 令牌 | `X-API-Key` 请求头(Comfy Cloud 账户) | 无(本地)或用于合作节点的 API 密钥 | -| **基础 URL** | `https://cloud.comfy.org` 或 `http://127.0.0.1:8189` | `https://cloud.comfy.org` | 你的服务器 URL(例如 `http://localhost:8188`) | -| **官方客户端** | Python 和 TypeScript SDK | 无,通过 HTTP 调用 | 无,通过 HTTP 调用 | -| **协议** | REST + SSE | REST + WebSocket | REST + WebSocket | -| **范围** | 运行工作流并获取结果 | 完整的云端功能范围,包括模型和账户 | 完整的本地功能范围,包括队列和节点信息 | -| **最适合** | 需要长期保持可用的新集成 | SDK 尚未覆盖的云端功能 | 完全控制、自定义硬件和模型 | - -它们都使用相同的工作流格式([API 格式](/zh/development/api-development/workflow-api-format)),因此你可以在本地开发和测试工作流,并将其移至云端而无需更改。 - -## 入门 - - - - 使用 Python 或 TypeScript 运行工作流,可对接云端或您自己的机器。 - - - 在 Comfy 的托管基础设施上运行工作流。无需设置 GPU。 - - - 在您自己的机器上将 ComfyUI 作为服务器运行,并通过 API 调用。 - - - 在无头或 API 驱动的工作流中使用付费合作节点。 - - - ---- - -## 先决条件 - -在使用任何 API 之前,你需要: - -- 任何涉及 Comfy Cloud 或合作节点的操作都需要 API 密钥(参见 [获取 API 密钥](/zh/development/api-development/getting-an-api-key))。纯本地 ComfyUI 则不需要。 diff --git a/zh/development/comfy-router/models/byteplus/seedance-1-0-lite-i2v-250428/code.mdx b/zh/development/comfy-router/models/byteplus/seedance-1-0-lite-i2v-250428/code.mdx deleted file mode 100644 index 6c1cdef29b..0000000000 --- a/zh/development/comfy-router/models/byteplus/seedance-1-0-lite-i2v-250428/code.mdx +++ /dev/null @@ -1,434 +0,0 @@ ---- -title: "搭配 Comfy Router 使用 Seedance 1.0 Lite I2V 250428" -description: "通过 Comfy Router 调用 byteplus/seedance-1-0-lite-i2v-250428:端点、请求形状以及 Router 返回的响应。" -sidebarTitle: "Seedance 1.0 Lite I2V 250428" -translationSourceHash: 0f64abdd -translationFrom: development/comfy-router/models/byteplus/seedance-1-0-lite-i2v-250428/code.mdx -translationBlockHashes: - "_intro": 66c320e8 - "Quick start": a84cd948 - "Schema": 0dd61406 - "Examples": d126be96 ---- -{/* 已生成文件。由 `pnpm code-pages:gen` 从 router-schemas/byteplus/seedance-1-0-lite-i2v-250428.json 生成。 */} - -import RouterCodeFooter from "/snippets/zh/comfy-router/model-code-footer.mdx"; - -`byteplus/seedance-1-0-lite-i2v-250428` 的 API 参考,由 Comfy Router 从 BytePlus 提供。 - -## 快速开始 - -在[你的 Comfy 工作区](https://platform.comfy.org/profile/api-keys)中创建密钥,并将其导出为 `COMFY_API_KEY`。Python 和 TypeScript 代码片段使用 Comfy SDK(`pip install comfy-sdk`、`npm install @comfyorg/sdk`);cURL 代码片段是通过原始 HTTP 执行的相同调用。 - -**模型 ID:** `byteplus/seedance-1-0-lite-i2v-250428` - -**端点:** `POST https://api.comfy.org/v2/models/byteplus/seedance-1-0-lite-i2v-250428` - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# The SDK automatically creates an idempotency key and reuses it for automatic retries. -with Comfy() as client: - result = client.models.run( - "byteplus/seedance-1-0-lite-i2v-250428", - { - "content": [ - { - "text": "A red fox trotting through a snowy pine forest", - "type": "text", - }, - ], - "duration": 5, - "ratio": "16:9", - "resolution": "720p", - }, - ) - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// The SDK automatically creates an idempotency key and reuses it for automatic retries. -const { data } = await comfy.models.run("byteplus/seedance-1-0-lite-i2v-250428", { - content: [ - { - text: "A red fox trotting through a snowy pine forest", - type: "text", - }, - ], - duration: 5, - ratio: "16:9", - resolution: "720p", -}); - -console.log(data); -``` - -```bash cURL -curl https://api.comfy.org/v2/models/byteplus/seedance-1-0-lite-i2v-250428 \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"content\": [{\"text\":\"A red fox trotting through a snowy pine forest\",\"type\":\"text\"}], \"duration\": 5, \"ratio\": \"16:9\", \"resolution\": \"720p\"}" -``` - - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -with Comfy() as client: - handle = client.models.submit( - "byteplus/seedance-1-0-lite-i2v-250428", - { - "content": [ - { - "text": "A red fox trotting through a snowy pine forest", - "type": "text", - }, - ], - "duration": 5, - "ratio": "16:9", - "resolution": "720p", - }, - ) - print("request_id:", handle.request_id) # with the model ID, all another process needs - - # Poll until the request completes, waiting the Retry-After the server names. - for update in handle.iter_events(): - print(update.status, update.queue_position) - - # The provider's own payload, the same value models.run() returns. - # A request that failed or was cancelled raises the typed Router error here. - result = handle.get() - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -const handle = await comfy.models.submit("byteplus/seedance-1-0-lite-i2v-250428", { - content: [ - { - text: "A red fox trotting through a snowy pine forest", - type: "text", - }, - ], - duration: 5, - ratio: "16:9", - resolution: "720p", -}); -console.log("requestId:", handle.requestId); // with the model ID, all another process needs - -// Poll until the request completes, waiting the Retry-After the server names. -for await (const update of handle.events()) { - console.log(update.status, update.queuePosition); -} - -// The same result models.run() returns. A request that failed or was cancelled rejects here. -const result = await handle.get(); - -console.log(result.data); -``` - -```bash cURL -# 1. Submit. Router answers 201 with request_id, status_url, response_url and cancel_url. -curl https://api.comfy.org/v2/models/byteplus/seedance-1-0-lite-i2v-250428/requests \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"content\": [{\"text\":\"A red fox trotting through a snowy pine forest\",\"type\":\"text\"}], \"duration\": 5, \"ratio\": \"16:9\", \"resolution\": \"720p\"}" - -# 2. Poll until status is COMPLETED, waiting the Retry-After seconds each response names. -REQUEST_ID="" -curl -i https://api.comfy.org/v2/models/byteplus/seedance-1-0-lite-i2v-250428/requests/$REQUEST_ID/status \ - -H "X-API-Key: $COMFY_API_KEY" - -# 3. Collect. 200 with the model's native output, 202 with the status body while it is still running. -curl https://api.comfy.org/v2/models/byteplus/seedance-1-0-lite-i2v-250428/requests/$REQUEST_ID \ - -H "X-API-Key: $COMFY_API_KEY" -``` - - - - - -## Schema - -### 输入 - - - 此生成任务结果的回调通知地址 - - 格式:`uri` - - - - 模型生成视频所需的输入内容 - - - - 输入音频对象。仅 Seedance 2.5、2.0 和 2.0 fast 支持音频输入。Seedance 2.0 和 2.0 fast 不能单独使用音频,必须至少包含 1 张图像或视频;Seedance 2.5 支持仅音频输入。 - - - - 音频 URL、Base64 编码或资产 ID。 -音频 URL:音频的公开 URL(wav、mp3)。 -Base64:格式为 data:audio/\;base64,\ -资产 ID:格式为 asset://\ - - - - - - - - 用于图生视频生成的图像内容(当 type 为 "image_url" 时) -图片网址:请确保图片网址可访问。 -Base64 编码内容:格式必须为 data:image/\;base64,\ -资产 ID:格式为 asset://\ - - - - 内容项的角色/位置。 -对于图像:first_frame、last_frame 或 reference_image。 -对于视频:reference_video(仅 Seedance 2.5、2.0 和 2.0 fast)。 -对于音频:reference_audio(仅 Seedance 2.5、2.0 和 2.0 fast)。 - - 可选值:`first_frame`、`last_frame`、`reference_image`、`reference_video`、`reference_audio` - - - - 模型的输入文本信息。包含文本提示词和可选参数。 - -文本提示词(必填):使用中英文字符描述要生成的视频。 - -参数(可选):在文本提示词之后添加 --[parameters] 以控制视频规格: -- --resolution(--rs):480p、720p、1080p(默认值:720p) -- --ratio(--rt):21:9、16:9、4:3、1:1、3:4、9:16、9:21、adaptive(默认值:16:9 或 adaptive) -- --duration(--dur):3-12 秒(默认值:5) -- --framepersecond(--fps):24(默认值:24) -- --watermark(--wm):true/false(默认值:false) -- --seed(--seed):-1 到 2^32-1(默认值:-1) -- --camerafixed(--cf):true/false(默认值:false) - -示例:"A beautiful landscape --ratio 16:9 --resolution 720p --duration 5" - - - - 输入内容的类型 - - 可选值:`text`、`image_url`、`video_url`、`audio_url` - - - - 输入视频对象。仅 Seedance 2.5、2.0 和 2.0 fast 支持视频输入。 - - - - 视频 URL 或资产 ID。 -视频 URL:视频的公开 URL(mp4、mov)。 -资产 ID:格式为 asset://\ - - - - 视频时长(秒)。Seedance 2.5:[4,30] 或 -1(自动;视频编辑任务仅支持 -1)。Seedance 2.0 和 2.0 fast:[4,15] 或 -1(自动)。Seedance 1.5 pro:[4,12] 或 -1。Seedance 1.0:[2,12]。 - - 范围:`2` 到 `30` - - - - 任务超时阈值(秒)。默认 172800(48 小时)。范围:[3600, 259200]。 - - 范围:`3600` 到 `259200` - - - - Seedance 2.5、2.0、2.0 fast 和 1.5 pro 支持。生成的视频是否包含与画面同步的音频。 -true:模型输出带有同步音频的视频。 -false:模型输出无声视频。 - - - - 要调用的模型 ID。支持的模型:seedance-1-5-pro-251215、seedance-1-0-pro-250528、seedance-1-0-pro-fast-251015、seedance-1-0-lite-t2v-250428、seedance-1-0-lite-i2v-250428、dreamina-seedance-2-0-260128、dreamina-seedance-2-0-fast-260128、dreamina-seedance-2-0-mini 和 dreamina-seedance-2-5-260628。直接向 POST /proxy/byteplus/api/v3/contents/generations/tasks 发起 v1 调用时必须提供该参数:代理会拒绝任何其他值,若省略该参数则返回 400。它不在本 schema 的 `required` 列表中,因为 Comfy Router 会从 /v2/models/byteplus/\{model} 的 `{model}` 路径段填充它,因此 Router 调用方会省略它。 - - - - 仅 Seedance 2.5。输出视频的容器格式。 -mp4:通用容器(H.264/AAC,yuv420p),兼容性广且文件大小更小。 -mov:专业容器(H.264 High 4:4:4 Predictive/PCM,yuv444p),颜色精度高,适合后期制作;文件大小更大。 - - 可选值:`mp4`、`mov` - - - - 已生成视频的宽高比。Seedance 2.0 和 2.0 fast、1.5 pro 默认值:adaptive。 - - 可选值:`16:9`、`4:3`、`1:1`、`3:4`、`9:16`、`21:9`、`9:21`、`adaptive` - - - - 视频分辨率。Seedance 2.5、2.0 和 2.0 fast、1.5 pro、1.0 lite 默认值:720p。Seedance 1.0 pro 和 pro-fast 默认值:1080p。 -注意:Seedance 2.0 和 2.0 fast 不支持 1080p。Seedance 2.5 支持 480p、720p 和 1080p。 - - 可选值:`480p`、`720p`、`1080p`、`4k` - - - - 是否返回已生成视频的最后一帧图像。`true`:返回已生成视频的最后一帧图像。将该参数设置为 true 后,可通过调用"查询视频生成任务信息"接口获取最后一帧图像。最后一帧图像为 PNG 格式,其像素宽度和高度与已生成视频一致,且不包含水印。使用该参数可以生成多个连续视频:将前一个已生成视频的最后一帧用作下一个视频任务的首帧,从而快速生成多个连续视频。 -`false`:不返回已生成视频的最后一帧图像。 - - - - 用于控制随机性的种子整数。取值范围:[-1, 2^32-1]。-1 表示使用随机种子。 - - 范围:`-1` 到 `4294967295` - - - - 处理所使用的服务层级。Seedance 2.5、2.0 和 2.0 fast 不支持 flex(离线推理)。 - - 可选值:`default`、`flex` - - - - 已生成视频是否包含水印。 - - -由 Router 在 `GET /v2/models/byteplus/seedance-1-0-lite-i2v-250428/openapi.json` 提供的 schema 生成,这也是请求到达提供商之前 Router 用于校验调用的同一份文档。 -### 输出 - - - 视频生成任务完成后得到的输出,其中包含输出视频的下载 URL,以及 BytePlus 返回时其最后一帧的下载 URL。`video_url` 和 `last_frame_url` 都会被重新托管到 Comfy 存储上;这里的其他所有字段都是 BytePlus 自己的字段。可为空:任务完成 24 小时后 BytePlus 会清除这些 URL,而在之后轮询到的已成功完成的文档中,`content` 可能缺失或为 null。 - - - - 生成视频最后一帧的下载 URL,当请求设置了 `return_last_frame` 时返回。不要根据此 URL 推断图像格式:BytePlus 在请求侧将最后一帧记录为 PNG,Router 会重新托管它收到的任何字节,并根据上游的 Content-Type 或内容嗅探来确定其类型,只有当两者都失败时,才会以 `image/jpeg` 作为最后的兜底。Router 会把最后一帧重新托管到 Comfy 存储上并重写此字段,因此它通常是 Comfy 签名的 URL,有效期最长为 24 小时:签发时按 24 小时签名,并从 23 小时的备忘录中重放,因此稍后轮询返回的 URL 有效期可能只剩不到一小时。当无法执行重新托管时,该字段会保留 BytePlus 自己的 URL,而 BytePlus 会在任务完成 24 小时后清除它。无论哪种情况,链接都会过期,因此请下载该帧,而不要保存 URL。 - - - - 生成视频的容器格式(mp4 或 mov),当 BytePlus 将其嵌套在 `content` 内部时返回。Seedance 模型更常见的是将其作为 `content` 的顶层同级字段返回,参见顶层 `output_format` 字段;Router 会读取两者中存在的那个。 - - - - 输出视频的下载 URL。Router 会把视频重新托管到 Comfy 存储上并重写此字段,因此它通常是 Comfy 签名的 URL,有效期最长为 24 小时:签发时按 24 小时签名,并从 23 小时的备忘录中重放,因此稍后轮询返回的 URL 有效期可能只剩不到一小时。当无法执行重新托管时,该字段会保留 BytePlus 自己的 URL,而 BytePlus 会在任务完成 24 小时后清除它,且在某些模型上将其限制为 100 次下载。无论哪种情况,链接都会过期,因此请下载视频,而不要保存 URL。 - - - - 任务的创建时间。该值为 UNIX 时间戳,单位为秒。 - - - - 生成视频的时长,单位为秒。这里声明为 number 而非 integer,是因为 BytePlus 在这点上并不一致:视频任务曾被观察到返回整数秒,而 BytePlus 的其他同级接口报告的是小数时长,因此客户端不应假定它是整数值。这是 BytePlus 自己的字段,在成功的视频任务上返回并原样转发。 - - - - 错误信息。如果任务成功,则返回 null。如果任务失败,则返回错误信息。 - - - - 错误码 - - - - 报错信息 - - - - 视频生成任务的 ID - - - - 任务所用模型的名称和版本 - - - - 生成视频的容器格式(mp4 或 mov),作为 `content` 的同级字段在顶层返回,这正是 Seedance 视频任务查询返回它的位置。这是 BytePlus 自己的字段,原样转发。 - - - - 生成视频的分辨率,例如 `1080p`。这是 BytePlus 自己的字段,在成功的视频任务上返回并原样转发。 - - - - 任务实际使用的生成种子。这是 BytePlus 自己的字段,在成功的视频任务上返回并原样转发。 - - 格式:`int64` - - - - 任务的状态 - - 可能的值:`queued`、`running`、`cancelled`、`succeeded`、`failed`、`expired` - - - - 任务最后更新的时间。该值为 UNIX 时间戳,单位为秒。 - - - - 该请求的 token 用量 - - - - 模型生成的 token 数量 - - - - 对于视频生成模型,不计算输入 token 数量,并默认为 0。因此 total_tokens = completion_tokens。 - - -## 示例 - -### 输入 - -```json -{ - "content": [ - { - "text": "A red fox trotting through a snowy pine forest", - "type": "text" - } - ], - "duration": 5, - "ratio": "16:9", - "resolution": "720p" -} -``` - -### 输出 - -```json -{ - "content": { - "last_frame_url": "https://example.invalid/byteplus/seedance-1-0-lite-t2v-250428/last-frame", - "video_url": "https://example.invalid/byteplus/seedance-1-0-lite-t2v-250428/generated.mp4" - }, - "created_at": 1767225600, - "duration": 5, - "error": null, - "id": "3f7a1b28-5c0d-4e91-8a6f-1b2c3d4e5f60", - "model": "seedance-1-0-lite-i2v-250428", - "output_format": "mp4", - "resolution": "1080p", - "seed": 1234567890123, - "status": "succeeded", - "updated_at": 1767225730 -} -``` - - diff --git a/zh/development/comfy-router/models/byteplus/seedance-1-0-lite-t2v-250428/code.mdx b/zh/development/comfy-router/models/byteplus/seedance-1-0-lite-t2v-250428/code.mdx deleted file mode 100644 index f63eaea8c2..0000000000 --- a/zh/development/comfy-router/models/byteplus/seedance-1-0-lite-t2v-250428/code.mdx +++ /dev/null @@ -1,435 +0,0 @@ ---- -title: "使用 Comfy Router 调用 Seedance 1.0 Lite T2V 250428" -description: "通过 Comfy Router 调用 byteplus/seedance-1-0-lite-t2v-250428:端点、请求结构以及 Router 返回的响应。" -sidebarTitle: "Seedance 1.0 Lite T2V 250428" -translationSourceHash: 6065cd55 -translationFrom: development/comfy-router/models/byteplus/seedance-1-0-lite-t2v-250428/code.mdx -translationBlockHashes: - "_intro": a1ec32a9 - "Quick start": bf8ec8dc - "Schema": 060399d4 - "Examples": 7c3591f8 ---- -{/* GENERATED FILE. Generated from router-schemas/byteplus/seedance-1-0-lite-t2v-250428.json by `pnpm code-pages:gen`. */} - -import RouterCodeFooter from "/snippets/zh/comfy-router/model-code-footer.mdx"; - -`byteplus/seedance-1-0-lite-t2v-250428` 的 API 参考,由 Comfy Router 从 BytePlus 提供。 - -## 快速开始 - -在[你的 Comfy 工作区](https://platform.comfy.org/profile/api-keys)中创建一个密钥,并将其导出为 `COMFY_API_KEY`。Python 和 TypeScript 代码片段使用 Comfy SDK(`pip install comfy-sdk`、`npm install @comfyorg/sdk`);cURL 代码片段则是通过原始 HTTP 发起的同一调用。 - -**模型 ID:** `byteplus/seedance-1-0-lite-t2v-250428` - -**端点:** `POST https://api.comfy.org/v2/models/byteplus/seedance-1-0-lite-t2v-250428` - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# The SDK automatically creates an idempotency key and reuses it for automatic retries. -with Comfy() as client: - result = client.models.run( - "byteplus/seedance-1-0-lite-t2v-250428", - { - "content": [ - { - "text": "A red fox trotting through a snowy pine forest", - "type": "text", - }, - ], - "duration": 5, - "ratio": "16:9", - "resolution": "720p", - }, - ) - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// The SDK automatically creates an idempotency key and reuses it for automatic retries. -const { data } = await comfy.models.run("byteplus/seedance-1-0-lite-t2v-250428", { - content: [ - { - text: "A red fox trotting through a snowy pine forest", - type: "text", - }, - ], - duration: 5, - ratio: "16:9", - resolution: "720p", -}); - -console.log(data); -``` - -```bash cURL -curl https://api.comfy.org/v2/models/byteplus/seedance-1-0-lite-t2v-250428 \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"content\": [{\"text\":\"A red fox trotting through a snowy pine forest\",\"type\":\"text\"}], \"duration\": 5, \"ratio\": \"16:9\", \"resolution\": \"720p\"}" -``` - - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -with Comfy() as client: - handle = client.models.submit( - "byteplus/seedance-1-0-lite-t2v-250428", - { - "content": [ - { - "text": "A red fox trotting through a snowy pine forest", - "type": "text", - }, - ], - "duration": 5, - "ratio": "16:9", - "resolution": "720p", - }, - ) - print("request_id:", handle.request_id) # with the model ID, all another process needs - - # Poll until the request completes, waiting the Retry-After the server names. - for update in handle.iter_events(): - print(update.status, update.queue_position) - - # The provider's own payload, the same value models.run() returns. - # A request that failed or was cancelled raises the typed Router error here. - result = handle.get() - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -const handle = await comfy.models.submit("byteplus/seedance-1-0-lite-t2v-250428", { - content: [ - { - text: "A red fox trotting through a snowy pine forest", - type: "text", - }, - ], - duration: 5, - ratio: "16:9", - resolution: "720p", -}); -console.log("requestId:", handle.requestId); // with the model ID, all another process needs - -// Poll until the request completes, waiting the Retry-After the server names. -for await (const update of handle.events()) { - console.log(update.status, update.queuePosition); -} - -// The same result models.run() returns. A request that failed or was cancelled rejects here. -const result = await handle.get(); - -console.log(result.data); -``` - -```bash cURL -# 1. Submit. Router answers 201 with request_id, status_url, response_url and cancel_url. -curl https://api.comfy.org/v2/models/byteplus/seedance-1-0-lite-t2v-250428/requests \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"content\": [{\"text\":\"A red fox trotting through a snowy pine forest\",\"type\":\"text\"}], \"duration\": 5, \"ratio\": \"16:9\", \"resolution\": \"720p\"}" - -# 2. Poll until status is COMPLETED, waiting the Retry-After seconds each response names. -REQUEST_ID="" -curl -i https://api.comfy.org/v2/models/byteplus/seedance-1-0-lite-t2v-250428/requests/$REQUEST_ID/status \ - -H "X-API-Key: $COMFY_API_KEY" - -# 3. Collect. 200 with the model's native output, 202 with the status body while it is still running. -curl https://api.comfy.org/v2/models/byteplus/seedance-1-0-lite-t2v-250428/requests/$REQUEST_ID \ - -H "X-API-Key: $COMFY_API_KEY" -``` - - - - - -## Schema - -### 输入 - - - 本次生成任务结果的回调通知地址 - - 格式:`uri` - - - - 供模型生成视频的输入内容 - - - - 输入音频对象。仅 Seedance 2.5、2.0 和 2.0 fast 支持音频输入。Seedance 2.0 和 2.0 fast 不能单独使用音频,必须至少包含 1 个图像或视频;Seedance 2.5 支持仅音频输入。 - - - - 音频 URL、Base64 编码或 Asset ID。 -音频 URL:音频的公开 URL(wav、mp3)。 -Base64:格式为 data:audio/\;base64,\ -Asset ID:格式为 asset://\ - - - - - - - - 用于图生视频生成的图像内容(当 type 为 "image_url" 时) -图像 URL:请确保该图像 URL 可访问。 -Base64 编码内容:格式必须为 data:image/\;base64,\ -Asset ID:格式为 asset://\ - - - - 内容项的角色/位置。 -对于图像:first_frame、last_frame 或 reference_image。 -对于视频:reference_video(仅 Seedance 2.5、2.0 和 2.0 fast)。 -对于音频:reference_audio(仅 Seedance 2.5、2.0 和 2.0 fast)。 - - 可选值:`first_frame`, `last_frame`, `reference_image`, `reference_video`, `reference_audio` - - - - 模型的输入文本信息。包含文本提示词和可选参数。 - -文本提示词(必填):使用中英文字符描述要生成的视频。 - -参数(可选):在文本提示词后添加 --[parameters] 以控制视频规格: -- --resolution (--rs):480p、720p、1080p(默认:720p) -- --ratio (--rt):21:9、16:9、4:3、1:1、3:4、9:16、9:21、adaptive(默认:16:9 或 adaptive) -- --duration (--dur):3-12 秒(默认:5) -- --framepersecond (--fps):24(默认:24) -- --watermark (--wm):true/false(默认:false) -- --seed (--seed):-1 到 2^32-1(默认:-1) -- --camerafixed (--cf):true/false(默认:false) - -示例:"A beautiful landscape --ratio 16:9 --resolution 720p --duration 5" - - - - 输入内容的类型 - - 可选值:`text`, `image_url`, `video_url`, `audio_url` - - - - 输入视频对象。仅 Seedance 2.5、2.0 和 2.0 fast 支持视频输入。 - - - - 视频 URL 或 Asset ID。 -视频 URL:视频的公开 URL(mp4、mov)。 -Asset ID:格式为 asset://\ - - - - 视频时长(秒)。Seedance 2.5:[4,30] 或 -1(自动;视频编辑任务仅支持 -1)。Seedance 2.0 和 2.0 fast:[4,15] 或 -1(自动)。Seedance 1.5 pro:[4,12] 或 -1。Seedance 1.0:[2,12]。 - - 范围:`2` 到 `30` - - - - 任务超时阈值(秒)。默认 172800(48 小时)。范围:[3600, 259200]。 - - 范围:`3600` 到 `259200` - - - - Seedance 2.5、2.0、2.0 fast 和 1.5 pro 支持。生成的视频是否包含与画面同步的音频。 -true:模型输出带同步音频的视频。 -false:模型输出无声视频。 - - - - 要调用的模型 ID。支持的模型:seedance-1-5-pro-251215、seedance-1-0-pro-250528、seedance-1-0-pro-fast-251015、seedance-1-0-lite-t2v-250428、seedance-1-0-lite-i2v-250428、dreamina-seedance-2-0-260128、dreamina-seedance-2-0-fast-260128、dreamina-seedance-2-0-mini 和 dreamina-seedance-2-5-260628。直接以 v1 调用 POST /proxy/byteplus/api/v3/contents/generations/tasks 时必须提供它,代理会拒绝任何其他值;若省略它,则返回 400。它不在本 Schema 的 `required` 列表中,因为 Comfy Router 会从 /v2/models/byteplus/\{model} 的 `{model}` 路径段填充它,因此 Router 调用方会省略它。 - - - - 仅 Seedance 2.5。输出视频的容器格式。 -mp4:通用容器(H.264/AAC,yuv420p),兼容性广,文件大小更小。 -mov:专业容器(H.264 High 4:4:4 Predictive/PCM,yuv444p),颜色精度高,适合后期制作;文件大小更大。 - - 可选值:`mp4`, `mov` - - - - 生成的视频宽高比。Seedance 2.0 和 2.0 fast、1.5 pro 默认:adaptive。 - - 可选值:`16:9`, `4:3`, `1:1`, `3:4`, `9:16`, `21:9`, `9:21`, `adaptive` - - - - 视频分辨率。Seedance 2.5、2.0 和 2.0 fast、1.5 pro、1.0 lite 默认:720p。Seedance 1.0 pro 和 pro-fast 默认:1080p。 -注意:Seedance 2.0 和 2.0 fast 不支持 1080p。Seedance 2.5 支持 480p、720p 和 1080p。 - - 可选值:`480p`, `720p`, `1080p`, `4k` - - - - 是否返回已生成视频的最后一帧图像。是:返回已生成视频的最后一帧图像。将此参数设置为是后,可通过调用"查询视频生成任务信息"获取最后一帧图像。该最后一帧图像为 PNG 格式,其像素宽度和高度与已生成视频一致,且不含水印。使用此参数可以生成多个连续视频:将前一个已生成视频的最后一帧作为下一个视频任务的第一帧,从而快速生成多个连续视频。 -否:不返回已生成视频的最后一帧图像。 - - - - 用于控制随机性的种子整数。范围:[-1, 2^32-1]。-1 表示使用随机种子。 - - 范围:`-1` 到 `4294967295` - - - - 用于处理的服务层级。Seedance 2.5、2.0 和 2.0 fast 不支持 flex(离线推理)。 - - 可选值:`default`、`flex` - - - - 已生成视频是否包含水印。 - - -由 Router 在 `GET /v2/models/byteplus/seedance-1-0-lite-t2v-250428/openapi.json` 提供的 schema 生成,与请求到达提供商之前用于校验调用的文档相同。 -### 输出 - - - 视频生成任务完成后得到的输出,其中包含输出视频的下载 URL,并且在 BytePlus 返回时,还包含其最后一帧的下载 URL。`video_url` 和 `last_frame_url` 都会被重新托管到 Comfy 存储上;这里的其他每个字段都来自 BytePlus 本身。可为 null:BytePlus 会在任务结束 24 小时后清除这些 URL,之后轮询一个已成功的文档时,`content` 可能缺失或为 null。 - - - - 已生成视频最后一帧的下载 URL,仅当请求设置了 `return_last_frame` 时返回。不要根据这个 URL 推断图像格式:BytePlus 在请求侧将最后一帧记为 PNG,Router 会重新托管它实际拿到的任何字节,并根据上游的 Content-Type 或内容嗅探来确定其类型,而 `image/jpeg` 只是两者都失败时的最后兜底。Router 会把最后一帧重新托管到 Comfy 存储上并改写此字段,因此它通常是一个有效期最长 24 小时的 Comfy 签名 URL:生成时签名 24 小时,并从 23 小时的备忘中重放,所以之后的轮询可能返回一个只剩一小时有效期的链接。当无法执行重新托管时,该字段会保留 BytePlus 自己的 URL,BytePlus 会在任务结束 24 小时后清除它。无论哪种情况链接都会过期,因此请下载该帧,而不要保存 URL。 - - - - 已生成视频的容器格式(mp4 或 mov),当 BytePlus 将其嵌套在 `content` 内时返回。Seedance 模型更常把它作为 `content` 的顶层同级字段返回,参见顶层的 `output_format` 字段。Router 会读取两者中存在的那个。 - - - - 输出视频的下载 URL。Router 会把视频重新托管到 Comfy 存储上并改写此字段,因此它通常是一个有效期最长 24 小时的 Comfy 签名 URL:生成时签名 24 小时,并从 23 小时的备忘中重放,所以之后的轮询可能返回一个只剩一小时有效期的链接。当无法执行重新托管时,该字段会保留 BytePlus 自己的 URL,BytePlus 会在任务结束 24 小时后清除它,并在某些模型上限制为 100 次下载。无论哪种情况链接都会过期,因此请下载视频,而不要保存 URL。 - - - - 任务创建的时间。该值为 UNIX 时间戳,单位为秒。 - - - - 已生成视频的时长,单位为秒。之所以声明为 number 而不是整数,是因为 BytePlus 在这点上并不一致:视频任务曾被观察到返回整秒,而 BytePlus 相邻的其他接口会报告小数时长,因此客户端不能假定它是整数值。这是 BytePlus 自己的字段,在成功的视频任务中返回并原样转发。 - - - - 错误信息。如果任务成功,返回 null。如果任务失败,则返回错误信息。 - - - - 错误码 - - - - 报错信息 - - - - 视频生成任务的 ID - - - - 任务所用模型的名称和版本 - - - - 已生成视频的容器格式(mp4 或 mov),作为 `content` 的同级字段在顶层返回:Seedance 视频任务查询正是在这里返回它。这是 BytePlus 自己的字段,原样转发。 - - - - 已生成视频的分辨率,例如 `1080p`。这是 BytePlus 自己的字段,在成功的视频任务中返回并原样转发。 - - - - 该任务实际使用的生成种子。这是 BytePlus 自己的字段,在成功的视频任务中返回并原样转发。 - - 格式:`int64` - - - - 任务状态 - - 可能的值:`queued`、`running`、`cancelled`、`succeeded`、`failed`、`expired` - - - - 任务最后更新的时间。该值为 UNIX 时间戳,单位为秒。 - - - - 本次请求的 token 用量 - - - - 模型生成的 token 数量 - - - - 对于视频生成模型,不计算输入 token 数量,默认为 0。因此 total_tokens = completion_tokens。 - - -## 示例 - -### 输入 - -```json -{ - "content": [ - { - "text": "A red fox trotting through a snowy pine forest", - "type": "text" - } - ], - "duration": 5, - "ratio": "16:9", - "resolution": "720p" -} -``` - -### 输出 - -```json -{ - "content": { - "last_frame_url": "https://example.invalid/byteplus/seedance-1-0-lite-t2v-250428/last-frame", - "video_url": "https://example.invalid/byteplus/seedance-1-0-lite-t2v-250428/generated.mp4" - }, - "created_at": 1767225600, - "duration": 5, - "error": null, - "id": "3f7a1b28-5c0d-4e91-8a6f-1b2c3d4e5f60", - "model": "seedance-1-0-lite-t2v-250428", - "output_format": "mp4", - "resolution": "1080p", - "seed": 1234567890123, - "status": "succeeded", - "updated_at": 1767225730 -} -``` - - - diff --git a/zh/development/comfy-router/models/byteplus/seededit-3-0-i2i-250628/code.mdx b/zh/development/comfy-router/models/byteplus/seededit-3-0-i2i-250628/code.mdx deleted file mode 100644 index a393ac6b57..0000000000 --- a/zh/development/comfy-router/models/byteplus/seededit-3-0-i2i-250628/code.mdx +++ /dev/null @@ -1,391 +0,0 @@ ---- -title: "将 Seededit 3.0 I2I 250628 与 Comfy Router 配合使用" -description: "通过 Comfy Router 调用 byteplus/seededit-3-0-i2i-250628:端点、请求结构以及 Router 返回的响应。" -sidebarTitle: "Seededit 3.0 I2I 250628" -translationSourceHash: cfe4b48a -translationFrom: development/comfy-router/models/byteplus/seededit-3-0-i2i-250628/code.mdx -translationBlockHashes: - "_intro": b2e7faed - "Quick start": 0aef594c - "Schema": fe63d102 - "Examples": 130ffbde ---- -{/* 已生成的文件。由 `pnpm code-pages:gen` 从 router-schemas/byteplus/seededit-3-0-i2i-250628.json 生成。 */} - -import RouterCodeFooter from "/snippets/zh/comfy-router/model-code-footer.mdx"; - -`byteplus/seededit-3-0-i2i-250628` 的 API 参考文档,由 Comfy Router 提供,模型来自 BytePlus。 - -## 快速开始 - -在[你的 Comfy 工作区](https://platform.comfy.org/profile/api-keys)中创建一个密钥,并将其导出为 `COMFY_API_KEY`。Python 和 TypeScript 代码片段使用 Comfy SDK(`pip install comfy-sdk`、`npm install @comfyorg/sdk`);cURL 代码片段则是通过原始 HTTP 执行的同一调用。 - -**模型 ID:** `byteplus/seededit-3-0-i2i-250628` - -**端点:** `POST https://api.comfy.org/v2/models/byteplus/seededit-3-0-i2i-250628` - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# The SDK automatically creates an idempotency key and reuses it for automatic retries. -with Comfy() as client: - result = client.models.run( - "byteplus/seededit-3-0-i2i-250628", - { - "prompt": "A red fox trotting through a snowy pine forest, cinematic lighting", - "response_format": "url", - "watermark": False, - }, - ) - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// The SDK automatically creates an idempotency key and reuses it for automatic retries. -const { data } = await comfy.models.run("byteplus/seededit-3-0-i2i-250628", { - prompt: "A red fox trotting through a snowy pine forest, cinematic lighting", - response_format: "url", - watermark: false, -}); - -console.log(data); -``` - -```bash cURL -curl https://api.comfy.org/v2/models/byteplus/seededit-3-0-i2i-250628 \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"prompt\": \"A red fox trotting through a snowy pine forest, cinematic lighting\", \"response_format\": \"url\", \"watermark\": false}" -``` - - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -with Comfy() as client: - handle = client.models.submit( - "byteplus/seededit-3-0-i2i-250628", - { - "prompt": "A red fox trotting through a snowy pine forest, cinematic lighting", - "response_format": "url", - "watermark": False, - }, - ) - print("request_id:", handle.request_id) # with the model ID, all another process needs - - # Poll until the request completes, waiting the Retry-After the server names. - for update in handle.iter_events(): - print(update.status, update.queue_position) - - # The provider's own payload, the same value models.run() returns. - # A request that failed or was cancelled raises the typed Router error here. - result = handle.get() - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -const handle = await comfy.models.submit("byteplus/seededit-3-0-i2i-250628", { - prompt: "A red fox trotting through a snowy pine forest, cinematic lighting", - response_format: "url", - watermark: false, -}); -console.log("requestId:", handle.requestId); // with the model ID, all another process needs - -// Poll until the request completes, waiting the Retry-After the server names. -for await (const update of handle.events()) { - console.log(update.status, update.queuePosition); -} - -// The same result models.run() returns. A request that failed or was cancelled rejects here. -const result = await handle.get(); - -console.log(result.data); -``` - -```bash cURL -# 1. Submit. Router answers 201 with request_id, status_url, response_url and cancel_url. -curl https://api.comfy.org/v2/models/byteplus/seededit-3-0-i2i-250628/requests \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"prompt\": \"A red fox trotting through a snowy pine forest, cinematic lighting\", \"response_format\": \"url\", \"watermark\": false}" - -# 2. Poll until status is COMPLETED, waiting the Retry-After seconds each response names. -REQUEST_ID="" -curl -i https://api.comfy.org/v2/models/byteplus/seededit-3-0-i2i-250628/requests/$REQUEST_ID/status \ - -H "X-API-Key: $COMFY_API_KEY" - -# 3. Collect. 200 with the model's native output, 202 with the status body while it is still running. -curl https://api.comfy.org/v2/models/byteplus/seededit-3-0-i2i-250628/requests/$REQUEST_ID \ - -H "X-API-Key: $COMFY_API_KEY" -``` - - - - - -## 架构 - -### 输入 - - - 控制输出图像与输入提示词的契合程度。范围 [1, 10]。值越高,对提示词的遵循度越强。seedream-3-0-t2i-250415 的默认值为 2.5,seededit-3-0-i2i-250628 的默认值为 5.5。seedream-5.0-pro、5.0-lite、4.5 和 4.0 不支持该参数。 - - Range: `1` to `10` - - Format: `float` - - - - seedream-5.0-pro、5.0-lite、4.5 和 4.0,以及 seededit-3.0-i2i 支持此参数。 - -输入待编辑图像的 Base64 编码或可访问的网址。seedream-5.0-pro、5.0-lite、4.5 和 4.0 支持输入单张图像或多张图像(参见多图融合示例),而 seededit-3.0-i2i 仅支持单张图像输入。 - -• 图片网址:请确保图片网址可访问。 -• Base64 编码:格式必须为 data:image/\<图像格式>;base64,\。注意:\<图像格式> 必须为小写,例如 data:image/png;base64,\。 - -Comfy Router 将整个 JSON 请求限制为 10 MiB,其中包括 base64 膨胀后的数据以及所有参考图像。对于会超出该传输限制的输入,请使用网址。 - -输入图像必须满足以下要求: -• 图像格式:jpeg、png(seedream-5.0-pro、5.0-lite、4.5 和 4.0 还支持 webp、bmp、tiff 和 gif;seedream-5.0-pro 还支持 heic 和 heif) -• 宽高比(宽度/高度):seedream-5.0-pro、5.0-lite、4.5 和 4.0 在 [1/16, 16] 范围内;seededit-3.0-i2i 在 [1/3, 3] 范围内 -• 宽度和高度(px):> 14 -• 大小:不超过 10 MB(seedream-5.0-pro 为 30 MB) -• 总像素:seedream-5.0-pro 不超过 6000x6000(36,000,000 px) -• 最多 14 张参考图像(seedream-5.0-pro 为 10 张) - -在图层分离场景中(启用 layer_decomposition),image 为必填项,且仅支持单张输入图像(传入多张图像会返回错误)。输入图像必须为 png、jpeg、webp、bmp、tiff 或 gif(不支持 heic 和 heif),大小不超过 30 MB,总像素在 [512x512, 6000x6000] 范围内,宽高比在 [1/16, 16] 范围内。 - - - - 控制是否启用图层分离。仅 seedream-5.0-pro 支持该参数。 -true:图层分离模式。模型将单张输入图像分解为一张基础图像加多个图层(最多 16 个),并返回每个生成图层的位置和内容信息,包括堆叠顺序(z_index)、边界框(bounding_box)、名称(name)和描述(description)。 -false:标准图像生成模式,不执行图层分离。 -关于图层分离模式的说明:仅支持单张输入图像(传入多张图像会返回错误);如果任一图层生成失败,整个请求都会失败,不支持部分成功;最多返回 17 张图像(1 张基础图像 + 16 个图层)。传入 sequential_image_generation、sequential_image_generation_options、tools 和 stream 会返回错误。 - - - - 模型标识符。支持的模型:seedream-3-0-t2i-250415、seededit-3-0-i2i-250628、seedream-4-0-250828、seedream-4-5-251128、seedream-5-0-260128 和 seedream-5-0-pro-260628。直接以 v1 调用 POST /proxy/byteplus/api/v3/images/generations 时必须提供该参数,代理会拒绝任何其他值,若省略则返回 400。它不在本 schema 的 `required` 列表中,因为 Comfy Router 会从 /v2/models/byteplus/\{model} 的 `{model}` 路径段中填充它,因此 Router 调用方会省略它。 - - - - 提示词优化功能的配置。仅 seedream-5.0-pro/5.0-lite/4.5(仅支持 standard 模式)和 seedream-4.0 支持该参数。 - - - - 设置提示词优化功能的模式。standard = 质量更高,生成时间更长。fast = 速度更快,但质量较为一般。 - - Possible values: `standard`, `fast` - - - - 指定输出图像的格式。仅 seedream-5.0-pro 和 5.0-lite 支持该参数。在图层分离场景中,output_format 仅控制基础图像的格式;每个图层始终以 png 格式输出。 - - Possible values: `png`, `jpeg` - - - - 用于图像生成或变换的文本描述。 -在图层分离场景中为可选项(seedream-5.0-pro 且启用 layer_decomposition):如果提供了提示词,模型会根据提示词意图识别并分离你指定的元素;如果未提供提示词,模型会自动检测图像中的所有主要元素,并将其分离为独立的图层。 - - - - 指定响应中返回的生成图像的格式 - - Possible values: `url`, `b64_json` - - - - 用于控制图像生成随机性的随机种子。范围:[-1, 2147483647]。如果未指定,将自动生成一个种子。要复现相同的输出,请使用相同的种子值。 - - Range: `-1` to `2147483647` - - - - 控制是否禁用批处理生成功能。该参数仅在 seedream-5.0-lite、4.5 和 4.0 上受支持(seedream-5.0-pro 不支持)。有效值: -auto:在自动模式下,模型会根据用户提示词自动判断是否返回多张图像,以及将包含多少张图像。 -disabled:禁用批处理生成功能。模型将只生成一张图像。 - - Possible values: `auto`, `disabled` - - - - 仅 seedream-5.0-lite、4.5 和 4.0 支持此参数(seedream-5.0-pro 不支持)。 -批处理图像生成功能的配置。仅当 sequential_image_generation 设置为 auto 时,此参数才生效。 - - - - 指定本次请求中生成图像的最大数量。输入参考图像数量 + 生成图像数量 ≤ 15。 - - 范围:`1` 到 `15` - - - - "seedream-3-0-t2i-250415":指定生成图像的尺寸(宽 x 高,单位为像素)。必须介于 [512x512, 2048x2048] 之间 -"seededit-3-0-i2i-250628":生成图像的宽度和高度像素值。目前仅支持 adaptive。 -"seedream-4-0-250828":设置生成图像的规格。有两种方法,但不能同时使用。 - 方法 1 | 指定分辨率。可选值:1K、2K、4K - 方法 2 | 指定宽度和高度像素值。默认:2048x2048,总像素:[1024x1024, 4096x4096],宽高比:[1/16, 16] -"seedream-4-5-251128":有两种可用方法。 - 方法 1 | 指定分辨率。可选值:2K、4K - 方法 2 | 指定宽度和高度像素值。默认:2048x2048,总像素:[2560x1440, 4096x4096],宽高比:[1/16, 16] -"seedream-5-0-260128":有两种可用方法。 - 方法 1 | 指定分辨率。可选值:2K、3K - 方法 2 | 指定宽度和高度像素值。默认:2048x2048,总像素:[2560x1440, ~3072x3072],宽高比:[1/16, 16] -"seedream-5-0-pro-260628":有两种可用方法(不能同时使用)。 - 方法 1 | 指定分辨率,并在提示词中描述图像的宽高比、形状或用途;最终尺寸由模型决定。可选值:1K、2K - 方法 2 | 指定宽度和高度像素值。默认:1024x1024,总像素:[1024x1024 (1048576), 2048x2048 (4194304)],宽高比:[1/16, 16] -启用 layer_decomposition 的 "seedream-5-0-pro-260628":仅支持分辨率级别的方法。可选值:1K、1.5K、2K、auto。默认:auto。 - 基础图像按指定分辨率输出,并保留原始输入图像的宽高比;每个图层按接近指定分辨率输出,并保留其在原始图像中的宽高比。 - auto:根据输入图像的尺寸和宽高比输出。介于 [1280x720, ~2048x2048] 之间的输入按原始输入尺寸输出;小于 1K 的输入按 1K 输出;大于 2K 的输入按 2K 输出。 - - - - Comfy Router 会将显式提供的 stream 标记设为 false,因为它会捕获完整的 JSON 结果。在 v1 代理上,此字段控制是否启用流式输出模式。仅 seedream-5.0-lite、4.5 和 4.0 支持此参数(seedream-5.0-pro 不支持)。false = 所有输出图像一次性返回。true = 每张输出图像生成后立即返回。 - - - - 指定是否为生成图像添加水印。false = 不添加水印,true = 添加带有 "AI generated" 标签的水印 - - -由 Router 在 `GET /v2/models/byteplus/seededit-3-0-i2i-250628/openapi.json` 提供的 schema 生成,该文档与请求到达提供商之前用于校验调用的文档相同。 -### 输出 - - - Unix 时间戳(以秒为单位),表示请求的创建时间 - - - - 包含所生成图像的信息。 -在图层分离场景中,数组的第一个元素是基础图像(z_index=0),后续元素是各图层,按 z_index 递增排序。 - - - - Base64 编码的图像数据(当 response_format 为 "b64_json" 时) - - - - 当前图层在基础图像中所占区域的边界框信息。仅图层会返回该字段;基础图像覆盖整个画布,不返回 bounding_box。仅当 layer_decomposition 为 true 时返回。 - - - - 图层边界框的绝对像素坐标,以输出基础图像的坐标系为准,左上角为 (0, 0)。坐标格式:[left, top, right, bottom]。 - - - - 图层边界框的千分位量化(归一化)坐标,根据基础图像尺寸按比例映射到 [0, 1000] 的离散整数范围,最大截断为 1000。坐标格式:[left, top, right, bottom]。 - - - - 当前分离元素的详细描述,相比 name 提供更丰富的图层特征(如颜色、状态、材质)。仅图层会返回该字段;基础图像不返回。仅当 layer_decomposition 为 true 时返回。 - - - - 当前分离元素的名称/标签,由模型根据分离主体的特征自动生成。仅图层会返回该字段;基础图像不返回。仅当 layer_decomposition 为 true 时返回。 - - - - 输出图像的文件格式。仅 seedream-5.0-pro 支持该字段。 - - - - 图像的宽度和高度(以像素为单位),格式为 \x\。仅 seedream-5.0-pro、5.0-lite、4.5 和 4.0 支持该参数。 - - - - 用于下载图像的 URL(当 response_format 为 "url" 时) - - Format: `uri` - - - - 图层的堆叠顺序,从下到上递增:0 是最底层的图层(基础图像);数值越大位置越高。可使用它按正确的堆叠顺序将各图层重新合成为完整图像。仅当 layer_decomposition 为 true 时返回。 - - - - 错误信息(如有) - - - - 错误码 - - - - 报错信息 - - - - 请求所使用的模型 ID - - - - - - - - 模型生成的图像数量 - - - - 输入到模型的图像数量。仅 seedream-5.0-pro 支持该字段。 - - - - 模型生成图片所使用的 token 数量。 - - - - 本次请求消耗的 token 总数。 - - -## 示例 - -### 输入 - -```json -{ - "prompt": "A red fox trotting through a snowy pine forest, cinematic lighting", - "response_format": "url", - "watermark": false -} -``` - -### 输出 - -```json -{ - "created": 1767225600, - "data": [ - { - "size": "1024x1024", - "url": "https://example.invalid/byteplus/seedream-3-0-t2i-250415/generated.png" - } - ], - "model": "seededit-3-0-i2i-250628", - "usage": { - "generated_images": 1 - } -} -``` - - - diff --git a/zh/development/comfy-router/models/byteplus/seedream-3-0-t2i-250415/code.mdx b/zh/development/comfy-router/models/byteplus/seedream-3-0-t2i-250415/code.mdx deleted file mode 100644 index de9a45fa03..0000000000 --- a/zh/development/comfy-router/models/byteplus/seedream-3-0-t2i-250415/code.mdx +++ /dev/null @@ -1,388 +0,0 @@ ---- -title: "在 Comfy Router 中使用 Seedream 3.0 T2I 250415" -description: "通过 Comfy Router 调用 byteplus/seedream-3-0-t2i-250415:endpoint、请求形状以及 Router 返回的响应。" -sidebarTitle: "Seedream 3.0 T2I 250415" -translationSourceHash: 18f23e78 -translationFrom: development/comfy-router/models/byteplus/seedream-3-0-t2i-250415/code.mdx -translationBlockHashes: - "_intro": dafe6167 - "Quick start": 16428856 - "Schema": c6abe2a5 - "Examples": 61ceb30b ---- -{/* GENERATED FILE. Generated from router-schemas/byteplus/seedream-3-0-t2i-250415.json by `pnpm code-pages:gen`. */} - -import RouterCodeFooter from "/snippets/zh/comfy-router/model-code-footer.mdx"; - -`byteplus/seedream-3-0-t2i-250415` 的 API 参考文档,由 Comfy Router 从 BytePlus 提供。 - -## 快速开始 - -在 [你的 Comfy 工作区](https://platform.comfy.org/profile/api-keys) 中创建密钥,并将其导出为 `COMFY_API_KEY`。Python 和 TypeScript 代码片段使用 Comfy SDK(`pip install comfy-sdk`、`npm install @comfyorg/sdk`);cURL 代码片段是通过原始 HTTP 执行的同一调用。 - -**模型 ID:** `byteplus/seedream-3-0-t2i-250415` - -**端点:** `POST https://api.comfy.org/v2/models/byteplus/seedream-3-0-t2i-250415` - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# The SDK automatically creates an idempotency key and reuses it for automatic retries. -with Comfy() as client: - result = client.models.run( - "byteplus/seedream-3-0-t2i-250415", - { - "prompt": "A red fox trotting through a snowy pine forest, cinematic lighting", - "response_format": "url", - "watermark": False, - }, - ) - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// The SDK automatically creates an idempotency key and reuses it for automatic retries. -const { data } = await comfy.models.run("byteplus/seedream-3-0-t2i-250415", { - prompt: "A red fox trotting through a snowy pine forest, cinematic lighting", - response_format: "url", - watermark: false, -}); - -console.log(data); -``` - -```bash cURL -curl https://api.comfy.org/v2/models/byteplus/seedream-3-0-t2i-250415 \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"prompt\": \"A red fox trotting through a snowy pine forest, cinematic lighting\", \"response_format\": \"url\", \"watermark\": false}" -``` - - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -with Comfy() as client: - handle = client.models.submit( - "byteplus/seedream-3-0-t2i-250415", - { - "prompt": "A red fox trotting through a snowy pine forest, cinematic lighting", - "response_format": "url", - "watermark": False, - }, - ) - print("request_id:", handle.request_id) # with the model ID, all another process needs - - # Poll until the request completes, waiting the Retry-After the server names. - for update in handle.iter_events(): - print(update.status, update.queue_position) - - # The provider's own payload, the same value models.run() returns. - # A request that failed or was cancelled raises the typed Router error here. - result = handle.get() - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -const handle = await comfy.models.submit("byteplus/seedream-3-0-t2i-250415", { - prompt: "A red fox trotting through a snowy pine forest, cinematic lighting", - response_format: "url", - watermark: false, -}); -console.log("requestId:", handle.requestId); // with the model ID, all another process needs - -// Poll until the request completes, waiting the Retry-After the server names. -for await (const update of handle.events()) { - console.log(update.status, update.queuePosition); -} - -// The same result models.run() returns. A request that failed or was cancelled rejects here. -const result = await handle.get(); - -console.log(result.data); -``` - -```bash cURL -# 1. Submit. Router answers 201 with request_id, status_url, response_url and cancel_url. -curl https://api.comfy.org/v2/models/byteplus/seedream-3-0-t2i-250415/requests \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"prompt\": \"A red fox trotting through a snowy pine forest, cinematic lighting\", \"response_format\": \"url\", \"watermark\": false}" - -# 2. Poll until status is COMPLETED, waiting the Retry-After seconds each response names. -REQUEST_ID="" -curl -i https://api.comfy.org/v2/models/byteplus/seedream-3-0-t2i-250415/requests/$REQUEST_ID/status \ - -H "X-API-Key: $COMFY_API_KEY" - -# 3. Collect. 200 with the model's native output, 202 with the status body while it is still running. -curl https://api.comfy.org/v2/models/byteplus/seedream-3-0-t2i-250415/requests/$REQUEST_ID \ - -H "X-API-Key: $COMFY_API_KEY" -``` - - - - - -## Schema - -### 输入 - - - 控制输出图像与输入提示词的贴合程度。取值范围 [1, 10]。值越高,提示词遵循度越强。seedream-3-0-t2i-250415 默认值为 2.5,seededit-3-0-i2i-250628 默认值为 5.5。seedream-5.0-pro、5.0-lite、4.5 和 4.0 不支持该参数。 - - 取值范围:`1` 到 `10` - - 格式:`float` - - - - Seedream-5.0-pro、5.0-lite、4.5 和 4.0,以及 seededit-3.0-i2i 支持该参数。 - -输入要编辑图像的 Base64 编码或可访问的 URL。Seedream-5.0-pro、5.0-lite、4.5 和 4.0 支持输入单张图像或多张图像(参见多图融合示例),而 seededit-3.0-i2i 仅支持单张图像输入。 - -• 图片网址:请确保图片网址可访问。 -• Base64 编码:格式必须为 data:image/\;base64,\。注意:\ 必须为小写,例如 data:image/png;base64,\。 - -Comfy Router 将整个 JSON 请求限制为 10 MiB,包括 base64 编码膨胀和所有参考图像。对于会超出此传输限制的输入,请使用 URL。 - -输入图像必须满足以下要求: -• 图像格式:jpeg、png(seedream-5.0-pro、5.0-lite、4.5 和 4.0 还支持 webp、bmp、tiff 和 gif;seedream-5.0-pro 还支持 heic 和 heif) -• 宽高比(宽度/高度):seedream-5.0-pro、5.0-lite、4.5 和 4.0 需在 [1/16, 16] 范围内;seededit-3.0-i2i 需在 [1/3, 3] 范围内 -• 宽度和高度(px):> 14 -• 大小:不超过 10 MB(seedream-5.0-pro 为 30 MB) -• 总像素:seedream-5.0-pro 不超过 6000x6000(36,000,000 px) -• 最多 14 张参考图像(seedream-5.0-pro 为 10 张) - -在图层分离场景中(启用 layer_decomposition),image 为必填项,且仅支持单张输入图像(传入多张图像会返回错误)。输入图像必须为 png、jpeg、webp、bmp、tiff 或 gif(不支持 heic 和 heif),大小不超过 30 MB,总像素在 [512x512, 6000x6000] 范围内,宽高比在 [1/16, 16] 范围内。 - - - - 控制是否启用图层分离。仅 seedream-5.0-pro 支持该参数。 -是:图层分离模式。模型将单张输入图像分解为一张基础图像加多个图层(最多 16 个),并返回每个生成图层的位置和内容信息,包括堆叠顺序(z_index)、边界框(bounding_box)、名称(name)和描述(description)。 -否:标准图像生成模式;不执行图层分离。 -图层分离模式注意事项:仅支持单张输入图像(传入多张图像会返回错误);如果任一单个图层生成失败,整个请求即失败,不支持部分成功;最多返回 17 张图像(1 张基础图像 + 16 个图层)。若传入 sequential_image_generation、sequential_image_generation_options、tools 和 stream 会返回错误。 - - - - 模型标识符。支持的模型:seedream-3-0-t2i-250415、seededit-3-0-i2i-250628、seedream-4-0-250828、seedream-4-5-251128、seedream-5-0-260128 和 seedream-5-0-pro-260628。直接通过 v1 调用 POST /proxy/byteplus/api/v3/images/generations 时必须提供该参数,代理会拒绝任何其他值,若省略则返回 400。它不在本 schema 的 `required` 列表中,因为 Comfy Router 会从 /v2/models/byteplus/\{model} 的 `{model}` 路径段填充它,因此 Router 调用方会省略该参数。 - - - - 提示词优化功能的配置。仅 seedream-5.0-pro/5.0-lite/4.5(仅支持 standard 模式)和 seedream-4.0 支持该参数。 - - - - 设置提示词优化功能的模式。standard = 更高质量,生成时间更长。fast = 速度更快,但质量较为一般。 - - 可能的值:`standard`、`fast` - - - - 指定输出图像的格式。仅 seedream-5.0-pro 和 5.0-lite 支持该参数。在图层分离场景中,output_format 仅控制基础图像的格式;每个图层始终以 png 输出。 - - 可能的值:`png`、`jpeg` - - - - 用于图像生成或转换的文本描述。 -在图层分离场景中为可选项(seedream-5.0-pro 启用 layer_decomposition 时):如果提供了提示词,模型会根据提示词意图识别并分离你指定的元素;如果未提供提示词,模型会自动检测图像中的所有主要元素并将其分离为独立图层。 - - - - 指定响应中返回的已生成图像的格式 - - 可能的值:`url`、`b64_json` - - - - 用于控制图像生成随机性的随机种子。取值范围:[-1, 2147483647]。如果未指定,将自动生成一个种子。要复现相同的输出,请使用相同的种子值。 - - 取值范围:`-1` 到 `2147483647` - - - - 控制是否禁用批处理生成功能。该参数仅在 seedream-5.0-lite、4.5 和 4.0 上受支持(seedream-5.0-pro 不支持)。有效值: -auto:自动模式下,模型根据用户的提示词自动判断是否返回多张图像以及包含多少张图像。 -disabled:禁用批处理生成功能。模型仅生成一张图像。 - - 可能的值:`auto`、`disabled` - - 仅 seedream-5.0-lite、4.5 和 4.0 支持此参数(seedream-5.0-pro 不支持)。 -批处理图像生成功能的配置。仅当 sequential_image_generation 设置为 auto 时,此参数才生效。 - - - - 指定本次请求中生成图像的最大数量。输入参考图像数量 + 生成图像数量 ≤ 15。 - - 范围:`1` 到 `15` - - - - "seedream-3-0-t2i-250415":指定已生成图像的尺寸(宽度 x 高度,单位为像素)。必须介于 [512x512, 2048x2048] 之间 -"seededit-3-0-i2i-250628":已生成图像的宽度和高度像素值。目前仅支持自适应。 -"seedream-4-0-250828":设置已生成图像的规格。可用两种方法,但不能同时使用。 - 方法 1 | 指定分辨率。可选值:1K、2K、4K - 方法 2 | 以像素为单位指定宽度和高度。默认值:2048x2048,总像素:[1024x1024, 4096x4096],宽高比:[1/16, 16] -"seedream-4-5-251128":可用两种方法。 - 方法 1 | 指定分辨率。可选值:2K、4K - 方法 2 | 以像素为单位指定宽度和高度。默认值:2048x2048,总像素:[2560x1440, 4096x4096],宽高比:[1/16, 16] -"seedream-5-0-260128":可用两种方法。 - 方法 1 | 指定分辨率。可选值:2K、3K - 方法 2 | 以像素为单位指定宽度和高度。默认值:2048x2048,总像素:[2560x1440, ~3072x3072],宽高比:[1/16, 16] -"seedream-5-0-pro-260628":可用两种方法(不能同时使用)。 - 方法 1 | 指定分辨率,并在提示词中描述图像的宽高比、形状或用途;由模型决定最终尺寸。可选值:1K、2K - 方法 2 | 以像素为单位指定宽度和高度。默认值:1024x1024,总像素:[1024x1024 (1048576), 2048x2048 (4194304)],宽高比:[1/16, 16] -"seedream-5-0-pro-260628" 在启用 layer_decomposition 时:仅支持分辨率级别的方法。可选值:1K、1.5K、2K、auto。默认值:auto。 - 基础图像按指定分辨率输出,并采用原始输入图像的宽高比;每个图层输出的尺寸接近指定分辨率,同时保持它在原始图像中的宽高比。 - auto:根据输入图像的尺寸和宽高比进行输出。[1280x720, ~2048x2048] 范围内的输入按原始输入尺寸输出;小于 1K 的输入按 1K 输出;大于 2K 的输入按 2K 输出。 - - - - Comfy Router 会将显式提供的 stream 标志固定为 false,因为它捕获的是完整的 JSON 结果。在 v1 代理上,该字段控制是否启用流式输出模式。仅 seedream-5.0-lite、4.5 和 4.0 支持此参数(seedream-5.0-pro 不支持)。false = 所有输出图像一次性返回。true = 每张输出图像在生成后立即返回。 - - - - 指定是否为已生成图像添加水印。false = 不添加水印,true = 添加带有 "AI generated" 标签的水印 - - -由 Router 在 `GET /v2/models/byteplus/seedream-3-0-t2i-250415/openapi.json` 提供的 schema 生成,这也是请求到达提供商之前 Router 用于验证调用的同一份文档。 -### 输出 - - - Unix 时间戳(以秒为单位),表示请求的创建时间 - - - - 包含已生成图像的相关信息。 -在图层分离场景中,数组的第一个元素是基础图像(z_index=0),后续元素是各个图层,按 z_index 递增的顺序排列。 - - - - Base64 编码的图像数据(当 response_format 为 "b64_json" 时) - - - - 当前图层在基础图像中所占区域的边界框信息。仅图层会返回此字段;基础图像覆盖整个画布,不返回 bounding_box。仅在 layer_decomposition 为 true 时返回。 - - - - 该图层边界框的绝对像素坐标,以输出基础图像的坐标系为准,左上角为 (0, 0)。坐标格式:[left, top, right, bottom]。 - - - - 该图层边界框的千分位量化(归一化)坐标,根据基础图像尺寸按比例映射到 [0, 1000] 的离散整数范围,最大值截断为 1000。坐标格式:[left, top, right, bottom]。 - - - - 当前分离元素的详细描述,提供比 name 更丰富的图层特征(如颜色、状态、材质)。仅图层会返回此字段;基础图像不返回。仅在 layer_decomposition 为 true 时返回。 - - - - 当前分离元素的名称/标签,由模型根据分离主体的特征自动生成。仅图层会返回此字段;基础图像不返回。仅在 layer_decomposition 为 true 时返回。 - - - - 输出图像的文件格式。仅 seedream-5.0-pro 支持此字段。 - - - - 图像的宽度和高度(以像素为单位),格式为 \x\。仅 seedream-5.0-pro、5.0-lite、4.5 和 4.0 支持此参数。 - - - - 用于下载图像的 URL(当 response_format 为 "url" 时) - - 格式:`uri` - - - - 图层的堆叠顺序,从下到上递增:0 是最底层图层(基础图像);数值越大位置越高。可用它按正确的堆叠顺序将各图层重新合成为完整图像。仅在 layer_decomposition 为 true 时返回。 - - - - 错误信息(如有) - - - - 错误代码 - - - - 报错信息 - - - - 请求所使用的模型 ID - - - - - - - - 模型已生成的图像数量 - - - - 输入到模型的图像数量。仅 seedream-5.0-pro 支持此字段。 - - - - 模型生成图片所使用的 token 数量。 - - - - 本次请求消耗的 token 总数。 - - -## 示例 - -### 输入 - -```json -{ - "prompt": "A red fox trotting through a snowy pine forest, cinematic lighting", - "response_format": "url", - "watermark": false -} -``` - -### 输出 - -```json -{ - "created": 1767225600, - "data": [ - { - "size": "1024x1024", - "url": "https://example.invalid/byteplus/seedream-3-0-t2i-250415/generated.png" - } - ], - "model": "seedream-3-0-t2i-250415", - "usage": { - "generated_images": 1 - } -} -``` - - diff --git a/zh/development/comfy-router/models/kling/kling-v1-5/code.mdx b/zh/development/comfy-router/models/kling/kling-v1-5/code.mdx deleted file mode 100644 index c14a105e3d..0000000000 --- a/zh/development/comfy-router/models/kling/kling-v1-5/code.mdx +++ /dev/null @@ -1,468 +0,0 @@ ---- -title: "搭配 Comfy Router 使用 Kling V1.5" -description: "通过 Comfy Router 调用 kling/kling-v1-5:端点、请求形状以及 Router 返回的响应。" -sidebarTitle: "Kling V1.5" -translationSourceHash: 7447a97c -translationFrom: development/comfy-router/models/kling/kling-v1-5/code.mdx -translationBlockHashes: - "_intro": f02fc14d - "Quick start": 31463fb0 - "Schema": d81409e3 - "Examples": e835e733 ---- -{/* GENERATED FILE. Generated from router-schemas/kling/kling-v1-5.json by `pnpm code-pages:gen`. */} - -import RouterCodeFooter from "/snippets/zh/comfy-router/model-code-footer.mdx"; - -`kling/kling-v1-5` 的 API 参考文档,由 Comfy Router 提供,模型来自 Kling。 - -## 快速开始 {#quick-start} - -在 [你的 Comfy 工作区](https://platform.comfy.org/profile/api-keys) 中创建密钥,并将其导出为 `COMFY_API_KEY`。Python 和 TypeScript 代码片段使用 Comfy SDK(`pip install comfy-sdk`、`npm install @comfyorg/sdk`);cURL 代码片段是通过原始 HTTP 发起的相同调用。 - -**模型 ID:** `kling/kling-v1-5` - -**端点:** `POST https://api.comfy.org/v2/models/kling/kling-v1-5` - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# The SDK automatically creates an idempotency key and reuses it for automatic retries. -with Comfy() as client: - result = client.models.run( - "kling/kling-v1-5", - { - "duration": "5", - "image": "https://example.invalid/kling/reference.png", - "mode": "std", - "prompt": "The fox turns its head towards the camera.", - }, - ) - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// The SDK automatically creates an idempotency key and reuses it for automatic retries. -const { data } = await comfy.models.run("kling/kling-v1-5", { - duration: "5", - image: "https://example.invalid/kling/reference.png", - mode: "std", - prompt: "The fox turns its head towards the camera.", -}); - -console.log(data); -``` - -```bash cURL -curl https://api.comfy.org/v2/models/kling/kling-v1-5 \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"duration\": \"5\", \"image\": \"https://example.invalid/kling/reference.png\", \"mode\": \"std\", \"prompt\": \"The fox turns its head towards the camera.\"}" -``` - - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -with Comfy() as client: - handle = client.models.submit( - "kling/kling-v1-5", - { - "duration": "5", - "image": "https://example.invalid/kling/reference.png", - "mode": "std", - "prompt": "The fox turns its head towards the camera.", - }, - ) - print("request_id:", handle.request_id) # with the model ID, all another process needs - - # Poll until the request completes, waiting the Retry-After the server names. - for update in handle.iter_events(): - print(update.status, update.queue_position) - - # The provider's own payload, the same value models.run() returns. - # A request that failed or was cancelled raises the typed Router error here. - result = handle.get() - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -const handle = await comfy.models.submit("kling/kling-v1-5", { - duration: "5", - image: "https://example.invalid/kling/reference.png", - mode: "std", - prompt: "The fox turns its head towards the camera.", -}); -console.log("requestId:", handle.requestId); // with the model ID, all another process needs - -// Poll until the request completes, waiting the Retry-After the server names. -for await (const update of handle.events()) { - console.log(update.status, update.queuePosition); -} - -// The same result models.run() returns. A request that failed or was cancelled rejects here. -const result = await handle.get(); - -console.log(result.data); -``` - -```bash cURL -# 1. Submit. Router answers 201 with request_id, status_url, response_url and cancel_url. -curl https://api.comfy.org/v2/models/kling/kling-v1-5/requests \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"duration\": \"5\", \"image\": \"https://example.invalid/kling/reference.png\", \"mode\": \"std\", \"prompt\": \"The fox turns its head towards the camera.\"}" - -# 2. Poll until status is COMPLETED, waiting the Retry-After seconds each response names. -REQUEST_ID="" -curl -i https://api.comfy.org/v2/models/kling/kling-v1-5/requests/$REQUEST_ID/status \ - -H "X-API-Key: $COMFY_API_KEY" - -# 3. Collect. 200 with the model's native output, 202 with the status body while it is still running. -curl https://api.comfy.org/v2/models/kling/kling-v1-5/requests/$REQUEST_ID \ - -H "X-API-Key: $COMFY_API_KEY" -``` - - - - - - -## 数据结构 - -### 输入 - - - 回调通知地址。当任务状态发生变化时,服务器将发送通知。 - - Format: `uri` - - - - - - - - - - - - 控制相机沿水平轴(x 轴)的运动。负值表示向左,正值表示向右。 - - Range: `-10` to `10` - - - - 控制相机在竖直平面内的旋转(x 轴)。负值表示向下旋转,正值表示向上旋转。 - - Range: `-10` to `10` - - - - 控制相机的翻滚数量(z 轴)。负值表示逆时针,正值表示顺时针。 - - Range: `-10` to `10` - - - - 控制相机在水平平面内的旋转(y 轴)。负值表示向左旋转,正值表示向右旋转。 - - Range: `-10` to `10` - - - - 控制相机沿竖直轴(y 轴)的运动。负值表示向下,正值表示向上。 - - Range: `-10` to `10` - - - - 控制相机焦距的变化。负值表示视野变窄,正值表示视野变宽。 - - Range: `-10` to `10` - - - - 预定义的相机运动类型。simple:可自定义的相机运动。down_back:相机下降并向后移动。forward_up:相机向前移动并向上倾斜。right_turn_forward:向右旋转并向前移动。left_turn_forward:向左旋转并向前移动。 - - Possible values: `simple`, `down_back`, `forward_up`, `right_turn_forward`, `left_turn_forward` - - - - 视频生成的灵活度。该值越高,模型的灵活度越低,与用户提示词的相关性越强。 - - Range: `0` to `1` - - Format: `float` - - - - 视频时长(秒) - - Possible values: `3`, `4`, `5`, `6`, `7`, `8`, `9`, `10`, `11`, `12`, `13`, `14`, `15` - - - - 动态画笔配置列表(最多 6 组)。对于 5 秒的视频,轨迹长度不得超过 77 个坐标。 - - - - 动态画笔应用区域(用户使用运动画笔创建的遮罩图像)。宽高比必须与输入图像匹配。 - - Format: `uri` - - - - - - - - 轨迹点的水平坐标。以图像左下角为原点 (0,0)。 - - - - 轨迹点的竖直坐标。以图像左下角为原点 (0,0)。 - - - - 基于元素 ID 配置的参考元素列表。最多支持 3 个参考元素。element_list 与 voice_list 参数互斥。 - - - - 元素 ID - - Format: `int64` - - - - 自定义任务 ID。在单个用户账户内必须唯一。 - - - - 参考图像 - URL 或 Base64 编码字符串,不能超过 10MB,分辨率不低于 300*300px,宽高比在 1:2.5 ~ 2.5:1 之间。Base64 不应包含 data:image 前缀。 - - - - 参考图像 - 结束帧控制。URL 或 Base64 编码字符串,不能超过 10MB,分辨率不低于 300*300px。Base64 不应包含 data:image 前缀。不能与 dynamic_masks/static_mask 或 camera_control 同时使用。 - - - - 视频生成模式。std:标准模式,性价比高。pro:专业模式,可生成时长更长的视频,输出质量更高。 - - Possible values: `std`, `pro` - - - - 模型名。使用 Comfy Router 时可省略或传 null;模型由请求路径选择。若提供名称,则必须与该路径匹配。 - - - - 每个分镜的信息,例如提示词和时长。最多支持 6 个分镜,最少 1 个。当 multi_shot 为 true 且 shot_type 为 customize 时必填。 - - - - 该分镜的时长(秒)。不得超过任务总时长,且不得小于 1。所有分镜时长之和等于任务总时长。 - - - - 分镜序号 - - - - 该分镜的提示词。最大长度 512 个字符。 - - - - 是否生成多分镜视频。为 true 时,prompt 参数无效。为 false 时,shot_type 和 multi_prompt 参数无效。 - - - - 负面文本提示词。推荐直接在正向提示词中通过负面语句来补充负面提示词信息。 - - - - 正向文本提示词。使用 \<\<\>> 指定与 voice_list 参数顺序相匹配的声音。一个任务最多可引用 2 个音色。指定音色时,sound 参数的值必须为 on。 - - - - 分镜方式。当 multi_shot 参数设为 true 时必填。 - - 可选值:`customize`、`intelligence` - - - - 生成视频时是否同时生成声音。仅 V2.6 及后续版本的模型支持此参数。 - - 可选值:`on`、`off` - - - - 静态画笔作用区域(用户使用运动画笔创建的遮罩图像)。宽高比必须与输入图像一致。 - - - - 生成视频时引用的声音列表。最多支持 2 个声音。element_list 与 voice_list 参数互斥。 - - - - 通过声音定制 API 返回的声音 ID,或系统预置的声音 ID。 - - - - 是否同时生成带水印的结果。目前不支持自定义水印。 - - - - true 表示生成水印,false 表示不生成水印。 - - -本文档由 Router 在 `GET /v2/models/kling/kling-v1-5/openapi.json` 提供的 schema 生成,该文档也是请求到达提供商之前用于校验调用的同一份文档。 -### 输出 - - - 错误码 - - - - - - - - 任务创建时间,Unix 时间戳,单位为毫秒 - - - - 任务的扣费单位数 - - - - 任务 ID - - - - - - - - - - - - - - - - - - - - 视频总时长,单位为秒 - - - - 已生成视频的 ID - - - - 已生成视频的 URL - - Format: `uri` - - - - 带水印的已生成视频 URL,防盗链格式 - - Format: `uri` - - - - 任务状态 - - 可选值:`submitted`、`processing`、`succeed`、`failed` - - - - 任务状态信息,任务失败时显示失败原因 - - - - 任务更新时间,Unix 时间戳,单位为毫秒 - - - - - - - - - - - - 报错信息 - - - - 请求 ID - - -## 示例 - -### 输入 - -```json -{ - "duration": "5", - "image": "https://example.invalid/kling/reference.png", - "mode": "std", - "prompt": "The fox turns its head towards the camera." -} -``` - -### 输出 - -```json -{ - "code": 0, - "data": { - "created_at": 1798761600000, - "task_id": "kling-task-1a2b3c4d5e6f", - "task_result": { - "videos": [ - { - "duration": "5", - "id": "kling-video-6f5e4d3c2b1a", - "url": "https://example.invalid/kling/kling-v1/generated.mp4" - } - ] - }, - "task_status": "succeed", - "task_status_msg": "", - "updated_at": 1798761840000 - }, - "message": "SUCCEED", - "request_id": "9f2c1a04-7b6e-4d38-8a51-3c0e7d9b2f46" -} -``` - - - diff --git a/zh/development/comfy-router/models/kling/kling-v1-6/code.mdx b/zh/development/comfy-router/models/kling/kling-v1-6/code.mdx deleted file mode 100644 index 556337fb92..0000000000 --- a/zh/development/comfy-router/models/kling/kling-v1-6/code.mdx +++ /dev/null @@ -1,421 +0,0 @@ ---- -title: "将 Kling V1.6 与 Comfy Router 配合使用" -description: "通过 Comfy Router 调用 kling/kling-v1-6:endpoint、请求结构以及 Router 返回的响应。" -sidebarTitle: "Kling V1.6" -translationSourceHash: 4e28fa7d -translationFrom: development/comfy-router/models/kling/kling-v1-6/code.mdx -translationBlockHashes: - "_intro": e5d8f71a - "Quick start": 77975fae - "Schema": ffd91cca - "Examples": 14429ff8 ---- -{/* 已生成文件。由 `pnpm code-pages:gen` 从 router-schemas/kling/kling-v1-6.json 生成。 */} - -import RouterCodeFooter from "/snippets/zh/comfy-router/model-code-footer.mdx"; - -`kling/kling-v1-6` 的 API 参考,由 Comfy Router 从 Kling 提供。 - -## 快速开始 - -在[你的 Comfy 工作区](https://platform.comfy.org/profile/api-keys)中创建一个密钥,并将其导出为 `COMFY_API_KEY`。Python 和 TypeScript 代码片段使用 Comfy SDK(`pip install comfy-sdk`、`npm install @comfyorg/sdk`);cURL 代码片段是通过原始 HTTP 发出的同一调用。 - -**模型 ID:** `kling/kling-v1-6` - -**端点:** `POST https://api.comfy.org/v2/models/kling/kling-v1-6` - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# The SDK automatically creates an idempotency key and reuses it for automatic retries. -with Comfy() as client: - result = client.models.run( - "kling/kling-v1-6", - { - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting.", - }, - ) - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// The SDK automatically creates an idempotency key and reuses it for automatic retries. -const { data } = await comfy.models.run("kling/kling-v1-6", { - aspect_ratio: "16:9", - duration: "5", - mode: "std", - prompt: "A red fox trotting through falling snow, cinematic lighting.", -}); - -console.log(data); -``` - -```bash cURL -curl https://api.comfy.org/v2/models/kling/kling-v1-6 \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"aspect_ratio\": \"16:9\", \"duration\": \"5\", \"mode\": \"std\", \"prompt\": \"A red fox trotting through falling snow, cinematic lighting.\"}" -``` - - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -with Comfy() as client: - handle = client.models.submit( - "kling/kling-v1-6", - { - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting.", - }, - ) - print("request_id:", handle.request_id) # with the model ID, all another process needs - - # Poll until the request completes, waiting the Retry-After the server names. - for update in handle.iter_events(): - print(update.status, update.queue_position) - - # The provider's own payload, the same value models.run() returns. - # A request that failed or was cancelled raises the typed Router error here. - result = handle.get() - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -const handle = await comfy.models.submit("kling/kling-v1-6", { - aspect_ratio: "16:9", - duration: "5", - mode: "std", - prompt: "A red fox trotting through falling snow, cinematic lighting.", -}); -console.log("requestId:", handle.requestId); // with the model ID, all another process needs - -// Poll until the request completes, waiting the Retry-After the server names. -for await (const update of handle.events()) { - console.log(update.status, update.queuePosition); -} - -// The same result models.run() returns. A request that failed or was cancelled rejects here. -const result = await handle.get(); - -console.log(result.data); -``` - -```bash cURL -# 1. Submit. Router answers 201 with request_id, status_url, response_url and cancel_url. -curl https://api.comfy.org/v2/models/kling/kling-v1-6/requests \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"aspect_ratio\": \"16:9\", \"duration\": \"5\", \"mode\": \"std\", \"prompt\": \"A red fox trotting through falling snow, cinematic lighting.\"}" - -# 2. Poll until status is COMPLETED, waiting the Retry-After seconds each response names. -REQUEST_ID="" -curl -i https://api.comfy.org/v2/models/kling/kling-v1-6/requests/$REQUEST_ID/status \ - -H "X-API-Key: $COMFY_API_KEY" - -# 3. Collect. 200 with the model's native output, 202 with the status body while it is still running. -curl https://api.comfy.org/v2/models/kling/kling-v1-6/requests/$REQUEST_ID \ - -H "X-API-Key: $COMFY_API_KEY" -``` - - - - - - -## 数据结构 - -### 输入 - - - 视频宽高比 - - 可选值:`16:9`、`9:16`、`1:1` - - - - 回调通知地址 - - 格式:`uri` - - - - - - - - - - - - 控制相机沿水平轴(x 轴)的移动。负值表示向左,正值表示向右。 - - 范围:`-10` 到 `10` - - - - 控制相机在竖直平面内的旋转(x 轴)。负值表示向下旋转,正值表示向上旋转。 - - 范围:`-10` 到 `10` - - - - 控制相机的翻滚幅度(z 轴)。负值表示逆时针,正值表示顺时针。 - - 范围:`-10` 到 `10` - - - - 控制相机在水平平面内的旋转(y 轴)。负值表示向左旋转,正值表示向右旋转。 - - 范围:`-10` 到 `10` - - - - 控制相机沿竖直轴(y 轴)的移动。负值表示向下,正值表示向上。 - - 范围:`-10` 到 `10` - - - - 控制相机焦距的变化。负值表示视野变窄,正值表示视野变宽。 - - 范围:`-10` 到 `10` - - - - 预设的相机运动类型。simple:可自定义的相机运动。down_back:相机下降并向后移动。forward_up:相机向前移动并向上倾斜。right_turn_forward:向右旋转并向前移动。left_turn_forward:向左旋转并向前移动。 - - 可选值:`simple`、`down_back`、`forward_up`、`right_turn_forward`、`left_turn_forward` - - - - 视频生成时的灵活度。值越高,模型的灵活度越低,与用户提示词的相关性越强。 - - 范围:`0` 到 `1` - - 格式:`float` - - - - 视频时长,单位为秒 - - 可选值:`3`、`4`、`5`、`6`、`7`、`8`、`9`、`10`、`11`、`12`、`13`、`14`、`15` - - - - 自定义任务 ID - - - - 视频生成模式。std:标准模式,性价比高。pro:专业模式,生成的视频时长更长,输出质量更高。 - - 可选值:`std`、`pro` - - - - 模型名。使用 Comfy Router 时请省略该参数或发送 null,模型由请求路径决定。若提供名称,则必须与该路径匹配。 - - - - 每个分镜的信息,例如提示词和时长。最多支持 6 个分镜,最少 1 个。当 multi_shot 为 true 且 shot_type 为 customize 时必填。 - - - - 该分镜的时长,单位为秒。不得超过任务总时长,且不得小于 1。所有分镜时长之和等于任务总时长。 - - - - 镜头序号 - - - - 该分镜的提示词。最大长度为 512 个字符。 - - - - 是否生成多镜头视频。为 true 时,prompt 参数无效。为 false 时,shot_type 和 multi_prompt 参数无效。 - - - - 负面文本提示词。建议直接在正面提示词中用否定语句补充负面提示信息。 - - - - 正面文本提示词。使用 \<\<\>> 指定与 voice_list 参数顺序相匹配的声音。一个任务最多可引用 2 种音色。指定音色时,sound 参数的值必须为 on。 - - - - 分镜方法。当 multi_shot 参数设置为 true 时必填。 - - 可选值:`customize`、`intelligence` - - - - 生成视频时是否同时生成声音。仅 V2.6 及后续版本的模型支持该参数。 - - 可选值:`on`、`off` - - - - 是否同时生成带水印的结果。目前不支持自定义水印。 - - - - true 表示生成水印,false 表示不生成。 - - -生成本页内容依据的是 Router 在 `GET /v2/models/kling/kling-v1-6/openapi.json` 提供的 schema,它也是请求到达提供商之前用于校验调用的同一份文档。 -### 输出 - - - 错误码 - - - - - - - - 任务创建时间,Unix 时间戳(毫秒) - - - - 任务的扣费单位数 - - - - 任务 ID - - - - - - - - - - - - - - - - - - - - 视频总时长,单位为秒 - - - - 已生成视频 ID - - - - 已生成视频的 URL - - Format: `uri` - - - - 带水印的已生成视频 URL,防盗链格式 - - Format: `uri` - - - - 任务状态 - - 可选值:`submitted`、`processing`、`succeed`、`failed` - - - - 任务状态信息,任务失败时显示失败原因 - - - - 任务更新时间,Unix 时间戳(毫秒) - - - - - - - - - - - - 报错信息 - - - - 请求 ID - - -## 示例 - -### 输入 - -```json -{ - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting." -} -``` - -### 输出 - -```json -{ - "code": 0, - "data": { - "created_at": 1798761600000, - "task_id": "kling-task-1a2b3c4d5e6f", - "task_result": { - "videos": [ - { - "duration": "5", - "id": "kling-video-6f5e4d3c2b1a", - "url": "https://example.invalid/kling/kling-v1/generated.mp4" - } - ] - }, - "task_status": "succeed", - "task_status_msg": "", - "updated_at": 1798761840000 - }, - "message": "SUCCEED", - "request_id": "9f2c1a04-7b6e-4d38-8a51-3c0e7d9b2f46" -} -``` - - diff --git a/zh/development/comfy-router/models/kling/kling-v1/code.mdx b/zh/development/comfy-router/models/kling/kling-v1/code.mdx deleted file mode 100644 index 4513ed49d1..0000000000 --- a/zh/development/comfy-router/models/kling/kling-v1/code.mdx +++ /dev/null @@ -1,421 +0,0 @@ ---- -title: "使用 Kling V1 与 Comfy Router" -description: "通过 Comfy Router 调用 kling/kling-v1:端点、请求结构以及 Router 返回的响应。" -sidebarTitle: "Kling V1" -translationSourceHash: 49bc09b7 -translationFrom: development/comfy-router/models/kling/kling-v1/code.mdx -translationBlockHashes: - "_intro": 88237ef1 - "Quick start": 25cc5cf0 - "Schema": 16c4273c - "Examples": 14429ff8 ---- -{/* GENERATED FILE. Generated from router-schemas/kling/kling-v1.json by `pnpm code-pages:gen`. */} - -import RouterCodeFooter from "/snippets/zh/comfy-router/model-code-footer.mdx"; - -`kling/kling-v1` 的 API 参考,由 Comfy Router 提供,模型来自 Kling。 - -## 快速开始 - -在[你的 Comfy 工作区](https://platform.comfy.org/profile/api-keys)中创建一个密钥,并将其导出为 `COMFY_API_KEY`。Python 和 TypeScript 代码片段使用 Comfy SDK(`pip install comfy-sdk`、`npm install @comfyorg/sdk`);cURL 代码片段则是通过原生 HTTP 执行的同一调用。 - -**Model ID:** `kling/kling-v1` - -**端点:** `POST https://api.comfy.org/v2/models/kling/kling-v1` - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# The SDK automatically creates an idempotency key and reuses it for automatic retries. -with Comfy() as client: - result = client.models.run( - "kling/kling-v1", - { - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting.", - }, - ) - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// The SDK automatically creates an idempotency key and reuses it for automatic retries. -const { data } = await comfy.models.run("kling/kling-v1", { - aspect_ratio: "16:9", - duration: "5", - mode: "std", - prompt: "A red fox trotting through falling snow, cinematic lighting.", -}); - -console.log(data); -``` - -```bash cURL -curl https://api.comfy.org/v2/models/kling/kling-v1 \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"aspect_ratio\": \"16:9\", \"duration\": \"5\", \"mode\": \"std\", \"prompt\": \"A red fox trotting through falling snow, cinematic lighting.\"}" -``` - - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -with Comfy() as client: - handle = client.models.submit( - "kling/kling-v1", - { - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting.", - }, - ) - print("request_id:", handle.request_id) # with the model ID, all another process needs - - # Poll until the request completes, waiting the Retry-After the server names. - for update in handle.iter_events(): - print(update.status, update.queue_position) - - # The provider's own payload, the same value models.run() returns. - # A request that failed or was cancelled raises the typed Router error here. - result = handle.get() - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -const handle = await comfy.models.submit("kling/kling-v1", { - aspect_ratio: "16:9", - duration: "5", - mode: "std", - prompt: "A red fox trotting through falling snow, cinematic lighting.", -}); -console.log("requestId:", handle.requestId); // with the model ID, all another process needs - -// Poll until the request completes, waiting the Retry-After the server names. -for await (const update of handle.events()) { - console.log(update.status, update.queuePosition); -} - -// The same result models.run() returns. A request that failed or was cancelled rejects here. -const result = await handle.get(); - -console.log(result.data); -``` - -```bash cURL -# 1. Submit. Router answers 201 with request_id, status_url, response_url and cancel_url. -curl https://api.comfy.org/v2/models/kling/kling-v1/requests \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"aspect_ratio\": \"16:9\", \"duration\": \"5\", \"mode\": \"std\", \"prompt\": \"A red fox trotting through falling snow, cinematic lighting.\"}" - -# 2. Poll until status is COMPLETED, waiting the Retry-After seconds each response names. -REQUEST_ID="" -curl -i https://api.comfy.org/v2/models/kling/kling-v1/requests/$REQUEST_ID/status \ - -H "X-API-Key: $COMFY_API_KEY" - -# 3. Collect. 200 with the model's native output, 202 with the status body while it is still running. -curl https://api.comfy.org/v2/models/kling/kling-v1/requests/$REQUEST_ID \ - -H "X-API-Key: $COMFY_API_KEY" -``` - - - - - -## Schema {#schema} - -### 输入 - - - 视频宽高比 - - 可选值:`16:9`、`9:16`、`1:1` - - - - 回调通知地址 - - 格式:`uri` - - - - - - - - - - - - 控制相机沿水平轴(x 轴)的移动。负值表示向左,正值表示向右。 - - 范围:`-10` 到 `10` - - - - 控制相机在垂直平面内的旋转(x 轴)。负值表示向下旋转,正值表示向上旋转。 - - 范围:`-10` 到 `10` - - - - 控制相机的翻滚幅度(z 轴)。负值表示逆时针,正值表示顺时针。 - - 范围:`-10` 到 `10` - - - - 控制相机在水平平面内的旋转(y 轴)。负值表示向左旋转,正值表示向右旋转。 - - 范围:`-10` 到 `10` - - - - 控制相机沿竖直轴(y 轴)的移动。负值表示向下,正值表示向上。 - - 范围:`-10` 到 `10` - - - - 控制相机焦距的变化。负值表示视野变窄,正值表示视野变宽。 - - 范围:`-10` 到 `10` - - - - 预设的相机运动类型。simple:可自定义的相机运动。down_back:相机下降并向后移动。forward_up:相机向前移动并向上倾斜。right_turn_forward:向右旋转并向前移动。left_turn_forward:向左旋转并向前移动。 - - 可选值:`simple`、`down_back`、`forward_up`、`right_turn_forward`、`left_turn_forward` - - - - 视频生成的灵活度。该值越高,模型的灵活度越低,与用户提示词的相关性越强。 - - 范围:`0` 到 `1` - - 格式:`float` - - - - 视频时长,单位为秒 - - 可选值:`3`、`4`、`5`、`6`、`7`、`8`、`9`、`10`、`11`、`12`、`13`、`14`、`15` - - - - 自定义任务 ID - - - - 视频生成模式。std:标准模式,具有成本效益。pro:专业模式,可生成时长更长、质量更高的视频。 - - 可选值:`std`、`pro` - - - - 模型名。使用 Comfy Router 时可省略或传 null;模型由请求路径决定。若传入名称,则必须与该路径一致。 - - - - 每个分镜的信息,例如提示词和时长。最多支持 6 个分镜,最少 1 个。当 multi_shot 为 true 且 shot_type 为 customize 时必填。 - - - - 该分镜的时长,单位为秒。不得超过任务总时长,且不得小于 1。所有分镜时长之和等于任务总时长。 - - - - 镜头序号 - - - - 该分镜的提示词。最大长度为 512 个字符。 - - - - 是否生成多镜头视频。为 true 时,prompt 参数无效。为 false 时,shot_type 和 multi_prompt 参数无效。 - - - - 负面文本提示词。建议直接通过正向提示词中的否定语句来补充负面提示词信息。 - - - - 正向文本提示词。使用 \<\<\>> 指定与 voice_list 参数顺序相匹配的声音。一个任务最多可引用 2 种音色。指定音色时,sound 参数值必须为 on。 - - - - 分镜方式。当 multi_shot 参数为 true 时必填。 - - 可选值:`customize`、`intelligence` - - - - 生成视频时是否同时生成声音。仅 V2.6 及后续版本的模型支持该参数。 - - 可选值:`on`、`off` - - - - 是否同时生成带水印的结果。目前不支持自定义水印。 - - - - true 表示生成水印,false 表示不生成。 - - -根据 Router 在 `GET /v2/models/kling/kling-v1/openapi.json` 提供的 schema 生成,这也是请求到达提供商之前用于校验调用的同一份文档。 -### 输出 - - - 错误码 - - - - - - - - 任务创建时间,Unix 时间戳(毫秒) - - - - 任务的扣减单位 - - - - 任务 ID - - - - - - - - - - - - - - - - - - - - 视频总时长(秒) - - - - 已生成视频 ID - - - - 已生成视频的 URL - - 格式:`uri` - - - - 带水印的已生成视频 URL,采用防盗链格式 - - 格式:`uri` - - - - 任务状态 - - 可能的值:`submitted`、`processing`、`succeed`、`failed` - - - - 任务状态信息,任务失败时显示失败原因 - - - - 任务更新时间,Unix 时间戳(毫秒) - - - - - - - - - - - - 报错信息 - - - - 请求 ID - - -## 示例 - -### 输入 - -```json -{ - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting." -} -``` - -### 输出 - -```json -{ - "code": 0, - "data": { - "created_at": 1798761600000, - "task_id": "kling-task-1a2b3c4d5e6f", - "task_result": { - "videos": [ - { - "duration": "5", - "id": "kling-video-6f5e4d3c2b1a", - "url": "https://example.invalid/kling/kling-v1/generated.mp4" - } - ] - }, - "task_status": "succeed", - "task_status_msg": "", - "updated_at": 1798761840000 - }, - "message": "SUCCEED", - "request_id": "9f2c1a04-7b6e-4d38-8a51-3c0e7d9b2f46" -} -``` - - - diff --git a/zh/development/comfy-router/models/kling/kling-v2-1-master/code.mdx b/zh/development/comfy-router/models/kling/kling-v2-1-master/code.mdx deleted file mode 100644 index b3bc7d25b3..0000000000 --- a/zh/development/comfy-router/models/kling/kling-v2-1-master/code.mdx +++ /dev/null @@ -1,422 +0,0 @@ ---- -title: "使用 Kling V2.1 Master 与 Comfy Router" -description: "通过 Comfy Router 调用 kling/kling-v2-1-master:端点、请求结构以及 Router 返回的响应。" -sidebarTitle: "Kling V2.1 Master" -translationSourceHash: 4f57933f -translationFrom: development/comfy-router/models/kling/kling-v2-1-master/code.mdx -translationBlockHashes: - "_intro": a94d25f9 - "Quick start": 57640f5d - "Schema": 3d3492a4 - "Examples": 14429ff8 ---- -{/* GENERATED FILE. Generated from router-schemas/kling/kling-v2-1-master.json by `pnpm code-pages:gen`. */} - -import RouterCodeFooter from "/snippets/zh/comfy-router/model-code-footer.mdx"; - -`kling/kling-v2-1-master` 的 API 参考,由 Kling 通过 Comfy Router 提供。 - -## 快速开始 - -在[你的 Comfy 工作区](https://platform.comfy.org/profile/api-keys)中创建密钥,并将其导出为 `COMFY_API_KEY`。Python 和 TypeScript 代码片段使用 Comfy SDK(`pip install comfy-sdk`、`npm install @comfyorg/sdk`);cURL 代码片段则是通过原始 HTTP 执行的同一调用。 - -**模型 ID:** `kling/kling-v2-1-master` - -**端点:** `POST https://api.comfy.org/v2/models/kling/kling-v2-1-master` - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# The SDK automatically creates an idempotency key and reuses it for automatic retries. -with Comfy() as client: - result = client.models.run( - "kling/kling-v2-1-master", - { - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting.", - }, - ) - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// The SDK automatically creates an idempotency key and reuses it for automatic retries. -const { data } = await comfy.models.run("kling/kling-v2-1-master", { - aspect_ratio: "16:9", - duration: "5", - mode: "std", - prompt: "A red fox trotting through falling snow, cinematic lighting.", -}); - -console.log(data); -``` - -```bash cURL -curl https://api.comfy.org/v2/models/kling/kling-v2-1-master \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"aspect_ratio\": \"16:9\", \"duration\": \"5\", \"mode\": \"std\", \"prompt\": \"A red fox trotting through falling snow, cinematic lighting.\"}" -``` - - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -with Comfy() as client: - handle = client.models.submit( - "kling/kling-v2-1-master", - { - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting.", - }, - ) - print("request_id:", handle.request_id) # with the model ID, all another process needs - - # Poll until the request completes, waiting the Retry-After the server names. - for update in handle.iter_events(): - print(update.status, update.queue_position) - - # The provider's own payload, the same value models.run() returns. - # A request that failed or was cancelled raises the typed Router error here. - result = handle.get() - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -const handle = await comfy.models.submit("kling/kling-v2-1-master", { - aspect_ratio: "16:9", - duration: "5", - mode: "std", - prompt: "A red fox trotting through falling snow, cinematic lighting.", -}); -console.log("requestId:", handle.requestId); // with the model ID, all another process needs - -// Poll until the request completes, waiting the Retry-After the server names. -for await (const update of handle.events()) { - console.log(update.status, update.queuePosition); -} - -// The same result models.run() returns. A request that failed or was cancelled rejects here. -const result = await handle.get(); - -console.log(result.data); -``` - -```bash cURL -# 1. Submit. Router answers 201 with request_id, status_url, response_url and cancel_url. -curl https://api.comfy.org/v2/models/kling/kling-v2-1-master/requests \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"aspect_ratio\": \"16:9\", \"duration\": \"5\", \"mode\": \"std\", \"prompt\": \"A red fox trotting through falling snow, cinematic lighting.\"}" - -# 2. Poll until status is COMPLETED, waiting the Retry-After seconds each response names. -REQUEST_ID="" -curl -i https://api.comfy.org/v2/models/kling/kling-v2-1-master/requests/$REQUEST_ID/status \ - -H "X-API-Key: $COMFY_API_KEY" - -# 3. Collect. 200 with the model's native output, 202 with the status body while it is still running. -curl https://api.comfy.org/v2/models/kling/kling-v2-1-master/requests/$REQUEST_ID \ - -H "X-API-Key: $COMFY_API_KEY" -``` - - - - - - -## 数据结构 - -### 输入 - - - 视频比例 - - 可选值:`16:9`、`9:16`、`1:1` - - - - 回调通知地址 - - 格式:`uri` - - - - - - - - - - - - 控制相机沿水平轴(x 轴)的移动。负值表示向左,正值表示向右。 - - 范围:`-10` 到 `10` - - - - 控制相机在竖直平面内的旋转(x 轴)。负值表示向下旋转,正值表示向上旋转。 - - 范围:`-10` 到 `10` - - - - 控制相机的翻滚量(z 轴)。负值表示逆时针,正值表示顺时针。 - - 范围:`-10` 到 `10` - - - - 控制相机在水平平面内的旋转(y 轴)。负值表示向左旋转,正值表示向右旋转。 - - 范围:`-10` 到 `10` - - - - 控制相机沿竖直轴(y 轴)的移动。负值表示向下,正值表示向上。 - - 范围:`-10` 到 `10` - - - - 控制相机焦距的变化。负值表示视野变窄,正值表示视野变宽。 - - 范围:`-10` 到 `10` - - - - 预定义的相机运动类型。simple:可自定义的相机运动。down_back:相机下降并向后移动。forward_up:相机向前移动并向上倾斜。right_turn_forward:向右旋转并向前移动。left_turn_forward:向左旋转并向前移动。 - - 可选值:`simple`、`down_back`、`forward_up`、`right_turn_forward`、`left_turn_forward` - - - - 视频生成的灵活度。值越高,模型的灵活度越低,与用户提示词的相关性越强。 - - 范围:`0` 到 `1` - - 格式:`float` - - - - 视频时长,单位为秒 - - 可选值:`3`、`4`、`5`、`6`、`7`、`8`、`9`、`10`、`11`、`12`、`13`、`14`、`15` - - - - 自定义任务 ID - - - - 视频生成模式。std:标准模式,性价比高。pro:专业模式,可生成时长更长、质量更高的视频。 - - 可选值:`std`、`pro` - - - - 模型名。使用 Comfy Router 时可省略或传 null;模型由请求路径决定。若提供名称,则必须与该路径匹配。 - - - - 每个分镜的信息,例如提示词和时长。最多支持 6 个分镜,最少 1 个。当 multi_shot 为 true 且 shot_type 为 customize 时必填。 - - - - 该分镜的时长,单位为秒。不得超过任务总时长,且不得小于 1。所有分镜的时长之和等于任务总时长。 - - - - 镜头序号 - - - - 该分镜的提示词。最大长度 512 个字符。 - - - - 是否生成多镜头视频。为 true 时,prompt 参数无效。为 false 时,shot_type 和 multi_prompt 参数无效。 - - - - 负面文本提示词。建议直接在正面提示词中通过否定句补充负面提示词信息。 - - - - 正面文本提示词。使用 \<\<\>> 指定与 voice_list 参数顺序相匹配的声音。一个任务最多可引用 2 种音色。指定音色时,sound 参数值必须为 on。 - - - - 分镜方式。当 multi_shot 参数设置为 true 时必填。 - - 可选值:`customize`、`intelligence` - - - - 生成视频时是否同时生成声音。仅 V2.6 及后续版本的模型支持此参数。 - - 可选值:`on`、`off` - - - - 是否同时生成带水印的结果。目前不支持自定义水印。 - - - - true 表示生成水印,false 表示不生成。 - - -该内容由 Router 在 `GET /v2/models/kling/kling-v2-1-master/openapi.json` 提供的 schema 生成,也是请求到达提供商之前用于校验调用的同一份文档。 -### 输出 - - - 错误码 - - - - - - - - 任务创建时间,Unix 时间戳(毫秒) - - - - 任务扣除的单位数量 - - - - 任务 ID - - - - - - - - - - - - - - - - - - - - 视频总时长(秒) - - - - 已生成视频的 ID - - - - 已生成视频的 URL - - 格式:`uri` - - - - 带水印的已生成视频 URL,防盗链格式 - - 格式:`uri` - - - - 任务状态 - - 可能的值:`submitted`、`processing`、`succeed`、`failed` - - - - 任务状态信息,任务失败时显示失败原因 - - - - 任务更新时间,Unix 时间戳(毫秒) - - - - - - - - - - - - 报错信息 - - - - 请求 ID - - -## 示例 - -### 输入 - -```json -{ - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting." -} -``` - -### 输出 - -```json -{ - "code": 0, - "data": { - "created_at": 1798761600000, - "task_id": "kling-task-1a2b3c4d5e6f", - "task_result": { - "videos": [ - { - "duration": "5", - "id": "kling-video-6f5e4d3c2b1a", - "url": "https://example.invalid/kling/kling-v1/generated.mp4" - } - ] - }, - "task_status": "succeed", - "task_status_msg": "", - "updated_at": 1798761840000 - }, - "message": "SUCCEED", - "request_id": "9f2c1a04-7b6e-4d38-8a51-3c0e7d9b2f46" -} -``` - - - diff --git a/zh/development/comfy-router/models/kling/kling-v2-1/code.mdx b/zh/development/comfy-router/models/kling/kling-v2-1/code.mdx deleted file mode 100644 index fd6cf305b6..0000000000 --- a/zh/development/comfy-router/models/kling/kling-v2-1/code.mdx +++ /dev/null @@ -1,468 +0,0 @@ ---- -title: "将 Kling V2.1 与 Comfy Router 配合使用" -description: "通过 Comfy Router 调用 kling/kling-v2-1:端点、请求结构以及 Router 返回的响应。" -sidebarTitle: "Kling V2.1" -translationSourceHash: 93fbd156 -translationFrom: development/comfy-router/models/kling/kling-v2-1/code.mdx -translationBlockHashes: - "_intro": d015787e - "Quick start": afcb7671 - "Schema": 175b57fe - "Examples": e835e733 ---- -{/* 已生成文件。由 `pnpm code-pages:gen` 从 router-schemas/kling/kling-v2-1.json 生成。 */} - -import RouterCodeFooter from "/snippets/zh/comfy-router/model-code-footer.mdx"; - -`kling/kling-v2-1` 的 API 参考,由 Comfy Router 从 Kling 提供。 - -## 快速开始 - -在[你的 Comfy 工作区](https://platform.comfy.org/profile/api-keys)中创建密钥,并将其导出为 `COMFY_API_KEY`。Python 和 TypeScript 代码片段使用 Comfy SDK(`pip install comfy-sdk`、`npm install @comfyorg/sdk`);cURL 代码片段则是通过原始 HTTP 发出的同一调用。 - -**模型 ID:** `kling/kling-v2-1` - -**端点:** `POST https://api.comfy.org/v2/models/kling/kling-v2-1` - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# The SDK automatically creates an idempotency key and reuses it for automatic retries. -with Comfy() as client: - result = client.models.run( - "kling/kling-v2-1", - { - "duration": "5", - "image": "https://example.invalid/kling/reference.png", - "mode": "std", - "prompt": "The fox turns its head towards the camera.", - }, - ) - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// The SDK automatically creates an idempotency key and reuses it for automatic retries. -const { data } = await comfy.models.run("kling/kling-v2-1", { - duration: "5", - image: "https://example.invalid/kling/reference.png", - mode: "std", - prompt: "The fox turns its head towards the camera.", -}); - -console.log(data); -``` - -```bash cURL -curl https://api.comfy.org/v2/models/kling/kling-v2-1 \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"duration\": \"5\", \"image\": \"https://example.invalid/kling/reference.png\", \"mode\": \"std\", \"prompt\": \"The fox turns its head towards the camera.\"}" -``` - - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -with Comfy() as client: - handle = client.models.submit( - "kling/kling-v2-1", - { - "duration": "5", - "image": "https://example.invalid/kling/reference.png", - "mode": "std", - "prompt": "The fox turns its head towards the camera.", - }, - ) - print("request_id:", handle.request_id) # with the model ID, all another process needs - - # Poll until the request completes, waiting the Retry-After the server names. - for update in handle.iter_events(): - print(update.status, update.queue_position) - - # The provider's own payload, the same value models.run() returns. - # A request that failed or was cancelled raises the typed Router error here. - result = handle.get() - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -const handle = await comfy.models.submit("kling/kling-v2-1", { - duration: "5", - image: "https://example.invalid/kling/reference.png", - mode: "std", - prompt: "The fox turns its head towards the camera.", -}); -console.log("requestId:", handle.requestId); // with the model ID, all another process needs - -// Poll until the request completes, waiting the Retry-After the server names. -for await (const update of handle.events()) { - console.log(update.status, update.queuePosition); -} - -// The same result models.run() returns. A request that failed or was cancelled rejects here. -const result = await handle.get(); - -console.log(result.data); -``` - -```bash cURL -# 1. Submit. Router answers 201 with request_id, status_url, response_url and cancel_url. -curl https://api.comfy.org/v2/models/kling/kling-v2-1/requests \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"duration\": \"5\", \"image\": \"https://example.invalid/kling/reference.png\", \"mode\": \"std\", \"prompt\": \"The fox turns its head towards the camera.\"}" - -# 2. Poll until status is COMPLETED, waiting the Retry-After seconds each response names. -REQUEST_ID="" -curl -i https://api.comfy.org/v2/models/kling/kling-v2-1/requests/$REQUEST_ID/status \ - -H "X-API-Key: $COMFY_API_KEY" - -# 3. Collect. 200 with the model's native output, 202 with the status body while it is still running. -curl https://api.comfy.org/v2/models/kling/kling-v2-1/requests/$REQUEST_ID \ - -H "X-API-Key: $COMFY_API_KEY" -``` - - - - - - -## 数据结构 - -### 输入 - - - 回调通知地址。任务状态发生变化时,服务器将通过该地址进行通知。 - - 格式:`uri` - - - - - - - - - - - - 控制相机沿水平轴(x 轴)的移动。负值表示向左,正值表示向右。 - - 范围:`-10` 到 `10` - - - - 控制相机在竖直平面内的旋转(x 轴)。负值表示向下旋转,正值表示向上旋转。 - - 范围:`-10` 到 `10` - - - - 控制相机的翻滚数量(z 轴)。负值表示逆时针,正值表示顺时针。 - - 范围:`-10` 到 `10` - - - - 控制相机在水平平面内的旋转(y 轴)。负值表示向左旋转,正值表示向右旋转。 - - 范围:`-10` 到 `10` - - - - 控制相机沿竖直轴(y 轴)的移动。负值表示向下,正值表示向上。 - - 范围:`-10` 到 `10` - - - - 控制相机焦距的变化。负值表示视野变窄,正值表示视野变宽。 - - 范围:`-10` 到 `10` - - - - 预设的相机运动类型。simple:可自定义的相机运动。down_back:相机下降并向后移动。forward_up:相机向前移动并向上倾斜。right_turn_forward:向右旋转并向前移动。left_turn_forward:向左旋转并向前移动。 - - 可选值:`simple`、`down_back`、`forward_up`、`right_turn_forward`、`left_turn_forward` - - - - 视频生成的灵活度。该值越高,模型的灵活度越低,与用户提示词的相关性越强。 - - 范围:`0` 到 `1` - - 格式:`float` - - - - 视频时长,单位为秒 - - 可选值:`3`、`4`、`5`、`6`、`7`、`8`、`9`、`10`、`11`、`12`、`13`、`14`、`15` - - - - 动态画笔配置列表(最多 6 组)。对于 5 秒的视频,轨迹长度不得超过 77 个坐标点。 - - - - 动态画笔的应用区域(由用户使用运动画笔创建的遮罩图像)。宽高比必须与输入图像一致。 - - 格式:`uri` - - - - - - - - 轨迹点的水平坐标。以图像左下角为原点 (0,0)。 - - - - 轨迹点的竖直坐标。以图像左下角为原点 (0,0)。 - - - - 基于元素 ID 配置的参考元素列表。最多支持 3 个参考元素。element_list 与 voice_list 参数互斥。 - - - - 元素 ID - - 格式:`int64` - - - - 自定义任务 ID。在单个用户账户内必须唯一。 - - - - 参考图像 - URL 或 Base64 编码字符串,不能超过 10MB,分辨率不低于 300*300px,宽高比在 1:2.5 ~ 2.5:1 之间。Base64 不应包含 data:image 前缀。 - - - - 参考图像 - 结束帧控制。URL 或 Base64 编码字符串,不能超过 10MB,分辨率不低于 300*300px。Base64 不应包含 data:image 前缀。不能与 dynamic_masks/static_mask 或 camera_control 同时使用。 - - - - 视频生成模式。std:标准模式,更具性价比。pro:专业模式,可生成时长更长、质量更高的视频。 - - 可选值:`std`、`pro` - - - - 模型名。使用 Comfy Router 时可省略或传 null;模型由请求路径决定。若提供名称,则必须与请求路径一致。 - - - - 每个分镜的信息,例如提示词和时长。最多支持 6 个分镜,最少 1 个。当 multi_shot 为 true 且 shot_type 为 customize 时必填。 - - - - 该分镜的时长,单位为秒。不得超过任务总时长,且不得小于 1。所有分镜时长之和等于任务总时长。 - - - - 镜头序号 - - - - 该分镜的提示词。最大长度为 512 个字符。 - - - - 是否生成多镜头视频。为 true 时,prompt 参数无效。为 false 时,shot_type 和 multi_prompt 参数无效。 - - - - Negative text prompt。推荐直接在正向提示词中通过否定语句补充负面提示词信息。 - - - - Positive text prompt。使用 \<\<\>> 指定与 voice_list 参数顺序相匹配的声音。一个任务最多可引用 2 个音色。指定音色时,sound 参数值必须为 on。 - - - - Storyboard method。当 multi_shot 参数设置为 true 时必填。 - - Possible values: `customize`, `intelligence` - - - - Whether to generate sound simultaneously when generating videos。仅 V2.6 及后续版本的模型支持此参数。 - - Possible values: `on`, `off` - - - - Static Brush Application Area(用户使用运动画笔创建的遮罩图像)。宽高比必须与输入图像一致。 - - - - 生成视频时引用的声音列表。最多支持 2 个声音。element_list 与 voice_list 参数互斥。 - - - - 通过声音自定义 API 返回的声音 ID,或系统预设的声音 ID。 - - - - Whether to generate watermarked results simultaneously。目前不支持自定义水印。 - - - - true means generate watermark, false means do not generate。 - - -Generated from the schema Router serves at `GET /v2/models/kling/kling-v2-1/openapi.json`, the same document it validates a call against before the request reaches the provider。 -### 输出 - - - 错误码 - - - - - - - - 任务创建时间,Unix 时间戳(毫秒) - - - - 任务的扣减单元 - - - - 任务 ID - - - - - - - - - - - - - - - - - - - - 视频总时长,单位为秒 - - - - 已生成视频 ID - - - - 已生成视频的 URL - - 格式:`uri` - - - - 带水印的已生成视频 URL,防盗链格式 - - 格式:`uri` - - - - 任务状态 - - 可能的值:`submitted`、`processing`、`succeed`、`failed` - - - - 任务状态信息,任务失败时显示失败原因 - - - - 任务更新时间,Unix 时间戳(毫秒) - - - - - - - - - - - - 报错信息 - - - - 请求 ID - - -## 示例 - -### 输入 - -```json -{ - "duration": "5", - "image": "https://example.invalid/kling/reference.png", - "mode": "std", - "prompt": "The fox turns its head towards the camera." -} -``` - -### 输出 - -```json -{ - "code": 0, - "data": { - "created_at": 1798761600000, - "task_id": "kling-task-1a2b3c4d5e6f", - "task_result": { - "videos": [ - { - "duration": "5", - "id": "kling-video-6f5e4d3c2b1a", - "url": "https://example.invalid/kling/kling-v1/generated.mp4" - } - ] - }, - "task_status": "succeed", - "task_status_msg": "", - "updated_at": 1798761840000 - }, - "message": "SUCCEED", - "request_id": "9f2c1a04-7b6e-4d38-8a51-3c0e7d9b2f46" -} -``` - - - diff --git a/zh/development/comfy-router/models/kling/kling-v2-master/code.mdx b/zh/development/comfy-router/models/kling/kling-v2-master/code.mdx deleted file mode 100644 index e4bc17f040..0000000000 --- a/zh/development/comfy-router/models/kling/kling-v2-master/code.mdx +++ /dev/null @@ -1,421 +0,0 @@ ---- -title: "使用 Kling V2 Master 与 Comfy Router" -description: "通过 Comfy Router 调用 kling/kling-v2-master:端点、请求形状以及 Router 返回的响应。" -sidebarTitle: "Kling V2 Master" -translationSourceHash: f9334f9e -translationFrom: development/comfy-router/models/kling/kling-v2-master/code.mdx -translationBlockHashes: - "_intro": c470eb90 - "Quick start": 1369e080 - "Schema": 769d8e31 - "Examples": 14429ff8 ---- -{/* GENERATED FILE. Generated from router-schemas/kling/kling-v2-master.json by `pnpm code-pages:gen`. */} - -import RouterCodeFooter from "/snippets/zh/comfy-router/model-code-footer.mdx"; - -`kling/kling-v2-master` 的 API 参考,由 Comfy Router 提供,来自 Kling。 - -## 快速开始 - -在[你的 Comfy 工作区](https://platform.comfy.org/profile/api-keys)中创建密钥,并将其导出为 `COMFY_API_KEY`。Python 和 TypeScript 代码片段使用 Comfy SDK(`pip install comfy-sdk`、`npm install @comfyorg/sdk`);cURL 代码片段是通过原始 HTTP 发出的同一调用。 - -**模型 ID:** `kling/kling-v2-master` - -**端点:** `POST https://api.comfy.org/v2/models/kling/kling-v2-master` - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# The SDK automatically creates an idempotency key and reuses it for automatic retries. -with Comfy() as client: - result = client.models.run( - "kling/kling-v2-master", - { - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting.", - }, - ) - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// The SDK automatically creates an idempotency key and reuses it for automatic retries. -const { data } = await comfy.models.run("kling/kling-v2-master", { - aspect_ratio: "16:9", - duration: "5", - mode: "std", - prompt: "A red fox trotting through falling snow, cinematic lighting.", -}); - -console.log(data); -``` - -```bash cURL -curl https://api.comfy.org/v2/models/kling/kling-v2-master \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"aspect_ratio\": \"16:9\", \"duration\": \"5\", \"mode\": \"std\", \"prompt\": \"A red fox trotting through falling snow, cinematic lighting.\"}" -``` - - - - - -```python Python -from comfy_sdk import Comfy - -# Reads COMFY_API_KEY from the environment. -# Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -with Comfy() as client: - handle = client.models.submit( - "kling/kling-v2-master", - { - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting.", - }, - ) - print("request_id:", handle.request_id) # with the model ID, all another process needs - - # Poll until the request completes, waiting the Retry-After the server names. - for update in handle.iter_events(): - print(update.status, update.queue_position) - - # The provider's own payload, the same value models.run() returns. - # A request that failed or was cancelled raises the typed Router error here. - result = handle.get() - -print(result) -``` - -```typescript TypeScript -import { comfy } from "@comfyorg/sdk"; - -// Reads COMFY_API_KEY from the environment. -// Each submit() call mints its own Idempotency-Key and reuses it for automatic retries. -const handle = await comfy.models.submit("kling/kling-v2-master", { - aspect_ratio: "16:9", - duration: "5", - mode: "std", - prompt: "A red fox trotting through falling snow, cinematic lighting.", -}); -console.log("requestId:", handle.requestId); // with the model ID, all another process needs - -// Poll until the request completes, waiting the Retry-After the server names. -for await (const update of handle.events()) { - console.log(update.status, update.queuePosition); -} - -// The same result models.run() returns. A request that failed or was cancelled rejects here. -const result = await handle.get(); - -console.log(result.data); -``` - -```bash cURL -# 1. Submit. Router answers 201 with request_id, status_url, response_url and cancel_url. -curl https://api.comfy.org/v2/models/kling/kling-v2-master/requests \ - -H "X-API-Key: $COMFY_API_KEY" \ - -H "Idempotency-Key: $(uuidgen)" \ - -H "Content-Type: application/json" \ - -d "{\"aspect_ratio\": \"16:9\", \"duration\": \"5\", \"mode\": \"std\", \"prompt\": \"A red fox trotting through falling snow, cinematic lighting.\"}" - -# 2. Poll until status is COMPLETED, waiting the Retry-After seconds each response names. -REQUEST_ID="" -curl -i https://api.comfy.org/v2/models/kling/kling-v2-master/requests/$REQUEST_ID/status \ - -H "X-API-Key: $COMFY_API_KEY" - -# 3. Collect. 200 with the model's native output, 202 with the status body while it is still running. -curl https://api.comfy.org/v2/models/kling/kling-v2-master/requests/$REQUEST_ID \ - -H "X-API-Key: $COMFY_API_KEY" -``` - - - - - -## 模式 - -### 输入 - - - 视频比例 - - 可能的值:`16:9`、`9:16`、`1:1` - - - - 回调通知地址 - - 格式:`uri` - - - - - - - - - - - - 控制相机沿水平轴(x 轴)的运动。负值表示向左,正值表示向右。 - - 范围:`-10` 到 `10` - - - - 控制相机在竖直平面内的旋转(x 轴)。负值表示向下旋转,正值表示向上旋转。 - - 范围:`-10` 到 `10` - - - - 控制相机的滚动量(z 轴)。负值表示逆时针,正值表示顺时针。 - - 范围:`-10` 到 `10` - - - - 控制相机在水平平面内的旋转(y 轴)。负值表示向左旋转,正值表示向右旋转。 - - 范围:`-10` 到 `10` - - - - 控制相机沿竖直轴(y 轴)的运动。负值表示向下,正值表示向上。 - - 范围:`-10` 到 `10` - - - - 控制相机焦距的变化。负值表示视野变窄,正值表示视野变宽。 - - 范围:`-10` 到 `10` - - - - 预定义的相机运动类型。simple:可自定义的相机运动。down_back:相机下降并向后移动。forward_up:相机向前移动并向上倾斜。right_turn_forward:向右旋转并向前移动。left_turn_forward:向左旋转并向前移动。 - - 可能的值:`simple`、`down_back`、`forward_up`、`right_turn_forward`、`left_turn_forward` - - - - 视频生成的灵活性。值越高,模型的灵活度越低,与用户提示词的相关性越强。 - - 范围:`0` 到 `1` - - 格式:`float` - - - - 视频时长(秒) - - 可能的值:`3`、`4`、`5`、`6`、`7`、`8`、`9`、`10`、`11`、`12`、`13`、`14`、`15` - - - - 自定义任务 ID - - - - 视频生成模式。std:标准模式,具有成本效益。pro:专业模式,生成时长更长但质量更高的输出。 - - 可能的值:`std`、`pro` - - - - 模型名。使用 Comfy Router 时省略或发送 null;模型由请求路径选择。提供的名称必须与该路径匹配。 - - - - 每个分镜的信息,例如提示词和时长。最多支持 6 个分镜,最少 1 个。当 multi_shot 为 true 且 shot_type 为 customize 时必填。 - - - - 此分镜的时长(秒)。不得超过任务总时长,且不得小于 1。所有分镜时长之和等于任务总时长。 - - - - 分镜序号 - - - - 此分镜的提示词。最大长度 512 个字符。 - - - - 是否生成多镜头视频。当为 true 时,prompt 参数无效。当为 false 时,shot_type 和 multi_prompt 参数无效。 - - - - 负面文本提示词。建议直接在正向提示词中通过否定句补充负面提示信息。 - - - - 正向文本提示词。使用 \<\<\>> 指定与 voice_list 参数顺序匹配的声音。一个任务最多可引用 2 个音调。指定音调时,sound 参数值必须为 on。 - - - - 分镜方法。当 multi_shot 参数设置为 true 时必填。 - - 可能的值:`customize`、`intelligence` - - - - 生成视频时是否同时生成声音。仅 V2.6 及后续版本的模型支持此参数。 - - 可能的值:`on`、`off` - - - - 是否同时生成带水印的结果。目前不支持自定义水印。 - - - - true 表示生成水印,false 表示不生成。 - - -由 Router 在 `GET /v2/models/kling/kling-v2-master/openapi.json` 提供的模式生成,也是在请求到达提供商之前用于验证调用的同一份文档。 -### 输出 - - - 错误代码 - - - - - - - - 任务创建时间,Unix 时间戳,单位为毫秒 - - - - 任务扣除的单位数 - - - - 任务 ID - - - - - - - - - - - - - - - - - - - - 视频总时长,单位为秒 - - - - 已生成视频 ID - - - - 已生成视频的 URL - - 格式:`uri` - - - - 已生成视频带水印的 URL,防盗链格式 - - 格式:`uri` - - - - 任务状态 - - 可选值:`submitted`、`processing`、`succeed`、`failed` - - - - 任务状态信息,任务失败时显示失败原因 - - - - 任务更新时间,Unix 时间戳,单位为毫秒 - - - - - - - - - - - - 报错信息 - - - - 请求 ID - - -## 示例 - -### 输入 - -```json -{ - "aspect_ratio": "16:9", - "duration": "5", - "mode": "std", - "prompt": "A red fox trotting through falling snow, cinematic lighting." -} -``` - -### 输出 - -```json -{ - "code": 0, - "data": { - "created_at": 1798761600000, - "task_id": "kling-task-1a2b3c4d5e6f", - "task_result": { - "videos": [ - { - "duration": "5", - "id": "kling-video-6f5e4d3c2b1a", - "url": "https://example.invalid/kling/kling-v1/generated.mp4" - } - ] - }, - "task_status": "succeed", - "task_status_msg": "", - "updated_at": 1798761840000 - }, - "message": "SUCCEED", - "request_id": "9f2c1a04-7b6e-4d38-8a51-3c0e7d9b2f46" -} -``` - - - From 6e97847c2417014c03f6d68c99f871e91f149131 Mon Sep 17 00:00:00 2001 From: lin-bot23 Date: Fri, 18 Sep 2026 19:22:01 +0800 Subject: [PATCH 2/2] chore: add localized redirects and drop inbound links for removed pages The redirect check requires a redirect entry for every deleted .mdx, and the Mintlify broken-link check resolves links through redirects. The retired pages only had English redirects, and the translated pages still linked the localized paths, so both checks failed. - 33 new redirects, one per removed locale page: the retired comfy-router model pages point at the localized model index, and api-development/overview points at the localized development overview (the run-workflows overview has no localized page yet) - the stale links are removed from the nine pages that still referenced them: development/overview and api-development/workflow-api-format lose the overview link, and comfy-router/models loses the ten retired model rows, matching what the English pages do --- docs.json | 165 ++++++++++++++++++ .../api-development/workflow-api-format.mdx | 1 - ja/development/comfy-router/models.mdx | 10 -- ja/development/overview.mdx | 4 +- .../api-development/workflow-api-format.mdx | 1 - ko/development/comfy-router/models.mdx | 10 -- ko/development/overview.mdx | 4 +- .../api-development/workflow-api-format.mdx | 1 - zh/development/comfy-router/models.mdx | 10 -- zh/development/overview.mdx | 4 +- 10 files changed, 171 insertions(+), 39 deletions(-) diff --git a/docs.json b/docs.json index 78c16cb192..ec25d121d0 100644 --- a/docs.json +++ b/docs.json @@ -6812,6 +6812,7 @@ "zh/development/api-development/sdks", "zh/development/serverless/overview", "zh/development/api-development/getting-an-api-key", + "zh/development/api-development/overview", "zh/api-reference/v2/overview", { "group": "Comfy API v2 参考文档", @@ -6905,9 +6906,13 @@ "zh/development/comfy-router/models/byteplus/seed-2-0-pro-260328/code", "zh/development/comfy-router/models/byteplus/seed-audio-1-0-multilingual/code", "zh/development/comfy-router/models/byteplus/seed-audio-1-0/code", + "zh/development/comfy-router/models/byteplus/seedance-1-0-lite-i2v-250428/code", + "zh/development/comfy-router/models/byteplus/seedance-1-0-lite-t2v-250428/code", "zh/development/comfy-router/models/byteplus/seedance-1-0-pro-250528/code", "zh/development/comfy-router/models/byteplus/seedance-1-0-pro-fast-251015/code", "zh/development/comfy-router/models/byteplus/seedance-1-5-pro-251215/code", + "zh/development/comfy-router/models/byteplus/seededit-3-0-i2i-250628/code", + "zh/development/comfy-router/models/byteplus/seedream-3-0-t2i-250415/code", "zh/development/comfy-router/models/byteplus/seedream-4-0-250828/code", "zh/development/comfy-router/models/byteplus/seedream-4-5-251128/code", "zh/development/comfy-router/models/byteplus/seedream-5-0-260128/code", @@ -6980,8 +6985,14 @@ "pages": [ "zh/development/comfy-router/models/kling/kling-3-0-turbo/code", "zh/development/comfy-router/models/kling/kling-image-o1/code", + "zh/development/comfy-router/models/kling/kling-v1-5/code", + "zh/development/comfy-router/models/kling/kling-v1-6/code", + "zh/development/comfy-router/models/kling/kling-v1/code", + "zh/development/comfy-router/models/kling/kling-v2-1-master/code", + "zh/development/comfy-router/models/kling/kling-v2-1/code", "zh/development/comfy-router/models/kling/kling-v2-5-turbo/code", "zh/development/comfy-router/models/kling/kling-v2-6/code", + "zh/development/comfy-router/models/kling/kling-v2-master/code", "zh/development/comfy-router/models/kling/kling-v3-omni/code", "zh/development/comfy-router/models/kling/kling-v3/code", "zh/development/comfy-router/models/kling/kling-video-o1/code", @@ -10545,6 +10556,7 @@ "ja/development/api-development/sdks", "ja/development/serverless/overview", "ja/development/api-development/getting-an-api-key", + "ja/development/api-development/overview", "ja/api-reference/v2/overview", { "group": "Comfy API v2リファレンス", @@ -10638,9 +10650,13 @@ "ja/development/comfy-router/models/byteplus/seed-2-0-pro-260328/code", "ja/development/comfy-router/models/byteplus/seed-audio-1-0-multilingual/code", "ja/development/comfy-router/models/byteplus/seed-audio-1-0/code", + "ja/development/comfy-router/models/byteplus/seedance-1-0-lite-i2v-250428/code", + "ja/development/comfy-router/models/byteplus/seedance-1-0-lite-t2v-250428/code", "ja/development/comfy-router/models/byteplus/seedance-1-0-pro-250528/code", "ja/development/comfy-router/models/byteplus/seedance-1-0-pro-fast-251015/code", "ja/development/comfy-router/models/byteplus/seedance-1-5-pro-251215/code", + "ja/development/comfy-router/models/byteplus/seededit-3-0-i2i-250628/code", + "ja/development/comfy-router/models/byteplus/seedream-3-0-t2i-250415/code", "ja/development/comfy-router/models/byteplus/seedream-4-0-250828/code", "ja/development/comfy-router/models/byteplus/seedream-4-5-251128/code", "ja/development/comfy-router/models/byteplus/seedream-5-0-260128/code", @@ -10713,8 +10729,14 @@ "pages": [ "ja/development/comfy-router/models/kling/kling-3-0-turbo/code", "ja/development/comfy-router/models/kling/kling-image-o1/code", + "ja/development/comfy-router/models/kling/kling-v1-5/code", + "ja/development/comfy-router/models/kling/kling-v1-6/code", + "ja/development/comfy-router/models/kling/kling-v1/code", + "ja/development/comfy-router/models/kling/kling-v2-1-master/code", + "ja/development/comfy-router/models/kling/kling-v2-1/code", "ja/development/comfy-router/models/kling/kling-v2-5-turbo/code", "ja/development/comfy-router/models/kling/kling-v2-6/code", + "ja/development/comfy-router/models/kling/kling-v2-master/code", "ja/development/comfy-router/models/kling/kling-v3-omni/code", "ja/development/comfy-router/models/kling/kling-v3/code", "ja/development/comfy-router/models/kling/kling-video-o1/code", @@ -14191,6 +14213,7 @@ "ko/development/api-development/sdks", "ko/development/serverless/overview", "ko/development/api-development/getting-an-api-key", + "ko/development/api-development/overview", "ko/api-reference/v2/overview", { "group": "Comfy API v2 참조", @@ -14284,9 +14307,13 @@ "ko/development/comfy-router/models/byteplus/seed-2-0-pro-260328/code", "ko/development/comfy-router/models/byteplus/seed-audio-1-0-multilingual/code", "ko/development/comfy-router/models/byteplus/seed-audio-1-0/code", + "ko/development/comfy-router/models/byteplus/seedance-1-0-lite-i2v-250428/code", + "ko/development/comfy-router/models/byteplus/seedance-1-0-lite-t2v-250428/code", "ko/development/comfy-router/models/byteplus/seedance-1-0-pro-250528/code", "ko/development/comfy-router/models/byteplus/seedance-1-0-pro-fast-251015/code", "ko/development/comfy-router/models/byteplus/seedance-1-5-pro-251215/code", + "ko/development/comfy-router/models/byteplus/seededit-3-0-i2i-250628/code", + "ko/development/comfy-router/models/byteplus/seedream-3-0-t2i-250415/code", "ko/development/comfy-router/models/byteplus/seedream-4-0-250828/code", "ko/development/comfy-router/models/byteplus/seedream-4-5-251128/code", "ko/development/comfy-router/models/byteplus/seedream-5-0-260128/code", @@ -14359,8 +14386,14 @@ "pages": [ "ko/development/comfy-router/models/kling/kling-3-0-turbo/code", "ko/development/comfy-router/models/kling/kling-image-o1/code", + "ko/development/comfy-router/models/kling/kling-v1-5/code", + "ko/development/comfy-router/models/kling/kling-v1-6/code", + "ko/development/comfy-router/models/kling/kling-v1/code", + "ko/development/comfy-router/models/kling/kling-v2-1-master/code", + "ko/development/comfy-router/models/kling/kling-v2-1/code", "ko/development/comfy-router/models/kling/kling-v2-5-turbo/code", "ko/development/comfy-router/models/kling/kling-v2-6/code", + "ko/development/comfy-router/models/kling/kling-v2-master/code", "ko/development/comfy-router/models/kling/kling-v3-omni/code", "ko/development/comfy-router/models/kling/kling-v3/code", "ko/development/comfy-router/models/kling/kling-video-o1/code", @@ -15828,6 +15861,138 @@ { "source": "/development/comfy-router/models/kling/kling-v2-master/code", "destination": "/development/comfy-router/models" + }, + { + "source": "/ja/development/api-development/overview", + "destination": "/ja/development/overview" + }, + { + "source": "/zh/development/api-development/overview", + "destination": "/zh/development/overview" + }, + { + "source": "/ko/development/api-development/overview", + "destination": "/ko/development/overview" + }, + { + "source": "/ja/development/comfy-router/models/byteplus/seedance-1-0-lite-i2v-250428/code", + "destination": "/ja/development/comfy-router/models" + }, + { + "source": "/zh/development/comfy-router/models/byteplus/seedance-1-0-lite-i2v-250428/code", + "destination": "/zh/development/comfy-router/models" + }, + { + "source": "/ko/development/comfy-router/models/byteplus/seedance-1-0-lite-i2v-250428/code", + "destination": "/ko/development/comfy-router/models" + }, + { + "source": "/ja/development/comfy-router/models/byteplus/seedance-1-0-lite-t2v-250428/code", + "destination": "/ja/development/comfy-router/models" + }, + { + "source": "/zh/development/comfy-router/models/byteplus/seedance-1-0-lite-t2v-250428/code", + "destination": "/zh/development/comfy-router/models" + }, + { + "source": "/ko/development/comfy-router/models/byteplus/seedance-1-0-lite-t2v-250428/code", + "destination": "/ko/development/comfy-router/models" + }, + { + "source": "/ja/development/comfy-router/models/byteplus/seededit-3-0-i2i-250628/code", + "destination": "/ja/development/comfy-router/models" + }, + { + "source": "/zh/development/comfy-router/models/byteplus/seededit-3-0-i2i-250628/code", + "destination": "/zh/development/comfy-router/models" + }, + { + "source": "/ko/development/comfy-router/models/byteplus/seededit-3-0-i2i-250628/code", + "destination": "/ko/development/comfy-router/models" + }, + { + "source": "/ja/development/comfy-router/models/byteplus/seedream-3-0-t2i-250415/code", + "destination": "/ja/development/comfy-router/models" + }, + { + "source": "/zh/development/comfy-router/models/byteplus/seedream-3-0-t2i-250415/code", + "destination": "/zh/development/comfy-router/models" + }, + { + "source": "/ko/development/comfy-router/models/byteplus/seedream-3-0-t2i-250415/code", + "destination": "/ko/development/comfy-router/models" + }, + { + "source": "/ja/development/comfy-router/models/kling/kling-v1-5/code", + "destination": "/ja/development/comfy-router/models" + }, + { + "source": "/zh/development/comfy-router/models/kling/kling-v1-5/code", + "destination": "/zh/development/comfy-router/models" + }, + { + "source": "/ko/development/comfy-router/models/kling/kling-v1-5/code", + "destination": "/ko/development/comfy-router/models" + }, + { + "source": "/ja/development/comfy-router/models/kling/kling-v1-6/code", + "destination": "/ja/development/comfy-router/models" + }, + { + "source": "/zh/development/comfy-router/models/kling/kling-v1-6/code", + "destination": "/zh/development/comfy-router/models" + }, + { + "source": "/ko/development/comfy-router/models/kling/kling-v1-6/code", + "destination": "/ko/development/comfy-router/models" + }, + { + "source": "/ja/development/comfy-router/models/kling/kling-v1/code", + "destination": "/ja/development/comfy-router/models" + }, + { + "source": "/zh/development/comfy-router/models/kling/kling-v1/code", + "destination": "/zh/development/comfy-router/models" + }, + { + "source": "/ko/development/comfy-router/models/kling/kling-v1/code", + "destination": "/ko/development/comfy-router/models" + }, + { + "source": "/ja/development/comfy-router/models/kling/kling-v2-1-master/code", + "destination": "/ja/development/comfy-router/models" + }, + { + "source": "/zh/development/comfy-router/models/kling/kling-v2-1-master/code", + "destination": "/zh/development/comfy-router/models" + }, + { + "source": "/ko/development/comfy-router/models/kling/kling-v2-1-master/code", + "destination": "/ko/development/comfy-router/models" + }, + { + "source": "/ja/development/comfy-router/models/kling/kling-v2-1/code", + "destination": "/ja/development/comfy-router/models" + }, + { + "source": "/zh/development/comfy-router/models/kling/kling-v2-1/code", + "destination": "/zh/development/comfy-router/models" + }, + { + "source": "/ko/development/comfy-router/models/kling/kling-v2-1/code", + "destination": "/ko/development/comfy-router/models" + }, + { + "source": "/ja/development/comfy-router/models/kling/kling-v2-master/code", + "destination": "/ja/development/comfy-router/models" + }, + { + "source": "/zh/development/comfy-router/models/kling/kling-v2-master/code", + "destination": "/zh/development/comfy-router/models" + }, + { + "source": "/ko/development/comfy-router/models/kling/kling-v2-master/code", + "destination": "/ko/development/comfy-router/models" } ] } diff --git a/ja/development/api-development/workflow-api-format.mdx b/ja/development/api-development/workflow-api-format.mdx index 40688196a6..a317dac259 100644 --- a/ja/development/api-development/workflow-api-format.mdx +++ b/ja/development/api-development/workflow-api-format.mdx @@ -172,7 +172,6 @@ ComfyUI フロントエンドでワークフローを開き、`File → Export W ## 関連ページ -- [API 概要](/ja/development/api-development/overview) — Cloud と Server API の比較 - [Cloud API 概要](/ja/development/cloud/overview) — Comfy Cloud に API 形式のワークフローを送信 - [API 例](/ja/development/comfyui-server/api-examples) — API 形式ワークフローの実例 - [API Key の取得](/ja/development/api-development/getting-an-api-key) — Cloud API と Partner Nodes に必要 diff --git a/ja/development/comfy-router/models.mdx b/ja/development/comfy-router/models.mdx index 024e565b19..95075b99c1 100644 --- a/ja/development/comfy-router/models.mdx +++ b/ja/development/comfy-router/models.mdx @@ -100,13 +100,9 @@ translationBlockHashes: - [Seed 2.0 Pro 260328](/ja/development/comfy-router/models/byteplus/seed-2-0-pro-260328/code): `byteplus/seed-2-0-pro-260328` - [Seed Audio 1.0 Multilingual](/ja/development/comfy-router/models/byteplus/seed-audio-1-0-multilingual/code): `byteplus/seed-audio-1.0-multilingual` - [Seed Audio 1.0](/ja/development/comfy-router/models/byteplus/seed-audio-1-0/code): `byteplus/seed-audio-1.0` -- [Seedance 1.0 Lite I2V 250428](/ja/development/comfy-router/models/byteplus/seedance-1-0-lite-i2v-250428/code): `byteplus/seedance-1-0-lite-i2v-250428` -- [Seedance 1.0 Lite T2V 250428](/ja/development/comfy-router/models/byteplus/seedance-1-0-lite-t2v-250428/code): `byteplus/seedance-1-0-lite-t2v-250428` - [Seedance 1.0 Pro 250528](/ja/development/comfy-router/models/byteplus/seedance-1-0-pro-250528/code): `byteplus/seedance-1-0-pro-250528` - [Seedance 1.0 Pro Fast 251015](/ja/development/comfy-router/models/byteplus/seedance-1-0-pro-fast-251015/code): `byteplus/seedance-1-0-pro-fast-251015` - [Seedance 1.5 Pro 251215](/ja/development/comfy-router/models/byteplus/seedance-1-5-pro-251215/code): `byteplus/seedance-1-5-pro-251215` -- [Seededit 3.0 I2I 250628](/ja/development/comfy-router/models/byteplus/seededit-3-0-i2i-250628/code): `byteplus/seededit-3-0-i2i-250628` -- [Seedream 3.0 T2I 250415](/ja/development/comfy-router/models/byteplus/seedream-3-0-t2i-250415/code): `byteplus/seedream-3-0-t2i-250415` - [Seedream 4.0 250828](/ja/development/comfy-router/models/byteplus/seedream-4-0-250828/code): `byteplus/seedream-4-0-250828` - [Seedream 4.5 251128](/ja/development/comfy-router/models/byteplus/seedream-4-5-251128/code): `byteplus/seedream-4-5-251128` - [Seedream 5.0 260128](/ja/development/comfy-router/models/byteplus/seedream-5-0-260128/code): `byteplus/seedream-5-0-260128` @@ -163,14 +159,8 @@ translationBlockHashes: - [Kling 3.0 Turbo](/ja/development/comfy-router/models/kling/kling-3-0-turbo/code): `kling/kling-3.0-turbo` - [Kling Image O1](/ja/development/comfy-router/models/kling/kling-image-o1/code): `kling/kling-image-o1` -- [Kling V1.5](/ja/development/comfy-router/models/kling/kling-v1-5/code): `kling/kling-v1-5` -- [Kling V1.6](/ja/development/comfy-router/models/kling/kling-v1-6/code): `kling/kling-v1-6` -- [Kling V1](/ja/development/comfy-router/models/kling/kling-v1/code): `kling/kling-v1` -- [Kling V2.1 Master](/ja/development/comfy-router/models/kling/kling-v2-1-master/code): `kling/kling-v2-1-master` -- [Kling V2.1](/ja/development/comfy-router/models/kling/kling-v2-1/code): `kling/kling-v2-1` - [Kling V2.5 Turbo](/ja/development/comfy-router/models/kling/kling-v2-5-turbo/code): `kling/kling-v2-5-turbo` - [Kling V2.6](/ja/development/comfy-router/models/kling/kling-v2-6/code): `kling/kling-v2-6` -- [Kling V2 Master](/ja/development/comfy-router/models/kling/kling-v2-master/code): `kling/kling-v2-master` - [Kling V3 Omni](/ja/development/comfy-router/models/kling/kling-v3-omni/code): `kling/kling-v3-omni` - [Kling V3](/ja/development/comfy-router/models/kling/kling-v3/code): `kling/kling-v3` - [Kling Video O1](/ja/development/comfy-router/models/kling/kling-video-o1/code): `kling/kling-video-o1` diff --git a/ja/development/overview.mdx b/ja/development/overview.mdx index 454e635bdc..bd9474e07c 100644 --- a/ja/development/overview.mdx +++ b/ja/development/overview.mdx @@ -18,7 +18,7 @@ ComfyUI はモジュール式の GenAI 推論エンジンです。API サーバ Python または TypeScript SDK をインストールし、ワークフローを送信して、出力をダウンロードできます。現在ベータ版です。 -関連情報: [デザインノート](/ja/development/api-development/sdks-design) · [Comfy API v2 リファレンス](/ja/api-reference/v2/overview) · [API 概要](/ja/development/api-development/overview) +関連情報: [デザインノート](/ja/development/api-development/sdks-design) · [Comfy API v2 リファレンス](/ja/api-reference/v2/overview) ## ComfyUI をサーバーとしてデプロイ @@ -38,7 +38,7 @@ ComfyUI はモジュール式の GenAI 推論エンジンです。API サーバ 認証方法、ジョブの送信、ステータス確認、Comfy Cloud からの結果ダウンロードを解説。 -関連リンク:[API リファレンス](/ja/development/cloud/api-reference) · [OpenAPI 仕様](/ja/development/cloud/openapi) · [API Key を取得する](/ja/development/api-development/getting-an-api-key) · [API 概要](/ja/development/api-development/overview) +関連リンク:[API リファレンス](/ja/development/cloud/api-reference) · [OpenAPI 仕様](/ja/development/cloud/openapi) · [API Key を取得する](/ja/development/api-development/getting-an-api-key) ## Agent Tools / MCP diff --git a/ko/development/api-development/workflow-api-format.mdx b/ko/development/api-development/workflow-api-format.mdx index 8352fe4ba6..82532bfdfc 100644 --- a/ko/development/api-development/workflow-api-format.mdx +++ b/ko/development/api-development/workflow-api-format.mdx @@ -172,7 +172,6 @@ ComfyUI 프론트엔드에서 워크플로를 열고, `파일 → 워크플로 ## 관련 페이지 -- [API 개요](/ko/development/api-development/overview) — Cloud 및 서버 API 옵션 비교 - [Cloud API 개요](/ko/development/cloud/overview) — Comfy Cloud에 API 형식 워크플로 제출 - [API 예제](/ko/development/comfyui-server/api-examples) — API 형식 워크플로 실습 보기 - [API 키 얻기](/ko/development/api-development/getting-an-api-key) — Cloud API 및 파트너 노드에 필요 diff --git a/ko/development/comfy-router/models.mdx b/ko/development/comfy-router/models.mdx index 5b7b71d3aa..bdf011ce9c 100644 --- a/ko/development/comfy-router/models.mdx +++ b/ko/development/comfy-router/models.mdx @@ -100,13 +100,9 @@ translationBlockHashes: - [Seed 2.0 Pro 260328](/ko/development/comfy-router/models/byteplus/seed-2-0-pro-260328/code): `byteplus/seed-2-0-pro-260328` - [Seed Audio 1.0 Multilingual](/ko/development/comfy-router/models/byteplus/seed-audio-1-0-multilingual/code): `byteplus/seed-audio-1.0-multilingual` - [Seed Audio 1.0](/ko/development/comfy-router/models/byteplus/seed-audio-1-0/code): `byteplus/seed-audio-1.0` -- [Seedance 1.0 Lite I2V 250428](/ko/development/comfy-router/models/byteplus/seedance-1-0-lite-i2v-250428/code): `byteplus/seedance-1-0-lite-i2v-250428` -- [Seedance 1.0 Lite T2V 250428](/ko/development/comfy-router/models/byteplus/seedance-1-0-lite-t2v-250428/code): `byteplus/seedance-1-0-lite-t2v-250428` - [Seedance 1.0 Pro 250528](/ko/development/comfy-router/models/byteplus/seedance-1-0-pro-250528/code): `byteplus/seedance-1-0-pro-250528` - [Seedance 1.0 Pro Fast 251015](/ko/development/comfy-router/models/byteplus/seedance-1-0-pro-fast-251015/code): `byteplus/seedance-1-0-pro-fast-251015` - [Seedance 1.5 Pro 251215](/ko/development/comfy-router/models/byteplus/seedance-1-5-pro-251215/code): `byteplus/seedance-1-5-pro-251215` -- [Seededit 3.0 I2I 250628](/ko/development/comfy-router/models/byteplus/seededit-3-0-i2i-250628/code): `byteplus/seededit-3-0-i2i-250628` -- [Seedream 3.0 T2I 250415](/ko/development/comfy-router/models/byteplus/seedream-3-0-t2i-250415/code): `byteplus/seedream-3-0-t2i-250415` - [Seedream 4.0 250828](/ko/development/comfy-router/models/byteplus/seedream-4-0-250828/code): `byteplus/seedream-4-0-250828` - [Seedream 4.5 251128](/ko/development/comfy-router/models/byteplus/seedream-4-5-251128/code): `byteplus/seedream-4-5-251128` - [Seedream 5.0 260128](/ko/development/comfy-router/models/byteplus/seedream-5-0-260128/code): `byteplus/seedream-5-0-260128` @@ -163,14 +159,8 @@ translationBlockHashes: - [Kling 3.0 Turbo](/ko/development/comfy-router/models/kling/kling-3-0-turbo/code): `kling/kling-3.0-turbo` - [Kling Image O1](/ko/development/comfy-router/models/kling/kling-image-o1/code): `kling/kling-image-o1` -- [Kling V1.5](/ko/development/comfy-router/models/kling/kling-v1-5/code): `kling/kling-v1-5` -- [Kling V1.6](/ko/development/comfy-router/models/kling/kling-v1-6/code): `kling/kling-v1-6` -- [Kling V1](/ko/development/comfy-router/models/kling/kling-v1/code): `kling/kling-v1` -- [Kling V2.1 Master](/ko/development/comfy-router/models/kling/kling-v2-1-master/code): `kling/kling-v2-1-master` -- [Kling V2.1](/ko/development/comfy-router/models/kling/kling-v2-1/code): `kling/kling-v2-1` - [Kling V2.5 Turbo](/ko/development/comfy-router/models/kling/kling-v2-5-turbo/code): `kling/kling-v2-5-turbo` - [Kling V2.6](/ko/development/comfy-router/models/kling/kling-v2-6/code): `kling/kling-v2-6` -- [Kling V2 Master](/ko/development/comfy-router/models/kling/kling-v2-master/code): `kling/kling-v2-master` - [Kling V3 Omni](/ko/development/comfy-router/models/kling/kling-v3-omni/code): `kling/kling-v3-omni` - [Kling V3](/ko/development/comfy-router/models/kling/kling-v3/code): `kling/kling-v3` - [Kling Video O1](/ko/development/comfy-router/models/kling/kling-video-o1/code): `kling/kling-video-o1` diff --git a/ko/development/overview.mdx b/ko/development/overview.mdx index 011bac6344..7387ddfa37 100644 --- a/ko/development/overview.mdx +++ b/ko/development/overview.mdx @@ -18,7 +18,7 @@ ComfyUI는 서버로 실행되고 API를 통해 접근 가능하며, 커스텀 Python 또는 TypeScript SDK를 설치하고, 워크플로를 제출한 뒤, 출력을 다운로드하세요. 현재 베타 버전입니다. -참고: [설계 노트](/ko/development/api-development/sdks-design) · [Comfy API v2 레퍼런스](/ko/api-reference/v2/overview) · [API 개요](/ko/development/api-development/overview) +참고: [설계 노트](/ko/development/api-development/sdks-design) · [Comfy API v2 레퍼런스](/ko/api-reference/v2/overview) ## ComfyUI를 서버로 배포하기 @@ -38,7 +38,7 @@ ComfyUI는 서버로 실행되고 API를 통해 접근 가능하며, 커스텀 Comfy Cloud에서 인증 방법, 작업 제출, 상태 확인 및 결과 다운로드 방법을 알아보세요. -참고: [API 참조](/ko/development/cloud/api-reference) · [OpenAPI 스펙](/ko/development/cloud/openapi) · [API 키 얻기](/ko/development/api-development/getting-an-api-key) · [API 개요](/ko/development/api-development/overview) +참고: [API 참조](/ko/development/cloud/api-reference) · [OpenAPI 스펙](/ko/development/cloud/openapi) · [API 키 얻기](/ko/development/api-development/getting-an-api-key) ## 에이전트 도구 / MCP diff --git a/zh/development/api-development/workflow-api-format.mdx b/zh/development/api-development/workflow-api-format.mdx index 07be8e921d..c7c5e09c50 100644 --- a/zh/development/api-development/workflow-api-format.mdx +++ b/zh/development/api-development/workflow-api-format.mdx @@ -172,7 +172,6 @@ ComfyUI 前端可以以两种格式保存工作流: ## 相关页面 -- [API 总览](/zh/development/api-development/overview) — 比较 Cloud 和 Server API 选项 - [Cloud API 概述](/zh/development/cloud/overview) — 向 Comfy Cloud 提交 API 格式的工作流 - [API 示例](/zh/development/comfyui-server/api-examples) — 查看 API 格式工作流的使用示例 - [获取 API Key](/zh/development/api-development/getting-an-api-key) — Cloud API 和 Partner Nodes 所需 diff --git a/zh/development/comfy-router/models.mdx b/zh/development/comfy-router/models.mdx index 2a667a3d9b..aa120feb11 100644 --- a/zh/development/comfy-router/models.mdx +++ b/zh/development/comfy-router/models.mdx @@ -100,13 +100,9 @@ translationBlockHashes: - [Seed 2.0 Pro 260328](/zh/development/comfy-router/models/byteplus/seed-2-0-pro-260328/code):`byteplus/seed-2-0-pro-260328` - [Seed Audio 1.0 Multilingual](/zh/development/comfy-router/models/byteplus/seed-audio-1-0-multilingual/code):`byteplus/seed-audio-1.0-multilingual` - [Seed Audio 1.0](/zh/development/comfy-router/models/byteplus/seed-audio-1-0/code):`byteplus/seed-audio-1.0` -- [Seedance 1.0 Lite I2V 250428](/zh/development/comfy-router/models/byteplus/seedance-1-0-lite-i2v-250428/code):`byteplus/seedance-1-0-lite-i2v-250428` -- [Seedance 1.0 Lite T2V 250428](/zh/development/comfy-router/models/byteplus/seedance-1-0-lite-t2v-250428/code):`byteplus/seedance-1-0-lite-t2v-250428` - [Seedance 1.0 Pro 250528](/zh/development/comfy-router/models/byteplus/seedance-1-0-pro-250528/code):`byteplus/seedance-1-0-pro-250528` - [Seedance 1.0 Pro Fast 251015](/zh/development/comfy-router/models/byteplus/seedance-1-0-pro-fast-251015/code):`byteplus/seedance-1-0-pro-fast-251015` - [Seedance 1.5 Pro 251215](/zh/development/comfy-router/models/byteplus/seedance-1-5-pro-251215/code):`byteplus/seedance-1-5-pro-251215` -- [Seededit 3.0 I2I 250628](/zh/development/comfy-router/models/byteplus/seededit-3-0-i2i-250628/code):`byteplus/seededit-3-0-i2i-250628` -- [Seedream 3.0 T2I 250415](/zh/development/comfy-router/models/byteplus/seedream-3-0-t2i-250415/code):`byteplus/seedream-3-0-t2i-250415` - [Seedream 4.0 250828](/zh/development/comfy-router/models/byteplus/seedream-4-0-250828/code):`byteplus/seedream-4-0-250828` - [Seedream 4.5 251128](/zh/development/comfy-router/models/byteplus/seedream-4-5-251128/code):`byteplus/seedream-4-5-251128` - [Seedream 5.0 260128](/zh/development/comfy-router/models/byteplus/seedream-5-0-260128/code):`byteplus/seedream-5-0-260128` @@ -163,14 +159,8 @@ translationBlockHashes: - [Kling 3.0 Turbo](/zh/development/comfy-router/models/kling/kling-3-0-turbo/code): `kling/kling-3.0-turbo` - [Kling Image O1](/zh/development/comfy-router/models/kling/kling-image-o1/code): `kling/kling-image-o1` -- [Kling V1.5](/zh/development/comfy-router/models/kling/kling-v1-5/code): `kling/kling-v1-5` -- [Kling V1.6](/zh/development/comfy-router/models/kling/kling-v1-6/code): `kling/kling-v1-6` -- [Kling V1](/zh/development/comfy-router/models/kling/kling-v1/code): `kling/kling-v1` -- [Kling V2.1 Master](/zh/development/comfy-router/models/kling/kling-v2-1-master/code): `kling/kling-v2-1-master` -- [Kling V2.1](/zh/development/comfy-router/models/kling/kling-v2-1/code): `kling/kling-v2-1` - [Kling V2.5 Turbo](/zh/development/comfy-router/models/kling/kling-v2-5-turbo/code): `kling/kling-v2-5-turbo` - [Kling V2.6](/zh/development/comfy-router/models/kling/kling-v2-6/code): `kling/kling-v2-6` -- [Kling V2 Master](/zh/development/comfy-router/models/kling/kling-v2-master/code): `kling/kling-v2-master` - [Kling V3 Omni](/zh/development/comfy-router/models/kling/kling-v3-omni/code): `kling/kling-v3-omni` - [Kling V3](/zh/development/comfy-router/models/kling/kling-v3/code): `kling/kling-v3` - [Kling Video O1](/zh/development/comfy-router/models/kling/kling-video-o1/code): `kling/kling-video-o1` diff --git a/zh/development/overview.mdx b/zh/development/overview.mdx index 7afd34d6ff..a5eff709e3 100644 --- a/zh/development/overview.mdx +++ b/zh/development/overview.mdx @@ -18,7 +18,7 @@ ComfyUI 是一个模块化的 GenAI 推理引擎,可以部署为 API 服务器 安装 Python 或 TypeScript SDK,提交工作流并下载输出。目前为测试版。 -另请参阅:[设计说明](/zh/development/api-development/sdks-design) · [Comfy API v2 参考](/zh/api-reference/v2/overview) · [API 概述](/zh/development/api-development/overview) +另请参阅:[设计说明](/zh/development/api-development/sdks-design) · [Comfy API v2 参考](/zh/api-reference/v2/overview) ## 部署 ComfyUI 作为 API 服务 @@ -38,7 +38,7 @@ ComfyUI 是一个模块化的 GenAI 推理引擎,可以部署为 API 服务器 了解如何认证、提交任务、查询状态以及从 Comfy Cloud 下载结果。 -另见:[API 参考](/zh/development/cloud/api-reference) · [OpenAPI 规范](/zh/development/cloud/openapi) · [获取 API Key](/zh/development/api-development/getting-an-api-key) · [API 概览](/zh/development/api-development/overview) +另见:[API 参考](/zh/development/cloud/api-reference) · [OpenAPI 规范](/zh/development/cloud/openapi) · [获取 API Key](/zh/development/api-development/getting-an-api-key) ## Agent Tools / MCP