Generated banner for N8n Workflow Lifecycle Official
Generated logo for N8n Workflow Lifecycle Official

N8n Workflow Lifecycle Official

n8nOfficialPublished by n8n

  • Skill
  • Workflow
  • Automation and integrations
  • Apache-2.0
  • No issues found

From the author

Use when starting, designing, organizing, finishing, or shipping an n8n workflow. Covers visual layout (sticky notes), descriptions that capture the *why*, node names, validation, testing, folders/projects, and publishing. Triggers on create_workflow_from_code, update_workflow, validate_workflow, publish_workflow, archive_workflow, "design", "lay out", "organize", "structure", "sticky", "describe this workflow", "ship", "deploy", "publish", "name this workflow", or any folder/project organization request.
— the description by n8n

AutoGineer summary

Written by AutoGineer from the skill’s own files, not by the author

This skill provides a structured six-stage methodology for managing n8n workflows from initial planning to production handoff. It emphasizes rigorous validation, proper documentation, and clear communication to ensure workflows are maintainable, reliable, and correctly configured. The framework covers technical best practices like node grouping, naming conventions, and folder management, while also addressing the human-in-the-loop requirements for credential verification and production readiness.

What it does

  • Guides users through a six-stage lifecycle: Plan, Build, Validate, Test, Publish, and Handoff.
  • Provides strict protocols for node naming, workflow descriptions, and visual organization using sticky notes and node groups.
  • Enforces validation checks using both automated tools and manual verification steps before publishing.
  • Manages folder organization and MCP access settings for workflow discoverability.
  • Defines clear handoff procedures to ensure users can operate and monitor workflows in production.
  • Outlines specific anti-patterns to avoid, such as incorrect assumptions about parallel execution or skipping testing.

When to use it

  • When starting a new n8n workflow project from scratch.
  • When organizing or refactoring existing workflows to improve readability and maintainability.
  • Before deploying any workflow to a production environment.
  • When troubleshooting workflows that are failing or behaving unexpectedly.
  • When coordinating with users to ensure they have the necessary context to operate a finished workflow.

Advantages

  • Reduces the likelihood of production failures by enforcing a mandatory testing and validation sequence.
  • Improves long-term maintainability through standardized naming and documentation practices.
  • Ensures workflows are properly organized and discoverable within the n8n instance.
  • Clarifies the division of responsibility between the agent and the user, particularly regarding credentials and MCP access.
  • Prevents common pitfalls like silent connection drops or incorrect assumptions about workflow execution order.

Usage examples

“Design a new workflow to sync customer data from Postgres to Slack.”
The agent initiates the 'Plan' stage, asking for specific requirements and checking for existing sub-workflows before drafting the structure.
“I need to ship this workflow to production, is it ready?”
The agent runs the validation checklist, verifies connections, asks the user to confirm credentials, and performs a test run before proceeding to publish.
“Organize my messy workflow into something readable.”
The agent applies node groups to logical steps, adds descriptive sticky notes, and updates the workflow description to capture the 'why' behind the design.

Install

  1. Download the skill as a ZIP:

    https://mp-staging.autogineer.com/agent-skills/n8n-io/n8n-workflow-lifecycle-official/download
  2. Unzip it into the cross-client skills folder of your project:

    mkdir -p .agents/skills && unzip n8n-workflow-lifecycle-official.zip -d .agents/skills

Documentation by n8n

n8n Workflow Lifecycle

The six stages

  1. PLAN. Gather requirements, ask clarifying questions, search for existing workflows / sub-workflows that already do this.

  2. BUILD. Write SDK code (with skills: subworkflows, node-config, expressions, code-nodes; readability section below). Use validate_node_config as a side-channel for iteration, debugging, or small single-node edits: clean per-parameter errors without full-graph noise. Not a replacement for validate_workflow in VALIDATE.

  3. VALIDATE. validate_workflow + get_workflow_details for connections, then have the user verify per-node credentials and create anything you couldn't (missing credentials, folders, etc).

  4. TEST. test_workflow with prepare_workflow_pin_data; iterate until output matches intent.

  5. PUBLISH. publish_workflow only after stages 3 and 4 are clean.

  6. HANDOFF. Production handoff: how to trigger it, what it returns, what to watch, what they should know to use it well.

