Documentation Index
Fetch the complete documentation index at: https://mintlify.com/czlonkowski/n8n-skills/llms.txt
Use this file to discover all available pages before exploring further.
Workflow Patterns
Proven architectural patterns for building n8n workflows, based on analysis of real workflow usage.Pattern Selection Guide
| Pattern | Use When | Example |
|---|---|---|
| Webhook Processing | Receiving events from external systems | Stripe payment → DB → confirmation email |
| HTTP API Integration | Fetching data from REST APIs | GitHub issues → Jira tickets |
| Database Operations | Syncing, querying, ETL workflows | Postgres → transform → MySQL |
| AI Agent Workflow | Conversational AI, multi-step reasoning | Chat AI with tool access |
| Scheduled Tasks | Recurring reports, maintenance | Daily analytics → email report |
Pattern Statistics
Most common triggers: Webhook (35%), Schedule (28%), Manual (22%), Service triggers (15%) Most common transformations: Set/field mapping (68%), Code/custom logic (42%), IF/conditional (38%), Switch (18%) Most common outputs: HTTP Request (45%), Slack (32%), Database writes (28%), Email (24%)Pattern 1: Webhook Processing
Most common pattern — 35% of all workflowsStructure
Node List
- Webhook — HTTP endpoint (instant trigger)
- IF / Switch — Validate incoming data
- Set — Map/transform fields
- Action node — Slack, Email, HTTP Request, Database
- Respond to Webhook — Send HTTP response back to caller
Use Cases
- Form submissions (contact forms, sign-ups)
- Payment webhooks (Stripe, PayPal)
- Git webhooks (GitHub, GitLab push events)
- Slack slash commands
- Chat integrations
Quick Start Example
Template Reference
The n8n template library has hundreds of webhook processing examples. Search with:Pattern 2: HTTP API Integration
Structure
Node List
- Trigger — Manual, Schedule, or Webhook
- HTTP Request — Fetch from REST API
- Split In Batches — Handle large result sets
- Set / Code — Transform API response
- Action node — Database write, Slack notification, etc.
- Error Trigger — Catch and handle failures
Use Cases
- Data fetching and synchronization with third-party services
- Building data pipelines between systems
- Multi-step API orchestration
- Converting between service formats (e.g., GitHub → Jira)
Quick Start Example
Key Configuration Notes
Template Reference
Pattern 3: Database Operations
Structure
Node List
- Schedule — Trigger on cron schedule
- Postgres / MySQL / MongoDB — Read source database
- IF — Check if records exist or need updating
- Set / Code — Transform and clean data
- Postgres / MySQL — Write to target database
- Postgres — Update sync timestamp or log result
Use Cases
- Database synchronization between systems
- ETL (Extract, Transform, Load) workflows
- Scheduled reports from database queries
- Data backup and archival
- Incremental sync (only new/changed records)
Quick Start Example
Key Configuration Notes
Pattern 4: AI Agent Workflow
Structure
Node List
- Webhook / Chat Trigger — Receive user message
- AI Agent (
nodes-langchain.agent) — Core reasoning node - OpenAI Chat Model — Connected via
ai_languageModel - Tool nodes — Connected via
ai_tool(HTTP Request, DB Query, etc.) - Window Buffer Memory — Connected via
ai_memory - Webhook Response — Send AI reply back to user
Use Cases
- Conversational chatbots with tool access
- AI assistants that can query databases or call APIs
- Content generation with data lookup
- Multi-step reasoning and decision-making
Quick Start Example
AI Connection Types Reference
Pattern 5: Scheduled Tasks
Structure
Node List
- Schedule Trigger — Cron-based timing
- HTTP Request / Database — Fetch fresh data
- Code / Set — Aggregate and format data
- Email / Slack — Deliver report or notification
- Error Trigger → Slack — Notify on failure
Use Cases
- Daily/weekly analytics reports emailed to team
- Hourly health checks for external services
- Nightly database backups
- Periodic data synchronization
- Maintenance workflows (cleanup, archival)
Quick Start Example
Template #2947 (Weather to Slack):Schedule Examples
Data Flow Patterns
- Linear
- Branching
- Parallel
- Loop
- Error Handler
Common Workflow Components
Triggers
Triggers
- Webhook — HTTP endpoint, instant response to events
- Schedule — Cron-based timing for periodic tasks
- Manual — Click to execute (testing and admin)
- Polling — Check for changes at intervals
Transformation Nodes
Transformation Nodes
- Set — Map and transform fields (used in 68% of workflows)
- Code — Complex custom logic in JavaScript or Python
- IF / Switch — Conditional routing
- Merge — Combine multiple data streams
Error Handling
Error Handling
- Error Trigger — Catch workflow-level errors
- IF — Check for error conditions inline
- Stop and Error — Explicit failure node
- Continue On Fail — Per-node setting to keep workflow running
Workflow Creation Checklist
Planning Phase
- Identify the pattern (webhook, API, database, AI, scheduled)
- List required nodes (use
search_nodes) - Map data flow: input → transform → output
- Plan error handling strategy
Implementation Phase
- Create workflow with appropriate trigger
- Add data source nodes
- Configure authentication/credentials
- Add transformation nodes (Set, Code, IF)
- Add output/action nodes
- Configure error handling
Validation Phase
- Validate each node with
validate_node - Validate complete workflow with
validate_workflow - Test with sample data
- Handle edge cases (empty data, API errors)
Common Gotchas
| Gotcha | Problem | Solution |
|---|---|---|
| Webhook data structure | Can’t access payload fields | Data is under $json.body.* |
| Multiple input items | Node processes all items but you want one | Use “Execute Once” mode or $json[0].field |
| Auth failures | 401/403 errors | Configure credentials section, not parameters |
| Unexpected execution order | Nodes run out of order | Check Settings → Execution Order (use v1) |
| Expression shows literal | {{}} not evaluated | Add {{}} around expressions |
Best Practices
Do
- Start with the simplest pattern that solves your problem
- Plan workflow structure before building
- Add error handling to every production workflow
- Test with sample data before activation
- Use descriptive node names
- Build iteratively (avg 56s between edits is normal)
Don't
- Build complex multi-pattern workflows without clear boundaries
- Skip validation before activation
- Ignore error scenarios
- Hardcode credentials in node parameters
- Forget to handle empty data cases
- Deploy without testing