servicebus-mcp

v0.2.6
servicebus-mcp Checked 2 days ago Published 9 months ago

MCP server for sending and inspecting messages on Azure Service Bus

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

servicebus_list_namespaces

List all Azure Service Bus namespaces in the current subscription. The subscription is resolved automatically — first from the AZURE_SUBSCRIPTION_ID environment variable, then from the active 'az login' session. If neither is available, an error is returned with instructions.

servicebus_list_queues

List all queues in an Azure Service Bus namespace. Returns a sorted JSON array of queue names. The namespace can be given as a short name (e.g. shdapps-dev1-eus2-sbn) or as a fully qualified hostname — the .servicebus.windows.net suffix will be appended automatically if missing.

ParameterTypeDescription
namespace *string

servicebus_list_topics

List all topics in an Azure Service Bus namespace. Returns a sorted JSON array of topic names. If include_subscriptions is true, returns a JSON object mapping each topic name to a sorted array of its subscription names. The namespace can be given as a short name (e.g. shdapps-dev1-eus2-sbn) or as a fully qualified hostname — the .servicebus.windows.net suffix will be appended automatically if missing.

ParameterTypeDescription
namespace *string
include_subscriptionsboolean

servicebus_send_message

Send a single message to an Azure Service Bus queue or topic. The namespace can be given as a short name (e.g. shdapps-dev1-eus2-sbn) or as a fully qualified hostname — the .servicebus.windows.net suffix will be appended automatically if missing. scheduled_enqueue_time accepts an ISO 8601 string (e.g. '2026-03-05T10:00:00Z'). If provided, the message will be enqueued at that time rather than immediately. Auth uses DefaultAzureCredential. Ensure you have run 'az login' before use.

ParameterTypeDescription
body *string
namespace *string
queue *string
application_properties
correlation_id
scheduled_enqueue_time
session_id

servicebus_send_batch

Send multiple messages to an Azure Service Bus queue or topic in a single batch. Each message in the 'messages' array should have: - body (string, required): the message content - session_id (string, optional) - correlation_id (string, optional) - application_properties (object, optional): key/value map of custom properties - scheduled_enqueue_time (string, optional): ISO 8601 time to enqueue the message The entire batch is delivered in a single send operation. Useful for seeding test data.

ParameterTypeDescription
messages *array
namespace *string
queue *string

servicebus_peek_messages

Non-destructively peek at messages in an Azure Service Bus queue. Messages are not locked or consumed — this is a read-only operation. Returns message bodies and metadata (sequence number, enqueue time, properties). max_count is capped at 100. For session-enabled queues, provide a session_id to peek a specific session. If session_id is omitted on a session-enabled queue, the next available session is accepted, peeked, and immediately released. Use servicebus_peek_messages_to_file instead if message bodies may be large.

ParameterTypeDescription
namespace *string
queue *string
max_countinteger
session_id

servicebus_peek_messages_to_file

Non-destructively peek at messages in an Azure Service Bus queue, saving bodies to a file. Message bodies are written to output_file as JSON (keyed by sequence number). Only metadata (sequence number, enqueue time, properties) is returned in context — use this variant when message bodies may be large to avoid filling the context window. For session-enabled queues, provide a session_id to peek a specific session. If session_id is omitted on a session-enabled queue, the next available session is accepted, peeked, and immediately released.

ParameterTypeDescription
namespace *string
output_file *string
queue *string
max_countinteger
session_id

servicebus_peek_dlq

Non-destructively peek at messages in the dead letter queue for an Azure Service Bus queue. Messages are not locked or consumed — this is a read-only operation. Returns message bodies, dead letter reason, error description, and other metadata. max_count is capped at 100. Use servicebus_peek_dlq_to_file instead if message bodies may be large.

ParameterTypeDescription
namespace *string
queue *string
max_countinteger

servicebus_peek_dlq_to_file

Non-destructively peek at messages in the dead letter queue for an Azure Service Bus queue, saving bodies to a file. Message bodies are written to output_file as JSON (keyed by sequence number). Only metadata (dead letter reason, error description, sequence number, enqueue time) is returned in context.

