AZ-104Chapter 109 of 168Objective 3.3

Azure Logic Apps Workflows

This chapter covers Azure Logic Apps workflows, a key compute service for automating business processes and integrating applications without writing code. For the AZ-104 exam, you must understand when to use Logic Apps versus other Azure compute services, how to design workflows with triggers and actions, and how to manage and monitor them. Approximately 10-15% of exam questions touch on integration services, with Logic Apps being a significant part. This chapter provides the depth needed to answer scenario-based questions confidently.

25 min read
Intermediate
Updated May 31, 2026

The Order Processing Pipeline

Imagine a package delivery hub that receives orders from multiple sources (email, phone, web forms). Each order is a message that needs to be processed through a series of steps: validate address, check inventory, calculate shipping, and send confirmation. The hub has a conveyor belt system where each step is a station. A controller (the workflow engine) reads the order, then directs it to the first station. After that station finishes, the controller moves the order to the next, and so on. If a station fails (e.g., inventory system down), the controller can retry the step a few times or move the order to a 'problem pile' (dead-letter queue). The controller also logs every action and can trigger alerts if orders pile up. This is exactly how Azure Logic Apps works: triggers receive events, actions process them step by step, and the engine manages state, retries, and error handling automatically.

How It Actually Works

What is Azure Logic Apps and Why Does It Exist?

Azure Logic Apps is a cloud-based platform for creating and running automated workflows that integrate apps, data, services, and systems. It is designed to solve the problem of connecting disparate systems without writing complex integration code. Logic Apps provides a visual designer and hundreds of prebuilt connectors to services like Office 365, SQL Server, Salesforce, and Azure services. Workflows are defined declaratively using a JSON-based workflow definition language (Workflow Definition Language) and are executed by the Azure Logic Apps runtime.

For the AZ-104 exam, you need to know that Logic Apps is a serverless compute option (though it can also run in an integration service environment). It is billed based on execution and connector usage, not on pre-provisioned VMs. This makes it cost-effective for sporadic workloads.

How Logic Apps Works Internally

A Logic App workflow consists of two main parts: triggers and actions. The trigger is the event that starts the workflow. Actions are the steps that run after the trigger fires. The workflow engine orchestrates the execution, handling state, retries, and error handling.

Trigger Types:

Polling triggers: Check for new data at a regular interval (e.g., every minute). The trigger is 'fired' when the condition is met (e.g., new email in inbox).

Push triggers: Receive events immediately via webhooks (e.g., when an HTTP request is received).

Event triggers: Respond to events in Azure services (e.g., when a blob is created in Azure Storage).

The trigger has a state that determines whether it has fired. For polling triggers, the state includes a timestamp of the last check. The trigger's recurrence interval is configurable (minimum 1 second for some connectors, but typically 1 minute for polling).

Actions:

Each action is a step that performs an operation, such as calling an API, transforming data, or sending an email. Actions can be:

Built-in actions: HTTP, Request, Response, Compose, Parse JSON, etc.

Managed connector actions: Office 365, SQL Server, Azure Blob Storage, etc.

Custom connector actions: Created by users for proprietary APIs.

Actions can be sequential, parallel, or conditional using loops, conditions, and switches.

Workflow Execution:

When a trigger fires, the Logic Apps runtime creates a workflow run instance. The run executes each action in the defined order (or in parallel if specified). The runtime manages:

State persistence: The state of each run is stored in Azure Storage. By default, run history is retained for 90 days (configurable up to 90 days).

Retry policy: Actions can be configured to retry on failure with exponential backoff. Default retry: 4 attempts with 7-second interval, but configurable.

Timeout: Each action has a timeout. Built-in actions have a 120-second timeout by default; connector actions have 2-minute timeout.

Error handling: You can configure fallback actions (e.g., send alert on failure) using the 'Configure run after' setting.

Workflow Definition Language (WDL):

The workflow is defined in JSON. A simplified example:

{
    "definition": {
        "$schema": "https://schema.management.azure.com/providers/Microsoft.Logic/schemas/2016-06-01/workflowdefinition.json#",
        "actions": {
            "Send_an_email": {
                "inputs": {
                    "body": {
                        "Content": "Order received: @{triggerBody()?['OrderID']}",
                        "Subject": "New Order"
                    },
                    "host": {
                        "connection": {
                            "name": "@parameters('$connections')['office365']['connectionId']"
                        }
                    },
                    "method": "post",
                    "path": "/v2/Mail"
                },
                "runAfter": {},
                "type": "ApiConnection"
            }
        },
        "contentVersion": "1.0.0.0",
        "outputs": {},
        "parameters": {
            "$connections": {
                "defaultValue": {},
                "type": "Object"
            }
        },
        "triggers": {
            "When_a_HTTP_request_is_received": {
                "inputs": {
                    "schema": {}
                },
                "kind": "Http",
                "type": "Request"
            }
        }
    },
    "parameters": {}
}

