Skip to main content
Glama

FluxMCP

PyPI version PyPI downloads CI License: MIT MCP Python 3.10+

Ein Model Context Protocol (MCP)-Server für KI-Bildgenerierung und -bearbeitung mit Flux über die AceDataCloud-Plattform.

Erstelle und bearbeite beeindruckende KI-Bilder mit Flux-Modellen (flux-dev, flux-pro, flux-kontext) direkt von Claude, Cursor oder jedem MCP-kompatiblen Client.

Funktionen

  • Bildgenerierung – Bilder aus Text-Prompts mit 6 Flux-Modellen generieren

  • Bildbearbeitung – Vorhandene Bilder mit kontextbewussten Flux-Kontext-Modellen bearbeiten

  • Aufgabenverwaltung – Asynchrone Generierungsaufgaben und Stapelstatusabfragen verfolgen

  • Modellführer – Integrierte Anleitung zur Modellauswahl und Prompt-Erstellung

  • Dualer Transport – stdio (lokal) und HTTP (remote/cloud) Modi

  • Docker-bereit – Containerisiert mit K8s-Bereitstellungsmanifesten

  • Sicher – Bearer-Token-Authentifizierung mit Anforderungsisolierung im HTTP-Modus

Related MCP server: DiffuGen

Tool-Referenz

Tool

Beschreibung

flux_generate_image

KI-Bilder aus einem Text-Prompt mit Flux generieren.

flux_edit_image

Ein vorhandenes Bild mit Flux und einem Text-Prompt bearbeiten.

flux_list_models

Alle verfügbaren Flux-Modelle und ihre Fähigkeiten auflisten.

flux_list_actions

Alle verfügbaren Flux-Tools und ihre Anwendungsfälle auflisten.

flux_get_task

Status und Ergebnis einer Flux-Bildgenerierungsaufgabe abfragen.

flux_get_tasks_batch

Mehrere Flux-Bildgenerierungsaufgaben gleichzeitig abfragen.

Schnellstart

1. API-Token erhalten

  1. Registriere dich auf der AceDataCloud-Plattform

  2. Gehe zur API-Dokumentationsseite

  3. Klicke auf „Abrufen“, um dein API-Token zu erhalten

  4. Kopiere das Token für die spätere Verwendung

2. Gehosteten Server verwenden (empfohlen)

AceDataCloud hostet einen verwalteten MCP-Server – keine lokale Installation erforderlich.

Endpunkt: https://flux.mcp.acedata.cloud/mcp

Alle Anfragen erfordern ein Bearer-Token. Verwende das API-Token aus Schritt 1.

Claude.ai

Verbinde dich direkt auf Claude.ai mit OAuth – kein API-Token erforderlich:

  1. Gehe zu Claude.ai Einstellungen → Integrationen → Weitere hinzufügen

  2. Gib die Server-URL ein: https://flux.mcp.acedata.cloud/mcp

  3. Schließe den OAuth-Anmeldevorgang ab

  4. Beginne, die Tools in deinem Gespräch zu verwenden

Claude Desktop

Füge zu deiner Konfiguration hinzu (~/Library/Application Support/Claude/claude_desktop_config.json auf macOS):

{
  "mcpServers": {
    "flux": {
      "type": "streamable-http",
      "url": "https://flux.mcp.acedata.cloud/mcp",
      "headers": {
        "Authorization": "Bearer YOUR_API_TOKEN"
      }
    }
  }
}

Cursor / Windsurf

Füge zu deiner MCP-Konfiguration hinzu (.cursor/mcp.json oder .windsurf/mcp.json):

{
  "mcpServers": {
    "flux": {
      "type": "streamable-http",
      "url": "https://flux.mcp.acedata.cloud/mcp",
      "headers": {
        "Authorization": "Bearer YOUR_API_TOKEN"
      }
    }
  }
}

VS Code (Copilot)

Füge zu deiner VS-Code-MCP-Konfiguration hinzu (.vscode/mcp.json):

{
  "servers": {
    "flux": {
      "type": "streamable-http",
      "url": "https://flux.mcp.acedata.cloud/mcp",
      "headers": {
        "Authorization": "Bearer YOUR_API_TOKEN"
      }
    }
  }
}

