How dungssj/n8n-clone works
n8n is a self-hostable visual workflow-automation platform with integrations and native LangChain-based AI. The main user journey is to build or import a workflow in the editor, save it through the workflow API, and run it; workflows can use triggers, integration nodes, code, and AI components. The graph includes execution, binary-data storage, and OAuth as supporting layers. Several subsystems are represented from the README and source index rather than inspected implementation, so their connections are limited to documented relationships.
Main entry points: workflow-execution.service.ts Execution service · workflows.controller.ts Workflow API · App.vue Workflow editor · nodes-base Integration nodes
Components 18
Workflow authoring
- Workflow editor
packages/editor-ui/src/App.vue - Workflow API
packages/cli/src/workflows/workflows.controller.ts - Workflow service
packages/cli/src/workflows/workflow.service.ts - Manual run API
packages/cli/src/workflows/workflows.controller.ts
Workflow runtime
- Execution service
packages/cli/src/workflows/workflow-execution.service.ts - Active workflows
packages/cli/src/active-workflow-manager.ts - Node execution context
packages/core/src/execution-engine/node-execution-context/node-execution-context.ts - Webhook context
packages/core/src/execution-engine/node-execution-context/webhook-context.ts - Scheduled tasks
packages/core/src/execution-engine/scheduled-task-manager.ts
Workflow capabilities
- Integration nodes
packages/nodes-base - LangChain nodes
packages/@n8n/nodes-langchain - Chat triggers
packages/@n8n/nodes-langchain/nodes/trigger/ChatTrigger/ChatTrigger.node.ts - Code node
packages/@n8n/nodes-langchain/nodes/code/Code.node.ts
Platform services
- Binary data
packages/core/src/binary-data/file-system.manager.ts - OAuth client
packages/@n8n/client-oauth2/src/ClientOAuth2.ts - Workflow database
packages/cli/src/db.ts
Other components
- Technical team
- External services
Connections 18
- Technical team → Workflow editor: builds workflows
README.md - Workflow editor → Workflow API: saves workflows
- Workflow API → Workflow service: manages workflows
packages/cli/src/workflows/workflows.controller.ts - Workflow API → Workflow database: persists workflows
packages/cli/src/workflows/workflows.controller.ts - Technical team → Manual run API: runs workflow
README.md - Manual run API → Execution service: dispatches run
packages/cli/src/workflows/workflows.controller.ts - Execution service → Active workflows: coordinates
- Execution service → Node execution context: executes nodes
- Webhook context → Node execution context: extends
packages/core/src/execution-engine/node-execution-context/webhook-context.ts - Execution service → Integration nodes: runs integration nodes
- Execution service → LangChain nodes: runs AI nodes
- Execution service → Code node: runs code
- Execution service → Scheduled tasks: uses schedules
- Chat triggers → External services: serves chat
- Integration nodes → External services: connects services
README.md - LangChain nodes → External services: uses models
README.md - OAuth client → External services: authenticates requests
- Execution service → Binary data: stores binary data