# Copyright (c) 2025 Patrick Motsch
# Trigger node definitions - workflow entry points.

TRIGGER_NODES = [
    {
        "id": "trigger.manual",
        "category": "trigger",
        "label": {"en": "Manual Trigger", "de": "Manueller Trigger", "fr": "Déclencheur manuel"},
        "description": {"en": "Start workflow on button press", "de": "Startet den Workflow bei Knopfdruck", "fr": "Démarre le workflow sur clic"},
        "parameters": [],
        "inputs": 0,
        "outputs": 1,
        "executor": "trigger",
        "meta": {"icon": "mdi-play", "color": "#4CAF50"},
    },
    {
        "id": "trigger.schedule",
        "category": "trigger",
        "label": {"en": "Schedule", "de": "Zeitplan", "fr": "Planification"},
        "description": {"en": "Run on a cron schedule", "de": "Läuft nach Cron-Zeitplan", "fr": "S'exécute selon un cron"},
        "parameters": [
            {"name": "cron", "type": "string", "required": True, "description": {"en": "Cron expression (e.g. 0 9 * * * for daily at 9)", "de": "Cron-Ausdruck", "fr": "Expression cron"}},
        ],
        "inputs": 0,
        "outputs": 1,
        "executor": "trigger",
        "meta": {"icon": "mdi-clock", "color": "#2196F3"},
    },
    {
        "id": "trigger.formSubmit",
        "category": "trigger",
        "label": {"en": "Form Submit", "de": "Formular-Absendung", "fr": "Soumission formulaire"},
        "description": {"en": "Start when form is submitted", "de": "Startet bei Formular-Absendung", "fr": "Démarre à la soumission du formulaire"},
        "parameters": [
            {"name": "formId", "type": "string", "required": True, "description": {"en": "Form identifier", "de": "Formular-ID", "fr": "Identifiant du formulaire"}},
        ],
        "inputs": 0,
        "outputs": 1,
        "executor": "trigger",
        "meta": {"icon": "mdi-form-select", "color": "#9C27B0"},
    },
]
