Category Archives: Logic App
Post message on teams with logic app
Hello everyone in this blog we will see how we can post a message on a teams channel using logic app. Step 1: Go to portal.azure.com and select logic app azure service. Step 2: Create a logic by filling the details accordingly. Step 3: Select the recurrence trigger for logic app Step 4: Now click on new step and select Ms Teams connector. Step 5: Select Post message on teams options. Step 6: Select your teams channel name and channel and write the message that you want to send. In this way you can post a message on teams. Hope this helps.
Share Story :
Developer Tools for Logic Apps 1 : Create Logic app using Azure Portal
Azure Logic Apps is a cloud service that automates the execution of your business processes or workflows. It allows you to use a graphical design tool called the Logic Apps Designer to arrange pre-made components into the sequence you need. There are three ways in which we can create Logic App. Azure Portal – probably the most used form. Visual Studio – probably the favourite tool amongst developers. Visual Studio Code – with is getting more fans every day. Let’s Create logic app using Azure Portal Sign into the Azure Portal with your Azure account credentials. In the Azure portal search box, enter Logic Apps, and select Logic Apps. On the Logic Apps page, select Add. On the Logic App pane, provide the following details and then select Review + Create, and select Create. If you have more than one subscription, select the proper one from the Subscription combo box. On the Resource group, select an existing one or create a new one, but be aware that the Azure Resource group’s name must be unique inside your subscription. On the Logic App Name field, provide a name to your Logic App. Again, it has to be unique and can contain only letters, numbers, hyphens (-), underscores (_), parentheses ((,)), and periods (.). From the existing options, select the region where you want to store your logic apps on the Location field. You can also choose to enable Log Analytics to push the Logic App runtime events into it and help you monitor your workflows. After Azure successfully deploys your app, select Go to resource. Select a blank Logic app. To do that you need to select Blank Logic App under Templates and You can start defining your start building your sequence of tasks.
Share Story :
Developer Tools for Logic Apps 2: How to Add Logic App extension in Visual Studio
In order to create logic app using visual studio we should have VS Community edition or greater. Prerequisites Visual Studio 2019, 2017, or 2015 – Community edition or greater; Visual Studio Tools for Azure: In the Visual Studio installer, install Visual Studio (or modify an existing installation). Make sure the Azure development and ASP.NET and web development workloads are selected. Install Azure Logic Apps Tools for Visual Studio 2019 Open your Visual Studio, on the entry screen select the option Continue without code -> Then on the menu, navigate to Extensions > Manage Extensions Select Online and search for Logic Apps The add-in will be listed in the search results section. Click Download to download and install the add-in. You need to close your Visual Studio in order to begin installing this extension. On the VSIX Installer screen Make sure that the correct version of Visual Studio is selected. Click Install or Modify. This will download and install the add-in to your version of Visual Studio. At the end select Close.
Share Story :
Developer Tools for Logic Apps 3: Using the Visual Studio to create your Logic Apps
The Logic Apps designer integrates with the current Azure Resource Group project so you can seamlessly work with resource deployments that include Logic Apps. Open Visual Studio and on the Create a new project panel, select C# > Azure > Cloud, or select for Azure Resource Group; Select Azure Resource Group from the template list; On the Configure your new project panel, give a proper Project name, Location, Solution name, and leave the Framework as .Net Framework 4.7.2 and select Create. Finally, on the Select Azure Template panel, from the Visual Studio Templates list, select the Logic App template and select OK. This will create an empty Visual Studio Logic App solution. Now on the Visual Studio solution: Right-click on the LogicApp.json file and select Open With Logic App Designer This will open a Logic App Properties window, where you need to: Define the credentials to authenticate on the Azure subscription; Define the Subscription and Resource Group where you want to create these resources; Define if you want the Location to be in the same Region or in an Integration Service Environment (ISE) and click on OK; This will embed the Logic App designer inside the Visual Studio.
Share Story :
Developer Tools for Logic Apps 4: Using the Visual Studio Code to create your Logic Apps
VS Code is the light weight and yet powerful editor to create logic app. In order to create logic app in VS code you must have Visual Studio Code 1.31.0 (January 2019) or later. To start with, first, you must install the extension from the marketplace. To do that, search Azure Logic Apps extension in the marketplace and Click on Install. Open your Visual Studio Code and bring up the Extensions view by clicking on the Extensions icon in the Activity Bar on the side of VS Code. And search Azure Logic Apps; After the installation of these extensions, you will find the two Azure Logic Apps section and then click on the Sign In Azure option. After you sign in then navigate to your subscriptions and create new Logic app (for this you need to right click on the subscription and select create new logic app) This will open a small Logic App creation wizard on the top, in the center of the Visual Studio Code window, asking if we want to Create a new resource group or choose an existing one. If we select Create new resource group, then a new window appears asking for you to provide the resource group name Then we need to select a location to where the resource will be added In last step of the wizard will be providing a name for your Logic App
Share Story :
How to Read value from App Configuration in Logic App
Azure App Configuration is a managed service that helps developers centralize their application configuration and feature settings simply and securely. Use Azure App Configuration to store and secure configuration settings for your application in a single location. App configuration offer the following benefits. A fully managed service that can be set up in minutes Flexible key representations and mappings Tagging with labels Point-in-time replay of settings Dedicated UI for feature flag management App configuration is useful in following Scenario. Centralize management and distribution of hierarchical configuration data for different environments and geographies Dynamically change application settings without the need to redeploy or restart an application Control feature availability in real-time The only problem was that unlike Key Vault, which has an available connector to be used inside Logic Apps, App Configuration doesn’t have a connector available. So in order to implement this scenario we’ll going to use Azure function app Create an Azure Function App: The Azure Functions project template in Visual Studio creates a project that you can publish to a function app in Azure. From the Visual Studio menu, select File > New > Project. In Create a new project, enter functions in the search box, choose the Azure Functions template, and then select Next. In Configure your new project, enter a Project name for your project, and then select Create. The function app name must be valid as a C# namespace, so don’t use underscores, hyphens, or any other nonalphanumeric characters. Select Httptrigger function app Connect to App configuration store: Right-click your project, and select Manage NuGet Packages. On the Browse tab, search for and add the Microsoft.Extensions.Configuration.AzureAppConfiguration NuGet package to your project. Add the following namespaces of the .NET Core configuration and the App Configuration provider. using Microsoft.Extensions.Configuration; using Microsoft.Extensions.Configuration.AzureAppConfiguration; The key that we want to read should be passed by query parameter. string appKey = req.Query[“appKey”]; And finally, the function should raise proper HTTP response status codes according to the situation: 200 Ok if successful returns a value for that key 500 Internal Server Error if something fails, for example, there is no connection string to the App Configuration defined and 404 Not Found if the key is not found Use below code for reference if(string.IsNullOrEmpty(appKey)) return new BadRequestObjectResult(“parameter ‘appKey’ not found or empty.”); try { string connectionString = Environment.GetEnvironmentVariable(“AppConfigConnection”); var builder = new ConfigurationBuilder(); builder.AddAzureAppConfiguration(connectionString); var build = builder.Build(); string keyValue = build[appKey.ToString()]; if (string.IsNullOrEmpty(keyValue)) { var result = new ObjectResult(“Azure Configuration Key not found – ” + appKey); result.StatusCode = StatusCodes.Status404NotFound; return result; } else return new OkObjectResult(keyValue); } catch(Exception ex) { var result = new ObjectResult(ex.Message); result.StatusCode = StatusCodes.Status500InternalServerError; return result; } Once you create your Function App and all you key-values inside App Configuration, you have to: Go to your Function App Configuration option under Settings And create a new application settings call AppConfigConnection containing the connection string to your App Configuration resource. Once we done that you can call Azure Function in your logic app