60 lines
1.9 KiB
Python
60 lines
1.9 KiB
Python
# Copyright (c) 2025 Patrick Motsch
|
|
# Canvas start nodes — variant reflects workflow configuration (gear in editor).
|
|
|
|
TRIGGER_NODES = [
|
|
{
|
|
"id": "trigger.manual",
|
|
"category": "trigger",
|
|
"label": "Start",
|
|
"description": "Manuell, API oder Hintergrund-Starts (Webhook, E-Mail, …).",
|
|
"parameters": [],
|
|
"inputs": 0,
|
|
"outputs": 1,
|
|
"inputPorts": {},
|
|
"outputPorts": {0: {"schema": "ActionResult"}},
|
|
"executor": "trigger",
|
|
"meta": {"icon": "mdi-play", "color": "#4CAF50"},
|
|
},
|
|
{
|
|
"id": "trigger.form",
|
|
"category": "trigger",
|
|
"label": "Start (Formular)",
|
|
"description": "Felder werden beim Start befüllt; konfigurieren Sie die Felder auf dieser Node.",
|
|
"parameters": [
|
|
{
|
|
"name": "formFields",
|
|
"type": "json",
|
|
"required": False,
|
|
"frontendType": "fieldBuilder",
|
|
"description": "Felddefinitionen",
|
|
},
|
|
],
|
|
"inputs": 0,
|
|
"outputs": 1,
|
|
"inputPorts": {},
|
|
"outputPorts": {0: {"schema": "FormPayload", "dynamic": True, "deriveFrom": "formFields"}},
|
|
"executor": "trigger",
|
|
"meta": {"icon": "mdi-form-select", "color": "#9C27B0"},
|
|
},
|
|
{
|
|
"id": "trigger.schedule",
|
|
"category": "trigger",
|
|
"label": "Start (Zeitplan)",
|
|
"description": "Cron-Ausdruck für geplante Läufe.",
|
|
"parameters": [
|
|
{
|
|
"name": "cron",
|
|
"type": "string",
|
|
"required": False,
|
|
"frontendType": "cron",
|
|
"description": "Cron-Ausdruck",
|
|
},
|
|
],
|
|
"inputs": 0,
|
|
"outputs": 1,
|
|
"inputPorts": {},
|
|
"outputPorts": {0: {"schema": "ActionResult"}},
|
|
"executor": "trigger",
|
|
"meta": {"icon": "mdi-clock", "color": "#2196F3"},
|
|
},
|
|
]
|