# Convert OTP to PDF in Node.js

> Convert OTP to PDF in Node.js. Use the Node.js API to convert OTP files to PDF files.

Source: https://products.aspose.com/slides/nodejs-java/conversion/otp-to-pdf/
Updated: 2026-07-13



## Convert OTP to PDF in Node.js

[**Aspose.Slides for Node.js via Java**](/slides/nodejs-java/) lets developers create, read, edit, and convert presentation files in Node.js applications. You can load an `OTP` file with the `Presentation` class and export it to a `PDF` file by using the presentation API.

## Convert OTP to PDF using Node.js

To convert `OTP` to `PDF`, create a `Presentation` from the source file and export it to a `PDF` file.

### Node.js code to convert OTP to PDF

```javascript
const presentation = new aspose.slides.Presentation("sourceFile.otp");
try {
    presentation.save("output.pdf", aspose.slides.SaveFormat.Pdf);
}
finally {
    presentation.dispose();
}
```

## How to convert OTP to PDF using Aspose.Slides for Node.js via Java API

To convert OTP to PDF using Aspose.Slides for Node.js via Java, import the package, load the source file, and export it in the required format.

Install [**Aspose.Slides for Node.js via Java**](/slides/nodejs-java/).

Import the `aspose.slides.via.java` package in your Node.js project.

Load the source `OTP` file with the `Presentation` class.

Call the `save` method with the output file path and `SaveFormat.Pdf`.

## Convert OTP to Other Supported Formats