Oder installiere die Ace Data Cloud MCP-Erweiterung für VS Code, die die gehosteten MCP-Server mit einem Klick registriert.

JetBrains-IDEs

  1. Gehe zu Einstellungen → Tools → KI-Assistent → Model Context Protocol (MCP)

  2. Klicke auf Hinzufügen → HTTP

  3. Füge ein:

{
  "mcpServers": {
    "flux": {
      "url": "https://flux.mcp.acedata.cloud/mcp",
      "headers": {
        "Authorization": "Bearer YOUR_API_TOKEN"
      }
    }
  }
}

Claude Code

Claude Code unterstützt MCP-Server nativ:

claude mcp add flux --transport http https://flux.mcp.acedata.cloud/mcp \
  -h "Authorization: Bearer YOUR_API_TOKEN"

Oder füge zu .mcp.json deines Projekts hinzu:

{
  "mcpServers": {
    "flux": {
      "type": "streamable-http",
      "url": "https://flux.mcp.acedata.cloud/mcp",
      "headers": {
        "Authorization": "Bearer YOUR_API_TOKEN"
      }
    }
  }
}

Cline

Füge zu Clines MCP-Einstellungen hinzu (.cline/mcp_settings.json):

{
  "mcpServers": {
    "flux": {
      "type": "streamable-http",
      "url": "https://flux.mcp.acedata.cloud/mcp",
      "headers": {
        "Authorization": "Bearer YOUR_API_TOKEN"
      }
    }
  }
}

Amazon Q Developer

Füge zu deiner MCP-Konfiguration hinzu:

{
  "mcpServers": {
    "flux": {
      "type": "streamable-http",
      "url": "https://flux.mcp.acedata.cloud/mcp",
      "headers": {
        "Authorization": "Bearer YOUR_API_TOKEN"
      }
    }
  }
}

Roo Code

Füge zu den Roo-Code-MCP-Einstellungen hinzu:

{
  "mcpServers": {
    "flux": {
      "type": "streamable-http",
      "url": "https://flux.mcp.acedata.cloud/mcp",
      "headers": {
        "Authorization": "Bearer YOUR_API_TOKEN"
      }
    }
  }
}

Continue.dev

Füge zu .continue/config.yaml hinzu:

mcpServers:
  - name: flux
    type: streamable-http
    url: https://flux.mcp.acedata.cloud/mcp
    headers:
      Authorization: "Bearer YOUR_API_TOKEN"

Zed

Füge zu Zeds Einstellungen hinzu (~/.config/zed/settings.json):

{
  "language_models": {
    "mcp_servers": {
      "flux": {
        "url": "https://flux.mcp.acedata.cloud/mcp",
        "headers": {
          "Authorization": "Bearer YOUR_API_TOKEN"
        }
      }
    }
  }
}

cURL-Test

# Health check (no auth required)
curl https://flux.mcp.acedata.cloud/health

# MCP initialize
curl -X POST https://flux.mcp.acedata.cloud/mcp \
  -H "Content-Type: application/json" \
  -H "Accept: application/json" \
  -H "Authorization: Bearer YOUR_API_TOKEN" \
  -d '{"jsonrpc":"2.0","id":1,"method":"initialize","params":{"protocolVersion":"2025-03-26","capabilities":{},"clientInfo":{"name":"test","version":"1.0"}}}'

3. Oder lokal ausführen (Alternative)

Wenn du den Server lieber auf deinem eigenen Rechner ausführen möchtest:

# Install from PyPI
pip install mcp-flux-pro
# or
uvx mcp-flux-pro

# Set your API token
export ACEDATACLOUD_API_TOKEN="your_token_here"

# Run (stdio mode for Claude Desktop / local clients)
mcp-flux-pro

# Run (HTTP mode for remote access)
mcp-flux-pro --transport http --port 8000

Claude Desktop (Lokal)

{
  "mcpServers": {
    "flux": {
      "command": "uvx",
      "args": ["mcp-flux-pro"],
      "env": {
        "ACEDATACLOUD_API_TOKEN": "your_token_here"
      }
    }
  }
}

