n8n/packages/workflow/package.json
Yuliia Pominchuk 0a36cf18a7
feat(core): Read a workflow's declared input contract outside its node
The fields a workflow declares on its Execute Workflow Trigger are what a run
surface renders a form from, so a caller needs them without executing the node.
Adds a service that answers eligibility and schema together — a workflow with no
readable contract cannot be offered for direct running, and the caller should
not have to ask twice.

Moves the extraction from nodes-base into n8n-workflow. It now has several
readers — the parent editor's resource mapper, MCP deriving tool arguments, and
the run surfaces — and they must all see the same fields. nodes-base re-exports
so call sites are unchanged.

A pre-1.1 trigger gates its input-source parameter behind the node version and
therefore declares nothing, which reads as passthrough. That is correct, and
covered.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-04 16:18:42 +02:00

105 lines
3.2 KiB
JSON

{
"name": "n8n-workflow",
"version": "2.34.0",
"description": "Workflow base code of n8n",
"types": "dist/esm/index.d.ts",
"module": "dist/esm/index.js",
"main": "dist/cjs/index.js",
"exports": {
".": {
"types": "./dist/esm/index.d.ts",
"import": "./dist/esm/index.js",
"require": "./dist/cjs/index.js"
},
"./common": {
"types": "./dist/esm/common/index.d.ts",
"import": "./dist/esm/common/index.js",
"require": "./dist/cjs/common/index.js"
},
"./expression-sandboxing": {
"types": "./dist/esm/expression-sandboxing.d.ts",
"import": "./dist/esm/expression-sandboxing.js",
"require": "./dist/cjs/expression-sandboxing.js"
},
"./*": "./*"
},
"scripts": {
"clean": "rimraf dist .turbo",
"dev": "pnpm watch",
"typecheck": "tsc --noEmit",
"build:vite": "vite build",
"build": "tsc --build tsconfig.build.esm.json tsconfig.build.cjs.json",
"build:unchecked": "tsc --build tsconfig.build.esm.json tsconfig.build.cjs.json --noCheck",
"format": "biome format --write .",
"format:check": "biome ci .",
"lint": "eslint src --quiet",
"lint:fix": "eslint src --fix",
"watch": "tsc --build tsconfig.build.esm.json tsconfig.build.cjs.json --watch",
"test": "vitest run",
"test:unit": "vitest run",
"test:changed": "janitor test-scoped",
"test:dev": "vitest --watch",
"mutate": "node ../../scripts/mutation-health/mutate.mjs --package-dir packages/workflow"
},
"files": [
"dist/**/*"
],
"devDependencies": {
"@langchain/core": "catalog:",
"@n8n/config": "workspace:*",
"@n8n/playwright-janitor": "workspace:*",
"@n8n/typescript-config": "workspace:*",
"@n8n/vitest-config": "workspace:*",
"@stryker-mutator/core": "catalog:",
"@stryker-mutator/vitest-runner": "catalog:",
"@types/express": "catalog:",
"@types/jmespath": "^0.15.0",
"@types/json-schema": "catalog:",
"@types/lodash": "catalog:",
"@types/luxon": "catalog:",
"@types/md5": "^2.3.5",
"@types/ssh2": "catalog:",
"@types/xml2js": "catalog:",
"fast-check": "catalog:",
"nock": "catalog:",
"typescript": "catalog:typescript",
"vite": "catalog:",
"vitest": "catalog:",
"vitest-mock-extended": "catalog:",
"zod": "catalog:"
},
"dependencies": {
"@codemirror/autocomplete": "catalog:",
"@n8n/errors": "workspace:*",
"@n8n/expression-runtime": "workspace:*",
"@n8n/tournament": "workspace:*",
"@n8n/utils": "workspace:*",
"@sentry/core": "catalog:sentry",
"@sentry/node": "catalog:sentry",
"ast-types": "0.16.1",
"axios": "catalog:",
"callsites": "catalog:",
"esprima-next": "5.8.4",
"form-data": "catalog:",
"generate-schema": "2.6.0",
"jmespath": "0.16.0",
"js-base64": "catalog:",
"json-schema": "catalog:",
"jsonrepair": "catalog:",
"jssha": "3.3.1",
"lodash": "catalog:",
"luxon": "catalog:",
"md5": "2.3.0",
"recast": "0.22.0",
"ssh2": "catalog:",
"title-case": "3.0.3",
"transliteration": "2.3.5",
"uuid": "catalog:",
"xml2js": "catalog:"
},
"peerDependencies": {
"zod": "catalog:"
},
"license": "LicenseRef-n8n-sustainable-use"
}