Skip to main content
Glama
n8n MCP Server

n8n MCP Server

by r-ms

n8n_update_workflow_json

Deploy a complete n8n workflow from a JSON string: parse it, run validation and auto-fixes, update the workflow, and optionally activate it after deployment.

Instructions

Deploy a complete workflow from JSON string. Parses the JSON, runs pre-flight validation/auto-fix, PUTs the update, and optionally activates. Use this for 'edit local file → deploy' patterns instead of raw curl.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "workflowId": "<workflowId>",
      "json": "<json>"
    },
    "name": "n8n_update_workflow_json"
  }
}

Input Schema

NameRequiredDescriptionDefault
jsonYesComplete workflow JSON as a string
activateNoActivate after deploy (default: false)
workflowIdYesWorkflow ID to update

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.9/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description does substantial work: it discloses an internal pipeline, warns that pre-flight validation/auto-fix runs (an implicit input transformation), and states that activation is opt-in with a default of false. It does not disclose that a 'complete' JSON replaces the entire existing workflow (destructive overwrite), or what happens when validation fails, which are the remaining behavioral gaps.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Three short sentences, front-loaded with the action, then the process, then the routing hint. Every clause carries information and nothing is padded.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a mutation tool with zero annotations and no output schema, the description covers the how (pipeline) but leaves key operational facts unstated: that it overwrites the whole workflow, what the response contains, and failure behavior when JSON is invalid. The auto-fix step is mentioned but not explained, leaving ambiguity about whether the stored workflow differs from the submitted JSON.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so all three parameters are documented structurally and the baseline is 3. The description reinforces 'complete' for the json parameter, implying full replacement rather than merge, but adds no format or size constraints beyond what the schema already states.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description gives a specific verb and resource ('Deploy a complete workflow from JSON string') and enumerates the internal steps (parse, validate/auto-fix, PUT, optional activate). The word 'complete' hints at full-replacement semantics, but the near-identically named sibling n8n_update_workflow is never mentioned, so the agent must infer the distinction rather than being told it.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It supplies a concrete usage pattern ('edit local file → deploy') and names an alternative to avoid ('raw curl'), which is real routing guidance. It stops short of a when-not rule or an explicit comparison against the sibling n8n_update_workflow, which is the most likely source of mis-selection.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.