Azure Logic Apps Guru
Enterprise-grade agent for expert, guidance, azure, logic. Includes structured workflows, validation checks, and reusable patterns for devops infrastructure.
Azure Logic Apps Guru
An Azure Logic Apps expert providing guidance on developing, optimizing, and troubleshooting Logic Apps workflows with deep expertise in Workflow Definition Language (WDL), integration patterns, and enterprise automation.
When to Use This Agent
Choose Azure Logic Apps Guru when:
- Building complex multi-step Logic Apps with conditional branching
- Designing enterprise integration scenarios (B2B, EDI, API management)
- Optimizing Logic Apps performance and reducing execution costs
- Troubleshooting failed runs and connector-specific issues
- Migrating from Consumption to Standard Logic Apps
Consider alternatives when:
- Building general Azure infrastructure (use Azure Infra Engineer Partner)
- Creating Azure Functions (use a general Azure development agent)
- Working with non-Azure workflow engines (use the relevant platform agent)
Quick Start
# .claude/agents/azure-logic-apps-guru.yml name: Azure Logic Apps Guru description: Expert Azure Logic Apps development and optimization model: claude-sonnet tools: - Read - Write - Edit - Bash - WebSearch
Example invocation:
claude "Optimize our Logic App that processes 10,000 invoices daily — reduce execution time, handle failures gracefully, and minimize connector API calls"
Core Concepts
Logic Apps Types Comparison
| Feature | Consumption | Standard |
|---|---|---|
| Hosting | Multi-tenant | Single-tenant / ASE |
| Pricing | Per action execution | vCPU + memory (plan-based) |
| VNet Integration | No | Yes (Private Endpoints) |
| Local Development | Limited | VS Code + Azurite |
| Stateful/Stateless | Stateful only | Both |
| Scale | Auto (platform managed) | Manual or auto rules |
| Best For | Low-medium volume | High volume, enterprise |
Performance Optimization
// Optimized For-Each with controlled concurrency { "For_each_invoice": { "type": "Foreach", "foreach": "@body('Get_Invoices')", "actions": { "Process_Invoice": { "type": "Http", "inputs": { "method": "POST", "uri": "https://api.example.com/invoices/process", "body": "@items('For_each_invoice')" } } }, "operationOptions": "Sequential", "runtimeConfiguration": { "concurrency": { "repetitions": 20 } } } }
Error Handling Patterns
// Scope with error handling (try-catch pattern) { "Try_Process": { "type": "Scope", "actions": { "Call_API": { "type": "Http", "inputs": { "..." : "..." } }, "Update_Database": { "type": "ApiConnection", "inputs": { "..." : "..." } } } }, "Catch_Errors": { "type": "Scope", "actions": { "Log_Error": { "type": "Compose", "inputs": { "error": "@result('Try_Process')", "workflowRunId": "@workflow().run.name", "timestamp": "@utcNow()" } }, "Send_Alert": { "type": "ApiConnection", "inputs": { "..." : "..." } } }, "runAfter": { "Try_Process": ["Failed", "TimedOut"] } } }
Configuration
| Parameter | Description | Default |
|---|---|---|
app_type | Logic Apps type (consumption, standard) | standard |
concurrency | Max concurrent workflow runs | 25 |
action_timeout | Default action timeout | PT2M |
retry_policy | Retry strategy (none, fixed, exponential) | exponential |
trigger_type | Trigger mechanism (recurrence, webhook, event) | Workflow-specific |
monitoring | Log Analytics integration | enabled |
Best Practices
-
Use Scopes for logical grouping and error handling. Scopes act as try-catch blocks in Logic Apps. Group related actions into a "Try" scope, then add a "Catch" scope with
runAfterset to Failed/TimedOut. This pattern provides structured error handling without deeply nested conditions. The catch scope receives the error details fromresult('ScopeName')for logging and alerting. -
Minimize connector API calls by batching operations. Each connector call counts toward both rate limits and costs. Instead of calling a connector in a loop, batch operations where possible: use SQL stored procedures instead of individual queries, batch HTTP requests, and use SharePoint batch endpoints. A single batched call replacing 100 individual calls reduces both latency and cost by 100x.
-
Use stateless workflows for high-throughput, fire-and-forget scenarios. Standard Logic Apps support stateless workflows that do not persist run history, reducing I/O overhead and improving throughput. Use stateless for webhooks, event processing, and transformation pipelines where you do not need to inspect individual run history. Keep stateful workflows for business-critical flows that require audit trails and manual intervention.
-
Parameterize connector configurations for environment promotion. Do not hardcode connection strings, URLs, or API keys in workflow definitions. Use Logic Apps parameters and application settings to externalize environment-specific values. This allows the same workflow definition to deploy to dev, staging, and production by changing only the parameter file, following the same pattern as application configuration.
-
Implement dead-letter patterns for messages that cannot be processed. When a message fails processing after all retries, move it to a dead-letter queue or table instead of dropping it. Include the original message, error details, retry count, and timestamp. Set up monitoring on the dead-letter store to alert when messages accumulate, and build a reprocessing mechanism to replay failed messages after fixes.
Common Issues
Logic App runs exceed expected duration and cost. Inefficient loops, sequential processing of large arrays, and unnecessary API calls inflate execution time. Profile each run in the Logic Apps run history to identify slow actions. Replace sequential For-Each with concurrent processing (set concurrency > 1). Cache repeated lookups in variables. Use conditions early in the workflow to skip unnecessary processing for messages that do not meet criteria.
Connector authentication tokens expire during long-running workflows. OAuth tokens for connectors like Office 365 and SharePoint expire after a fixed period. Long-running workflows that span hours or days may encounter authentication failures mid-execution. Use managed identity authentication where supported (Azure services). For OAuth connectors, implement token refresh logic or break long workflows into shorter, chained executions.
Workflow definition becomes too large and complex to maintain. Complex business logic expressed entirely in Logic Apps WDL becomes an unmaintainable JSON file. Extract complex logic into Azure Functions that the Logic App calls via HTTP. Keep the Logic App focused on orchestration (routing, branching, retry) and delegate computation, validation, and transformation to code. This separation makes both the Logic App and the code independently testable and maintainable.
Reviews
No reviews yet. Be the first to review this template!
Similar Templates
API Endpoint Builder
Agent that scaffolds complete REST API endpoints with controller, service, route, types, and tests. Supports Express, Fastify, and NestJS.
Documentation Auto-Generator
Agent that reads your codebase and generates comprehensive documentation including API docs, architecture guides, and setup instructions.
Ai Ethics Advisor Partner
All-in-one agent covering ethics, responsible, development, specialist. Includes structured workflows, validation checks, and reusable patterns for ai specialists.