ParameterTypeDescription
namespace *string
output_file *string
queue *string
max_countinteger

servicebus_purge_dlq

Delete all messages from the dead letter queue for an Azure Service Bus queue. THIS IS DESTRUCTIVE — messages cannot be recovered after purging. Stops and leaves remaining messages untouched if the running total exceeds max_messages.

ParameterTypeDescription
namespace *string
queue *string
max_messagesinteger

servicebus_requeue_dlq

Move messages from a queue's dead letter queue back to the main queue. Each message is re-sent to the main queue preserving body, session_id, correlation_id, and application_properties, then completed (removed) from the dead letter queue. Stops if the running total would exceed max_messages.

ParameterTypeDescription
namespace *string
queue *string
max_messagesinteger

servicebus_purge_queue

Delete all messages from an Azure Service Bus queue. THIS IS DESTRUCTIVE — messages cannot be recovered after purging. Stops and leaves remaining messages untouched if the running total exceeds max_messages.

ParameterTypeDescription
namespace *string
queue *string
max_messagesinteger

servicebus_peek_subscription_messages

Non-destructively peek at messages in an Azure Service Bus topic subscription. Messages are not locked or consumed — this is a read-only operation. Returns message bodies and metadata (sequence number, enqueue time, properties). max_count is capped at 100. For session-enabled subscriptions, provide a session_id to peek a specific session. If session_id is omitted on a session-enabled subscription, the next available session is accepted, peeked, and immediately released. Use servicebus_peek_subscription_messages_to_file instead if message bodies may be large.

ParameterTypeDescription
namespace *string
subscription *string
topic *string
max_countinteger
session_id

servicebus_peek_subscription_messages_to_file

Non-destructively peek at messages in an Azure Service Bus topic subscription, saving bodies to a file. Message bodies are written to output_file as JSON (keyed by sequence number). Only metadata (sequence number, enqueue time, properties) is returned in context — use this variant when message bodies may be large to avoid filling the context window. For session-enabled subscriptions, provide a session_id to peek a specific session. If session_id is omitted on a session-enabled subscription, the next available session is accepted, peeked, and immediately released.…

ParameterTypeDescription
namespace *string
output_file *string
subscription *string
topic *string
max_countinteger
session_id

servicebus_peek_subscription_dlq

Non-destructively peek at messages in the dead letter queue for a topic subscription. Messages are not locked or consumed — this is a read-only operation. Returns message bodies, dead letter reason, error description, and other metadata. max_count is capped at 100. Use servicebus_peek_subscription_dlq_to_file instead if message bodies may be large.

ParameterTypeDescription
namespace *string
subscription *string
topic *string
max_countinteger

servicebus_peek_subscription_dlq_to_file

Non-destructively peek at messages in the dead letter queue for a topic subscription, saving bodies to a file. Message bodies are written to output_file as JSON (keyed by sequence number). Only metadata (dead letter reason, error description, sequence number, enqueue time) is returned in context.

ParameterTypeDescription
namespace *string
output_file *string
subscription *string
topic *string
max_countinteger

servicebus_purge_subscription

Delete all messages from an Azure Service Bus topic subscription. THIS IS DESTRUCTIVE — messages cannot be recovered after purging. Stops and leaves remaining messages untouched if the running total exceeds max_messages.

ParameterTypeDescription
namespace *string
subscription *string
topic *string
max_messagesinteger

servicebus_purge_subscription_dlq

Delete all messages from the dead letter queue for a topic subscription. THIS IS DESTRUCTIVE — messages cannot be recovered after purging. Stops and leaves remaining messages untouched if the running total exceeds max_messages.

ParameterTypeDescription
namespace *string
subscription *string
topic *string
max_messagesinteger

servicebus_requeue_subscription_dlq

Move messages from a topic subscription's dead letter queue back to the topic. Each message is re-sent to the topic preserving body, session_id, correlation_id, and application_properties, then completed (removed) from the dead letter queue. Stops if the running total would exceed max_messages.

ParameterTypeDescription
namespace *string
subscription *string
topic *string
max_messagesinteger