summary: Proxmox Backup Webhook description: | Empfängt Backup-Benachrichtigungen von Proxmox via Webhook, speichert alle VM-Backups in MySQL und sendet eine Zusammenfassung an Nextcloud Talk. value: modules: - id: a summary: Payload parsen & aufbereiten value: type: rawscript content: '!inline payload_parsen_&_aufbereiten.py' input_transforms: message: type: javascript expr: flow_input.body || flow_input.message || '' severity: type: javascript expr: flow_input.severity || '' title: type: javascript expr: flow_input.title || (flow_input.body || '').split('\n')[0].trim() || '' debug_mode: type: javascript expr: flow_input.debug_mode || false lock: '!inline payload_parsen_&_aufbereiten.lock' language: python3 - id: b summary: In MySQL speichern value: type: rawscript content: '!inline in_mysql_speichern.py' input_transforms: backups: type: javascript expr: results.a.backups batch_id: type: javascript expr: results.a.batch_id raw_payload: type: javascript expr: results.a.raw_payload total_size: type: javascript expr: results.a.total_size total_time: type: javascript expr: results.a.total_time debug_mode: type: javascript expr: flow_input.debug_mode || false lock: '!inline in_mysql_speichern.lock' language: python3 - id: c summary: Nachricht an Nextcloud Talk value: type: rawscript content: '!inline nachricht_an_nextcloud_talk.py' input_transforms: talk_message: type: javascript expr: results.a.talk_message debug_mode: type: javascript expr: flow_input.debug_mode || false lock: '!inline nachricht_an_nextcloud_talk.lock' language: python3 schema: $schema: https://json-schema.org/draft/2020-12/schema type: object properties: body: type: string description: "Proxmox-Webhook Payload (Matrix-Format): Titel + Details + Logs" default: "vzdump backup status (proxmox.netbird.stines.de): backup successful\n\nDetails\n=======\nVMID Name Status Time Size Filename\n127 OLV-CLOUD01-IP17.2 ok 4s 50 GiB vm/127/2026-04-22T19:43:13Z\n131 OLV-WORDP01-IP17.3 ok 3s 50 GiB vm/131/2026-04-22T19:43:17Z\n132 OLV-SMTP01-IP17.1 ok 5s 50 GiB vm/132/2026-04-22T19:43:20Z\n\nTotal running time: 12s\nTotal size: 150 GiB\n\nLogs\n====\nvzdump 127 131 132 --prune-backups 'keep-all=1' --mode snapshot\n\n127: 2026-04-22 21:43:13 INFO: Starting Backup of VM 127 (qemu)\n127: 2026-04-22 21:43:17 INFO: Finished Backup of VM 127 (00:00:04)\n\n131: 2026-04-22 21:43:17 INFO: Starting Backup of VM 131 (qemu)\n131: 2026-04-22 21:43:20 INFO: Finished Backup of VM 131 (00:00:03)\n\n132: 2026-04-22 21:43:20 INFO: Starting Backup of VM 132 (qemu)\n132: 2026-04-22 21:43:25 INFO: Finished Backup of VM 132 (00:00:05)" msgtype: type: string description: "Matrix-Nachrichtentyp (immer m.text)" default: "m.text" message: type: string description: "Fallback: direktes message-Feld (ältere Proxmox-Versionen)" default: "" severity: type: string description: Severity-Level (info, warning, error) default: "info" title: type: string description: "Titel (optional, wird sonst aus erster Zeile von body extrahiert)" default: "" debug_mode: type: boolean description: "Debug-Modus: überspringt DB-Insert und Nextcloud-Nachricht" default: false