Key Components, Values, Defaults, and Timers

Connectors: There are over 200 managed connectors. Each connector has a set of actions and triggers. For example, the Office 365 Outlook connector has triggers like 'When a new email arrives' and actions like 'Send an email'.

Custom connectors: Allow you to wrap your own REST APIs. They use OpenAPI (Swagger) or Postman collections.

Integration Service Environment (ISE): A dedicated environment for Logic Apps that runs in your virtual network. Provides higher performance, network isolation, and predictable pricing. For AZ-104, know that ISE is used for compliance or high-volume scenarios.

Limits: Default limits: 50 MB for request/response body (2 MB for single actions), 500 actions per workflow, 100 concurrent runs (per Logic App), 90-day retention of run history. These can be increased by contacting support or using ISE.

Pricing plans: Consumption (pay-per-execution) and ISE (fixed monthly).

Monitoring: Use Azure Monitor, Log Analytics, and Application Insights to track run history, failures, and performance. Alerts can be set on failed runs.

Configuration and Verification Commands

You can create and manage Logic Apps using Azure Portal, Azure CLI, PowerShell, or ARM templates.

Azure CLI example:

# Create a resource group
az group create --name MyResourceGroup --location westus

# Create a Logic App (consumption plan)
az logic workflow create --resource-group MyResourceGroup --location westus --name MyLogicApp --definition "path_to_definition.json"

# List all Logic Apps in a resource group
az logic workflow list --resource-group MyResourceGroup --output table

# Trigger a run
az logic workflow trigger --resource-group MyResourceGroup --name MyLogicApp --trigger-name manual

# View run history
az logic workflow run list --resource-group MyResourceGroup --name MyLogicApp --output table

How Logic Apps Interacts with Related Technologies

Azure Functions: Logic Apps can call Azure Functions as an action. Use Functions for custom code that Logic Apps cannot perform natively.

Azure API Management: Logic Apps can expose APIs through API Management for governance and security.

Azure Service Bus: Logic Apps can trigger on messages from Service Bus queues/topics.

Event Grid: Logic Apps can subscribe to Event Grid events and trigger workflows.

Power Automate: Power Automate is built on the same platform as Logic Apps but is designed for citizen developers. Logic Apps offers more advanced features and integration capabilities.

Exam Focus: What AZ-104 Tests

AZ-104 exam objective 3.3 includes implementing Logic Apps workflows. You should be able to:

Choose between Logic Apps and other compute services (Functions, WebJobs, etc.) based on scenario.

Design a workflow with appropriate triggers and actions.

Manage and monitor Logic Apps.

Understand pricing models (Consumption vs ISE).

Know connectors and when to use custom connectors.

Troubleshoot failed runs using run history and diagnostic logs.

Common wrong answers: Selecting Azure Functions when the scenario requires no-code integration; confusing Logic Apps with Power Automate (Power Automate is for Microsoft 365 scenarios, Logic Apps for enterprise integration).

Walk-Through

1

Create a Logic App

In the Azure Portal, navigate to 'Create a resource' > 'Integration' > 'Logic App'. Choose either 'Consumption' (pay-per-execution) or 'Standard' (hosted in an App Service plan). For AZ-104, focus on Consumption. Provide a name, subscription, resource group, and location. The location determines where the workflow definition is stored and executed. After creation, the Logic Apps Designer opens, allowing you to build the workflow.

2

Add a trigger

Triggers are the starting point. Common triggers include 'When a HTTP request is received' (manual trigger), 'Recurrence' (schedule-based), or 'When a new blob is created' (event-based). For polling triggers, set the recurrence interval (e.g., every 5 minutes). For push triggers, the Logic App creates a callback URL that external systems call. The trigger defines the input schema for the workflow.

3

Add actions

After the trigger, add one or more actions. Actions can be sequential or parallel. Use the designer to search for connectors and select actions (e.g., 'Send an email' from Office 365). Configure each action's inputs, which can be static or dynamic expressions (e.g., `@{triggerBody()?['field']}`). Set 'run after' conditions to define dependencies (e.g., run only if previous action succeeded, failed, or timed out).

4

Configure error handling

For each action, you can configure retry policy (number of retries, interval, and type: fixed, exponential, or none). Also, you can add parallel branches for error handling: e.g., if an action fails, send a notification. Use the 'Configure run after' setting to specify that a subsequent action runs only if the previous action failed. This is crucial for robust workflows.

5

Test and monitor

