How to use IBM® App Connect with Microsoft Azure Service Bus

Microsoft Azure Service Bus is a fully managed, cloud-based messaging service that facilitates communication between applications and services by using messages.

Supported product and API versions

To find out which product and API versions this connector supports, see Detailed System Requirements on the IBM Support page.

Connecting to Microsoft Azure Service Bus

Complete the connection fields that you see in the App Connect Designer Connect > Applications and APIs page (previously the Catalog page) or flow editor. If necessary, work with your Microsoft Azure Service Bus administrator to obtain these values.

Microsoft Azure Service Bus has the following authorization types and connection fields.

BASIC
Namespace: Enter the namespace of the Microsoft Azure Service Bus instance.
Tenant ID: Specify the identifier of your Microsoft Azure Active Directory (Azure AD) tenant that is associated with your Microsoft Azure Service Bus instance.
Client ID: Specify the application (client) ID value of your application that is registered in the Microsoft Azure app registration portal to access the Azure Service Bus instance.
Client secret: Specify the client secret of your application that is registered in the Microsoft Azure app registration portal to access the Microsoft Azure Service Bus instance.
Custom endpoint: Specify a custom Azure Service Bus endpoint address if you are using a custom domain or a specific endpoint for your Microsoft Azure Service Bus instance.
Private network connection: Select the name of a private network agent that App Connect uses to connect to your private network. This list is populated with the names of private network agents that are created on the Private networks page. For more information, see Connecting to a private network.
API KEY
Connection string: Specify the read-write or read-only key to access the account in the Microsoft Azure Service Bus service instance
Custom endpoint: Specify a custom Microsoft Azure Service Bus endpoint address if you are using a custom domain or a specific endpoint for your Microsoft Azure Service Bus instance
Private network connection: Select the name of a private network agent that App Connect uses to connect to your private network. This list is populated with the names of private network agents that are created on the Private networks page. For more information, see Connecting to a private network.

To obtain the connection values for Microsoft Azure Service Bus, see Obtaining connection values for Microsoft Azure Service Bus.

To connect to an Microsoft Azure Service Bus endpoint from the App Connect Designer Applications and APIs page for the first time, expand Microsoft Azure Service Bus, then click Connect. For more information, see Managing accounts.

Tip:

Before you use the account that is created in App Connect in a flow, rename the account to something meaningful that helps you to identify it. To rename the account on the Applications and APIs page, select the account, open its options menu (⋮), then click Rename Account.

General Considerations

Before you use App Connect Designer with Microsoft Azure Service Bus, take note of the following considerations:

  • You can see lists of the trigger events and actions that are available on the Applications and APIs page of the App Connect Designer.

    For some applications, the events and actions depend on the environment and whether the connector supports configurable events and dynamic discovery of actions. If the application supports configurable events, you see a Show more configurable events link under the events list. If the application supports dynamic discovery of actions, you see a Show more link under the actions list.

  • If you are using multiple accounts for an application, the set of fields that is displayed when you select an action for that application can vary for different accounts. In the flow editor, some applications always provide a curated set of static fields for an action. Other applications use dynamic discovery to retrieve the set of fields that are configured on the instance that you are connected to. For example, if you have two accounts for two instances of an application, the first account might use settings that are ready for immediate use. However, the second account might be configured with extra custom fields.

Post connection considerations

Take note of the following consideration after you are connected to Microsoft Azure Service Bus:
Message body is returned as a string in the Messages object
  • When you use actions within the Messages object, the message body in the response is automatically converted to a string, even if the original content is an object, array, or another data structure.
  • To work with the original data, use a JSON parser to convert the string into a JSON object.

Events and Actions

Microsoft Azure Service Bus events

These events are for changes in this application that trigger a flow to start completing the actions in the flow.

Event Description
New message Detects new messages in a queue or topic

Microsoft Azure Service Bus actions

Your flow completes these actions on this application.

Object Action Description
Messages Acknowledge a message Acknowledge messages from a queue or topic. This action is used to settle the message after it is processed.
Peek and lock message Nondestructive read from queue or topic. This operation atomically retrieves and locks a message from a queue or subscription for processing.
Receive and commit message Receives and commits messages from queue or topic
Send message Sends a message to a queue or topic
Send messages in bulk Sends messages in bulk to a queue or topic
Queues Create queue Creates a queue in Microsoft Azure Service Bus
Delete queue Deletes a queue from Microsoft Azure Service Bus
Retrieve all queues Retrieves all the queues from Microsoft Azure Service Bus
Retrieve queue by name Retrieves a queue from Microsoft Azure Service Bus by using its name
Update queue Updates a queue in Microsoft Azure Service Bus
Subscriptions Create subscription Creates a subscription to the Microsoft Azure Service Bus topic
Delete subscription Deletes the subscription from the Microsoft Azure Service Bus topic
Retrieve subscription Retrieves a subscription from the Microsoft Azure Service Bus topic
Retrieve subscription by name Retrieves a subscription from the Microsoft Azure Service Bus topic
Update subscription Updates the existing subscription in the Microsoft Azure Service Bus topic
Topics Create topic Creates a topic in Microsoft Azure Service Bus
Delete topic Deletes the topic from Microsoft Azure Service Bus
Retrieve all topics Retrieves all topics from Microsoft Azure Service Bus
Retrieve topic by name Retrieves a topic from Microsoft Azure Service Bus by using its name
Update topic Updates the existing topic in Microsoft Azure Service Bus

Examples

Templates
Use the following templates to quickly create flows for Microsoft Azure Cosmos DB. For more information, see Creating a flow from a template
IBM community blogs

Read blog: Introducing Microsoft Azure Cosmos DB and Azure Service Bus Connectors in IBM App Connect