Token导航 LogoToken导航

Agent Skill · 研究检索

n8n-code-&-expressions(n8n 代码和表达式)

n8n-code-&-expressions 用于查找、检索和筛选相关信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

n8n-code-&-expressions 是研究检索类 Agent Skill,可用宿主为 Codex、Claude、Cursor、Gemini CLI,通过GitHub 仓库获取,权限为权限未标注;许可证信息还不明确,暂无第三方扫描结果,按安装量在研究检索类的 73,675 个 Skill 里排第 33,915。

总安装 2,294周安装 98GitHub Stars 公开资料未说明下载 977核验 2026-05-01

安装说明

本站只整理中文说明,不托管安装包,也不代用户安装。
GitHub
许可证
unknown

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:n8n-code-&-expressions(n8n 代码和表达式)
来源仓库:https://github.com/willsigmon/sigstack
仓库路径:skills/n8n-code-&-expressions
安装命令:
npx skills add willsigmon/sigstack --skill "n8n-code-&-expressions"
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

AgentSkills.tonpx skills
npx skills add willsigmon/sigstack --skill "n8n-code-&-expressions"

这个 Skill 是做什么的

研究检索类 Skill 主要解决「找资料、核对事实、把来源整理清楚」的问题,通常会让助手先检索再总结。

发现并安装 AI 代理技能的通用工具,支持从 sigstack 仓库加载模块。适用于 Codex、Claude、Cursor、Gemini CLI 等多宿主环境扩展能力。通过 npx 命令添加 willsigmon/sigstack 中的指定技能。

安装命令:npx skills add willsigmon/sigstack --skill "n8n-code-&-expressions",需网络访问。使用前应确认技能功能与宿主兼容性,避免安装冗余或冲突模块。

来源仓库内路径:skills/n8n-code-&-expressions

上手步骤

4 步
  1. 1

    确认自己的宿主工具

    公开资料标注支持 Codex、Claude、Cursor、Gemini CLI;先确认自己用的是其中之一,再按对应工具的 Skills 目录放置。

  2. 2

    拿到安装命令

    可以直接复制的命令是 npx skills add willsigmon/sigstack --skill "n8n-code-&-expressions";命令里的占位符换成自己的路径或密钥再执行。

  3. 3

    安装后重启宿主

    命令执行完要完全退出宿主工具再打开,让新装的 Skill 被重新扫描到,否则列表里可能看不到。

  4. 4

    按最小权限试用

    权限没有明确标注,第一次使用时只给一个无关紧要的任务,观察它到底读了哪些文件和网络。

常见问题

6 条

n8n-code-&-expressions 怎么安装?

在终端执行 npx skills add willsigmon/sigstack --skill "n8n-code-&-expressions"。装完完全退出宿主工具再打开,让它重新扫描本地 Skill。

n8n-code-&-expressions 支持哪些 AI 工具?

公开资料标注支持 Codex、Claude、Cursor、Gemini CLI。其他工具只要能读取本地 Skill 目录,一般也能手动放进去,但要自己确认触发方式是否一致。

n8n-code-&-expressions 需要什么权限?

权限级别没有明确标注。第一次使用时建议只给无关紧要的任务,观察它实际读写了哪些内容。

n8n-code-&-expressions 是免费的吗?

公开资料没有标注明确许可证,收费和商用限制都无法确认。正式使用前请到来源仓库核对授权说明。

n8n-code-&-expressions 用的人多吗?

公开数据是累计安装 2,294 次,近一周安装 98 次,下载 977 次。这些数字来自第三方目录统计,只能当作热度参考,不代表质量或安全性。

n8n-code-&-expressions 安全吗?

没有查到第三方扫描结果,安全性无法从公开资料判断,安装前请自行审查源码、依赖和命令行为。

值得选的地方和要先想清楚的地方

值得选的地方

  • 同时适配 4 种工具,换客户端不用重新找替代品。

先想清楚的地方

  • 许可证没有明确标注,能不能商用、能不能再分发都不确定。
  • 没有第三方扫描结果,安全性只能靠自己读源码判断。
  • 第三方目录整理,版本更新和行为细节以来源仓库为准。

适不适合你

