Bussin Mcp

io.github.sgebb由 GitHub 帳號 sgebb 發布v0.2.0更新於 Nov 1, 2026

MCP server for Azure Service Bus. Peek, search and replay dead-letter messages from any MCP client.

概覽

AI 產生的概覽

針對 Azure Service Bus 的 MCP 伺服器,讓助理列出命名空間、佇列、主題與訂閱,並檢視或搜尋訊息(含死信佇列)。

可以做什麼
  • 列出命名空間、佇列、主題與訂閱,並顯示作用中、死信與排程訊息數量
  • 從佇列、主題訂閱或死信佇列檢視訊息,不加鎖、不取用
  • 依內文子字串、訊息 ID 或主旨搜尋佇列或訂閱,回傳符合的訊息與序號
  • 在操作者啟用後,可傳送訊息並將死信訊息重新提交回來源佇列
  • 在操作者啟用後,可刪除訊息、將作用中訊息移入死信佇列或清空實體
適用情境
適合在聊天用戶端中檢視 Azure Service Bus 訊息代理:找出有積壓的佇列、閱讀死信訊息以診斷失敗原因,或依內容找出特定訊息後再決定如何處理。
執行需求
透過 npx 或全域 npm 安裝在本機執行(需要 Node.js)。預設使用 Entra ID 登入,採用 DefaultAzureCredential(例如 az login、受控識別,或透過 AZURE_TENANT_ID、AZURE_CLIENT_ID 與 AZURE_CLIENT_SECRET 的服務主體)。命名空間上需有角色:檢視與搜尋需 Data Receiver,列出實體需 Reader,僅在啟用傳送時才需 Data Sender。也可改用 SAS 連接字串,但實體探索仍需 Entra ID。示範模式使用內建模擬器,不需 Azure 帳戶。
安裝前請注意
預設唯讀;傳送、重新提交、刪除、移入死信與清空等工具只有在操作者以參數啟用後才會註冊。清空操作要求 confirm 參數與實體名稱完全一致;重新提交預設只把訊息複製回來源佇列,原死信訊息仍保留,除非啟用破壞性工具。連接字串屬於機密憑證,建議優先使用 Entra ID。訊息內文截斷為 4000 字元,掃描受逾時限制。

安裝

在 SourceWeft 中

  1. 開啟 儀表板中的 Bussin Mcp,將其新增到工作區。
  2. 為需要使用其工具的對話啟用該服務。

Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。

其他 MCP 客戶端

參照 儲存庫 中的啟動說明。

README

bussin-mcp

Azure Service Bus tools for Claude, ChatGPT, Cursor, and any other MCP-aware client.

A Model Context Protocol server that lets an AI assistant inspect your Azure Service Bus queues, topics, subscriptions and dead-letter queues. Peek messages, search payloads and replay failures, using the same AMQP client that powers the Bussin web explorer.

Read-only by default. Nothing writes to your broker unless you say so.

bash
npx -y bussin-mcp --demo

Install

bash
npm install -g bussin-mcp

Or run it straight from npx, which is what the client config below does.

Quick start

Try it with no Azure account at all. --demo runs against an in-process simulator with seeded queues:

bash
npx -y bussin-mcp --demo

Claude Code

bash
claude mcp add bussin -- npx -y bussin-mcp --namespace my-namespace

Claude Desktop / Cursor

Add to your MCP config (claude_desktop_config.json, or .cursor/mcp.json):

json
{  "mcpServers": {    "bussin": {      "command": "npx",      "args": ["-y", "bussin-mcp", "--namespace", "my-namespace"]    }  }}

Authentication

Entra ID is the default and the recommended path. The server uses Azure's DefaultAzureCredential, so it picks up whatever you already have:

bash
az login

That also works with managed identity, or a service principal via AZURE_TENANT_ID, AZURE_CLIENT_ID and AZURE_CLIENT_SECRET.

You need two role assignments on the namespace (or its resource group):

RoleWhy
Azure Service Bus Data Receiverpeek and search messages
Azure Service Bus Data Senderonly if you enable --allow-send
Readerlist namespaces, queues and topics with their message counts

A SAS connection string is supported for namespaces your signed-in identity cannot see:

bash
npx -y bussin-mcp --connection-string "Endpoint=sb://...;SharedAccessKeyName=...;SharedAccessKey=..."

Connection strings authenticate the data plane only. Entity discovery (list_queues and friends) goes through Azure Resource Manager and needs Entra ID.

Safety model

The caller is a language model, so anything irreversible is opt-in. Tools you have not enabled are not registered at all: they are invisible to the model rather than merely refused, so there is nothing to talk it into.

FlagUnlocks
(none)list_namespaces, list_queues, list_topics, list_subscriptions, peek_messages, search_messages
--allow-sendsend_message, resubmit_dead_letter
--allow-destructivedelete_messages, dead_letter_messages, purge_entity

Additional guards:

  • Peek is genuinely non-destructive: no lock, no consumption, no delivery-count bump.
  • purge_entity requires confirmation: the confirm argument must exactly equal the entity name being purged.
  • resubmit_dead_letter is additive by default: it copies messages back to the source queue and leaves the dead-lettered originals in place. Removing them additionally requires --allow-destructive.
  • Scans are bounded: searches and purges stop at --search-timeout-ms (default 30s) rather than hanging the call.
  • Message bodies are truncated at 4000 characters per message, so a fat payload cannot blow out the model's context.

Options

