Sandbox
@SystemCraftsman/strimzi-kafka-cli

CLI and MCP server for Strimzi Kafka Operator

This repo provides the `kfk` command for working with Strimzi-managed Kafka on Kubernetes. It covers Kafka clusters, topics, users, Kafka Connect, MirrorMaker2, ACLs, backups, node pools, and operator install and uninstall.

92 stars14 forksPythonUpdated 1mo ago
Who it's for

Builders who manage Kafka on Kubernetes and want a Strimzi-focused CLI or MCP server.

What it delivers

You can manage Strimzi Kafka resources from a single command line or connect them to an agent through MCP.

What it does

Kafka resource commands

Create, alter, delete, and describe Kafka clusters, topics, users, and node pools.

Connect and MirrorMaker2 commands

Manage Kafka Connect clusters, connectors, and MirrorMaker2 resources.

Backup and restore

Back up and restore Kafka and Connect related Strimzi resources.

ACL and config management

Add or remove ACLs and change configs for topics, clients, and users.

MCP server

Expose Strimzi actions as MCP tools for agent workflows.

Operator management

Install and uninstall the Strimzi Kafka Operator from the CLI.

How to get it

  1. 1Run
    pip install strimzi-kafka-cli --user
  2. 2Or to install Strimzi Kafka CLI in an isolated environment, you can simply use pipx
    pipx install strimzi-kafka-cli
  3. 3To install with MCP server support
    pip install strimzi-kafka-cli[mcp] --user
  4. 4Or with pipx
    pipx install strimzi-kafka-cli[mcp]
  5. 5Run
    #Tap the homebrew repository first.
    brew tap systemcraftsman/strimzi-kafka-cli
    
    #Install Strimzi Kafka CLI
    brew install strimzi-kafka-cli

README

Build Integration Test Deploy PyPI Downloads License Strimzi MCP Server

Strimzi CLI logo

Strimzi Kafka CLI

Strimzi Kafka CLI is a CLI that helps traditional Apache Kafka users -both developers and administrators- to easily adapt to Strimzi, a Kubernetes operator for Apache Kafka.

The main intention is to ramp up Strimzi usage by creating a similar CLI experience with the traditional Apache Kafka tools that mostly starts with kafka-* prefix under the bin directory in an ordinary Kafka package.

Strimzi Kafka CLI uses the kfk command as an abbreviation for "Kafka For Kubernetes" or simply "k a f k a" which reminds of the kafka-* prefix of the ordinary Kafka script file names.

While having similar set of commands or options for some of the common objects, Strimzi Kafka CLI has some extra capabilities for managing or configuring Strimzi related resources.

Following are the commands of the current version of Strimzi Kafka CLI, that are used for different purposes:

Usage: kfk [OPTIONS] COMMAND [ARGS]...

  Strimzi Kafka CLI.

Options:
  --version  Show the version and exit.
  --help     Show this message and exit.

Commands:
  acls              Manages ACLs on Kafka.
  backup            Backs up and restores Strimzi resources.
    kafka             Backs up or restores a Kafka cluster and its resources.
    connect           Backs up or restores a Kafka Connect cluster and its connectors.
  clusters          Creates, alters, deletes, describes Kafka cluster(s).
  configs           Adds/Removes entity config for a topic, client, user...
  connect           Manages Kafka Connect clusters, connectors, and MirrorMaker2.
    clusters          Creates, alters, deletes, describes KafkaConnect cluster(s).
    connectors        Creates, alters, deletes, describes KafkaConnector(s).
    mirror-maker      Lists, describes, creates, deletes KafkaMirrorMaker2(s).
  console-consumer  Reads data from Kafka topics and outputs it to...
  console-producer  Reads data from standard input and publish it to Kafka.
  mcp               Starts the Strimzi MCP server.
  node-pools        Lists, describes, creates, deletes KafkaNodePool(s).
  operator          Installs/Uninstalls Strimzi Kafka Operator.
  topics            Creates, alters, deletes, describes Kafka topic(s).
  users             Creates, alters, deletes, describes Kafka users(s).

