Documentation

@marcmeese/n8n-nodes-doc2doc

n8n Community Nodes für die doc2doc API: Dokumente zwischen Formaten konvertieren (PDF, DOCX, ODT, Markdown, HTML, XLSX, PPTX, Bilder, EPUB, …).

Credential „Doc2Doc API“

Feld Beschreibung
Base URL Root-URL der API ohne /v1, z. B. http://doc2doc_server:8000
API Key Wird als Header X-API-Key gesendet

Der Credential-Test ruft GET /v1/formats auf.

Nodes

Node Funktion
(Doc2Doc) Convert Document Datei hochladen und konvertieren. Wartet standardmäßig auf das Ergebnis und gibt es als Binary aus.
(Doc2Doc) Get Conversion Status, Fortschritt und Ergebnis-Infos eines Jobs
(Doc2Doc) Download Result Ergebnis oder Manifest eines fertigen Jobs als Binary
(Doc2Doc) Cancel Conversion Laufenden Job abbrechen
(Doc2Doc) Get Formats Unterstützte Quell-/Zielformate und direkte Konvertierungen

Convert Document

  • Eingabe: Binary-Property (Standard data) oder lokaler Pfad im n8n-Container. Der Dateiname braucht eine Endung – doc2doc erkennt das Quellformat daran.
  • Zielformat: pdf, docx, doc, odt, rtf, txt, md, html, xlsx, xls, ods, csv, pptx, ppt, odp, png, jpg, epub.
  • Optionen: Quality Mode, OCR Mode, Languages, Page Range, Asset Mode, Allow Partial Result, Idempotency Key (siehe doc2doc-API-Doku).
  • Wait for Result (Standard an): fragt den Status ab (Poll Interval, mindestens die Server-Empfehlung) bis der Job fertig ist, und schreibt die Ergebnisdatei in Output Binary Field. Das JSON enthält den finalen Status. Mehrseitige Bild-Exporte oder Pakete mit Bildern kommen als ZIP.
    • FAILED, CANCELLED, EXPIRED → Fehler mit doc2doc-Fehlercode.
    • PARTIAL_SUCCESS (nur mit „Allow Partial Result“) → Erfolg, fehlende Seiten stehen in partial.
    • Timeout → Fehler mit Job-ID; der Job läuft serverseitig weiter und kann mit „Get Conversion“/„Download Result“ abgeholt werden.
  • Wait for Result aus: gibt sofort { id, status: "QUEUED", … } zurück. Die anderen Nodes übernehmen {{ $json.id }} automatisch als Conversion ID.

Entwicklung

npm install
npm run build   # tsc + Icons
npm test        # node --test gegen dist/
npm run lint

Veröffentlicht wird über .github/workflows/n8n-doc2doc.yml, sobald die Version in package.json erhöht und auf main gepusht wird.

Discussion