Convert from Base64 – Aspose.HTML Cloud
This article demonstrates how to convert Base64-encoded HTML content into various formats using Aspose.HTML Cloud API. While this example demonstrates converting HTML Base64 to PDF, the same API supports conversion to multiple other formats by simply changing the URL path:
- HTML Converter: PDF, XPS, DOCX, JPEG, PNG, TIFF, BMP, GIF, Markdown, and MHTML.
- SVG Converter: PDF, XPS, JPEG, PNG, TIFF, BMP, and GIF.
Before starting, ensure you have an authorization token. Refer to the Authorization Guide for details.
Base64 Conversion Methods
Aspose.HTML Cloud supports synchronous conversion for Base64-encoded content:
- Synchronous Conversion: Suitable for immediate conversion where the result is returned directly.
Synchronous Base64 HTML to PDF Conversion
Endpoint: POST https://api.aspose.cloud/v4.0/html/conversion/html-pdf/sync
Authorization: Bearer token
Request Body:
1{
2 "InputBase64": "PGh0bWw+PGJvZHk+PGgxPkhlbGxvIFdvcmxkPC9oMT48L2JvZHk+PC9odG1sPg=="
3}
Response: Converted PDF file as a binary stream.