Please take a look at the relevant article Strimzi Kafka CLI: Managing Strimzi in a Kafka Native Way for more details.

Installation

Using Python Package Installer

pip install strimzi-kafka-cli --user

Or to install Strimzi Kafka CLI in an isolated environment, you can simply use pipx:

pipx install strimzi-kafka-cli

To install with MCP server support:

pip install strimzi-kafka-cli[mcp] --user

Or with pipx:

pipx install strimzi-kafka-cli[mcp]

Using Homebrew

#Tap the homebrew repository first.
brew tap systemcraftsman/strimzi-kafka-cli

#Install Strimzi Kafka CLI
brew install strimzi-kafka-cli

Installing the CLI by using Homebrew already uses a virtual environment, so you don't have to worry about your main Python environment. MCP server support is included by default.

Project requires: Python >=3.11

Examples

MCP Server

Strimzi Kafka CLI includes an MCP (Model Context Protocol) server that allows AI assistants to manage Strimzi Kafka deployments on Kubernetes.

Starting the MCP Server

kfk mcp

Registering with Claude Code

claude mcp add strimzi-kafka-cli -- kfk mcp

Available Tools (42)

CategoryTools
Kafka Clusterslist_kafkas, get_kafka, get_kafka_status, create_kafka, delete_kafka, alter_kafka_config
Topicslist_topics, get_topic, create_topic, delete_topic, alter_topic
Userslist_users, get_user, create_user, delete_user, alter_user
Connect Clusterslist_connects, get_connect, create_connect, delete_connect, alter_connect
Connectorslist_connectors, get_connector, create_connector, delete_connector, alter_connector
MirrorMaker2list_mirror_maker_2s, get_mirror_maker_2, create_mirror_maker_2, delete_mirror_maker_2
Backupbackup_kafka, restore_kafka, backup_connect, restore_connect
ACLsadd_or_remove_acls
Operatorinstall_operator, uninstall_operator
Node Poolslist_node_pools, get_node_pool, create_node_pool, delete_node_pool
Versionget_version

Dependencies

Python Dependencies

Please see pyproject.toml file.

External Dependencies

Strimzi resources are automatically downloaded when the first kfk command is run. Strimzi Kafka CLI uses the Python Kubernetes client to interact with the cluster directly. You can check the dependency versions with:

kfk --version

Files in the repo

Repository payload16 top-level entries
  • .github
  • examples
  • kfk
  • tests
  • website
  • .gitignore
  • .pre-commit-config.yaml
  • CODE_OF_CONDUCT.md
  • CONTRIBUTING.md
  • Dockerfile
  • glama.json
  • LICENSE
  • Makefile
  • pyproject.toml
  • README.md
  • server.json

Discussion (0)

Ask about usage, or say what you built with it

Sign in to join the discussion.

No comments yet. Be the first to say what this is good for.

More tools

JuliusBrussee/
caveman

🪨 why use many token when few token do trick — Claude Code skill that cuts 65% of tokens by talking like caveman

105k
1 add
MemPalace/
mempalace

The best-benchmarked open-source AI memory system. And it's free.

59k
stablyai/
orca

Orca is the ADE for working with a fleet of parallel agents. Run any coding agent with your own subscription. Available on desktop, mobile and remote runtime.

66k

A cross-platform desktop All-in-One assistant for Claude Code, Codex, OpenCode, OpenClaw, Grok Build & Hermes Agent. Only official website: ccswitch.io

132k

Never stop coding. Free MIT AI gateway: one endpoint, 352 providers (150+ free), 1200+ models Kimi, Claude, GPT, Gemini, GLM, DeepSeek, MiniMax. Works with Claude Code, Codex, Cursor, OpenCode, Cline & Copilot. Quota-aware auto-fallback, RTK+Caveman compression saves 15-95% tokens, MCP/A2A, Desktop/PWA. Built by 550+ contributors

64k
headroomlabs-ai/
headroom

Compress tool outputs, logs, files, and RAG chunks before they reach the LLM. 20% fewer tokens for coding agents, 60-95% fewer tokens for JSON, same answers. Library, proxy, MCP server.

71k