data
Apache Kafka MCP Integration for OpenAI Agents SDK
Connect Apache Kafka to OpenAI Agents SDK through the local KosmoKrator MCP gateway with scoped tools, credentials, and write policy.
Connect Apache Kafka to OpenAI Agents SDK
Attach KosmoKrator integration tools to OpenAI Agents SDK workflows through a local MCP gateway.
Start the KosmoKrator MCP gateway locally and point the OpenAI Agents SDK MCP tool at that process or wrapper. The gateway is local, scoped to this integration, and starts with
--write=deny so OpenAI Agents can inspect read-capable tools without receiving write access by default.
Apache Kafka MCP Config for OpenAI Agents SDK
Use headless JSON commands for CI-style execution and MCP for agent tool discovery.
{
"mcpServers": {
"kosmokrator-kafka": {
"type": "stdio",
"command": "kosmo",
"args": [
"mcp:serve",
"--integration=kafka",
"--write=deny"
]
}
}
} Run the Gateway Manually
kosmokrator mcp:serve --integration=kafka --write=deny Why Use KosmoKrator Here
Expose only Apache Kafka instead of a broad multi-service tool list.
Reuse credentials already configured for the KosmoKrator CLI and Lua runtime.
Start read-only, then opt into ask or allow for trusted workspaces.
Apache Kafka Tools Visible to OpenAI Agents
OpenAI Agents sees stable MCP tool names generated from the Apache Kafka integration catalog.
| MCP tool | Source function | Type | Description |
|---|---|---|---|
integration__kafka__kafka_list_topics | kafka.kafka_list_topics | Read | List Kafka topics in a cluster. Returns topic names, partition counts, replication factors, and status. |
integration__kafka__kafka_get_topic | kafka.kafka_get_topic | Read | Get full details of a specific Kafka topic by name. Returns partition count, replication factor, and topic configuration. |
integration__kafka__kafka_create_topic | kafka.kafka_create_topic | Write | Create a new Kafka topic in a cluster. Specify the topic name, partition count, and optional replication factor and configs. |
integration__kafka__kafka_list_clusters | kafka.kafka_list_clusters | Read | List Kafka clusters in your Confluent Cloud environment. Returns cluster IDs, names, types, and status. |
integration__kafka__kafka_get_cluster | kafka.kafka_get_cluster | Read | Get details of a specific Kafka cluster. Returns broker count, controller info, and cluster configuration. |
integration__kafka__kafka_list_producers | kafka.kafka_list_producers | Read | List producers for a specific Kafka topic. Returns producer IDs, client IDs, and connection details. |
integration__kafka__kafka_get_current_user | kafka.kafka_get_current_user | Read | Get the currently authenticated Confluent Cloud user. Useful for verifying credentials and identifying the connected account. |