更适合

  • 已经在用 Codex,想直接扩展它能力的人。
  • 需要处理研究检索类任务、又不想每次都手写提示词的人。

不太适合

  • 需要明确授权才能用到公司项目里的场景。
  • 要求有安全扫描结论才肯安装的团队。
  • 需要厂商级技术支持和 SLA 的生产系统。

研究检索类 Skill 对比

6 个同类
Skill总安装GitHub 星权限许可证扫描
find-skills

寻找技能 · Codex、Claude

31,199,81316,486操作浏览器MIT有提醒
self-improving-agent

自我改进 Agent · OpenClaw

16,464,0023,396接触敏感数据MIT-0通过
soultrace

灵魂追踪 · Codex、Claude

7,588,94412需要联网未明确有提醒
self-improving

自我完善 · OpenClaw

6,829,2841,046需要联网MIT-0通过
microsoft-foundry

微软代工厂 · Codex、Claude

6,614,144764调用外部服务未明确有提醒
n8n-code-&-expressions

n8n 代码和表达式 · 本页

2,294—权限未标注未明确未收录

按安装量取同分类前几名;数字来自第三方目录统计,只作热度参考,不代表质量结论。

SKILL.md 原文

name
n8n Code & Expressions
description
Write code and expressions in n8n - JavaScript, Python, built-in variables, data transformation
allowed-tools
Read, Write, Edit, WebFetch

n8n Code & Expressions

Master n8n's expression syntax and code capabilities.

Expression Syntax

Expressions in n8n use {{ }} or ={{ }} syntax to reference data dynamically.

Core Variables

$json - Current Item Data
// Access fields from current item
{{ $json.name }}                    // Direct field
{{ $json.user.email }}              // Nested field
{{ $json["field-name"] }}           // Fields with special chars
{{ $json.items[0].id }}             // Array access
$input - Input Operations
// Get all input items
{{ $input.all() }}                  // Array of all items
{{ $input.first() }}                // First item
{{ $input.last() }}                 // Last item
{{ $input.item }}                   // Current item (in loop)

// Get specific item
{{ $input.item(0) }}                // Item at index
{{ $input.item(0).json.name }}      // Field from item
$binary - Binary Data
// Access file/binary data
{{ $binary.data }}                  // Binary data object
{{ $binary.data.fileName }}         // Original filename
{{ $binary.data.mimeType }}         // MIME type
{{ $binary.data.fileSize }}         // Size in bytes
$node - Other Node Data
// Reference output from specific node
{{ $node["HTTP Request"].json.response }}
{{ $node["Code"].json.result }}

// Get all items from node
{{ $node["Split"].json }}

Metadata Variables

$execution - Execution Info
{{ $execution.id }}                 // Execution ID
{{ $execution.mode }}               // "manual" or "trigger"
{{ $execution.resumeUrl }}          // URL to resume (Wait node)
{{ $execution.customData }}         // Custom execution data
$workflow - Workflow Info
{{ $workflow.id }}                  // Workflow ID
{{ $workflow.name }}                // Workflow name
{{ $workflow.active }}              // Is active (boolean)
$env - Environment Variables
{{ $env.MY_API_KEY }}               // Access env var
{{ $env["DATABASE_URL"] }}          // Env var with special chars
$vars - Workflow Variables
{{ $vars.baseUrl }}                 // Workflow-level variable
{{ $vars.apiVersion }}              // Defined in workflow settings
$now and $today
{{ $now }}                          // Current datetime (ISO)
{{ $today }}                        // Today's date (ISO)
{{ $now.toMillis() }}               // Unix timestamp (ms)
{{ $now.format('yyyy-MM-dd') }}     // Formatted date

Item Context Variables

{{ $itemIndex }}                    // Current item index (0-based)
{{ $runIndex }}                     // Current run index
{{ $prevNode }}                     // Previous node reference
{{ $position }}                     // Node position in workflow

Built-in Methods

String Methods

{{ $json.text.toUpperCase() }}
{{ $json.text.toLowerCase() }}
{{ $json.text.trim() }}
{{ $json.text.split(',') }}
{{ $json.text.replace('old', 'new') }}
{{ $json.text.slice(0, 10) }}
{{ $json.text.includes('search') }}
{{ $json.text.startsWith('prefix') }}
{{ $json.text.length }}

