---
title: 透過 RunAPI 在 WorkBuddy 使用 Flux 2——MCP 圖像指南 | RunAPI
description: 透過 RunAPI 使用 MCP 在 WorkBuddy 以 Black Forest Labs 的 Flux 2 產生圖像。可從工作台使用文字轉圖像及多來源 remix 工具。
url: https://runapi.ai/zh-HK/workbuddy-flux-2.md
canonical: https://runapi.ai/zh-HK/workbuddy-flux-2
locale: zh-HK
site: RunAPI
image: https://runapi.ai/assets/opengraph-bfaaa0f0.png
alternates:
  en: https://runapi.ai/workbuddy-flux-2
  zh-CN: https://runapi.ai/zh-CN/workbuddy-flux-2
  es: https://runapi.ai/es/workbuddy-flux-2
  ja: https://runapi.ai/ja/workbuddy-flux-2
  de: https://runapi.ai/de/workbuddy-flux-2
  fr: https://runapi.ai/fr/workbuddy-flux-2
  pt-BR: https://runapi.ai/pt-BR/workbuddy-flux-2
  ko: https://runapi.ai/ko/workbuddy-flux-2
  it: https://runapi.ai/it/workbuddy-flux-2
  nl: https://runapi.ai/nl/workbuddy-flux-2
  pl: https://runapi.ai/pl/workbuddy-flux-2
  tr: https://runapi.ai/tr/workbuddy-flux-2
  zh-TW: https://runapi.ai/zh-TW/workbuddy-flux-2
  zh-HK: https://runapi.ai/zh-HK/workbuddy-flux-2
  ar: https://runapi.ai/ar/workbuddy-flux-2
  x-default: https://runapi.ai/workbuddy-flux-2
model: flux-2
---

> HTML version: https://runapi.ai/zh-HK/workbuddy-flux-2
> Site index for agents: https://runapi.ai/llms.txt


# 在 WorkBuddy 使用 Flux 2。

Black Forest Labs 的 Flux 2 提供多個品質版本，涵蓋由較快速的生成到更高保真度的輸出。每個版本均支援文字轉圖像及多來源 remix，Flux 2 模型目錄列出每個版本支援的解析度及當前定價。WorkBuddy 可直接從工作台將它們作為 RunAPI MCP server 上的工具呼叫。