Trigger a run manually or wait for the scheduled trigger. In the Logic App blade, go to 'Overview' > 'Run history' to see each execution. Click on a run to see the status of each action (Succeeded, Failed, Skipped). Use 'Diagnostics settings' to send logs to Log Analytics. Create alerts based on failed runs. The run history is retained for 90 days by default.

What This Looks Like on the Job

Scenario 1: Order Processing in E-commerce

A company uses an on-premises ERP system and wants to automatically send order confirmations and update inventory when orders are placed through a web app. They deploy a Logic App with an HTTP trigger (webhook) that receives order JSON from the web app. The Logic App then: 1) Validates the order using a custom connector to the ERP, 2) Sends a confirmation email via Office 365, 3) Posts a message to a Service Bus queue for inventory update. In production, they handle peak loads (thousands of orders per hour) by using a Standard Logic App (higher throughput) and setting retry policies for transient failures. Misconfiguration often occurs when the HTTP trigger schema does not match the incoming payload, causing parse errors. They use run history and Application Insights to monitor failures.

Scenario 2: Automated Approval Workflow

A finance department needs a system for expense report approvals. When an employee submits an expense report in SharePoint, a Logic App triggers on new item creation. The workflow sends an approval email to the manager using the 'Send approval email' action (which uses Office 365). The manager can approve or reject via email. Based on the response, the Logic App updates the SharePoint item status and sends a notification to the employee. In production, they handle hundreds of reports per day. A common issue is that the email approval action requires the manager to reply with a specific format; if the reply is not recognized, the workflow times out. They mitigate this by adding a timeout and fallback action to escalate.

Scenario 3: IoT Data Processing

A manufacturing company collects sensor data from machines via Azure IoT Hub. They want to process alerts when temperature exceeds a threshold. A Logic App triggers on IoT Hub events (via Event Grid). The workflow parses the message, checks the temperature, and if above threshold, sends an SMS via Twilio connector and logs the event to Azure Table Storage. In production, they have thousands of devices sending data every minute. They use a Consumption plan with high concurrency (default 100 concurrent runs) but had to request an increase to 500 due to spikes. Misconfiguration: forgetting to set a retry policy on the SMS action caused missed alerts when the SMS provider was temporarily unavailable.

How AZ-104 Actually Tests This

AZ-104 Objective 3.3: Implement Logic Apps workflows

The exam tests your ability to choose the right compute service for integration scenarios. Key decision points:

Logic Apps vs Azure Functions: If the workflow requires stateful orchestration, multiple steps, or connectors to SaaS services, choose Logic Apps. If you need custom code with complex logic, use Functions. The exam often presents a scenario where a candidate selects Functions because they think they need custom code, but the scenario describes a simple integration with Office 365 — Logic Apps is correct.

Consumption vs Standard: Consumption is for most scenarios; Standard is for higher throughput, VNet integration, and dedicated compute. The exam may ask which plan to use for a scenario requiring network isolation.

Triggers: Know that polling triggers have a minimum interval (usually 1 minute) and that push triggers (HTTP) are immediate. The exam might ask about the trigger type for a real-time scenario.

Error handling: The 'run after' setting is critical. Common wrong answer: assuming that by default, subsequent actions run only on success — actually, you must configure it. The default is 'run after previous succeeds'.

Pricing: Consumption is pay-per-action and connector calls. ISE is fixed monthly. The exam may test which pricing model is cost-effective for low-volume workflows.

Common wrong answers:

1.

Selecting Azure Functions for a workflow that uses Office 365 connectors. Reason: Candidates think 'code' is needed, but Logic Apps has built-in connectors.

2.

Thinking that Logic Apps can run indefinitely — each run has a timeout (default 1 year for consumption? Actually, consumption runs have a 1-year timeout, but actions have shorter timeouts).

3.

Choosing Power Automate over Logic Apps for enterprise integration. Power Automate is for Microsoft 365 citizen developers, not for enterprise-grade integration.

4.

Forgetting that Logic Apps can be deployed in an ISE for network isolation, not just VMs.

Numbers and terms that appear verbatim:

90-day run history retention

500 actions per workflow (default)

100 concurrent runs per Logic App (Consumption)

2 MB request/response body for single actions (50 MB for larger with chunking)

Retry policy: default 4 attempts, 7-second interval, exponential backoff.

Connectors: Office 365, SQL Server, Service Bus, Event Grid, etc.

Edge cases:

If a Logic App is disabled, triggers do not fire, but existing runs continue.

You can use managed identities for authentication without secrets.

Logic Apps can call on-premises systems via the on-premises data gateway.

Eliminating wrong answers:

If the scenario mentions 'no-code' or 'visual designer', it's Logic Apps.

If it mentions 'custom code' or 'complex algorithms', it's Functions.

If it mentions 'scheduled tasks', consider Logic Apps (Recurrence trigger) or Functions (timer trigger).

