n8n-expression-syntax

Validates n8n expression syntax and fixes common {{}} errors in workflows.

Updated Apr 12, 2026
One-click install
npx skills add https://github.com/Sebasarmas19/Chatbot-Reminder --skill n8n-expression-syntax-sebasarmas19
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: n8n-expression-syntax
Source: https://github.com/Sebasarmas19/Chatbot-Reminder/tree/main/n8n-skills/skills/n8n-expression-syntax
Command: npx skills add https://github.com/Sebasarmas19/Chatbot-Reminder --skill n8n-expression-syntax-sebasarmas19

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Writing n8n expressions often leads to silent failures: missing curly braces, undefined webhook data, broken node references, and expressions mistakenly used inside Code nodes. This Skill provides the correct syntax rules, a catalog of 15 common mistakes with fixes, and real workflow examples so expressions resolve correctly the first time. ## Core Features & Use Cases - Expression Syntax Rules: Covers the {{ }} format and core variables ($json, $node, $now, $env) with validation rules for quotes, brackets, and case sensitivity. - Webhook Data Gotcha: Explains the critical detail that webhook payloads live under $json.body, the single most common source of undefined values. - Error Catalog & Examples: Includes 15 documented mistakes with fixes plus 10 real workflow examples covering Slack notifications, HTTP requests, date formatting, and array operations. - Use Case: When a workflow shows "undefined" for a webhook field, use this Skill to identify that the expression must be {{$json.body.email}} instead of {{$json.email}}. ## Quick Start Ask the AI to check why your n8n expression {{$json.name}} returns undefined in a webhook workflow and fix the syntax.

Frequently Asked Questions about n8n-expression-syntax

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

FAQPage Schema
How do I access webhook data in n8n expressions?

Webhook data in n8n is nested under the body property, so use {{$json.body.fieldName}} rather than {{$json.fieldName}}. The webhook node output separates headers, params, query, and body, which is why root-level access returns undefined.

Why is my n8n expression showing as literal text?

Expressions appear as literal text when they are not wrapped in double curly braces. Change $json.email to {{$json.email}} so n8n evaluates it instead of treating it as a plain string.

Can I use {{ }} expressions inside n8n Code nodes?

No, Code nodes use direct JavaScript access without curly braces. Write const email = $json.email or use $input.item.json.email instead of the {{ }} expression syntax, which only works in expression fields of other nodes.

How do I reference another node with spaces in its name?

Use bracket notation with quotes: {{$node["HTTP Request"].json.data}}. Node names are case-sensitive and must match the workflow exactly, so {{$node["http request"]}} would fail.

How do I handle field names with spaces in n8n expressions?

Use bracket notation such as {{$json['first name']}} because spaces break dot notation. This also applies to nested paths like {{$json['user data']['phone number']}}.

When should I not use n8n expressions?

Avoid expressions in Code nodes, webhook paths, and credential fields. Webhook paths must be static or use URL parameters like :userId, and credentials should use the n8n credential system rather than environment variable expressions.