Back to Resource Library
Implementation Guide

The n8n Developer Guide & Examples

A comprehensive n8n guide covering the n8n platform, open source vs. cloud, key developer concepts, and five high-impact workflow examples for professional services firms. Includes n8n community resources and best practices.

The n8n Developer Guide & Examples

n8n is an open-source workflow automation platform with native AI agent support. It runs as a visual canvas where nodes represent actions and connections represent data flow. Every workflow has a trigger (what starts it) and a chain of nodes that execute in response.

Unlike Zapier or Make, n8n can be fully self-hosted - your data never touches n8n's servers. Unlike LangChain, it requires no Python expertise. It occupies the space between no-code simplicity and engineering-grade control.

Canvas: The main workspace. Nodes are placed on the canvas and connected by dragging from one node's output to another's input. Data flows left to right.

Nodes: Each node is one action - an HTTP request, a data transform, a send email, an AI call. Nodes are configured in a sidebar panel that appears when clicked. Most configurations require filling in fields, not writing code.

Executions: Every time a workflow runs, n8n records an execution log. The log shows the data that entered each node and the data that exited it. This is how you debug: click any node in a past execution to see exactly what it received and what it returned.

Credentials: API

keys and OAuth tokens are stored as credentials, separate from workflows. A single HubSpot credential can be used across dozens of workflows without duplicating the API
key.

Expressions: n8n expressions access data from previous nodes using {{ $json.fieldName }} syntax. If the previous node returned { "email": "client@firm.com" }, the expression {{ $json.email }} returns client@firm.com. This is the primary way to wire data between nodes without code.

The Code Node: For transformations that cannot be expressed as expressions, a JavaScript or Python code block can be inserted as a node. Write the transform as a function that receives the current node's input data and returns the output data.

n8n Open Source vs. Cloud

n8n offers two deployment modes:

Self-hosted (Open Source)

  • Run on any server (DigitalOcean, AWS, GCP, local)
  • Free at the server cost level (~$18/month for a DigitalOcean Droplet)
  • Unlimited executions, unlimited workflows, unlimited users
  • You own the data - no data passes through n8n's servers
  • You are responsible for updates, backups, and uptime

n8n Cloud

  • Managed hosting - n8n handles infrastructure, updates, and uptime
  • Starts at €20/month for 2,500 executions
  • No server management required
  • Data is processed on n8n's EU servers (GDPR-compliant)
  • Scales by execution volume

Recommendation: For professional services firms handling client data, self-hosted is the appropriate choice unless there is no technical resource available for server maintenance. The $18/month server cost vs. €20+/month cloud cost is not the deciding factor - data residency is.

For server setup instructions, see How to Set Up a Virtual Machine & AI Server.

Key n8n Developer Concepts

Workflow Triggers Every workflow starts with a trigger node:

  • Webhook
    :
    Workflow runs when an HTTP POST is received at the webhook
    URL. Use for form submissions, CRM
    events, and external system events.
  • Schedule: Workflow runs at a fixed time (every 5 minutes, every weekday at 7 AM). Use for monitoring, digest delivery, and batch processing.
  • Email Trigger: Workflow runs when a new email arrives in a connected inbox. Use for email-based data extraction and routing.
  • CRM
    Trigger:
    Workflow runs when a specific event occurs in HubSpot, Salesforce, or another CRM
    (deal stage changed, contact created, form submitted).

Data Structure n8n represents data as arrays of JSON items. Each node can receive multiple items and output multiple items. The {{ $json }} expression references each item's JSON. {{ $items() }} references the full array. Understanding this is critical for workflows that process lists of records.

Error Handling Every node has an error output. Connect the error output to an error handler node - typically a Slack notification or a database write - to capture failures. Workflows without error handling fail silently in production.

The AI Agent Node The AI Agent node in the Advanced AI section is n8n's autonomous agent implementation. Connect it to:

  • A Chat Model node (OpenAI, Anthropic, Ollama) as the reasoning engine
  • Tool nodes as the available actions
  • A Memory node for conversation persistence

The agent handles the Reason → Act → Observe loop automatically.

5 High-Impact n8n Workflow Examples

Example 1: CRM Email Logger

Trigger: Gmail / Outlook trigger (poll every 5 minutes) Nodes: Contact lookup (HubSpot HTTP Request) → IF (contact found?) → AI Node (extract summary, action items, sentiment) → HubSpot activity create → Slack exception post (if contact not found) Impact: Eliminates manual CRM