Skipping a stage produces workflows that look done but break in production, or solve the wrong problem entirely. Three most common skips:

  • Build before plan. "User asked for X, I'll start coding" without confirming what X means, whether the same logic already exists as a sub-workflow, or which folder/project it belongs in. Cheaper to ask one clarifying question than to rebuild after.

  • Test before user-side wire-up. Running test_workflow before the user has verified credentials per node hits the wrong service or 401s. Get the user-side setup done as part of VALIDATE.

  • Publish without test. Validation passing means the SDK is well-formed; it does NOT mean the workflow is correct.

Non-negotiables

  1. Validate AND verify before publish. Run validate_workflow on the SDK code, then get_workflow_details after every create/update to check the connections object. Validation alone misses silently dropped wires. validate_node_config is a separate per-node iteration tool, not a replacement for this step.

  2. Surface known limitations to the user. If folders, MCP access, or any other limitation blocks the request, say so explicitly and propose a path. Don't silently dump workflows at the wrong location or report success on a request you couldn't fully fulfill.

  3. Ask before testing when not-auto-pinned downstreams have side effects. test_workflow auto-pins triggers, credentialed nodes, and HTTP Request nodes. Everything else (Code, Edit Fields, If, Wait, Execute Command, file ops, sub-workflow calls, Data Tables) runs for real. Ask the user before running if any of those would fire user-visible side effects. See references/TESTING.md.

Strong defaults

  • Test before publish with test_workflow + prepare_workflow_pin_data. See references/TESTING.md for mocking by trigger type, pinning individual nodes, and the side-effect surface. Looser for internal one-off scripts you watch run.

  • Always include a description on create_workflow_from_code. 1-2 sentences capturing what and why. See "Readability" below.

Validation isn't enough

validate_workflow runs schema and shape checks: missing parameters, type errors, references to non-existent nodes. It does not catch:

  • The .to()-inside-.add() connection trap (silent dropped wires)

  • Fan-outs collapsed to a single connection

  • Merge index off-by-one

  • Error outputs wired without onError: 'continueErrorOutput'

  • Parameters that are syntactically valid but semantically wrong (e.g., wrong sheet ID, wrong column name)

Validation is necessary but not sufficient. The real gate is:

  1. validate_workflow passes.

  2. get_workflow_details returns a connections object that matches your intent.

  3. test_workflow produces the right output on representative pinned data.

Only then call publish_workflow.

For the full pre-publish checklist, see references/VALIDATION_CHECKLIST.md.

Execution model

n8n workflows execute sequentially, left-to-right, top-to-bottom. Branches that visually appear parallel on the canvas (fan-out from one source to multiple downstreams) run one after the other, ordered by the target nodes' Y-position on the canvas. There is no automatic concurrency.

Practical consequences:

  • A fan-out to three slow HTTP calls runs in series; total latency is the sum, not the max.

  • "Parallel" branches share workflow state in execution order; downstream consumers see whatever the last branch left.

  • For real concurrency, dispatch sub-workflows with mode: 'each' and waitForSubWorkflow: false. See n8n-loops-official and n8n-subworkflows-official.

This is platform behavior, not an SDK quirk. Don't design fan-outs around assumed parallelism.

Naming conventions

Bad names compound: a workflow that's hard to find six months from now gets duplicated.

For full conventions (verb-noun patterns, capitalization, prefixes), read references/NAMING_CONVENTIONS.md. Short version:

  • Workflows: verb-first, scoped. Send weekly customer report not Customer report sender.

  • Nodes: describe what they do in this workflow, not the node type. Fetch active customers not Postgres1.

  • Sub-workflows: plain descriptive name (Parse RFC2822 date); carry the category in tags (subworkflow, a domain tag, tool), not a name prefix. search_workflows({ tags }) filters on them. See n8n-subworkflows-official references/NAMING_AND_DISCOVERY.md.

  • Tags: the AI-side discovery mechanism (n8n 2.27.0+). The MCP lists (list_workflow_tags), filters (search_workflows({ tags })), and attaches them (update_workflow addTags/removeTags, auto-creating unknown names). Lowercase, 2-4 per workflow. See references/NAMING_CONVENTIONS.md.

Readability: descriptions, node groups, sticky notes, conventions