- [取得 API Key](https://runapi.ai/zh-HK/login)
- [閱讀文件](https://runapi.ai/zh-HK/docs/guides)

一個 API key · 文字轉圖像 + remix 工具 · 1k / 2k 解析度（Max 僅 1k）

### 提示詞

```text
Use the runapi MCP server to generate an image with Flux 2 Pro.

Requirements:
- Call the RunAPI text_to_image tool with model "flux-2-pro-text-to-image"
- Prompt: a ceramic vase with dried flowers on a linen tablecloth, natural window light, 35mm film grain
- Set aspect_ratio to "3:4" and output_resolution to "2k"
- Wait for the task to complete and show me the image URL

```

### MCP 設定

```bash
{
  "mcpServers": {
    "runapi": {
      "url": "https://runapi.ai/mcp",
      "transport": "streamable_http",
      "headers": {
        "Authorization": "Bearer ${RUNAPI_API_KEY}"
      }
    }
  }
}

```

### 回應

```json
{
  "task_id": "tsk_abc123",
  "status": "completed",
  "model": "flux-2-pro-text-to-image",
  "output": {
    "image_url": "https://media.runapi.ai/outputs/tsk_abc123.png"
  }
}

```

## 三步在 WorkBuddy 使用 Flux 2

1. **新增 RunAPI MCP 伺服器** - 在 WorkBuddy 註冊一個名為 runapi 的 MCP server，透過 streamable HTTP 指向 https://runapi.ai/mcp，並讓 Authorization header 從 RUNAPI_API_KEY 讀取你的金鑰。若 RunAPI 已連接供 chat 使用，同一個 server 已提供 Flux 2——無需額外設定。 `url: https://runapi.ai/mcp
auth: Bearer ${RUNAPI_API_KEY}
`
2. **提示工作台代理** - 要求 WorkBuddy 呼叫 RunAPI text_to_image 工具，將 model 設為 flux-2-pro-text-to-image。加入 prompt，亦可選擇加入 aspect_ratio（1:1、4:3、16:9 等）及 output_resolution（1k 或 2k；Flux 2 Max 僅支援 1k）。如要進行多來源 remix，則要求 agent 改用帶有 source_image_urls 的 remix_image 工具。 `tool: text_to_image · model: flux-2-pro-text-to-image`
3. **取得結果** - MCP 伺服器會建立任務，追蹤至完成後將已完成的圖像 URL 傳回 WorkBuddy。代理會在對話中顯示該 URL——您無需手動輪詢。 `task_id: tsk_abc123 → completed`

## Flux 2 工具參數

| 參數 | 類型 | 說明 |
| --- | --- | --- |
| `model` | `string` | 必填。對應工具的 Flux 2 模型 ID，例如 flux-2-pro-text-to-image 或 flux-2-pro-remix-image。Flux 2 模型目錄列出所有可用版本。 |
| `prompt` | `string` | 要生成圖像的文字描述。 |
| `aspect_ratio` | `string` | 可選。輸出長寬比：1:1、4:3、3:4、16:9、9:16、3:2 或 2:3。Remix 工具亦接受 auto。 |
| `output_resolution` | `string` | 選填。預設為 1k。可用值因版本而異，請參閱 Flux 2 模型目錄。Flex 及 Pro 的 2k 每張圖像成本高於 1k。 |
| `source_image_urls` | `array` | remix_image 必填。用於混合或變換的來源圖像 URL 陣列。 |
| `callback_url` | `string` | 可選。用於非同步完成通知的 Webhook URL。 |

## WorkBuddy 上的 Flux 2 是甚麼？

Black Forest Labs 的 Flux 2 是可投入製作的圖像模型；用戶表示其「寫實感勝過 Midjourney」，材質保真度足以媲美真實攝影。它具備多參考圖條件控制及 4-megapixel 輸出，因此無需 fine-tuning 亦可取得品牌一致的結果。WorkBuddy 透過 RunAPI MCP server 將它作為工具存取，因此在工作台輸入文字簡報後，即可取得完成圖像的 URL。

## Flux 2 使用場景

- **電商產品攝影** - 產生看似真正影樓拍攝的產品相片及背景替換圖，取代目錄頁及商品列表所需的手動攝影——一切只需透過 WorkBuddy prompt 提出。
- **跨市場廣告本地化** - 從相同提示詞結構為 30 多個市場生成本地化廣告視覺，替換文字與文化參考，同時保持品牌一致性。
- **雜誌封面與編輯圖像** - 製作雜誌品質封面，圖像上的文字排版直接融入生成圖像，而非事後合成。

## Flux 2 + WorkBuddy 常見問題

### Flux 2 各個版本有何分別？

各版本在生成速度、輸出保真度及價格方面有所不同。每個版本均在同一個 RunAPI MCP server 提供 text_to_image 及 remix_image 工具。Flux 2 模型目錄中的版本表列出每個版本支援的參數及當前價格。

### Flux 2 圖像生成需要獨立的 MCP server 嗎？

不需要。你為 chat 加入的 runapi MCP server 已將 Flux 2 及所有其他 RunAPI 模型提供為可呼叫工具。同一個 RUNAPI_API_KEY 涵蓋 LLM、圖像、影片及音樂請求。

### Flux 2 輸出解析度是否影響定價？

視乎版本。Flux 2 Flex 及 Flux 2 Pro 按張計費，2k 比 1k 貴。Flux 2 Max 只輸出 1k，按單一價格按張計費。當前費率請參閱 Flux 2 模型目錄或 RunAPI 定價頁面。

### Flux 2 與 Flux Kontext 有何分別？

Flux Kontext 專注於以文字引導編輯圖像，以及透過單一輸入圖像維持角色一致性。Flux 2 則專注於文字轉圖像生成及多來源 remix，提供多個品質版本及可選輸出解析度。兩者均由 Black Forest Labs 開發，並可作為同一個 RunAPI MCP server 上的工具使用。

### WorkBuddy 中由誰處理異步任務輪詢？

由 RunAPI MCP server 處理。Flux 2 tasks 為 async，但 server 會追蹤每個 task 至完成，並將完成圖像的 URL 回傳至 WorkBuddy，因此你無需在工作台手動輪詢。


- [WorkBuddy 設定指南 →](https://runapi.ai/zh-HK/workbuddy.md) - 尚未連接？請先參閱 WorkBuddy 的 RunAPI MCP 設定指南。
- [Flux 2 模型 →](https://runapi.ai/zh-HK/models/flux-2.md) - 查看所有 Flux 2 版本、定價及 API 文件。

## 立即在 WorkBuddy 試用 Flux 2。

取得免費 RunAPI key，將 MCP server 加入 WorkBuddy，然後開始使用 Flux 2 產生圖像。

[瀏覽模型 →](https://runapi.ai/zh-HK/models.md)

---

## More from RunAPI

- [Home](https://runapi.ai/zh-HK/.md)
### 產品
- [模型目錄](https://runapi.ai/zh-HK/models.md)
- [收費](https://runapi.ai/zh-HK/pricing.md)
- [服務商](https://runapi.ai/zh-HK/models#all-models)
### 開發者
- [文件](https://runapi.ai/zh-HK/docs/guides)
- [SDK](https://runapi.ai/zh-HK/sdk.md)
- [CLI](https://runapi.ai/zh-HK/cli.md)
- [MCP Server](https://runapi.ai/zh-HK/mcp.md)
- [x402](https://runapi.ai/zh-HK/x402.md)
### 指南
- [Claude Code 與 Cursor](https://runapi.ai/zh-HK/claude-code-vs-cursor.md)
- [Cursor API 設定](https://runapi.ai/zh-HK/cursor-api-setup.md)
- [RunAPI 與 OpenRouter](https://runapi.ai/zh-HK/openrouter-alternative.md)
### 公司
- [企業版](https://runapi.ai/zh-HK/contact.md)
- [聯絡](https://runapi.ai/zh-HK/contact.md)
### 法律
- [條款](https://runapi.ai/zh-HK/terms.md)
- [私隱](https://runapi.ai/zh-HK/privacy.md)
- [Site index for agents](https://runapi.ai/llms.txt)

Contact: contact@runapi.ai

## Structured data

```json
[
  {
    "@context": "https://schema.org",
    "inLanguage": "zh-HK",
    "@type": "WebSite",
    "name": "RunAPI",
    "url": "https://runapi.ai/zh-HK",
    "potentialAction": {
      "@type": "SearchAction",
      "target": {
        "@type": "EntryPoint",
        "urlTemplate": "https://runapi.ai/zh-HK/models?q={search_term_string}"
      },
      "query-input": "required name=search_term_string"
    }
  },
  {
    "@context": "https://schema.org",
    "inLanguage": "zh-HK",
    "@type": "Organization",
    "name": "RunAPI",
    "url": "https://runapi.ai/zh-HK",
    "logo": {
      "@type": "ImageObject",
      "url": "https://runapi.ai/zh-HKicon.svg"
    },
    "sameAs": [
      "https://github.com/runapi-ai"
    ]
  },
  {
    "@context": "https://schema.org",
    "inLanguage": "zh-HK",
    "@type": "SoftwareApplication",
    "name": "適用於 WorkBuddy 的 RunAPI Flux 2",
    "applicationCategory": "DeveloperApplication",
    "description": "透過 RunAPI 使用 MCP 在 WorkBuddy 以 Black Forest Labs 的 Flux 2 產生圖像。可從工作台使用文字轉圖像及多來源 remix 工具。",
    "url": "https://runapi.ai/zh-HK/workbuddy-flux-2"
  },
  {
    "@context": "https://schema.org",
    "inLanguage": "zh-HK",
    "@type": "FAQPage",
    "mainEntity": [
      {
        "@type": "Question",
        "name": "Flux 2 各個版本有何分別？",
        "acceptedAnswer": {
          "@type": "Answer",
          "text": "各版本在生成速度、輸出保真度及價格方面有所不同。每個版本均在同一個 RunAPI MCP server 提供 text_to_image 及 remix_image 工具。Flux 2 模型目錄中的版本表列出每個版本支援的參數及當前價格。"
        }
      },
      {
        "@type": "Question",
        "name": "Flux 2 圖像生成需要獨立的 MCP server 嗎？",
        "acceptedAnswer": {
          "@type": "Answer",
          "text": "不需要。你為 chat 加入的 runapi MCP server 已將 Flux 2 及所有其他 RunAPI 模型提供為可呼叫工具。同一個 RUNAPI_API_KEY 涵蓋 LLM、圖像、影片及音樂請求。"
        }
      },
      {
        "@type": "Question",
        "name": "Flux 2 輸出解析度是否影響定價？",
        "acceptedAnswer": {
          "@type": "Answer",
          "text": "視乎版本。Flux 2 Flex 及 Flux 2 Pro 按張計費，2k 比 1k 貴。Flux 2 Max 只輸出 1k，按單一價格按張計費。當前費率請參閱 Flux 2 模型目錄或 RunAPI 定價頁面。"
        }
      },
      {
        "@type": "Question",
        "name": "Flux 2 與 Flux Kontext 有何分別？",
        "acceptedAnswer": {
          "@type": "Answer",
          "text": "Flux Kontext 專注於以文字引導編輯圖像，以及透過單一輸入圖像維持角色一致性。Flux 2 則專注於文字轉圖像生成及多來源 remix，提供多個品質版本及可選輸出解析度。兩者均由 Black Forest Labs 開發，並可作為同一個 RunAPI MCP server 上的工具使用。"
        }
      },
      {
        "@type": "Question",
        "name": "WorkBuddy 中由誰處理異步任務輪詢？",
        "acceptedAnswer": {
          "@type": "Answer",
          "text": "由 RunAPI MCP server 處理。Flux 2 tasks 為 async，但 server 會追蹤每個 task 至完成，並將完成圖像的 URL 回傳至 WorkBuddy，因此你無需在工作台手動輪詢。"
        }
      }
    ]
  },
  {
    "@context": "https://schema.org",
    "inLanguage": "zh-HK",
    "@type": "HowTo",
    "name": "如何透過 RunAPI 在 WorkBuddy 使用 Flux 2",
    "description": "在 WorkBuddy 將 RunAPI 加入為 MCP server，提示工作台 agent 呼叫 Flux 2 text_to_image 或 remix_image 工具，並取得生成的圖像 URL。",
    "step": [
      {
        "@type": "HowToStep",
        "position": 1,
        "name": "新增 RunAPI MCP 伺服器",
        "text": "在 WorkBuddy 註冊一個名為 runapi 的 MCP server，透過 streamable HTTP 指向 https://runapi.ai/mcp，並讓 Authorization header 從 RUNAPI_API_KEY 讀取你的金鑰。若 RunAPI 已連接供 chat 使用，同一個 server 已提供 Flux 2——無需額外設定。",
        "url": "https://runapi.ai/zh-HK/workbuddy-flux-2#how-step-1"
      },
      {
        "@type": "HowToStep",
        "position": 2,
        "name": "提示工作台代理",
        "text": "要求 WorkBuddy 呼叫 RunAPI text_to_image 工具，將 model 設為 flux-2-pro-text-to-image。加入 prompt，亦可選擇加入 aspect_ratio（1:1、4:3、16:9 等）及 output_resolution（1k 或 2k；Flux 2 Max 僅支援 1k）。如要進行多來源 remix，則要求 agent 改用帶有 source_image_urls 的 remix_image 工具。",
        "url": "https://runapi.ai/zh-HK/workbuddy-flux-2#how-step-2"
      },
      {
        "@type": "HowToStep",
        "position": 3,
        "name": "取得結果",
        "text": "MCP 伺服器會建立任務，追蹤至完成後將已完成的圖像 URL 傳回 WorkBuddy。代理會在對話中顯示該 URL——您無需手動輪詢。",
        "url": "https://runapi.ai/zh-HK/workbuddy-flux-2#how-step-3"
      }
    ]
  },
  {
    "@context": "https://schema.org",
    "inLanguage": "zh-HK",
    "@type": "BreadcrumbList",
    "itemListElement": [
      {
        "@type": "ListItem",
        "position": 1,
        "name": "主頁",
        "item": "https://runapi.ai/zh-HK"
      },
      {
        "@type": "ListItem",
        "position": 2,
        "name": "適用於 WorkBuddy 的 RunAPI Flux 2",
        "item": "https://runapi.ai/zh-HK/workbuddy-flux-2"
      }
    ]
  }
]
```
