ballerina-activemq-mcp-server
Provides tools for managing Apache ActiveMQ message broker setup, including validating broker connectivity, scaffolding Ballerina projects, adding queues/topics, configuring acknowledgement modes, and building/deploying projects within a WSO2 Integrator workspace.
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., "@ballerina-activemq-mcp-serverscaffold a new Ballerina ActiveMQ project"
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.
ballerina-activemq-mcp-server
An MCP server that automates the full setup and deployment of Ballerina + Apache ActiveMQ (OpenWire/JMS) integrations inside a WSO2 Integrator (BI) workspace — from broker validation to a runnable, BI-low-code-ready project — with minimal user interaction.
It generates code against the ballerinax/activemq connector (v0.1.0, Ballerina 2201.12.10),
matching the real connector API (Client / Listener / Caller / Transaction). See
INSPECTION_NOTES.md for the Phase 0 API inspection this is built on.
Tools
Tool | Purpose |
| TCP reachability to the OpenWire port (+ Jolokia console destination listing). |
| Main tool. Generate a complete BI-ready Ballerina project. |
| Write/rotate the broker |
| Add a queue producer/consumer helper module. |
| Add a topic (pub/sub) publisher helper module. |
| Add a Listener service — the polling-loop carrier — with ack-mode/transaction options. |
| Change the acknowledgement mode on a listener service (edits the |
| Run |
| Run |
Acknowledgement modes
| Ballerina enum | Needs | Semantics |
|
| no | auto-ack on successful |
|
| yes |
|
|
| no | lazy ack, possible duplicates |
|
| yes |
|
The ack mode is a compile-time annotation field, so it lives in
listener.bal(notConfig.toml).mq_set_ack_modeedits the source accordingly.
Related MCP server: wso2-bi-salesforce-mcp-server
Build
npm install
npm run buildRun
# stdio (default — for MCP clients that spawn the server)
npm start
# streamable HTTP, bound to 127.0.0.1
npm run start:http # or: node dist/index.js --http --port 3000Register with an MCP client (stdio)
{
"mcpServers": {
"ballerina-activemq": {
"command": "node",
"args": ["/absolute/path/to/ballerina-activemq-mcp-server/dist/index.js"]
}
}
}What gets scaffolded
mq_scaffold_project writes a complete project under <bi_path>/<project_name>/:
Ballerina.toml · Dependencies.toml · Config.toml (+ .example, gitignored) · .gitignore
main.bal · listener.bal · transactions.bal · modules/<dest>/<dest>.bal
docker-compose.yml (apache/activemq-classic:6.2.0) · README.mdmain.bal—configurablebroker settings +activemq:Clientproducer/consumer demo.listener.bal— the polling-loop carrier: a declarativeservice activemq:Service on mqListenerper destination, ack mode baked into@activemq:ServiceConfig.Virtual topics — publish to
topic://VirtualTopic.<name>; consume the queueConsumer.<group>.VirtualTopic.<name>.
Design notes
This is JMS/OpenWire, not Kafka. Consumer groups, offset commits, partitions, and
bootstrap.servers have no analog here and are intentionally absent — reliability comes from
ack modes and transacted sessions. The closest thing to a consumer group is an ActiveMQ
Virtual Topic, modeled as a queue naming convention. See INSPECTION_NOTES.md for the full
rejected-Kafka-patterns rationale.
License
Apache-2.0
Available Tools
9 toolsmq_add_listenerAdd Listener serviceA
Add a message Listener service — the polling-loop carrier — to listener.bal. Generates a declarative service activemq:Service on mqListener with the correct @activemq:ServiceConfig (queueName/topicName, sessionAckMode, pollingInterval, receiveTimeout) and an onMessage that carries an activemq:Caller for client/transacted ack modes (with acknowledge or commit/rollback). Supports queue, topic (optionally durable), and virtual-topic (consumer_group) destinations. If transacted=true conflicts with ack_mode, transacted wins (SESSION_TRANSACTED) with a warning. Creates listener.bal if absent; otherwise appends the service (or replaces the file if overwrite=true).
| Name | Required | Description | Default |
|---|---|---|---|
| durable | No | Topic only: use a DURABLE subscription. | |
| ack_mode | No | Acknowledgement mode baked into the listener's @activemq:ServiceConfig: auto=AUTO_ACKNOWLEDGE (default), client=CLIENT_ACKNOWLEDGE (manual caller->acknowledge), dups-ok=DUPS_OK_ACKNOWLEDGE, transacted=SESSION_TRANSACTED (caller->'commit()/'rollback()). | auto |
| org_name | Yes | Ballerina package organisation name (e.g. "acme"). Used in Ballerina.toml and the Config.toml table header [org.project]. | |
| overwrite | No | Overwrite listener.bal if it already exists (otherwise the service is appended). | |
| transacted | No | When true, force SESSION_TRANSACTED (overrides ack_mode with a warning) and emit commit/rollback in onMessage. | |
| destination | Yes | The destination this listener service consumes from. | |
| project_name | Yes | Ballerina package / project name. Becomes the folder <bi_path>/<project_name> and the package name. | |
| project_path | Yes | Absolute or ~/%USERPROFILE%-relative path to an existing scaffolded project root (the folder containing Ballerina.toml). | |
| service_name | No | Optional service identifier; defaults to a name derived from the destination. | |
| consumer_group | No | Virtual-topic only: consumer group id used in the Consumer.<group>.VirtualTopic.<name> queue. | |
| subscriber_name | No | Topic only: durable subscription name (required when durable=true). |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
All annotations are false, providing no safety hints. The description compensates by fully disclosing file behavior (creates/append/replaces with overwrite=true), the transacted vs ack_mode precedence with warning, and generated code structure (activemq:Caller for ack modes). This is far richer than the minimal annotation info.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is five sentences, each carrying essential operational information. It is logically structured and front-loaded with the main action, though slightly dense due to the detailed code-generation specifics. No wasted words.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given 11 parameters, nested objects, and no output schema, the description covers file handling, destination types, ack/transacted semantics, and conflict resolution. However, it does not mention return values or error scenarios, which could leave minor uncertainty about invocation outcomes.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, but the description adds critical meaning: conditional requirements (subscriber_name required when durable=true, consumer_group for virtual-topic), transacted overriding ack_mode, and how parameters map to generated @activemq:ServiceConfig fields. This significantly enhances schema descriptions.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's verb and resource: 'Add a message Listener service... to listener.bal.' It distinguishes itself from siblings by specifying it creates a declarative service with @activemq:ServiceConfig and onMessage, which is unique compared to mq_add_queue, mq_add_topic, and mq_set_ack_mode.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides clear context on when to use the tool (adding listeners for queue/topic/virtual-topic destinations and handling ack modes), but it does not explicitly mention alternatives or when not to use it. However, the distinct purpose is implied sufficiently.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
mq_add_queueAdd queue moduleA
Add a queue helper module to an existing project: creates modules//.bal with send() and receive() functions wired to the JMS queue (point-to-point). The producer sends with Client.sendMessage(queueName, ..) and receives synchronously with Client.receiveMessage(queueName, timeout). Does not overwrite unless overwrite=true.
| Name | Required | Description | Default |
|---|---|---|---|
| org_name | Yes | Ballerina package organisation name (e.g. "acme"). Used in Ballerina.toml and the Config.toml table header [org.project]. | |
| overwrite | No | Overwrite the module file if it already exists. | |
| queue_name | Yes | JMS queue name (point-to-point). Example: orders.queue | |
| project_name | Yes | Ballerina package / project name. Becomes the folder <bi_path>/<project_name> and the package name. | |
| project_path | Yes | Absolute or ~/%USERPROFILE%-relative path to an existing scaffolded project root (the folder containing Ballerina.toml). |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
The description discloses key behavior beyond the annotations: it creates a specific module file and functions, uses Client.sendMessage/receiveMessage, and explicitly states the overwrite condition ('Does not overwrite unless overwrite=true'). This adds meaningful behavioral detail even though annotations indicate readOnlyHint=false and destructiveHint=false.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a tight, three-sentence summary that is front-loaded with the primary purpose, then details the file/function generation and the overwrite guard. Every sentence contributes value without verbosity.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The description covers the tool's purpose, generated artifacts, and key behavior (overwrite). While it does not explain failure modes or build integration, it is complete for a focused module-generation tool among a broader toolset. No output schema exists, so return values are not expected to be documented.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, with each parameter having a clear description. The tool description adds minimal extra meaning to parameters (e.g., 'point-to-point' for queue_name, overwrite behavior), but these are already largely present in the schema. Thus a baseline of 3 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's action: 'Add a queue helper module to an existing project', and differentiates it by specifying the JMS queue (point-to-point) and the exact files/functions created. This distinguishes it from sibling tools like mq_add_topic and mq_add_listener.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description gives solid usage context ('to an existing project', 'wired to the JMS queue') and clearly scopes it to queue-based point-to-point messaging. It does not explicitly name alternative tools for topics/listeners, but the context is clear enough for an agent to select correctly.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
mq_add_topicAdd topic moduleA
Add a topic (pub/sub) helper module to an existing project: creates modules//.bal with a publish() function that sends to "topic://". Subscribers are created as Listener services (use mq_add_listener with type=topic, optionally durable=true + subscriber_name). Does not overwrite unless overwrite=true.
| Name | Required | Description | Default |
|---|---|---|---|
| durable | No | Generate a DURABLE subscriber (survives disconnects). Requires subscriber_name. | |
| org_name | Yes | Ballerina package organisation name (e.g. "acme"). Used in Ballerina.toml and the Config.toml table header [org.project]. | |
| overwrite | No | Overwrite the module file if it already exists. | |
| topic_name | Yes | JMS topic name (pub/sub). Example: order.events | |
| project_name | Yes | Ballerina package / project name. Becomes the folder <bi_path>/<project_name> and the package name. | |
| project_path | Yes | Absolute or ~/%USERPROFILE%-relative path to an existing scaffolded project root (the folder containing Ballerina.toml). | |
| subscriber_name | No | Durable subscription name (required when durable=true). |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Beyond annotations (readOnly=false, destructive=false), the description discloses key behaviors: it creates a specific file path, generates a publish function, and has an overwrite guard ('Does not overwrite unless overwrite=true'). It also notes that subscribers should be created via mq_add_listener, providing clarity about side effects and system architecture.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is three sentences, front-loaded with the core purpose, and every sentence adds value: file creation, function behavior, subscriber alternative, and overwrite behavior. No fluff or repetition.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given no output schema and moderate complexity (7 params, code generation), the description covers essential context: what is created, how subscribers are handled, and overwrite behavior. It doesn't mention return values or error handling, but for selection and invocation, it provides sufficient context. It also points to the sibling tool for listener creation, improving completeness.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, so baseline is 3. The description adds meaning beyond the schema by explaining how topic_name maps to the file and function (publish<Name>() to 'topic://<topic>') and how durable/subscriber_name relate to listener creation. This enhances parameter understanding without redundancy.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states 'Add a topic (pub/sub) helper module to an existing project' and specifies exactly what is created (modules/<topic>/<topic>.bal with a publish<Name>() function). It distinguishes from siblings by explicitly mentioning mq_add_listener for subscribers and implying queue vs topic via 'pub/sub'.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description gives clear context: use this to add a topic publisher module to an existing project. It names the alternative tool for creating subscribers ('use mq_add_listener with type=topic'), but does not explicitly exclude other cases like queues or when not to use it. Still, the guidance is actionable.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
mq_build_projectBuild Ballerina projectAIdempotent
Run bal build in a scaffolded project and report success or the compiler diagnostics. Verifies the Ballerina toolchain is installed first (bal version). Use offline=true to build against locally cached dependencies only. Does not modify source files.
| Name | Required | Description | Default |
|---|---|---|---|
| offline | No | Pass --offline to bal build (use only locally cached dependencies). | |
| timeout_ms | No | Max time to wait for `bal build` to finish (default 300000 ms). | |
| project_path | Yes | Absolute or ~/%USERPROFILE%-relative path to an existing scaffolded project root (the folder containing Ballerina.toml). |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already indicate idempotent and non-destructive behavior; the description adds that it verifies the Ballerina toolchain first and does not modify source files. It also discloses that it reports success or diagnostics, providing useful behavioral context beyond the annotations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Three concise sentences, front-loaded with the core action. Each sentence adds value: what it does, the toolchain check, and the offline behavior with the non-modification guarantee.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The description is complete for a build tool with no output schema. It covers prerequisites (scaffolded project, toolchain check), behavior (offline, no source modification), and return value (success or diagnostics).
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, so baseline is 3. The description mentions offline=true, but this exactly restates the schema description. No additional parameter meaning is provided.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool runs `bal build` in a scaffolded project and reports success or compiler diagnostics. This specific verb+resource distinguishes it from siblings like mq_scaffold_project (create) and mq_deploy_project (deploy).
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
It provides clear context by specifying 'in a scaffolded project' and the offline option for cached dependencies, implying when to use it. It does not explicitly name alternatives or exclusions, but the context is sufficient.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
mq_deploy_projectDeploy (run) Ballerina projectA
Run bal run for a scaffolded project as a detached background process and return its PID. Watches the process for wait_ms to catch an early crash (and report the output) before declaring it started. If service_port is given, also returns a composed service URL. The process keeps running after this call returns. Verifies the Ballerina toolchain first.
| Name | Required | Description | Default |
|---|---|---|---|
| wait_ms | No | How long to watch the process for an early crash before reporting it started (default 4000 ms). | |
| project_path | Yes | Absolute or ~/%USERPROFILE%-relative path to an existing scaffolded project root (the folder containing Ballerina.toml). | |
| service_port | No | Optional HTTP/observability port the running program exposes; used only to compose the returned service URL. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
The description richly discloses behavior: returns PID, watches for early crash for wait_ms, reports output, composes service URL if service_port given, and reveals that the process keeps running after return. This goes well beyond the annotations (readOnlyHint=false, idempotentHint=false) and adds critical operational context.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Four sentences, each adds distinct value. Front-loaded with the core action, then behavior, optional output, and persistence. No fluff or redundancy.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Despite no output schema, the description explains the return values (PID, optional service URL) and the asynchronous nature of the process. It also notes toolchain verification, making it complete for an agent to invoke correctly.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema covers all parameters (100% coverage), but the description adds context by explaining the functional role of wait_ms (watch for early crash) and service_port (compose service URL), enhancing the schema descriptions. Baseline is 3, and this pushes to 4.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description states the specific action: 'Run `bal run` for a scaffolded project as a detached background process and return its PID.' It clearly distinguishes from sibling tools like mq_build_project (build) and mq_scaffold_project (scaffold) by focusing on deployment/execution.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies usage after scaffolding and references a scaffolded project, but does not explicitly contrast with alternatives like mq_build_project or state when-not to use. It provides context (detached process, verifies toolchain) but lacks explicit exclusions or alternative guidance.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
mq_scaffold_projectScaffold ActiveMQ BI projectA
MAIN tool. Generate a complete, runnable WSO2 Integrator (BI) Ballerina project that integrates with ActiveMQ via the ballerinax/activemq connector. Creates Ballerina.toml (with the connector pinned from the local repository), Config.toml (+ .example, gitignored), .gitignore, main.bal (producer/consumer client demo), listener.bal (the polling-loop carrier with one declarative service activemq:Service on mqListener per destination) when include_listener is set, transactions.bal when transacted is set, a modules// helper per destination, a docker-compose.yml (apache/activemq-classic), and a README. Acknowledgement mode is baked into the listener's @activemq:ServiceConfig. If transacted=true conflicts with ack_mode, transacted wins (SESSION_TRANSACTED) and a warning is returned. Writes files to disk.
| Name | Required | Description | Default |
|---|---|---|---|
| bi_path | Yes | WSO2 Integrator (BI) workspace path the project folder is created under. Supports ~ (POSIX) and %USERPROFILE% (Windows) expansion. Defaults: ~/WSO2Integrator (macOS/Linux), %USERPROFILE%\WSO2Integrator (Windows). | |
| ack_mode | No | Acknowledgement mode baked into the listener's @activemq:ServiceConfig: auto=AUTO_ACKNOWLEDGE (default), client=CLIENT_ACKNOWLEDGE (manual caller->acknowledge), dups-ok=DUPS_OK_ACKNOWLEDGE, transacted=SESSION_TRANSACTED (caller->'commit()/'rollback()). | auto |
| org_name | Yes | Ballerina package organisation name (e.g. "acme"). Used in Ballerina.toml and the Config.toml table header [org.project]. | |
| password | No | Broker password (must be paired with username). Omit for an unauthenticated broker. | |
| username | No | Broker username (must be paired with password). Omit for an unauthenticated broker. | |
| overwrite | No | When true, overwrite an existing project folder. When false, the tool refuses if the folder already exists. | |
| broker_url | No | OpenWire broker URL. Supported forms: tcp://host:61616 (default), ssl://host:61617, or failover:(tcp://h1:61616,tcp://h2:61616). Example: tcp://localhost:61616 | tcp://localhost:61616 |
| transacted | No | When true, generate transactions.bal and force SESSION_TRANSACTED on the listener (overrides ack_mode with a warning). | |
| destinations | Yes | One or more destinations to wire up. Each generates a modules/<name>.bal helper, and (if include_listener) a listener service. | |
| project_name | Yes | Ballerina package / project name. Becomes the folder <bi_path>/<project_name> and the package name. | |
| include_listener | No | When true, generate listener.bal — the polling-loop carrier — with a service per destination. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Despite light annotations, the description discloses important behavioral details: it writes files to disk, lists every artifact generated, calls out conditional generation based on include_listener and transacted, and explains the conflict-resolution rule where transacted overrides ack_mode (with a warning). This goes well beyond the annotations and schema.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is long but packed with necessary detail about the many files and flags. It front-loads the core purpose and avoids filler. The lengthy file list is justified for a scaffolding tool, though it could be slightly tightened by moving implementation specifics into the schema.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a complex tool with 11 parameters, no output schema, and a dozen generated artifacts, the description covers the key generation rules, conditional files, and conflict handling. It explains what gets written, when, and how parameter interactions are resolved, making it sufficiently complete for an agent to invoke correctly.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, so the baseline is 3. The description adds extra semantic value by linking specific parameters to generated files ('listener.bal ... when include_listener is set', 'transactions.bal when transacted is set') and clarifying the precedence relationship between transacted and ack_mode, which is not captured in individual parameter descriptions.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description opens with 'MAIN tool' and states a specific verb and resource: 'Generate a complete, runnable WSO2 Integrator (BI) Ballerina project that integrates with ActiveMQ via the ballerinax/activemq connector.' It then enumerates the exact set of files created, making the tool's scope unmistakable and clearly distinguishing it from sibling tools that validate, add queues, or build/deploy.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The 'MAIN tool' marker and the comprehensive scaffold list establish that this tool is the entry point for creating a project. However, the description does not explicitly name alternatives or state when not to use this tool (e.g., 'for incremental changes use mq_add_queue'), so it lacks the explicit exclusions that would earn a 5.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
mq_set_ack_modeSet acknowledgement modeADestructiveIdempotent
Set/update the acknowledgement mode on listener service(s) by editing listener.bal in place. Rewrites sessionAckMode in the @activemq:ServiceConfig annotation and regenerates the affected onMessage to match (adds/removes the activemq:Caller parameter and the acknowledge / commit+rollback calls). Targets one service by service_name, or all services when omitted. Ack mode cannot live in Config.toml (it is a compile-time constant), which is why this edits source. Modifies a .bal file.
| Name | Required | Description | Default |
|---|---|---|---|
| ack_mode | Yes | New acknowledgement mode. The tool rewrites sessionAckMode in the listener.bal @activemq:ServiceConfig and adjusts the onMessage signature (adds/removes the Caller parameter + ack/commit calls) to match. | |
| project_path | Yes | Absolute or ~/%USERPROFILE%-relative path to an existing scaffolded project root (the folder containing Ballerina.toml). | |
| service_name | No | Target a specific service by name. When omitted, all services in listener.bal are updated. | |
| listener_file | No | Listener source file (relative to project_path) to edit. Defaults to listener.bal. | listener.bal |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already indicate destructiveHint=true and readOnlyHint=false; the description adds rich behavioral detail: rewrites sessionAckMode, regenerates the affected onMessage, adds/removes the activemq:Caller parameter and acknowledge/commit+rollback calls, and edits a .bal file in place. No contradiction with annotations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Exactly four sentences, front-loaded with the primary action, then relevant details. Every sentence contributes: what, why, scope, and mechanism. No fluff or redundancy.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a file-editing tool with no output schema, the description explains the what, why, how, and scope. It is sufficient for the agent to understand the operation. Not a 5 because it omits potential failure modes (e.g., file not found, malformed annotation), but given schema richness and annotations, it is quite complete.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Input schema has 100% description coverage for all 4 parameters. The description adds little beyond the schema: the service_name scoping ('Targets one service... or all services when omitted') is already present in the schema. Baseline 3 is appropriate as the schema carries the parameter semantics.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Starts with a specific verb+resource: 'Set/update the acknowledgement mode on listener service(s)'. It further details the mechanism (editing listener.bal, rewriting sessionAckMode, regenerating onMessage) and distinguishes itself from siblings like mq_write_config_toml and mq_add_listener by focusing on ack mode and source editing.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Provides a clear context and exclusion: 'Ack mode cannot live in Config.toml (it is a compile-time constant), which is why this edits source.' This guides against using a configuration-based alternative. However, it does not explicitly state when not to use this tool or compare with other sibling tools beyond the Config.toml note.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
mq_validate_brokerValidate ActiveMQ brokerARead-onlyIdempotent
Check that an ActiveMQ broker is reachable at the given OpenWire URL. Performs a TCP connectivity probe to each endpoint (handles tcp://, ssl://, and failover:(...) forms). When list_destinations is true, also queries the ActiveMQ web-console Jolokia REST agent (default port 8161) to list current queues and topics, degrading gracefully to a TCP-only result if the console is unreachable. Read-only; makes no changes.
| Name | Required | Description | Default |
|---|---|---|---|
| password | No | Broker password (must be paired with username). Omit for an unauthenticated broker. | |
| username | No | Broker username (must be paired with password). Omit for an unauthenticated broker. | |
| broker_url | No | OpenWire broker URL. Supported forms: tcp://host:61616 (default), ssl://host:61617, or failover:(tcp://h1:61616,tcp://h2:61616). Example: tcp://localhost:61616 | tcp://localhost:61616 |
| timeout_ms | No | Per-probe timeout in milliseconds for the TCP reachability check. | |
| console_port | No | ActiveMQ web-console / Jolokia REST port used to list destinations (default 8161). | |
| list_destinations | No | When true, also query the web console (Jolokia) for the current queues/topics. Degrades gracefully if the console is unreachable. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnly, idempotent, and non-destructive. The description adds valuable behavioral details: TCP probe mechanics, support for failover URL forms, optional Jolokia web-console query, and graceful degradation. No contradiction with annotations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is three sentences, front-loads the primary purpose, and contains no unnecessary filler. Every sentence adds meaningful detail about behavior and constraints.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
With no output schema, the description covers key behavior well, including protocol handling and graceful degradation. However, it does not specify the exact return format, which is a minor gap for a validation tool that may produce a structured report.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, so the baseline is 3. The description adds marginal context (e.g., 'TCP connectivity probe') but largely restates parameter meanings already present in the schema, such as URL forms and list_destinations behavior.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states a specific action ('Check that an ActiveMQ broker is reachable') with a specific resource ('at the given OpenWire URL'). It distinguishes itself from sibling tools (scaffold, build, deploy) by focusing on validation and connectivity probing.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description clearly implies use when validating broker connectivity or listing destinations. It does not explicitly mention when not to use it or name alternatives, but sibling tools are not direct alternatives, so the context is sufficiently clear.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
mq_write_config_tomlWrite broker Config.tomlADestructiveIdempotent
Write or rotate the broker connection Config.toml for an existing project. Sets the [org.project] table with brokerUrl and (optionally) username/password. Note: the acknowledgement mode and transacted flag live in listener.bal (compile-time annotation), so ack_mode/transacted here are written only as documented mirror comments. Overwrites the existing Config.toml.
| Name | Required | Description | Default |
|---|---|---|---|
| ack_mode | No | Optional: documented mirror of the listener ack mode written as a comment (ack mode itself lives in listener.bal, not Config.toml). | |
| org_name | Yes | Ballerina package organisation name (e.g. "acme"). Used in Ballerina.toml and the Config.toml table header [org.project]. | |
| password | No | Broker password (must be paired with username). Omit for an unauthenticated broker. | |
| username | No | Broker username (must be paired with password). Omit for an unauthenticated broker. | |
| broker_url | No | OpenWire broker URL. Supported forms: tcp://host:61616 (default), ssl://host:61617, or failover:(tcp://h1:61616,tcp://h2:61616). Example: tcp://localhost:61616 | tcp://localhost:61616 |
| transacted | No | Optional: documented mirror of the transacted flag (written as a comment). | |
| project_name | Yes | Ballerina package / project name. Becomes the folder <bi_path>/<project_name> and the package name. | |
| project_path | Yes | Absolute or ~/%USERPROFILE%-relative path to an existing scaffolded project root (the folder containing Ballerina.toml). |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare destructiveHint=true and readOnlyHint=false, and the description adds 'Overwrites the existing Config.toml' which aligns with that. It also discloses a subtle behavior: ack_mode/transacted parameters are only written as comments, not actually affecting runtime behavior. This goes beyond the annotations and schema, providing valuable caution.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is three sentences, each earning its place: the action, the table/parameters, and the critical caveat about ack_mode/transacted. It is front-loaded with the verb+resource and contains no fluff or repetition.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a config-writing tool with 8 parameters, no output schema, and strong annotations, the description covers the key aspects: what is written, to which file, and the overwrite behavior. It does not describe the return value or error scenarios, but given the tool's simplicity and the rich schema, this is adequate. The caveat about ack_mode/transacted adds necessary context for correct use.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema covers 100% of parameters with detailed descriptions, so the baseline is 3. The description adds semantic nuance about how ack_mode and transacted are treated (as documented mirror comments), which is not fully obvious from the schema alone. This extra explanation helps the agent understand the real effect of those parameters.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description uses a specific verb+resource: 'Write or rotate the broker connection Config.toml for an existing project.' It clearly states what the tool does and includes an explicit 'Overwrites the existing Config.toml' warning. This distinguishes it from sibling tools like scaffold or add queue, which operate on different resources.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description notes that the tool is for an existing project and that ack_mode/transacted are only mirror comments, implying that actual ack mode should be set via mq_set_ack_mode (a sibling tool). It does not explicitly name alternatives or state 'when not to use', but the context strongly guides the user away from using this tool for setting effective ack mode.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
9 tool updates
v0.1.0- First observed
mq_add_listener - First observed
mq_add_queue - First observed
mq_add_topic - First observed
mq_build_project - First observed
mq_deploy_project - First observed
mq_scaffold_project - First observed
mq_set_ack_mode - First observed
mq_validate_broker - First observed
mq_write_config_toml
TDQS
Scored across 9 tools
Each tool targets a distinct lifecycle stage or resource type: broker validation, project scaffolding, config writing, queue/topic/listener additions, ack mode editing, build, and deploy. The only similar pair (add_queue vs add_topic) is clearly differentiated by destination type (point-to-point vs pub/sub).
All tool names follow the consistent 'mq_verb_noun' pattern with snake_case throughout. Examples include mq_validate_broker, mq_scaffold_project, mq_add_queue, mq_set_ack_mode, and mq_build_project. This uniform convention makes tool discovery and selection highly predictable.
With 9 tools, the server is well-scoped for its purpose of managing an ActiveMQ Ballerina project lifecycle. The count is neither minimal (which would be vague) nor overwhelming, and each tool serves a clear, necessary function from validation through deployment.
The toolset covers the core lifecycle well: validate, scaffold, add components, configure, build, and deploy. Minor gaps exist such as the lack of a remove/teardown tool or a direct JMS message roundtrip test, but these are not critical for the primary scaffolding workflow and can be worked around via the generated code.
Maintenance
Related MCP Connectors
RabbitMQ + Elasticsearch + MySQL Stack Generator
RabbitMQ + Postgres + MongoDB Stack Generator
Build, validate, deploy — HTTP APIs, cron jobs, webhooks and MCP tools — from your AI client.
Build, validate, and deploy multi-agent AI solutions from any AI environment.
Related MCP Servers
- AlicenseAqualityCmaintenanceAn MCP server that lets an AI agent work with an ActiveMQ Artemis broker.8151MIT
- FlicenseAqualityDmaintenanceEnables AI assistants to set up, run, and manage Ballerina + Salesforce integrations inside a WSO2 Integrator workspace, providing 18 tools for OAuth2 token acquisition, project scaffolding, building, deploying, and stopping the integration service.18-
- AlicenseBqualityAmaintenanceEnables AI agents to manage RabbitMQ message brokers through admin APIs, supporting multiple brokers, OAuth authentication, and mutative tools.3941Apache 2.0
- FlicenseNot gradedqualityBmaintenanceAutomates the initialization of Java 21/Spring Boot microservices with Docker Compose, generating complete project archetypes for Seguros Bolivar.-