If so you can download any of the below versions for testing. The product will function as normal except for an evaluation limitation. At the time of purchase we provide a license file via email that will allow the product to work in its full capacity. If you would also like an evaluation license to test without any restrictions for 30 days, please follow the directions provided here.
If you experience errors, when you try to download a file, make sure your network policies (enforced by your company or ISP) allow downloading ZIP and/or MSI files.

Installation
Das Paket ist verfügbar bei npmjs.com und kann über npm mit folgendem Befehl installiert werden:
npm install groupdocs-conversion-cloud

Anforderungen
Abhängigkeiten
Das SDK benötigt die folgenden Pakete:
| Package | Constraint |
|---|
| axios | 1.14.0 |
| form-data | * |
| jsonwebtoken | 9.0.1 |
| qs | 6.15.0 |
Schnellstart
Um GroupDocs.Conversion Cloud zu nutzen, registrieren Sie sich im GroupDocs.Cloud Dashboard und erhalten Sie Ihre Client ID und Client Secret.
API initialisieren
Verwenden Sie den folgenden Code, um das GroupDocs.Conversion Cloud SDK for Node.js zu nutzen.
"use strict";
const conversion_cloud = require("groupdocs-conversion-cloud");
// Get your ClientId and ClientSecret at https://dashboard.groupdocs.cloud
const clientId = "YourClientId";
const clientSecret = "YourClientSecret";
const config = new conversion_cloud.Configuration(clientId, clientSecret);
config.apiBaseUrl = "https://api.groupdocs.cloud";
const convertApi = conversion_cloud.ConvertApi.fromConfig(config);
Das vollständige Beispiel finden Sie in RunExamples.js.
Dokument direkt konvertieren (ohne Cloud-Speicher)
Nach der Initialisierung konvertieren Sie mit diesem grundlegenden Beispiel ein lokales Dokument und erhalten das Ergebnis direkt.
"use strict";
const conversion_cloud = require("groupdocs-conversion-cloud");
const fs = require("fs");
const convertApi = conversion_cloud.ConvertApi.fromKeys("YourClientId", "YourClientSecret");
(async () => {
let file = fs.readFileSync("./Resources/WordProcessing/four-pages.docx");
let request = new conversion_cloud.ConvertDocumentDirectRequest("pdf", file);
let result = await convertApi.convertDocumentDirect(request);
console.log("Document converted: " + result.length);
})();
Das vollständige Beispiel finden Sie in ConvertToPdfDirect.js.
Dokumente mit Cloud-Speicher konvertieren
Dieses Beispiel lädt eine Datei in den GroupDocs Cloud-Speicher hoch, konvertiert sie und lädt das Ergebnis herunter.
"use strict";
const conversion_cloud = require("groupdocs-conversion-cloud");
const fs = require("fs");
const clientId = "YourClientId";
const clientSecret = "YourClientSecret";
const config = new conversion_cloud.Configuration(clientId, clientSecret);
config.apiBaseUrl = "https://api.groupdocs.cloud";
const convertApi = conversion_cloud.ConvertApi.fromConfig(config);
const fileApi = conversion_cloud.FileApi.fromConfig(config);
(async () => {
let file = fs.readFileSync("./myFile.docx");
await fileApi.uploadFile(new conversion_cloud.UploadFileRequest("myFile.docx", file));
let settings = new conversion_cloud.ConvertSettings();
settings.filePath = "myFile.docx";
settings.format = "pdf";
settings.outputPath = "converted";
let result = await convertApi.convertDocument(new conversion_cloud.ConvertDocumentRequest(settings));
console.log("Document converted: " + result[0].url);
let response = await fileApi.downloadFile(new conversion_cloud.DownloadFileRequest("converted/myFile.pdf", null));
console.log("Expected response type is Stream: " + response.length);
})();
Weitere Details finden Sie in der SDK README.
Dieser Code konvertiert ein kennwortgeschütztes Word-Dokument mit Ausgabeoptionen in PDF.
"use strict";
const conversion_cloud = require("groupdocs-conversion-cloud");
const convertApi = conversion_cloud.ConvertApi.fromKeys("YourClientId", "YourClientSecret");
(async () => {
let settings = new conversion_cloud.ConvertSettings();
settings.filePath = "WordProcessing/password-protected.docx";
settings.format = "pdf";
settings.outputPath = "converted";
let loadOptions = new conversion_cloud.WordProcessingLoadOptions();
loadOptions.password = "password";
let convertOptions = new conversion_cloud.PdfConvertOptions();
convertOptions.centerWindow = true;
convertOptions.compressImages = false;
convertOptions.displayDocTitle = true;
convertOptions.dpi = 1024;
convertOptions.fromPage = 1;
convertOptions.imageQuality = 100;
convertOptions.password = "password";
convertOptions.unembedFonts = true;
settings.loadOptions = loadOptions;
settings.convertOptions = convertOptions;
let result = await convertApi.convertDocument(new conversion_cloud.ConvertDocumentRequest(settings));
console.log("Document converted: " + result[0].url);
})();
Das vollständige Beispiel finden Sie in ConvertToPdf.js.
Bestimmte Seiten eines Dokuments konvertieren
Dieses Beispiel konvertiert nur die Seiten 1 und 3.
"use strict";
const conversion_cloud = require("groupdocs-conversion-cloud");
const convertApi = conversion_cloud.ConvertApi.fromKeys("YourClientId", "YourClientSecret");
(async () => {
let settings = new conversion_cloud.ConvertSettings();
settings.filePath = "WordProcessing/four-pages.docx";
settings.format = "pdf";
settings.outputPath = "converted/two-pages.pdf";
let convertOptions = new conversion_cloud.PdfConvertOptions();
convertOptions.pages = [1, 3];
settings.convertOptions = convertOptions;
let result = await convertApi.convertDocument(new conversion_cloud.ConvertDocumentRequest(settings));
console.log("Document converted: " + result[0].url);
})();
Das vollständige Beispiel finden Sie in ConvertSpecificPages.js.
Rufen Sie die unterstützten Quell-zu-Ziel-Konvertierungen ab.
"use strict";
const conversion_cloud = require("groupdocs-conversion-cloud");
const infoApi = conversion_cloud.InfoApi.fromKeys("YourClientId", "YourClientSecret");
(async () => {
let response = await infoApi.getSupportedConversionTypes(new conversion_cloud.GetSupportedConversionTypesRequest());
console.log("Formats count: " + response.length);
})();
Das vollständige Beispiel finden Sie in GetSupportedConversions.js.
Beispiele auf GitHub
Das Repository GroupDocs.Conversion Cloud Node.js Examples enthält sofort ausführbare Beispiele für:
| Category | Examples |
|---|
| Convert | PDF, HTML, Bild, Präsentation, Tabellenkalkulation, Textverarbeitung; direkte Konvertierung; asynchrone Konvertierung |
| Common Options | Wasserzeichen, bestimmte Seiten, aufeinanderfolgende Seiten, benutzerdefinierte Schriftarten |
| Load Options | CAD, CSV, E-Mail, HTML, OneNote, PDF, Präsentation, Tabellenkalkulation, Text, Textverarbeitung |
| Info | Unterstützte Konvertierungen, Dokumentinformationen, Lizenz |
So führen Sie die Beispiele aus
- Klonen oder laden Sie das Beispiel-Repository herunter
- Bearbeiten Sie
Examples/RunExamples.js und setzen Sie clientId und clientSecret - Wechseln Sie in das Verzeichnis
Examples - Führen Sie
npm install aus - Führen Sie
npm update aus - Führen Sie
npm run-script start aus
Weitere Details finden Sie unter Getting Started.

Document Conversion API | Node.js Cloud API | GroupDocs.Conversion Cloud | REST API | Document Conversion | Auto-detect Formats | Watermarking API | Multi-Format Output | Batch Document Conversion | PDF Conversion | Custom Conversion Options | Page-by-Page Conversion | Font Replacement | OCR Support | Metadata Extraction | Document Merge | Storage API | Document Information API | Document Load Options | Multi-Language Support | Cloud Storage Integration | SDKs for .NET, Java, Node.js | Secure API Access | Docker Support | Scalable Document Conversion | API Rate Limiting