celery-flower-mcp
Provides full control over Celery task queues and workers through the Flower monitoring interface, enabling AI assistants to monitor workers, manage tasks, inspect queues, and control worker pools in real-time.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@celery-flower-mcp list all workers and show their current status"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
๐ธ celery-flower-mcp
Give your AI assistant full control over Celery โ monitor workers, manage tasks, inspect queues.
Features ยท Quick Start ยท Configuration ยท Tools ยท Development ยท Contributing
What is this?
celery-flower-mcp is a Model Context Protocol server that exposes the full Celery Flower REST API as MCP tools. Point it at your Flower instance and your AI assistant (Claude, Cursor, Windsurf, etc.) can:
Monitor workers, tasks, and queues in real time
Control worker pools โ grow, shrink, autoscale, restart, shut down
Manage tasks โ apply, revoke, abort, set timeouts and rate limits
Inspect queues โ check depths, add/remove consumers
All 21 Flower API endpoints are covered.
Related MCP server: OpenAPI MCP Server
Features
Full API coverage โ every Flower REST endpoint exposed as an MCP tool
Dependency injection via dishka โ clean, testable architecture
Pydantic Settings โ typed configuration with
.envfile supportAsync throughout โ built on
httpx+FastMCP65 tests โ 49 unit tests (99% coverage) + 16 integration tests against real Flower
Strict typing โ mypy strict mode, fully annotated
Quick Start
Install via uvx
FLOWER_URL=http://localhost:5555 uvx celery-flower-mcpInstall from source
git clone https://github.com/Darius1223/celery-flower-mcp
cd celery-flower-mcp
uv sync
uv run python -m source.mainClaude Desktop
Add to ~/Library/Application Support/Claude/claude_desktop_config.json:
{
"mcpServers": {
"celery-flower": {
"command": "uvx",
"args": ["celery-flower-mcp"],
"env": {
"FLOWER_URL": "http://localhost:5555"
}
}
}
}Configuration
Configuration is read from environment variables or a .env file in the project root. Copy .env.example to get started:
cp .env.example .envVariable | Default | Description |
|
| Base URL of your Flower instance |
| โ | Basic auth username |
| โ | Basic auth password |
| โ | Bearer token (takes priority over basic auth) |
Available Tools
Workers (8 tools)
Tool | Description |
| List all workers โ optionally filter by name, refresh live stats, or get status only |
| Gracefully shut down a worker |
| Restart a worker's process pool |
| Add N processes to a worker's pool |
| Remove N processes from a worker's pool |
| Configure autoscale min/max bounds |
| Make a worker start consuming from a queue |
| Make a worker stop consuming from a queue |
Tasks (11 tools)
Tool | Description |
| List tasks with filters: state, worker, name, date range, search, pagination |
| List all registered task types across workers |
| Get full details for a task by UUID |
| Retrieve a task's result (with optional timeout) |
| Execute a task synchronously and wait for the result |
| Dispatch a task asynchronously, returns task UUID |
| Send a task by name โ no registration required on worker side |
| Abort a running task |
| Revoke a task; optionally terminate with a signal |
| Set soft and/or hard time limits for a task on a worker |
| Set rate limit for a task on a worker (e.g. |
Queues & Health (2 tools)
Tool | Description |
| Get the current depth of all configured queues |
| Check whether the Flower instance is reachable and healthy |
Architecture
source/
โโโ main.py # FastMCP server entry point + dishka container wiring
โโโ settings.py # Pydantic Settings โ typed config from env / .env
โโโ client.py # Async HTTP client wrapping Flower REST API
โโโ providers.py # dishka Provider โ manages FlowerClient lifecycle
โโโ tools/
โโโ workers.py # 8 worker management tools
โโโ tasks.py # 11 task management tools
โโโ queues.py # 2 queue / health toolsdishka manages the FlowerClient lifecycle: created once at startup, closed cleanly on shutdown via an async generator provider.
Development
make fmt # auto-format with ruff
make lint # lint with ruff
make typecheck # type-check with mypy (strict)
make test # run 49 unit tests
make cov # unit tests + coverage report
make all # fmt + lint + typecheckTesting
The test suite is split into two layers:
Unit tests (tests/) โ fast, no external dependencies, use pytest-httpx to mock HTTP calls:
make test
# or
uv run pytest tests/ -m "not integration"Integration tests (tests/integration/) โ run against a real Flower instance backed by Redis and a live Celery worker, all managed by Docker Compose:
make integrationThis command:
Builds and starts the Docker Compose stack (
docker-compose.test.yml) โ Redis โ Celery worker โ FlowerWaits for Flower's
/healthcheckendpoint to return OKRuns the 16 integration tests against
http://localhost:5555Tears down the stack when done
The stack is defined in docker-compose.test.yml. The worker and Flower images are built from tests/integration/Dockerfile.worker and tests/integration/Dockerfile.flower.
To start the stack manually for exploratory testing:
docker compose -f docker-compose.test.yml up -d --build
# run tests, explore, etc.
make integration-down # stop + remove volumesIntegration tests use pytest.mark.asyncio(loop_scope="session") so all tests share one event loop โ this avoids RuntimeError: Event loop is closed when httpx transports are cleaned up across test boundaries on Python 3.14.
See CONTRIBUTING.md for details on adding new tools or submitting a PR.
Changelog
See CHANGELOG.md.
License
Available Tools
21 toolsabort_taskC
Abort a running task.
Inputs: task_id (required). Returns: result
add_queue_consumerC
Make a worker start consuming from a queue.
Inputs: workername (required), queue (required). Returns: result
apply_taskA
Execute a task synchronously and wait for the result.
Inputs: taskname (required), args, kwargs, options. Returns: result
async_apply_taskC
Execute a task asynchronously and return its task ID.
Inputs: taskname (required), args, kwargs, options. Returns: result
autoscale_worker_poolB
Set autoscale bounds for a worker's pool.
Inputs: workername (required), min (required), max (required). Returns: result
cancel_queue_consumerC
Make a worker stop consuming from a queue.
Inputs: workername (required), queue (required). Returns: result
get_queue_lengthsA
Get the current length of all Celery queues.
Inputs: no named parameters. Returns: result
get_task_infoC
Get detailed information about a task by its ID.
Inputs: task_id (required). Returns: result
get_task_resultC
Get the result of a task.
Inputs: task_id (required), timeout. Returns: result
grow_worker_poolC
Grow a worker's process pool by n processes.
Inputs: workername (required), n. Returns: result
healthcheckA
Check whether the Flower instance is healthy.
Inputs: no named parameters. Returns: result
list_tasksC
List tasks with optional filters.
Inputs: limit, offset, workername, taskname, +5 more. Returns: result
list_task_typesA
List all registered task types.
Inputs: no named parameters. Returns: result
list_workersC
List all Celery workers.
Inputs: refresh, workername, status. Returns: result
restart_worker_poolC
Restart a worker's process pool.
Inputs: workername (required). Returns: result
revoke_taskC
Revoke a task, optionally terminating it if running.
Inputs: task_id (required), terminate, signal. Returns: result
send_taskB
Send a task via send_task (does not require task to be registered on the worker).
Inputs: taskname (required), args, kwargs, options. Returns: result
set_task_rate_limitC
Change the rate limit for a task on a worker.
Inputs: taskname (required), workername (required), ratelimit (required). Returns: result
set_task_timeoutC
Change soft and hard time limits for a task on a worker.
Inputs: taskname (required), workername (required), soft, hard. Returns: result
shrink_worker_poolB
Shrink a worker's process pool by n processes.
Inputs: workername (required), n. Returns: result
shutdown_workerB
Shut down a Celery worker.
Inputs: workername (required). Returns: result
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelogโฆ
TDQS
Scored across 21 tools
Most tools are distinct (e.g., list_workers vs. shutdown_worker), but some overlap exists: create_task vs. apply_task vs. async_apply_task could be confused, and get_task_result vs. get_task_info are similar. However, descriptions clarify the differences.
The majority follow a clear verb_noun pattern (list_*, get_*, set_*, create_, apply_*, etc.). There are minor deviations like 'healthcheck' (instead of check_health) and 'autoscale_worker_pool' (verb+noun with no underscore), but overall consistent.
21 tools is on the higher side but justified given the breadth of Celery/Flower management (workers, tasks, queues, health). The count is within the heavy range but not excessive for a complex domain.
The surface covers worker management (list, shutdown, restart, scale), task lifecycle (apply, send, revoke, abort, get results), and queue control (add/cancel consumer, get lengths). Missing: task retry or purge, but most essential operations are present.
Maintenance
Related MCP Connectors
Nifty's MCP server โ exposes tasks, projects, messages, and files as tools for AI agents.
MCP server for your apps' tools and custom tools, plus hosted AI agents and approval-gated workflows
MCP server for OpenAI API (chat completions, image generation, embeddings) via AceDataCloud
MCP server that lets AI assistants use all OneSchema features exposed via the public API.
Related MCP Servers
AlicenseAqualityFmaintenanceAn MCP server that enables AI assistants to interact with Apache Airflow's REST API for DAG management, task monitoring, and system diagnostics. It provides comprehensive tools for triggering workflows, retrieving logs, and inspecting system health across Airflow 2.x and 3.x versions.3113Apache 2.0- AlicenseAqualityDmaintenanceA generic MCP server that dynamically exposes any OpenAPI-documented REST API to LLMs by auto-discovering endpoints. It provides tools for exploring API capabilities and making authenticated requests directly through natural language interfaces.25 npmMIT

VoIPbin MCP Serverofficial
AlicenseBqualityBmaintenanceAn MCP server that enables AI assistants to interact with the VoIPbin CPaaS platform, exposing tools for managing calls, flows, messaging, conferencing, and more.662MIT- AlicenseNot gradedqualityDmaintenanceMCP Server for interacting with the Langflow API via a natural language interface. It exposes Langflow functionalities as tools for LLMs.MIT