If it mentions 'high throughput' or 'VNet', consider Standard Logic App or ISE.

Key Takeaways

Logic Apps is a serverless integration platform for automating workflows with triggers and actions.

Triggers can be polling (recurrence-based) or push (HTTP/event-based).

Actions are sequential or parallel steps that use connectors to interact with services.

Default retry policy: 4 attempts with 7-second interval and exponential backoff.

Run history is retained for 90 days; use Azure Monitor for alerts.

Choose Consumption for variable workloads, Standard for high throughput or VNet needs.

Logic Apps can call Azure Functions for custom code.

On-premises data gateway enables integration with on-premises systems.

ISE provides dedicated, isolated environment for compliance and high volume.

AZ-104 tests scenario-based decisions between Logic Apps, Functions, and Power Automate.

Easy to Mix Up

These come up on the exam all the time. Here's how to tell them apart.

Logic Apps (Consumption)

Pay-per-execution pricing

Serverless, no dedicated compute

Maximum 100 concurrent runs (default)

Run history retained for 90 days

Cannot run in VNet (unless using ISE)

Logic Apps (Standard)

Fixed monthly cost (App Service plan)

Dedicated compute (single or multi-tenant)

Higher throughput and concurrency limits

Run history retained for 90 days (configurable)

Can run in VNet for network isolation

Watch Out for These

Mistake

Logic Apps is only for no-code scenarios and cannot run custom code.

Correct

Logic Apps can execute custom code using inline JavaScript (in Standard plan) or by calling Azure Functions. However, for complex code, Functions is preferred.

Mistake

Logic Apps can run indefinitely without timeout.

Correct

Each workflow run has a maximum duration of 1 year (consumption) or 30 days (standard). Individual actions have timeouts (e.g., 120 seconds for HTTP actions).

Mistake

All connectors are free to use.

Correct

Managed connectors have pricing per action call. Some connectors (like Office 365) have a free tier with limited calls, but beyond that, charges apply.

Mistake

Logic Apps cannot integrate with on-premises systems.

Correct

Logic Apps can connect to on-premises systems using the on-premises data gateway, which acts as a bridge between Azure and on-premises data sources.

Mistake

Power Automate and Logic Apps are interchangeable.

Correct

Power Automate is built on the same platform but is designed for Microsoft 365 automation with a simpler interface. Logic Apps offers more connectors, advanced features (like ISE), and is intended for professional developers and enterprise integration.

Do You Actually Know This?

Reveal each answer, then mark whether you got it right. Score 60%+ to unlock the next chapter.

Frequently Asked Questions

What is the difference between Azure Logic Apps and Azure Functions?

Azure Logic Apps is a no-code/low-code integration platform for orchestrating workflows using prebuilt connectors. Azure Functions is a serverless compute service for running custom code. Use Logic Apps when you need to integrate multiple services with minimal code; use Functions when you need to run custom business logic. They can work together: Logic Apps can call Functions as an action.

How do I trigger a Logic App from an external system?

Use the 'When a HTTP request is received' trigger. This creates a public endpoint URL (callback URL) that external systems can POST to. The request must match the JSON schema defined in the trigger. You can secure the endpoint using Azure AD authentication, IP restrictions, or shared access signatures.

What is the maximum run history retention for Logic Apps?

The default and maximum retention period is 90 days for both Consumption and Standard plans. You cannot extend it beyond 90 days. After that, run history is automatically deleted. To keep logs longer, export them to Log Analytics or Azure Storage.

Can Logic Apps run inside a virtual network?

Yes, but only if you use a Standard Logic App (which can be deployed in an App Service Environment) or a Consumption Logic App deployed in an Integration Service Environment (ISE). ISE provides network isolation and dedicated compute.

How do I handle errors in a Logic App workflow?

Configure the 'run after' setting for each action to define dependencies (e.g., run only if previous action failed). You can also set retry policies (default: 4 retries with exponential backoff). Add parallel branches for error handling, such as sending a notification when an action fails.

What are custom connectors in Logic Apps?

Custom connectors allow you to wrap your own REST APIs so they can be used as triggers and actions in Logic Apps. You provide an OpenAPI definition (Swagger) or a Postman collection. Custom connectors are useful for integrating with proprietary or third-party systems that don't have a prebuilt connector.

Is there a limit on the number of actions in a Logic App?

Yes, the default limit is 500 actions per workflow. This includes all actions, loops, and conditions. If you exceed this, you need to split the workflow into multiple Logic Apps or use a Standard plan with higher limits.

Terms Worth Knowing

Ready to put this to the test?

You've just covered Azure Logic Apps Workflows — now see how well it sticks with free AZ-104 practice questions. Full explanations included, no account needed.

Done with this chapter?