> For the complete documentation index, see [llms.txt](https://docs.fastn.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.fastn.ai/connectors/catalog/cloud-devops/azure-service-bus.md). Agents can also search and read this documentation through its [MCP server](https://docs.fastn.ai/~gitbook/mcp).

# Azure Service Bus

Azure Service Bus is a cloud message broker. Send and receive messages on queues and topics, and manage queues, topics, subscriptions and rules.

![Azure Service Bus logo](https://1255842839-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F3iSr2Tx8FvvuoLPncziH%2Fuploads%2Fgit-blob-13158de3421c6a337d0d1b743a2fa7ec70645fa2%2Fazure-service-bus.png?alt=media)

|                    |                                                                                            |
| ------------------ | ------------------------------------------------------------------------------------------ |
| **Category**       | [Cloud and DevOps](https://docs.fastn.ai/connectors/catalog/cloud-devops.md)               |
| **Website**        | [servicebus.windows.net](https://servicebus.windows.net)                                   |
| **Authentication** | Namespace and shared access key                                                            |
| **Slug**           | `azureServiceBus`                                                                          |
| **On fastn.ai**    | [Embed Azure Service Bus in your product](https://fastn.ai/integrations/azure-service-bus) |

## Setup

Your customers enter their namespace and shared access key for Azure Service Bus when they connect. Nothing else needs setting up.

## Connect in Fastn

Your customers connect Azure Service Bus from your widget. To connect an account yourself:

1. Go to **Build → Integrations → Connectors** and search for **Azure Service Bus**.
2. Select **Connect** on the Azure Service Bus card.

   <figure><img src="https://1255842839-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F3iSr2Tx8FvvuoLPncziH%2Fuploads%2Fgit-blob-586dd03cdc0c6904263f58928d7a531eae2f85df%2Fconnect-search.png?alt=media" alt="The Connectors page in Fastn with ServiceNow typed in the search box and the ServiceNow card showing a Connect button"><figcaption><p>Search for the connector, then select Connect on its card. ServiceNow is shown here.</p></figcaption></figure>
3. Fill in the fields the form asks for, using the values from [Setup](#setup) above. Then select **Connect**.

   <figure><img src="https://1255842839-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F3iSr2Tx8FvvuoLPncziH%2Fuploads%2Fgit-blob-51fb88ef328c525b5b11f8d7094bab11efc333b8%2Fconnect-credentials.png?alt=media" alt="The Connect ServiceNow dialog with an optional account name and the Instance, Username and Password fields, and Cancel and Connect buttons"><figcaption><p>A connect form that asks for credentials. Each connector asks for its own fields.</p></figcaption></figure>
4. Check that the connection appears under **Operate → Connections** with the status `Active`. Your workflows can now use Azure Service Bus's actions.

For more detail, see [Connect an app](https://docs.fastn.ai/build/integrations/connectors/connect-an-app.md).

## Actions

<table><thead><tr><th width="240">Action</th><th width="260">Slug</th><th>What it does</th></tr></thead><tbody><tr><td>Abandon Queue Message</td><td><code>abandonQueueMessage</code></td><td>Abandon a peek-locked queue message, making it available for re-processing. The message lock is released immediately.</td></tr><tr><td>Abandon Subscription Message</td><td><code>abandonSubscriptionMessage</code></td><td>Abandon a peek-locked subscription message, releasing the lock and making it available again.</td></tr><tr><td>Complete Queue Message (Delete Locked)</td><td><code>completeQueueMessage</code></td><td>Complete (acknowledge) a peek-locked queue message, removing it from the queue. Provide the messageId and lockToken from a previous peek-lock.</td></tr><tr><td>Complete Subscription Message</td><td><code>completeSubscriptionMessage</code></td><td>Complete (acknowledge) a peek-locked topic subscription message, removing it from the subscription.</td></tr><tr><td>Create Queue</td><td><code>createQueue</code></td><td>Create a new queue in the namespace. Provide queue properties as XML body (QueueDescription).</td></tr><tr><td>Create Subscription</td><td><code>createSubscription</code></td><td>Create a new subscription on a topic.</td></tr><tr><td>Create Subscription Rule</td><td><code>createRule</code></td><td>Create a SQL-filter rule on a topic subscription so it only receives messages matching the SQL expression (evaluated over message and user properties). Create a rule named '$Default' to replace the catch-all filter.</td></tr><tr><td>Create Topic</td><td><code>createTopic</code></td><td>Create a new topic in the namespace.</td></tr><tr><td>Delete Queue</td><td><code>deleteQueue</code></td><td>Delete a queue from the namespace. All messages in the queue are discarded.</td></tr><tr><td>Delete Subscription</td><td><code>deleteSubscription</code></td><td>Delete a subscription from a topic.</td></tr></tbody></table>

<details>

<summary>View 25 more actions</summary>

<table><thead><tr><th width="240">Action</th><th width="260">Slug</th><th>What it does</th></tr></thead><tbody><tr><td>Delete Subscription Rule</td><td><code>deleteRule</code></td><td>Delete a rule (filter) from a topic subscription by name.</td></tr><tr><td>Delete Topic</td><td><code>deleteTopic</code></td><td>Delete a topic and all its subscriptions from the namespace.</td></tr><tr><td>Get Queue</td><td><code>getQueue</code></td><td>Get metadata and runtime info for a specific queue, including message counts.</td></tr><tr><td>Get Subscription</td><td><code>getSubscription</code></td><td>Get metadata for a topic subscription, including message counts.</td></tr><tr><td>Get Subscription Rule</td><td><code>getRule</code></td><td>Get a single rule (filter + optional action) by name from a topic subscription.</td></tr><tr><td>Get Topic</td><td><code>getTopic</code></td><td>Get metadata for a specific topic.</td></tr><tr><td>List Queues</td><td><code>listQueues</code></td><td>List all queues in the Service Bus namespace. Returns Atom XML with queue metadata.</td></tr><tr><td>List Subscription Rules</td><td><code>listRules</code></td><td>List all rules (filters) configured on a topic subscription. Each subscription has at least one rule; the default is a TrueFilter that matches everything.</td></tr><tr><td>List Subscriptions</td><td><code>listSubscriptions</code></td><td>List all subscriptions for a topic.</td></tr><tr><td>List Topics</td><td><code>listTopics</code></td><td>List all topics in the Service Bus namespace.</td></tr><tr><td>Peek-Lock Queue Message</td><td><code>peekLockQueueMessage</code></td><td>Non-destructively peek and lock the first available message from a queue; returns the message body. NOTE: Service Bus returns the lock token and message id in the 'BrokerProperties' HTTP response header, which the connector executor does not currently surface. As a result, completing/abandoning/renewing this exact locked message through the connector is not possible (the settle actions need a lock token obtained out-of-band). For straightforward at-least-once consumption, prefer Receive and Delete.</td></tr><tr><td>Peek-Lock Subscription Message</td><td><code>peekLockSubscriptionMessage</code></td><td>Peek-lock the first available message from a topic subscription; returns the message body. NOTE: the lock token and message id come back in the 'BrokerProperties' HTTP response header, which the connector executor does not currently surface, so completing/abandoning/renewing this exact locked message through the connector is not possible. For straightforward at-least-once consumption, prefer Receive and Delete.</td></tr><tr><td>Receive and Delete Dead-Letter Queue Message</td><td><code>receiveDeadLetterQueueMessage</code></td><td>Destructively receive a message from the dead-letter sub-queue of a queue ($DeadLetterQueue).</td></tr><tr><td>Receive and Delete Dead-Letter Subscription Message</td><td><code>receiveDeadLetterSubscriptionMessage</code></td><td>Destructively receive the first message from the dead-letter sub-queue of a topic subscription ($DeadLetterQueue).</td></tr><tr><td>Receive and Delete Queue Message</td><td><code>receiveAndDeleteQueueMessage</code></td><td>Destructively receive the first message from a queue (receive-and-delete mode). The message is removed from the queue immediately.</td></tr><tr><td>Receive and Delete Subscription Message</td><td><code>receiveAndDeleteSubscriptionMessage</code></td><td>Destructively receive the first available message from a topic subscription.</td></tr><tr><td>Renew Queue Message Lock</td><td><code>renewQueueMessageLock</code></td><td>Renew the lock on a peek-locked queue message to extend the processing time.</td></tr><tr><td>Renew Subscription Message Lock</td><td><code>renewSubscriptionMessageLock</code></td><td>Renew the lock on a peek-locked subscription message.</td></tr><tr><td>Send Batch Messages to Queue</td><td><code>sendBatchMessagesToQueue</code></td><td>Send a batch of messages to a Service Bus queue in a single request (application/vnd.microsoft.servicebus.params+json body).</td></tr><tr><td>Send Batch Messages to Topic</td><td><code>sendBatchMessagesToTopic</code></td><td>Publish a batch of messages to a Service Bus topic in a single request. Each message is an object with a Body and optional BrokerProperties/UserProperties. All active subscriptions receive a copy.</td></tr><tr><td>Send Message to Queue</td><td><code>sendMessageToQueue</code></td><td>Send a message to a Service Bus queue. The message body is sent as plain text. Optional properties: BrokerProperties (JSON), custom user properties, content type.</td></tr><tr><td>Send Message to Topic</td><td><code>sendMessageToTopic</code></td><td>Publish a message to a Service Bus topic. All active subscriptions will receive a copy.</td></tr><tr><td>Update Queue</td><td><code>updateQueue</code></td><td>Update properties of an existing queue. Uses PUT with If-Match: * to modify the QueueDescription in place. Only supply the properties you want to change.</td></tr><tr><td>Update Subscription</td><td><code>updateSubscription</code></td><td>Update properties of an existing topic subscription. Uses PUT with If-Match: * to modify the SubscriptionDescription in place.</td></tr><tr><td>Update Topic</td><td><code>updateTopic</code></td><td>Update properties of an existing topic. Uses PUT with If-Match: * to modify the TopicDescription in place.</td></tr></tbody></table>

</details>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.fastn.ai/connectors/catalog/cloud-devops/azure-service-bus.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
