|
1 | 1 | # StreamNative MCP Server |
2 | 2 |
|
3 | | -A Model Context Protocol (MCP) server for integrating AI agents with StreamNative Cloud resources and Apache Pulsar/Kafka messaging systems. |
| 3 | +A Model Context Protocol (MCP) server for integrating AI agents with StreamNative Cloud resources and Apache Kafka/Pulsar messaging systems. |
4 | 4 |
|
5 | 5 | ## Overview |
6 | 6 |
|
7 | | -StreamNative MCP Server provides a standard interface for LLMs (Large Language Models) and AI agents to interact with StreamNative Cloud services, Apache Pulsar, and Apache Kafka. This implementation follows the [Model Context Protocol](https://modelcontextprotocol.io/introduction) specification, enabling AI applications to access messaging services through a standardized interface. |
| 7 | +StreamNative MCP Server provides a standard interface for LLMs (Large Language Models) and AI agents to interact with StreamNative Cloud services, Apache Kafka, and Apache Pulsar. This implementation follows the [Model Context Protocol](https://modelcontextprotocol.io/introduction) specification, enabling AI applications to access messaging services through a standardized interface. |
8 | 8 |
|
9 | 9 | ## Features |
10 | 10 |
|
11 | 11 | - **StreamNative Cloud Integration**: |
12 | 12 | - Connect to StreamNative Cloud resources with authentication |
13 | 13 | - Switch to clusters available in your organization |
14 | 14 | - Describe the status of clusters resources |
15 | | -- **Apache Pulsar Support**: Interact with Pulsar resources including: |
16 | | - - Pulsar Admin operations (topics, namespaces, tenants, schemas, etc.) |
17 | | - - Pulsar Client operations (producers, consumers) |
18 | | - - Functions, Sources, and Sinks management |
19 | | -- **Apache Kafka Support**: Interact with Kafka resources including: |
| 15 | +- **Apache Kafka Support**: Interact with Apache Kafka resources including: |
20 | 16 | - Kafka Admin operations (topics, partitions, consumer groups) |
21 | 17 | - Schema Registry operations |
22 | | - - Kafka Connect operations |
| 18 | + - Kafka Connect operations (*) |
23 | 19 | - Kafka Client operations (producers, consumers) |
| 20 | +- **Apache Pulsar Support**: Interact with Apache Pulsar resources including: |
| 21 | + - Pulsar Admin operations (topics, namespaces, tenants, schemas, etc.) |
| 22 | + - Pulsar Client operations (producers, consumers) |
| 23 | + - Functions, Sources, and Sinks management |
24 | 24 | - **Multiple Connection Options**: |
25 | 25 | - Connect to StreamNative Cloud with service account authentication |
26 | | - - Connect directly to external Pulsar clusters |
27 | | - - Connect directly to external Kafka clusters |
| 26 | + - Connect directly to external Apache Kafka clusters |
| 27 | + - Connect directly to external Apache Pulsar clusters |
| 28 | + |
| 29 | +> *: The Kafka Connect operations are only tested and verfied on StreamNative Cloud. |
28 | 30 |
|
29 | 31 | ## Installation |
30 | 32 |
|
@@ -124,45 +126,65 @@ The StreamNative MCP Server supports enabling or disabling specific groups of fu |
124 | 126 |
|
125 | 127 | ### Available Features |
126 | 128 |
|
127 | | -The following sets of tools are available (all available by default on StreamNative Cloud) |
128 | | - |
129 | | -| Features | Description | |
130 | | -| ------|-------| |
131 | | -| `all` | All tools, including StreamNative Cloud tools, Pulsar tools and Kafka tools | |
132 | | -| `all-pulsar` | All Pulsar admin and Pulsar client tools | |
133 | | -| `all-kafka` | All Kafka admin and Kafka client tools | |
134 | | -| `pulsar-admin` | Pulsar administrative operations (including all `pulsar-admin-*`) | |
135 | | -| `pulsar-client` | Pulsar client operations (produce and consume messages) | |
136 | | -| `pulsar-admin-brokers` | Manage Pulsar brokers | |
137 | | -| `pulsar-admin-broker-stats` | Access Pulsar broker statistics | |
138 | | -| `pulsar-admin-clusters` | Manage Pulsar clusters | |
139 | | -| `pulsar-admin-functions-worker` | Manage Pulsar Function workers | |
140 | | -| `pulsar-admin-namespaces` | Manage Pulsar namespaces | |
141 | | -| `pulsar-admin-namespace-policy` | Configure Pulsar namespace policies | |
142 | | -| `pulsar-admin-isolation-policy` | Manage namespace isolation policies | |
143 | | -| `pulsar-admin-packages` | Manage Pulsar packages | |
144 | | -| `pulsar-admin-resource-quotas` | Configure resource quotas | |
145 | | -| `pulsar-admin-schemas` | Manage Pulsar schemas | |
146 | | -| `pulsar-admin-subscriptions` | Manage Pulsar subscriptions | |
147 | | -| `pulsar-admin-tenants` | Manage Pulsar tenants | |
148 | | -| `pulsar-admin-topics` | Manage Pulsar topics | |
149 | | -| `pulsar-admin-sinks` | Manage Pulsar IO sinks | |
150 | | -| `pulsar-admin-functions` | Manage Pulsar Functions | |
151 | | -| `pulsar-admin-sources` | Manage Pulsar IO sources | |
152 | | -| `pulsar-admin-topic-policy` | Configure Pulsar topic policies | |
153 | | -| `kafka-admin` | Kafka administrative operations (including all `kafka-admin-*`) | |
154 | | -| `kafka-client` | Kafka client operations (produce and consume messages) | |
155 | | -| `kafka-admin-topics` | Manage Kafka partitions | |
156 | | -| `kafka-admin-partitions` | Manage Kafka partitions | |
157 | | -| `kafka-admin-groups` | Manage Kafka consumer groups | |
158 | | -| `kafka-admin-schema-registry` | Interact with Kafka Schema Registry | |
159 | | -| `kafka-admin-connect` | Manage Kafka Connect connectors | |
160 | | -| `streamnative-cloud` | Manage the context, check resources logs of StreamNative Cloud | |
161 | | - |
162 | | -### Usage Examples |
163 | | - |
164 | | -To enable only specific feature sets: |
165 | | - |
| 129 | +The StreamNative MCP Server allows you to enable or disable specific groups of features using the `--features` flag. This helps you control which tools are available to your AI agents and can reduce context size for LLMs. |
| 130 | + |
| 131 | +#### Combination Feature Sets |
| 132 | + |
| 133 | +| Feature | Description | |
| 134 | +|---------------|-----------------------------------------------------------------------------| |
| 135 | +| `all` | Enables all features: StreamNative Cloud, Pulsar, and Kafka tools | |
| 136 | + |
| 137 | +--- |
| 138 | + |
| 139 | +#### Kafka Features |
| 140 | + |
| 141 | +| Feature | Description | Docs | |
| 142 | +|--------------------------|--------------------------------------------------|------| |
| 143 | +| `all-kafka` | Enables all Kafka admin and client tools, without Apache Pulsar and StreamNative Cloud tools | |
| 144 | +| `kafka-admin` | Kafka administrative operations (all admin tools) | | |
| 145 | +| `kafka-client` | Kafka client operations (produce/consume) |[kafka_client_consume.md](docs/tools/kafka_client_consume.md), [kafka_client_produce.md](docs/tools/kafka_client_produce.md) | |
| 146 | +| `kafka-admin-topics` | Manage Kafka topics | [kafka_admin_topics.md](docs/tools/kafka_admin_topics.md) | |
| 147 | +| `kafka-admin-partitions` | Manage Kafka partitions | [kafka_admin_partitions.md](docs/tools/kafka_admin_partitions.md) | |
| 148 | +| `kafka-admin-groups` | Manage Kafka consumer groups | [kafka_admin_groups.md](docs/tools/kafka_admin_groups.md) | |
| 149 | +| `kafka-admin-schema-registry` | Interact with Kafka Schema Registry | [kafka_admin_schema_registry.md](docs/tools/kafka_admin_schema_registry.md) | |
| 150 | +| `kafka-admin-connect` | Manage Kafka Connect connectors | [kafka_admin_connect.md](docs/tools/kafka_admin_connect.md) | |
| 151 | + |
| 152 | +--- |
| 153 | + |
| 154 | +#### Pulsar Features |
| 155 | + |
| 156 | +| Feature | Description | Docs | |
| 157 | +|--------------------------|--------------------------------------------------|------| |
| 158 | +| `all-pulsar` | Enables all Pulsar admin and client tools, without Apache Kafka and StreamNative Cloud tools | | |
| 159 | +| `pulsar-admin` | Pulsar administrative operations (all admin tools)| | |
| 160 | +| `pulsar-client` | Pulsar client operations (produce/consume) | [pulsar_client_consume.md](docs/tools/pulsar_client_consume.md), [pulsar_client_produce.md](docs/tools/pulsar_client_produce.md) | |
| 161 | +| `pulsar-admin-brokers` | Manage Pulsar brokers | [pulsar_admin_brokers.md](docs/tools/pulsar_admin_brokers.md) | |
| 162 | +| `pulsar-admin-broker-stats` | Access Pulsar broker statistics | [pulsar_admin_broker_stats.md](docs/tools/pulsar_admin_broker_stats.md) | |
| 163 | +| `pulsar-admin-clusters` | Manage Pulsar clusters | [pulsar_admin_clusters.md](docs/tools/pulsar_admin_clusters.md) | |
| 164 | +| `pulsar-admin-functions-worker`| Manage Pulsar Function workers | [pulsar_admin_functions_worker.md](docs/tools/pulsar_admin_functions_worker.md) | |
| 165 | +| `pulsar-admin-namespaces` | Manage Pulsar namespaces | [pulsar_admin_namespaces.md](docs/tools/pulsar_admin_namespaces.md) | |
| 166 | +| `pulsar-admin-namespace-policy`| Configure Pulsar namespace policies | [pulsar_admin_namespace_policy.md](docs/tools/pulsar_admin_namespace_policy.md) | |
| 167 | +| `pulsar-admin-isolation-policy`| Manage namespace isolation policies | [pulsar_admin_isolation_policy.md](docs/tools/pulsar_admin_isolation_policy.md) | |
| 168 | +| `pulsar-admin-packages` | Manage Pulsar packages | [pulsar_admin_packages.md](docs/tools/pulsar_admin_packages.md) | |
| 169 | +| `pulsar-admin-resource-quotas` | Configure resource quotas | [pulsar_admin_resource_quotas.md](docs/tools/pulsar_admin_resource_quotas.md) | |
| 170 | +| `pulsar-admin-schemas` | Manage Pulsar schemas | [pulsar_admin_schemas.md](docs/tools/pulsar_admin_schemas.md) | |
| 171 | +| `pulsar-admin-subscriptions` | Manage Pulsar subscriptions | [pulsar_admin_subscriptions.md](docs/tools/pulsar_admin_subscriptions.md) | |
| 172 | +| `pulsar-admin-tenants` | Manage Pulsar tenants | [pulsar_admin_tenants.md](docs/tools/pulsar_admin_tenants.md) | |
| 173 | +| `pulsar-admin-topics` | Manage Pulsar topics | [pulsar_admin_topics.md](docs/tools/pulsar_admin_topics.md) | |
| 174 | +| `pulsar-admin-sinks` | Manage Pulsar IO sinks | [pulsar_admin_sinks.md](docs/tools/pulsar_admin_sinks.md) | |
| 175 | +| `pulsar-admin-functions` | Manage Pulsar Functions | [pulsar_admin_functions.md](docs/tools/pulsar_admin_functions.md) | |
| 176 | +| `pulsar-admin-sources` | Manage Pulsar Sources | [pulsar_admin_sources.md](docs/tools/pulsar_admin_sources.md) | |
| 177 | +| `pulsar-admin-topic-policy` | Configure Pulsar topic policies | [pulsar_admin_topic_policy.md](docs/tools/pulsar_admin_topic_policy.md) | |
| 178 | + |
| 179 | +--- |
| 180 | + |
| 181 | +#### StreamNative Cloud Features |
| 182 | + |
| 183 | +| Feature | Description | Docs | |
| 184 | +|---------------------|------------------------------------------------------------------|------| |
| 185 | +| `streamnative-cloud`| Manage StreamNative Cloud context and check resource logs | [streamnative_cloud.md](docs/tools/streamnative_cloud.md) | |
| 186 | + |
| 187 | +You can combine these features as needed using the `--features` flag. For example, to enable only Pulsar client features: |
166 | 188 | ```bash |
167 | 189 | # Enable only Pulsar client features |
168 | 190 | bin/snmcp stdio --organization my-org --key-file /path/to/key-file.json --features pulsar-client |
@@ -244,3 +266,5 @@ This project uses [semver](https://semver.org/) semantics. |
244 | 266 | ## License |
245 | 267 |
|
246 | 268 | Licensed under the Apache License Version 2.0: http://www.apache.org/licenses/LICENSE-2.0 |
| 269 | + |
| 270 | + |
0 commit comments