Docker (Selbsthosting)

docker pull ghcr.io/acedatacloud/mcp-flux-pro:latest
docker run -p 8000:8000 ghcr.io/acedatacloud/mcp-flux-pro:latest

Clients verbinden sich mit ihrem eigenen Bearer-Token – der Server extrahiert das Token aus dem Authorization-Header jeder Anfrage.

Verfügbare Tools

Tool

Beschreibung

flux_generate_image

Bilder aus Text-Prompts mit Modellauswahl generieren

flux_edit_image

Vorhandene Bilder mit Textanweisungen bearbeiten

flux_get_task

Status einer einzelnen Generierungsaufgabe abfragen

flux_get_tasks_batch

Status mehrerer Aufgaben gleichzeitig abfragen

flux_list_models

Alle verfügbaren Flux-Modelle und Fähigkeiten auflisten

flux_list_actions

Alle Tools und Workflow-Beispiele anzeigen

Verfügbare Prompts

Prompt

Beschreibung

flux_image_generation_guide

Anleitung zur Auswahl des richtigen Tools und Modells

flux_prompt_writing_guide

Best Practices für effektive Prompts

flux_workflow_examples

Häufige Workflow-Muster und Beispiele

Unterstützte Modelle

Modell

Qualität

Geschwindigkeit

Größenformat

Am besten geeignet für

flux-dev

Gut

Schnell

Pixel (256-1440px)

Schnelles Prototyping

flux-pro

Hoch

Mittel

Pixel (256-1440px)

Produktionseinsatz

flux-kontext-pro

Hoch

Mittel

Seitenverhältnisse

Bildbearbeitung

flux-kontext-max

Höchste

Langsamer

Seitenverhältnisse

Komplexe Bearbeitung

flux-2-flex

Hoch

Schnell

Seitenverhältnisse

Flux 2 ausgewogene Qualität

flux-2-pro

Höher

Mittel

Seitenverhältnisse

Flux 2 Produktion

flux-2-max

Höchste

Langsamer

Seitenverhältnisse

Flux 2 maximale Qualität

flux-2-klein

Gut

Schnell

Seitenverhältnisse

Flux 2 effiziente Ausgabe

Verwendungsbeispiele

Ein Bild generieren

"Generate a photorealistic mountain landscape at golden hour"
→ flux_generate_image(prompt="...", model="flux-2-max", size="16:9")

Ein Bild bearbeiten

"Add sunglasses to the person in this photo"
→ flux_edit_image(prompt="Add sunglasses", image_url="https://...", size="1:1", model="flux-kontext-pro")

Aufgabenstatus prüfen

"What's the status of my generation?"
→ flux_get_task(task_id="...")

Umgebungsvariablen

Variable

Erforderlich

Standard

Beschreibung

ACEDATACLOUD_API_TOKEN

Ja (stdio)

—

API-Token von AceDataCloud

ACEDATACLOUD_API_BASE_URL

Nein

https://api.acedata.cloud

API-Basis-URL

ACEDATACLOUD_OAUTH_CLIENT_ID

Nein

—

OAuth-Client-ID (gehosteter Modus)

ACEDATACLOUD_PLATFORM_BASE_URL

Nein

https://platform.acedata.cloud

Plattform-Basis-URL

FLUX_REQUEST_TIMEOUT

Nein

1800

Anforderungs-Timeout in Sekunden

MCP_SERVER_NAME

Nein

flux

MCP-Servername

LOG_LEVEL

Nein

INFO

Protokollierungsstufe

Entwicklung

Einrichtung

git clone https://github.com/AceDataCloud/FluxMCP.git
cd FluxMCP
pip install -e ".[all]"
cp .env.example .env
# Edit .env with your API token

Lint & Format

ruff check .
ruff format .
mypy core tools main.py

Test

# Unit tests
pytest --cov=core --cov=tools

# Skip integration tests
pytest -m "not integration"

# With coverage report
pytest --cov=core --cov=tools --cov-report=html

Git-Hooks

git config core.hooksPath .githooks