Number Methods

{{ Math.round($json.price) }}
{{ Math.floor($json.value) }}
{{ Math.ceil($json.value) }}
{{ Math.abs($json.diff) }}
{{ Math.max($json.a, $json.b) }}
{{ Number.parseFloat($json.str) }}
{{ Number.parseInt($json.str, 10) }}
{{ $json.amount.toFixed(2) }}

Array Methods

{{ $json.items.length }}
{{ $json.items.map(i => i.name) }}
{{ $json.items.filter(i => i.active) }}
{{ $json.items.find(i => i.id === '123') }}
{{ $json.items.includes('value') }}
{{ $json.items.join(', ') }}
{{ $json.items.slice(0, 5) }}
{{ $json.items.sort((a,b) => a.name.localeCompare(b.name)) }}
{{ $json.items.reverse() }}
{{ [...new Set($json.items)] }}     // Unique values

Object Methods

{{ Object.keys($json.data) }}
{{ Object.values($json.data) }}
{{ Object.entries($json.data) }}
{{ JSON.stringify($json.data) }}
{{ JSON.parse($json.jsonString) }}
{{ {...$json.obj1, ...$json.obj2} }}  // Merge objects

Date Methods

// Luxon DateTime (built-in)
{{ DateTime.now().toISO() }}
{{ DateTime.fromISO($json.date).toFormat('MM/dd/yyyy') }}
{{ DateTime.now().plus({days: 7}).toISO() }}
{{ DateTime.now().minus({hours: 2}).toISO() }}
{{ DateTime.now().startOf('day').toISO() }}
{{ DateTime.now().endOf('month').toISO() }}

// Comparison
{{ DateTime.fromISO($json.date) > DateTime.now() }}
{{ DateTime.fromISO($json.date).diff(DateTime.now(), 'days').days }}

Utility Methods

// Conditionals
{{ $json.status === 'active' ? 'Yes' : 'No' }}
{{ $json.value ?? 'default' }}      // Nullish coalescing
{{ $json.name || 'Anonymous' }}     // Falsy fallback

// Type checking
{{ typeof $json.value }}
{{ Array.isArray($json.items) }}
{{ $json.value === null }}
{{ $json.value === undefined }}

Code Node (JavaScript)

Basic Structure

// Process all items - must return array of {json: {...}} objects
const results = [];

for (const item of $input.all()) {
  // Process each item
  results.push({
    json: {
      original: item.json,
      processed: true,
      timestamp: new Date().toISOString()
    }
  });
}

return results;

Single Item Return

// Return single item
return [{
  json: {
    result: 'processed',
    data: $json.input
  }
}];

Async Operations

// HTTP request example
const response = await fetch('https://api.example.com/data', {
  method: 'POST',
  headers: {'Content-Type': 'application/json'},
  body: JSON.stringify({input: $json.data})
});

const data = await response.json();

return [{json: data}];

Working with Binary Data

// Access binary data
const binaryData = $input.first().binary;
const fileName = binaryData.data.fileName;

// Create binary output
const csvContent = 'name,email\nJohn, [email protected] ';
const base64 = Buffer.from(csvContent).toString('base64');

return [{
  json: {exported: true},
  binary: {
    data: {
      data: base64,
      mimeType: 'text/csv',
      fileName: 'export.csv'
    }
  }
}];

Error Handling

try {
  const result = await riskyOperation($json.data);
  return [{json: {success: true, result}}];
} catch (error) {
  // Option 1: Return error info
  return [{json: {success: false, error: error.message}}];

  // Option 2: Throw to trigger error workflow
  throw new Error(`Processing failed: ${error.message}`);
}

Using External Data

// Get data from another node
const httpData = $node['HTTP Request'].json;

// Get all items from a node
const allItems = $items('Split Out');

// Get environment variable
const apiKey = $env.API_KEY;

Code Node (Python)

Basic Structure

# Process all items
results = []

for item in _input.all():
    data = item["json"]
    results.append({
        "json": {
            "original": data,
            "processed": True,
            "uppercase": data.get("text", "").upper()
        }
    })

return results

Data Transformation