entry for all client email interactions. Full implementation: Play 1: Hands-Free CRM.

Example 2: Inbound Lead Qualifier

Trigger: Webhook

(form submission) Nodes: AI Node (score lead) → IF (score >= 70?) → Email send (qualified response with booking link) → HubSpot contact create/update → Slack exception post (if below threshold) Impact: Sub-2-minute response to every inbound lead regardless of time. Full implementation: Play 2: 24/7 Lead Qualification.

Example 3: Daily Operations Digest

Trigger: Schedule (weekdays 6:30 AM) Nodes: HubSpot query (deals with no activity 14+ days) → HubSpot query (overdue tasks) → AI Node (generate digest) → Gmail send (to each partner) Impact: Partners start every day knowing exactly which accounts need attention without pulling a CRM

report.

Example 4: Document Q&A (RAG Pipeline)

Trigger: Webhook

(question submitted via Slack or chat widget) Nodes: Embeddings Node (embed question) → Vector Store Query (retrieve top 5 chunks) → AI Node (answer from retrieved context) → Return response Impact: Associates get instant answers from internal knowledge base without interrupting partners. Setup: Supabase pgvector Guide.

Example 5: Resume Screening Agent

Trigger: Email trigger (inbox monitoring for resume attachments) Nodes: Extract PDF text → AI Node (score against role criteria) → IF (score >= threshold) → HubSpot candidate create → Email send (next step instructions) → Slack notification (to recruiter) Impact: Screens 60 resumes/hour at a consistent quality standard. Full implementation: Play 6.

n8n Community & Resources

n8n Community Forum: community.n8n.io - the primary support channel. Most integration questions have been answered here. Search before posting; the forum has deep archives.

n8n Templates: The n8n template library (accessible from the n8n canvas) contains 1,500+ pre-built workflows. Start with a template for your use case and modify from there rather than building from scratch.

n8n Changelog: n8n releases approximately bi-weekly. Review the changelog when updating - new AI nodes and integrations are frequently introduced. Self-hosted instances require manual update via docker pull n8nio/n8n && docker restart n8n.

This Resource Site: All 12 Plays in this playbook use n8n as the workflow orchestration layer. The Guides section contains specific connection guides for Gmail, HubSpot, Salesforce, Slack, and 30+ other platforms.

Frequently Asked Questions

What is n8n and how does it work? n8n is an open-source workflow automation platform with native AI agent support. Every workflow has a trigger (what starts it) and a chain of nodes that execute in sequence. Unlike Zapier or Make, n8n can be fully self-hosted - your data never touches n8n's servers. Unlike LangChain, it requires no Python expertise.

Is n8n free to use? n8n is open-source and free to self-host. You pay only for the server it runs on - approximately $18/month for a DigitalOcean Droplet. n8n Cloud starts at €20/month for 2,500 executions. For most professional services firms, self-hosted is the appropriate choice for data residency.

What is the difference between n8n and Zapier? Three key differences: (1) Data residency - n8n self-hosted keeps all data on your server; Zapier routes data through Zapier's infrastructure. (2) Pricing - n8n self-hosted is effectively free at scale; Zapier charges per task and becomes expensive above 1,000 tasks/month. (3) Capability - n8n has native AI Agent nodes, code execution, and complex branching that Zapier cannot replicate.

How do I connect n8n to my CRM

? Most modern CRMs
(HubSpot, Salesforce, Pipedrive) have native n8n nodes that handle OAuth authentication and expose common operations. For CRMs
without a native node, the HTTP Request node connects to any REST API
. Setup time for a native node integration: 30-60 minutes.

What are the best n8n workflow examples for professional services? The five highest-impact workflows: CRM

Email Logger, Inbound Lead Qualifier (2-minute response), Daily Operations Digest, Document Q&A RAG
Pipeline, and Resume Screening Agent. See the 12 Plays for complete implementations with step-by-step build guides.

Revenue Institute

Reviewed by Revenue Institute

This guide is actively maintained and reviewed by the implementation experts at Revenue Institute. As the creators of The AI Workforce Playbook, we test and deploy these exact frameworks for professional services firms scaling without new headcount.

DFY Implementation

Need help turning this guide into reality?

Revenue Institute builds and implements the AI workforce for professional services firms.

Work with Revenue Institute