n8n-connections

Verify n8n SDK workflow connections for correct wiring and routing.

421|46|Updated Apr 20, 2026
One-click install
npx skills add https://github.com/n8n-io/skills --skill n8n-connections
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: n8n-connections
Source: https://github.com/n8n-io/skills/tree/main/skills/n8n-connections
Command: npx skills add https://github.com/n8n-io/skills --skill n8n-connections

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill prevents n8n SDK workflows from looking valid while key connections are silently dropped or misrouted, causing nodes to not fire or to receive the wrong data.

Core Features & Use Cases

  • Stop the .to()-after-.add() trap: ensure every wire uses the universal pattern so validation won’t pass while execution fails.
  • Correctly wire multi-output and composite handlers: route IF/Switch error branches and .onTrue, .onFalse, .onCase, .onError outputs reliably.
  • Handle fan-out, fan-in, and Merge indexing safely: verify Merge numberOfInputs and align useDataOfInput (1-indexed) with SDK .input(n) (0-indexed).
  • Post-create verification that matters: use get_workflow_details to confirm the connections object matches what your code intended.

Quick Start

When building an n8n workflow with the SDK, connect nodes using .add(source.output(n).to(target)) and verify the resulting connections via get_workflow_details before assuming the wiring is correct.

Frequently Asked Questions about n8n-connections

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
Why does my n8n workflow validate successfully but nodes fail to fire or receive the wrong data?

n8n workflow validation can pass while workflow connections are silently misrouted or dropped. Placing `.to()` incorrectly outside of `.add()` causes execution failures despite passing `validate_workflow` checks.

How do I correctly wire IF and Switch error branches in an n8n SDK workflow?

Wiring n8n IF and Switch branches requires routing `.onTrue`, `.onFalse`, `.onCase`, and `.onError` outputs correctly. You must use the universal `.add(source.output(n).to(target))` pattern to prevent silent connection drops in multi-output handlers.

How do I align Merge `useDataOfInput` with SDK input indexing in n8n workflows?

n8n Merge nodes require aligning `useDataOfInput` (1-indexed) with SDK `.input(n)` (0-indexed) correctly. You must verify `numberOfInputs` and translate the indexing safely to prevent fan-in data mismatches.

What is the best way to verify n8n SDK workflow connections after creating a workflow?

Verifying n8n workflow connections requires using `get_workflow_details` to inspect the `connections` object directly. Relying solely on `validate_workflow` is insufficient, as it can pass while key connections are silently broken.

Can I use `validate_workflow` to catch broken fan-out and fan-in connections in n8n SDK workflows?

`validate_workflow` does not reliably catch broken n8n fan-out and fan-in connections. You must inspect the `connections` object via `get_workflow_details` to confirm that the actual wiring matches your intended node routing.

What causes silently dropped connections when generating n8n workflows with the SDK?

Silently dropped n8n workflow connections are caused by incorrect `.to()` placement after `.add()` and improper input index alignment for Merge nodes. Using the correct wiring pattern prevents these multi-input and multi-output routing failures.