API-Referenz

Dieser MCP-Server verwendet die AceDataCloud-Flux-API:

  • POST /flux/images – Bilder generieren oder bearbeiten

  • POST /flux/tasks – Aufgabenstatus abfragen (einzeln oder stapelweise)

Vollständige API-Dokumentation: platform.acedata.cloud

Dokumentation

Dokumentation

Lizenz

MIT-Lizenz – siehe LICENSE für Details.

Available Tools

7 tools
flux_edit_imageAInspect

Edit an existing image using Flux with a text prompt.

This allows you to modify an existing image based on a text description.
The kontext models (flux-kontext-pro, flux-kontext-max) are specifically
designed for high-quality image editing and style transfer.

Use this when:
- You want to modify or transform an existing image
- You want to change specific elements in an image
- You want to apply style changes or artistic effects
- You want to add, remove, or replace objects in an image

For generating new images from scratch, use flux_generate_image instead.

Returns:
    Task ID and edited image information including URLs.

Inputs: size (required), prompt (required), image_url (required), model, +1 more. Returns: result

flux_generate_imageAInspect

Generate AI images from a text prompt using Flux.

Flux is a family of fast, high-quality image generation models by Black Forest Labs.
Different models offer different tradeoffs between speed, quality, and capabilities.

Use this when:
- You want to create new images from a text description
- You need high-quality AI-generated artwork or photos
- You want fast image generation with good prompt following

For editing existing images, use flux_edit_image instead.

Returns:
    Task ID and generated image information including URLs.

Inputs: size (required), prompt (required), count, model, +1 more. Returns: result

flux_generate_videoBInspect

Generate text/image/video-to-video or enhance an owned temporary draft. Poll flux_get_task.

Inputs: request (required). Returns: result

flux_get_taskAInspect

Query the status and result of a Flux image or video generation task.

Use this to check if a generation is complete and retrieve the resulting
image/video URLs and metadata.

Use this when:
- You want to check if an image generation has completed
- You need to retrieve image URLs from a previous generation
- You used async callback and want to check results later
- The initial generation returned a task_id without immediate results

Returns:
    Task status and generation result including image URLs.

Inputs: task_id (required). Returns: result

flux_get_tasks_batchAInspect

Query multiple Flux image or video generation tasks at once.

Efficiently check the status of multiple tasks in a single request.
More efficient than calling flux_get_task multiple times.

Use this when:
- You have multiple pending generations to check
- You want to get status of several images at once
- You're tracking a batch of generations

Returns:
    Status and result information for all queried tasks.

Inputs: task_ids (required). Returns: result

flux_list_actionsAInspect

List all available Flux tools and their use cases.

Reference guide for what each tool does and when to use it.

Returns:
    Categorized list of all tools with descriptions.

Inputs: no named parameters. Returns: result

flux_list_modelsAInspect

List all available Flux models and their capabilities.

Reference guide for choosing the right Flux model for your use case.

Returns:
    Detailed list of all Flux models with descriptions and recommendations.

Inputs: no named parameters. Returns: result

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A4/5.0

    Scored across 7 tools

    Disambiguation4/5

    The core tools are clearly separated: generate vs edit vs video generation, and single-task vs batch task queries are explicitly distinguished. Minor overlap exists because flux_generate_video bundles several video workflows and flux_get_tasks_batch could be seen as an optimization of flux_get_task, but descriptions make the intended boundaries clear.

    Naming Consistency5/5

    All tools follow a consistent flux_verb_noun snake_case pattern, such as flux_generate_image, flux_edit_image, flux_get_task, and flux_list_models. The convention is predictable throughout.

    Tool Count5/5

    Seven tools is well-scoped for an image/video generation service. The set covers generation, editing, task polling, batch polling, and reference discovery without obvious padding.

    Completeness4/5

    The surface covers the main lifecycle: generate/edit media, generate video, poll tasks, batch poll, and discover models/actions. Minor gaps remain around cancellation or listing existing tasks, but core workflows appear supported.

    Maintenance

    ActivityNo data
    ResponsivenessOutdated data

    Related MCP Connectors

    Related MCP Servers