# System API

## Bereich

Diese Datei dokumentiert Settings-, Diagnose-, Test-, Datasheet-, Bugtracker- und Systemverwaltungs-Routen.

## Settings und Diagnostik

| Methode | Pfad | Zweck | Nutzung in UI |
| --- | --- | --- | --- |
| PUT | `/api/settings` | allgemeine Einstellungen speichern | Settings |
| GET | `/api/system/diagnostics` | Systemdiagnose laden | Settings / Tools |
| GET | `/api/system/processes/demo-scale` | Demo-Scale Status lesen | Wiegen / Settings |
| POST | `/api/system/processes/demo-scale/start` | Demo-Scale starten | Wiegen / Settings |
| POST | `/api/system/processes/demo-scale/stop` | Demo-Scale stoppen | Wiegen / Settings |
| POST | `/api/system/processes/demo-scale/restart` | Demo-Scale neu starten | Wiegen / Settings |
| POST | `/api/system/tools/repair` | Repair-Job starten | Settings / Tools |
| GET | `/api/system/tools/repair/status/{job_id}` | Repair-Status lesen | Settings / Tools |

## Tests

| Methode | Pfad | Zweck | Nutzung in UI |
| --- | --- | --- | --- |
| GET | `/api/system/tests/latest` | letzten Teststand laden | Settings / Test Runner |
| POST | `/api/system/tests/run` | Testlauf starten | Settings / Test Runner |
| GET | `/api/system/tests/status/{job_id}` | Testlaufstatus lesen | Settings / Test Runner |
| POST | `/api/system/tests/stop/{job_id}` | Testlauf stoppen | Settings / Test Runner |

## Datasheet Tools

| Methode | Pfad | Zweck | Nutzung in UI |
| --- | --- | --- | --- |
| POST | `/api/system/datasheets/extract` | Datenblatt-Inhalte oder Metadaten extrahieren | Settings / Datasheet Tools |
| POST | `/api/system/datasheets/url` | Datenblatt-Link prüfen oder aufbereiten | Settings / Datasheet Tools |
| GET | `/api/system/datasheets/download-manager/latest` | letzten Download-Manager Status laden | Settings / Tools |
| GET | `/api/system/datasheets/download-manager/status/{job_id}` | laufenden Download-Job prüfen | Settings / Tools |
| POST | `/api/system/datasheets/download-manager/start` | Download-Manager starten | Settings / Tools |
| POST | `/api/system/datasheets/download-manager/stop/{job_id}` | Download-Manager stoppen | Settings / Tools |

## Assistenten und Factory Reset

| Methode | Pfad | Zweck | Nutzung in UI |
| --- | --- | --- | --- |
| GET | `/api/system/assistants/nexus-core` | Nexus-Core Assistent laden | Assistenten |
| POST | `/api/system/assistants/nexus-core/step` | nächsten Assistenten-Schritt verarbeiten | Assistenten |
| GET | `/api/system/assistants/printer-farm` | Printer-Farm Assistent laden | Assistenten |
| POST | `/api/system/assistants/printer-farm/step` | Farm-Assistent weiterfuehren | Assistenten |
| GET | `/api/system/assistants/maintenance` | Maintenance-Assistent laden | Assistenten |
| POST | `/api/system/assistants/maintenance/log` | Maintenance-Log schreiben | Assistenten |
| POST | `/api/system/factory-reset` | Werksreset auslösen | Settings / Daten |

## Crashlogs und Bugtracker

| Methode | Pfad | Zweck | Nutzung in UI |
| --- | --- | --- | --- |
| GET | `/api/system/crashlogs` | Crashlogs laden | Settings / Diagnose |
| DELETE | `/api/system/crashlogs` | Crashlogs leeren | Settings / Diagnose |
| POST | `/api/system/crashlogs` | Crashlog anlegen | Fehlerpfade |
| GET | `/api/system/bug-tracker/status` | Bugtracker-Status laden | Statusleiste |
| POST | `/api/system/bug-tracker/report` | Bug melden | Bugtracker |
| POST | `/api/system/bug-tracker/retry` | fehlgeschlagenen Report erneut senden | Bugtracker |

## Farm-Status und Backup-Import

| Methode | Pfad | Zweck | Nutzung in UI |
| --- | --- | --- | --- |
| GET | `/api/farm/printers/status` | Druckerstatus laden | Farm / Dashboard |
| GET | `/api/farm/scales/status` | Waagenstatus laden | Farm / Dashboard |
| GET | `/api/farm/dryers/status` | Trocknerstatus laden | Farm / Dashboard |
| POST | `/api/settings/backup/import` | Backup importieren | Settings / Daten |