Four levers carry the readability load, grouping from 7 boxes on and the other three from about 5 nodes on:

  • Workflow description: capture the why, including AI-derived context. Two sentences: what it does and why it exists. Most importantly, capture context you had during conversation that won't otherwise survive into the file (the constraint that drove the design, why this approach over the alternative, the user's reason for asking). Otherwise it dies with the chat.

  • Node groups: the only way to group nodes. Named frames, one per logical step (Validate input, Enrich order, Notify). Organization only, members run inline (reuse/isolation is a sub-workflow's job). Read references/NODE_GROUPS.md before creating or editing any group, and after any save that reported a group problem. The three things to know up front:

    • When: more than 7 boxes with every group collapsed, typically into 3-5 groups. A box is the trigger, each group, and each ungrouped node; sub-nodes and sticky notes don't count.

    • A group must be a connected, trigger-free section with at most one member facing out in each direction, with an Agent's sub-nodes all in or all out. Members are node names, not ids.

    • An invalid group op is skipped, not fatal, and unrelated edits can silently delete a valid existing group, so a save that looks clean can have lost one. The exception is a description over 145 characters: that rejects the whole update_workflow call. Read the group fields on every create and update, and repair before reporting done.

  • Sticky notes: annotate, don't group. Grouping is the node group's job (above). Stickies carry what a group name can't: a callout, a TODO, a warning. Read references/STICKY_NOTES.md before placing one.

    • On create, always anchor. sticky(content, [nodes], { color }) derives the box from the nodes it wraps, after layout. Coordinates guess at a canvas that doesn't exist yet; omitting both is worse, since the fallback centers the note under the whole graph and only dodges other stickies, never nodes. If you can't name the nodes a note is about, it doesn't belong on the canvas.

    • Three roles, and the anchor set follows from the role. A stage zone anchors one stage's nodes; a callout anchors the single node it warns about; a gray title band anchors the whole flow and is rare, only for a canvas you're deliberately leaving ungrouped.

    • Scale: under ~5 nodes, none. From 5 to 7 boxes, one zone per stage. Over 7, node groups section and document the canvas via their descriptions, and you anchor nothing to a grouped node: those positions are collapsed-chip slots, so the note draws over the expanded group and matches nothing collapsed.

    • Zones need room the derived box doesn't give. Declare height: 272 for a one-row zone, 464 for a branch fan (add 32 for Message an Agent v2+). Never declare a width. Then, once the canvas is final, widen every zone in one batched update_workflow: x = min(node.x) - 56, width = span + 112. Computed from the nodes, so re-running is harmless, but it's a finishing step, not per-edit.

    • update_workflow has no sticky op. A sticky there is an addNode of n8n-nodes-base.stickyNote with content, width, height, color in parameters; an omitted position means [0, 0].

    • Content and color: ### Title carrying the point, plus one short line. Only the top 64px clears the nodes, so never add height for more text; longer prose goes in node notes or the workflow description. color 1-7 stands for what happens there: green creates or involves a person, red is destructive or irreversible, blue is routing and transformation, gray is documentation. A user preference, then nearby workflows, outrank that.

  • Node notes for non-obvious config. Explain why a workaround exists or a Code node does what it does. Don't annotate obvious nodes.

Plus two notes:

  • Match existing project conventions before introducing your own. Skim a couple of nearby workflows via search_workflows + get_workflow_details and mirror the sticky palette, naming, and description style.

  • Layout runs on create, never on update. create_workflow_from_code lays out every node that doesn't carry an explicit position, so omit them and let it. Setting some and not others is the bad case: yours are honored and the rest are laid out around them, which is how nodes end up stacked. update_workflow runs no layout at all, so anything you add sits exactly where you put it.

Folder management

On a registered instance the MCP creates and organizes folders: create_folder, update_folder (rename/move), move_workflows_to_folder, and a folderId on create_workflow_from_code for create-time placement. search_folders resolves names to IDs.

If the user wants a folder that doesn't exist, create it, don't build at the root and report success. If the folder tools are absent, the instance isn't registered: folders are blocked in the UI too, so ask the user to register (free, in Settings) rather than create the folder by hand. No tool deletes a folder, and projects are read-only.

For the full protocol, read references/FOLDER_LIMITATIONS.md.

Per-workflow MCP access

Each workflow has an availableInMCP flag. The default depends on who created it:

  • Workflows created via the MCP (create_workflow_from_code) default to MCP-accessible. No toggle step needed: you can find them via search_workflows and operate on them right away.

  • Workflows created in the n8n UI can default to off. Until the user flips the toggle, the workflow is invisible to you.

The #1 case where this bites: the user built a workflow manually in the UI and now wants you to inspect or edit it, but you can't see it. Before assuming it doesn't exist or you're searching the wrong project, ask the user to confirm MCP access is enabled.

Sub-workflows called via MCP: the caller can use them as code-level sub-workflows without the toggle. To invoke as MCP-exposed tools, the toggle is required (and is on by default for MCP-created sub-workflows).

For the full case-by-case guide and user-facing message, read references/MCP_ACCESS_PER_WORKFLOW.md.

User-side wire-up (part of stage 3)

There are things the user has to do that you can't, and they need to be done before testing, otherwise the test fires against the wrong credential, hits a missing folder, or 401s. Surface these as a short list during VALIDATE, before TEST:

  • Verify credentials per node. newCredential('Label') is cosmetic. n8n auto-assigns the most recently edited credential of the right type, which silently picks the wrong one when the user has multiples (prod vs staging Gmail, two API keys). Tell them: "open every node that uses a credential and confirm the right one is selected." See n8n-credentials-and-security-official non-negotiable #2.

  • Create missing credentials. If the user pasted a secret in chat or the workflow needs an account that doesn't exist yet, name the credential type and have them create it in the UI.

  • Register for folders (only if the tools are missing). Folder tools need a registered instance. If they're absent, the user registers (free, in Settings) before you can create or place folders; otherwise you handle folders yourself. See references/FOLDER_LIMITATIONS.md.

  • MCP access toggle for user created workflows. Workflows you create via the MCP are MCP-accessible by default. The toggle only matters when the test depends on a UI-created workflow being callable from the MCP. See references/MCP_ACCESS_PER_WORKFLOW.md.

Don't proceed to TEST until these are confirmed done.

Handoff: production handoff (stage 6)

After publish_workflow and a clean test, the workflow is technically live, but the user still needs enough context to actually use it in production. Treat this like the freelancer-to-customer handoff: short, structured, and oriented toward how they'll operate it from here.

What to include:

  • How it triggers. Webhook URL (live now that it's published), schedule cadence + timezone, manual trigger button, sub-workflow caller, whichever applies. For webhooks, hand them the URL.

  • What it returns / where the data goes. One sentence. "Writes new rows to the customers table," "responds JSON to the caller," "fires the on-call Slack channel."

  • How to invoke it for real, with an example. "Hit the webhook with curl -X POST <url> -d '{...}'," "trigger manually from the UI," "wait until 09:00 UTC for the first scheduled run."

  • What to watch. Failure modes that surface as alerts/errors, rate-limit ceilings on upstream services, and where to look first when something breaks (executions tab, error workflow, audit log, etc.).

  • MCP access status. If you created the workflow via the MCP, it's already MCP-accessible. Let the user know they can revoke access in Settings if they want to lock it down. If they hand-built it in the UI, they need to flip MCP access on for any other agent to call it.

  • Anything still pending on their side. Secret rotation if a token was pasted in chat, follow-up wiring you couldn't reach, known TODOs left in stickies.

Keep it tight: half a dozen bullets, not a wall of text. The user shouldn't have to ask "ok, what now?"

Reference files

FileRead when
references/NAMING_CONVENTIONS.mdNaming a new workflow, sub-workflow, or node
references/NODE_GROUPS.mdBefore creating or editing any node group, or after a save reported a skipped or removed group
references/STICKY_NOTES.mdAbout to add, move, or resize a sticky note on either tool
references/FOLDER_LIMITATIONS.mdUser mentions a folder, project structure, or wants workflows organized
references/MCP_ACCESS_PER_WORKFLOW.mdBuilding a workflow that you or another agent will call via MCP
references/VALIDATION_CHECKLIST.mdJust finished a workflow and about to call publish_workflow
references/REVIEW_CHECKLIST.mdReviewing or auditing an existing workflow (any age, any author). Severity-tiered findings, distinct from the pre-publish validation checklist
references/TESTING.mdAbout to run test_workflow or execute_workflow, mocking trigger input, side-effect protocol

Anti-patterns

Anti-patternWhat goes wrongFix
Calling publish_workflow without validatingBroken workflows reach productionValidate, verify connections, then test
Creating workflows at root because the requested folder doesn't existWorkflows get lost, and the user has to drag them manuallySurface the limitation before building
Generic node names (HTTP Request1, Set2)Workflows are unreadable a month laterRename to describe the action
Missing description on create_workflow_from_codeWorkflow invisible in search, no context for maintainersAlways include 1-2 sentences
Asking the user to flip the MCP access toggle on a workflow you created via the MCPWastes their time, agent-created workflows default to MCP-accessibleOnly mention the toggle for UI-created workflows, or when the user wants to revoke MCP access on an agent-created one
Running test_workflow on a workflow with side-effecty non-pinned downstreams without askingReal Data Table write, real sub-workflow side effects, real Execute Command output, etc. Triggers + credentialed nodes + HTTP get pinned, nothing else doesAsk first. See references/TESTING.md.
No node groups on a canvas over 7 top-level boxesReader has to read every node to find what they wantGroup each logical step. See references/NODE_GROUPS.md
Reporting a create or update as done without reading its group fields (skippedGroups on create; skippedOperations / removedGroups on update)A group op was silently skipped, or an existing group was deleted by an unrelated edit, and the save still looked successfulCheck them on every call and repair. See references/NODE_GROUPS.md
Sticky note used to fake a group, or sticky-of-every-colorGrouping is the node group's job / color becomes pure noiseGroup with a node group; reserve stickies for callouts, one color per category
Hand-positioned stickies on create_workflow_from_codeCoordinates are chosen before layout runs, so the note lands away from the nodes it describesPass the nodes to sticky(content, [nodes]) and let the box be derived. See references/STICKY_NOTES.md
description: "Sends Slack."Adds nothing visible from the trigger and Slack nodeInclude why + AI-derived context: "Sends weekly summary to founders. Replaces manual report that kept getting skipped."
Designing fan-out branches as if they execute concurrentlyn8n runs fan-out branches sequentially, top-to-bottom by Y-position. Total runtime is the sum of branches, not the maxFor real concurrency, dispatch via Execute Workflow with mode: 'each' + waitForSubWorkflow: false. See n8n-subworkflows-official "Fire-and-forget parallelization"

Files

references/VALIDATION_CHECKLIST.md

Pre-publish validation checklist

Run before every publish_workflow. The whole list. Skipping items is how broken workflows ship.

The checklist

1. validate_workflow passed

Run validate_workflow. Schema and shape errors must be zero. If validation fails, fix and re-validate.

If a failure points at a single node's params, validate_node_config on that node alone returns per-parameter errors without full-graph noise. For tool subnodes, set isToolNode: true. Best used as a per-node spot-check during BUILD.

2. Antipattern scan (the build-time discipline check)

Walk the workflow with these questions in mind. These are patterns that recur across builds even when relevant skills are loaded, so making this explicit catches them.

Set nodes:

  • For each Set node, count how many downstream nodes reference its output fields.

  • If only 0 or 1 downstream consumer references each field, delete the Set node and inline the expression at the consumer. The most common antipattern (n8n-expressions-official non-negotiable #2).

  • Common offender: a Set node right before a Data Table Insert / Update node, mapping fields to match schema. Map directly in the Insert/Update node's expression slots.

  • Common offender: a Set node building a body before an Email/Slack node. Build the body in the body field with an expression.

Code nodes:

  • For each Code node, ask: could this be an expression or arrow-function-in-Edit-Fields?

  • If it's pure data shaping (.map, .filter, .find, field renaming, optional chaining), rewrite as expression or Edit Fields with arrow function. Code's bar is multi-source aggregation, external libraries, or stateful transforms (n8n-code-nodes-official).

  • For each operation the Code does, check separately for a native node. A Code node doing 4 things probably has 4 native answers. Read its body and ask:

    • this.helpers.httpRequest(...) → use the HTTP Request node.

    • Manual pagination loop (while (more) { start += page; ... }) → use HTTP Request's Pagination option.

    • Regex parsing structured response (/<id>...<\/id>/g, etc.) → use the XML node for XML, JSON.parse for JSON.

    • crypto.createHash(...) or crypto.createHmac(...) → use the Crypto node.

    • Status-code retry logic (if (status === 429) throw) → HTTP Request's retryOnFail (retries on any error, no per-status filter, capped at 5 tries / 5000ms wait). For 429-only or 5xx-only retry, use the error output + IF on $json.error.httpCode instead.

  • Identity Code nodes (return $('Some Node').all(); or return $input.all();) are always wrong. They re-emit upstream data, which means the workflow shape is wrong: the downstream consumer should branch off the upstream directly, or the per-item-vs-aggregate context mismatch should be solved with fan-out, not a Code-node bridge.

  • Common offender: flattening a single API response's nested structure. That's Edit Fields with arrow function, not Code.

Merge nodes:

  • Count wires going in. Confirm numberOfInputs matches.

  • For Merges using useDataOfInput, walk through the off-by-one rule (n8n-node-configuration-official references/MERGE_NODE.md).

Fan-out branches:

  • If the design assumes branches run in parallel, it's wrong. n8n runs them sequentially top-to-bottom by Y-position. For real concurrency, dispatch via Execute Workflow with mode: 'each' + waitForSubWorkflow: false.

DateTime nodes:

  • Replace with a Luxon expression (see n8n-expressions-official). DateTime nodes are almost always wrong.

Sub-workflow triggers:

  • For each Execute Workflow Trigger, confirm "Define Below" mode with typed fields. Passthrough is only correct for (a) binary-receiving sub-workflows that won't be agent tools or (b) sub-workflows that genuinely take no inputs (Define Below requires at least one field). For (b), verify the body opens with a Set ("Keep Only Set", no fields) and a sticky noting no inputs are expected. See n8n-subworkflows-official non-negotiable #2.

Message an Agent nodes (calling a first-class n8n Agent):

  • The Agent is published (production runs use the published version), has a memory block if sessionKey is set, and has no approval-required tools: approvals fail under Message an Agent.

  • sessionKey is prefixed per Agent (support-<telegramId>, not the bare id): keys are project-wide, so a second Agent called with a key the first already used fails. Max 74 chars.

  • onError: 'continueErrorOutput' with a handled error branch on anything user-facing. See n8n-agents-official references/MESSAGE_AN_AGENT.md.

Data references:

  • Search for $json. in expressions. Replace with $('Node Name').item.json. unless the node is directly downstream of a single source with no intermediates (n8n-expressions-official non-negotiable #1).

  • Search for $env. in expressions. Doesn't work, throws at runtime. Replace with $vars.X (paid plans), a Data Table, or a credential if it's a secret.

Skipping it is how build-time slips slip past validation.

3. Error handling is wired

For workflows that are webhook-triggered, production-bound, or otherwise user-facing, every fallible node should have its error path handled. This isn't about catching bugs. It's about returning a clean response when an upstream is down.

Invoke n8n-error-handling-official if any of these are true:

  • Webhook trigger with a respond-to-webhook pair.

  • Unattended (scheduled, cron, queue-driven).

  • A failure would silently drop user-visible work.

For internal one-off scripts (manual trigger), error handling can be looser.

4. Credentials, not tokens in text fields

Walk every node config for tokens, API keys, or auth values pasted into text parameters. They should be referenced via the credential system.

If you find any, invoke n8n-credentials-and-security-official and migrate before publishing.

5. test_workflow produced expected output

Use prepare_workflow_pin_data, then test_workflow. Inspect outputs via get_workflow_execution.

Before running: test_workflow auto-pins triggers, credentialed nodes, and HTTP Request. Code, Edit Fields, If, Data Tables, Execute Command, file ops, and sub-workflow calls run for real. If any of those have user-visible side effects, ask the user before running. See TESTING.md for the side-effect protocol, mocking by trigger type, pinning individual nodes, and the post-run announce-what-was-pinned protocol.

Check:

  • Output shape matches what consumers expect.

  • No unexpected errors swallowed by error branches.

  • Fan-outs all produced data, none collapsed to empty.

  • For webhook responses, the shape is correct (status, body, headers).

Fix and re-test if anything's off.

6. Naming, descriptions, structure

Quick pass:

  • Workflow name follows the verb-first pattern (NAMING_CONVENTIONS.md). Sub-workflows are tagged (subworkflow, a domain tag, tool) since that's how search_workflows({ tags }) finds them.

  • description is set and captures both what and why, with searchable keywords.

  • Nodes are renamed from defaults.

  • Canvases over 7 top-level boxes (trigger + groups + ungrouped nodes) group their logical steps. Ungrouped still runs, but a large ungrouped canvas is hard to read, and from n8n 2.40.0 the server warns about it. See NODE_GROUPS.md.

  • The last save reported no unresolved group problem: skippedGroups on a create, skippedOperations / removedGroups on an update, or an over-ceiling warning from either (one marked [pre-existing] was already true before your change: leave it). A group op can be skipped, and an existing group can be removed by unrelated edits, without the save failing. See NODE_GROUPS.md "Failure modes".

These don't block publish technically, but workflows without them rot faster.

7. Folder placement

If the user requested a specific folder, confirm via search_folders that the workflow ended up there. If the folder didn't exist, you should have surfaced that before building (FOLDER_LIMITATIONS.md). Don't silently dump at root.

8. MCP access (if applicable)

Workflows created via create_workflow_from_code default to MCP-accessible. No toggle step needed. Only ask the user to flip the toggle when:

  • They built the workflow in the n8n UI and you need to operate on it.

  • They want to revoke MCP access on an agent-created workflow (the toggle is on by default).

See MCP_ACCESS_PER_WORKFLOW.md.

Order matters

Top-to-bottom. Items 1-4 are gates: failing any means the workflow shouldn't publish. Items 5-8 are quality checks: failing means the workflow ships and rots, but won't break immediately.

The most common skip is item 2 (the antipattern scan). It feels like polish, but it catches things validate_workflow doesn't.

What to do if something fails after publish

Post-publish is high-stakes: run every operation through the user. Once a workflow is published, it may be receiving real traffic, holding state, or being depended on by other systems. Do not take autonomous action: no publish_workflow, no unpublish_workflow, no update_workflow, no archive_workflow, no triggering executions to "see what happens." Surface the problem, propose the fix, and wait for explicit approval before each step. The guidance below is what to recommend to the user, not what to do without asking.

n8n keeps versions: get_workflow_details returns both versionId (the current draft) and activeVersionId (the version that's live). They diverge when you save changes via update_workflow. Those changes only go live on the next publish_workflow call. Saving is not publishing.

  1. Consider rolling back first. get_workflow_history lists saved versions (newest first); get_workflow_version fetches a known-good one, and restore_workflow_version re-applies it as the draft (or pass its versionId to publish_workflow to go straight live). (n8n 2.29.0+.) Rollback no longer needs the user to copy a versionId from the UI, but per the guardrail above, recommend it and let the user approve before you restore.

  2. Recommend unpublish_workflow only if no rollback target exists and the workflow is actively running and broken. A scheduled or webhook workflow with broken connections shouldn't keep firing. Surface the problem and the recommendation, let the user pull the trigger.

  3. Fix-forward path: update_workflow saves the draft, then publish_workflow makes it live. Two separate steps: update_workflow does NOT auto-publish, the change sits as an unpublished draft until publish_workflow runs against it. Re-run this checklist before the publish step. Don't trust that "just one fix" doesn't ripple.

A note on speed

The cost of skipping is higher than the cost of checking. Debugging a broken production workflow is much more time consuming, stressful, and can cause damage.

Requirements and compatibility

Works with: Claude Code, Claude apps, OpenAI Codex, GitHub Copilot, Cursor, Gemini CLI, Kiro, OpenCode, Goose, Amp, Roo Code, JetBrains Junie, Factory Droid, Devin (ex-Windsurf), Mistral Vibe, OpenHands, Letta

“Works with” means the tool reads the open Agent Skills format; a skill written for one tool may use features others lack.

Needs: Needs an API key, Needs Node.js

Security

No issues found by our static scan· No issues found

A static scan is not a guarantee. Skills are third-party content: review a skill before you let an agent use it.

Attribution and licence

Published by
n8n
Publisher
n8n (Official)
Source
n8n-io/skills · skills/n8n-workflow-lifecycle-official · commit 27b6b9f
Licence
Apache License 2.0 (redistribution allowed)
  • LICENSE (added by AutoGineer from LICENSE)
  • ATTRIBUTION.md (written by AutoGineer)
Synced

AutoGineer is not affiliated with or endorsed by n8n.

Download ZIP

The ZIP holds the skill’s files, its licence files and an ATTRIBUTION.md. Download n8n-workflow-lifecycle-official.zip