OptionEnvironment variableDescription
--namespace <name>BUSSIN_NAMESPACEDefault namespace for tool calls
--demoBUSSIN_DEMORun against the built-in simulator; no Azure, no sign-in
--allow-sendBUSSIN_ALLOW_SENDEnable send and resubmit
--allow-destructiveBUSSIN_ALLOW_DESTRUCTIVEEnable delete, dead-letter and purge
--connection-string <cs>BUSSIN_CONNECTION_STRINGSAS connection string instead of Entra ID
--tenant <id>AZURE_TENANT_IDEntra tenant to authenticate against
--search-timeout-ms <n>BUSSIN_SEARCH_TIMEOUT_MSBound on a single scan or purge (default 30000)

Tools

Always available

  • list_namespaces: every Service Bus namespace the identity can see, across subscriptions
  • list_queues: queues with active, dead-letter and scheduled counts
  • list_topics: topics with message counts
  • list_subscriptions: subscriptions under a topic, with counts
  • peek_messages: read messages from a queue, subscription, or dead-letter queue
  • search_messages: scan for a body substring, message id, or subject

With --allow-send

  • send_message: send to a queue or topic
  • resubmit_dead_letter: replay dead-lettered messages back to their source queue

With --allow-destructive

  • delete_messages: permanently delete specific messages by sequence number
  • dead_letter_messages: move active messages to the dead-letter queue

Service Bus only receives deferred messages by sequence number, so both tools lock messages from the head of the queue up to the requested ones, settle those and release the rest. Their result lists what was settled and, under notFound, any sequence numbers that weren't.

  • purge_entity: delete every message from a queue, subscription, or DLQ

Example prompts

Which queues in my-namespace have dead-lettered messages?

Show me the last 5 dead-lettered messages on the orders queue and tell me what they have in common.

Search the payments subscription for anything mentioning "timeout" in the last batch.

These three DLQ messages failed on a bug we've now fixed, so resubmit them.

Related

Development

bash
npm installnpm run build     # builds the Node bundle of bussin-client-js, then bundles with esbuildnpm test          # drives the server over stdio against the simulatornpm run typecheck # tsc --noEmit

bussin-client-js lives in this repo and is inlined at build time, so the published package is self-contained and has no file: dependency.

Releasing

Publishing is driven by a tag, so it is always deliberate:

  1. Bump version in package.json
  2. Add the release to the changelog
  3. Tag and push:
bash
git tag mcp-v0.1.0 && git push origin mcp-v0.1.0

The workflow refuses to publish if the tag and package.json versions disagree, or if that version is already on npm. It publishes with --provenance, which links the tarball to the workflow run and commit that produced it.

One-time setup: create an npm automation token with publish rights, add it as the NPM_TOKEN secret under a repository environment named npm-publish.

To validate without publishing, run the workflow manually with dry_run enabled.

License

Business Source License 1.1 (BUSL-1.1) — see LICENSE.

Free for personal, educational, and internal business use. Commercial redistribution, rebranding, or hosting this software as a service by third parties is prohibited. Converts to Apache 2.0 on 2029-01-01.

來源:mcp-server/README.md,提交 1fe23e9

工具

6

list_namespaces

List Service Bus namespaces

List the Azure Service Bus namespaces the signed-in identity can see, across all enabled subscriptions. Large tenants can hold dozens, so pass nameFilter whenever you already know roughly what you are looking for. Requires Entra ID sign-in (not available with a connection string).

輸入參數nameFiltersubscriptionId

list_queues

List queues

List queues in a namespace with active, dead-letter and scheduled message counts. Use this before peeking so you know which queues have a backlog.

輸入參數namespace

list_topics

List topics

List topics in a namespace with their message counts. Messages sit on a topic's subscriptions rather than the topic itself, so follow up with list_subscriptions to find where a backlog actually is.

輸入參數namespace

list_subscriptions

List topic subscriptions

List the subscriptions under a topic, with active and dead-letter counts. Use this to pick the subscription to pass to peek_messages or search_messages.

輸入參數topic必填namespace

peek_messages

Peek messages

Peek messages from a queue, or from a topic subscription when topic and subscription are given. Peek is non-destructive: it does not lock, consume, or increment delivery count. Set fromDeadLetter to read the dead-letter queue instead of the main entity. This reads from the head of the entity outwards, so it is the right tool for "what is in this queue"; to find particular messages in a backlog, use search_messages instead of paging through peek. Needs the Azure Service Bus Data Receiver role (or Data Owner).

輸入參數countqueuetopicnamespacefromSequencesubscriptionfromDeadLetter

search_messages

Search messages

Scan a queue or subscription for messages matching a body substring, message id, or subject. Non-destructive. Scanning is bounded by maxMessages and by a server-side timeout, so on a deep backlog prefer a narrow filter. Returns matching messages with their sequence numbers. Prefer this over repeated peek_messages calls whenever you know something about the messages you want. The sequence numbers it returns are what delete_messages, resubmit_dead_letter and dead_letter_messages take as input. Needs the Data Receiver role (or Data Owner).

輸入參數queuetopicnamespacebodyFiltermaxMatchesmaxMessagessubscriptionsubjectFilterfromDeadLettermessageIdFilter

版本歷史

2
  1. v0.2.0最新Oct 31, 2026
  2. v0.1.2Sep 16, 2026

評分

已滿足適用檢查項的 80%

該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。

  • 近 30 天內可連通25 分
  • 已宣告認證方式10 分

    請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。

  • 已列出工具必需15 分
  • 描述必需15 分
  • 圖示10 分
  • 文件15 分
  • 授權條款10 分

    請在儲存庫或註冊中心條目中宣告授權條款。