import json
from datetime import datetime

# Access current item
data = _json

# Transform data
result = {
    "json": {
        "id": data.get("id"),
        "name": data.get("name", "").strip(),
        "score": int(data.get("score", 0)) * 2,
        "processed_at": datetime.now().isoformat()
    }
}

return [result]

Using Libraries

# Available: json, datetime, re, math, urllib
import re
import math

text = _json.get("content", "")
emails = re.findall(r'[\w\.-]+@[\w\.-]+', text)

return [{
    "json": {
        "emails": emails,
        "count": len(emails)
    }
}]

Data Transformation Patterns

Flatten Nested Data

const item = $json;
return [{
  json: {
    id: item.id,
    userName: item.user.name,
    userEmail: item.user.email,
    addressCity: item.address?.city ?? 'Unknown'
  }
}];

Group By Field

const items = $input.all();
const grouped = {};

for (const item of items) {
  const key = item.json.category;
  if (!grouped[key]) grouped[key] = [];
  grouped[key].push(item.json);
}

return Object.entries(grouped).map(([category, items]) => ({
  json: {category, items, count: items.length}
}));

Deduplicate

const items = $input.all();
const seen = new Set();
const unique = [];

for (const item of items) {
  const key = item.json.id;
  if (!seen.has(key)) {
    seen.add(key);
    unique.push(item);
  }
}

return unique;

Pivot Data

// Convert rows to columns
const items = $input.all();
const pivoted = {};

for (const item of items) {
  const {key, value} = item.json;
  pivoted[key] = value;
}

return [{json: pivoted}];

Batch Items

const items = $input.all();
const batchSize = 10;
const batches = [];

for (let i = 0; i < items.length; i += batchSize) {
  batches.push({
    json: {
      batch: Math.floor(i / batchSize) + 1,
      items: items.slice(i, i + batchSize).map(item => item.json)
    }
  });
}

return batches;

Common Recipes

Validate Required Fields

const required = ['email', 'name', 'amount'];
const missing = required.filter(f => !$json[f]);

if (missing.length > 0) {
  throw new Error(`Missing required fields: ${missing.join(', ')}`);
}

return [{json: {...$json, validated: true}}];

Parse JSON String

let parsed;
try {
  parsed = JSON.parse($json.jsonString);
} catch (e) {
  throw new Error('Invalid JSON input');
}
return [{json: parsed}];

Format Currency

const amount = $json.amount;
const formatted = new Intl.NumberFormat('en-US', {
  style: 'currency',
  currency: 'USD'
}).format(amount);

return [{json: {...$json, formattedAmount: formatted}}];

Generate UUID

function uuid() {
  return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, c => {
    const r = Math.random() * 16 | 0;
    const v = c === 'x' ? r : (r & 0x3 | 0x8);
    return v.toString(16);
  });
}

return [{json: {...$json, id: uuid()}}];

Rate Limit Helper

// Track calls for rate limiting
const execId = $execution.id;
const callCount = $workflow.staticData?.callCount ?? 0;

$workflow.staticData = {
  callCount: callCount + 1,
  lastCall: Date.now()
};

return [{json: {...$json, callNumber: callCount + 1}}];

Debugging

Log Data

console.log('Input:', JSON.stringify($json, null, 2));
console.log('Item count:', $input.all().length);
console.log('Execution:', $execution.id);

Inspect Types

return [{
  json: {
    inputType: typeof $json,
    keys: Object.keys($json),
    itemCount: $input.all().length,
    hasEmail: 'email' in $json,
    emailType: typeof $json.email
  }
}];

Output Format

EXPRESSION:
  {{ [expression here] }}
  Returns: [expected output]

CODE PATTERN:
  Purpose: [what it does]

[code here]

  Input: [sample input]
  Output: [sample output]

平台分布

Codex

35.56%
按下载量换算347

Claude

31.38%
按下载量换算307

Cursor

18.18%
按下载量换算178

Gemini CLI

10.15%
按下载量换算99

安全审计

暂无安全审计结果可展示。

权限和风险

权限未标注

当前来源未能明确判断权限范围,默认进入异常复核队列。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。目前只有一个公开来源,建议同时核对源仓库。

继续浏览同类 Skills