Using Managed Identities in a Logic App

Published by Tanguy SCHOUBERT
Category : Azure / Logic Apps



Ensuring the security and integrity of connections between resources is essential when implementing solutions on Azure. In this regard, Azure Logic Apps, among other Azure services, offers the Managed Identities functionality, simplifying authentication. In this article, I will guide you step by step on how to use this feature with Azure Storage and Azure Service Bus. Currently, Microsoft recommends this solution for authentication.



To get started, you should have previously created your Logic App, Azure storage account, and Azure Service Bus.

Step 1: Enable Managed Identity


  1. Go to the Azure portal and navigate to your Logic App.
  2. In the left panel, select “Identity” under “Settings.”
  3. In the “System assigned” section, enable the status by choosing “On” and confirm by clicking “Save.”


enable managed identity


It is possible to configure a User assigned identity, but it’s up to you to manage this identity. This provides more flexibility, such as the ability to share an identity among multiple resources, for example.

Step 2: Assign Roles to Your Managed Identity


First, go to your Azure storage account. In “Access control (IAM),” choose “Add role assignment.”

Then, assign the “Storage Blob Data Contributor” role to the Logic App. For Azure Service Bus, the process is similar. Depending on your needs, assign the “Azure Service Bus Data Sender” or “Azure Service Bus Data Receiver” role.
Assign role to managed identity


Step 3: Authentication in Logic App


When configuring a connector in your Logic App for Azure Storage or Azure Service Bus, choose “Managed Identity” as the authentication method.

Then, select the previously configured identity.

Authenticate with Managed Identity


Step 4: Test Your Configuration


It’s time to test! Create an action within your Logic App to interact with Azure Storage or Azure Service Bus. When you run your Logic App, make sure there are no authentication errors.



In conclusion, Managed Identities eliminate the need to manage API keys or other secrets, making authentication more secure.

Note: For a detailed explanation and the latest features, please refer to the official documentation: link to documentation.