The CloudConvert website / HTML to PDF, JPG and PNG converter is often used to generate PDF files or thumbnails. Currently, we are using a proven, WebKit-based engine. However, there are use cases that require an even more modern rendering. We are currently experimenting with automating the Chrome browser for this matter.
There is a new option available to enable Chrome for converting HTML files or websites. This option is named "use_chrome" when using our API.
Please note that currently not all of the pre-existing options are available when using Chrome instead of the current engine. The possible options are:
When converting to PDF:
When converting to JPG/PNG:
We are looking forward to get your feedback about this new feature. In particular we are interested if there are any formatting issues or if there are required options missing.
AWS Lambda is an event-driven compute service which runs your code (Lambda functions) in response to events, such as changes to data in an Amazon S3 bucket. The CloudConvert API can be used to automatically convert all files, added to a specific S3 bucket. Typical use cases are converting all office documents to PDF, creating thumbnails or encoding videos.
We have created a GitHub repository with an example Lambda function. To get it running, follow these instructions:
npm install
CLUDCONVERT_API_KEY
to your personal API key.AWS_ACCESS_KEY_ID
and AWS_SECRET_ACCESS_KEY
for downloading and uploading from/to your S3 bucket.outputformat
according to your need. All possible options can be identified using the API Console.convert.js
and the node_modules
folder.Our Amazon S3 integration is a well used feature. Besides S3 we now have integrated OpenStack Storage (Swift), Microsoft Azure File Storage and Google Cloud Storage. You can use any of these file storage solutions as input and output for CloudConvert conversions. Our API Console has been updated and can be used to live-test the new storage options.
We are happy to announce that CloudConvert is now fully integrated with Zapier! Using Zapier you can connect CloudConvert to 500+ other Apps like Evernote, Basecamp, Gmail, Trello, Slack and so many others. Below you can find some ideas for possible "Zaps".
We are looking forward to see your workflows and use cases for Zapier!
We did a lot of improvements on our API regarding input file uploads. Previously you had to embed the file together with all your parameters in a single multipart/form-related POST request. Although such multipart requests are widely used, implementing them is often pretty inconvenient. Therefore we decided to provide an alternative way of uploading the input files. In short you can use now a simple PUT requests to a designated upload url and send the actual file content as body of your request. Checkout our updated API documentation for details.
Using a designated upload url has another advantage: If your input files are provided by your users, you can now let them upload their files directly to CloudConvert. This avoids the time consuming process of uploading the files to your server first and afterwards sending them to us. We have updated our PHP wrapper with an example on how to use this:
<?php
require __DIR__ . '/vendor/autoload.php';
use \CloudConvert\Api;
$api = new Api("your_api_key");
$process = $api->createProcess([
'inputformat' => 'png',
'outputformat' => 'jpg',
]);
$process->start([
'input' => 'upload',
'outputformat' => 'jpg',
'converteroptions' => [
'quality' => 75,
],
'callback' => 'http://_INSERT_PUBLIC_URL_TO_/callback.php'
]);
?>
<form action="<?=$process->upload->url?>" method="POST" enctype="multipart/form-data">
<input type="file" name="file">
<input type="submit">
</form>
Don't worry - as always, our API stays full backward compatible. If you are using the old method of uploading files, nothing needs to be changed. Our suggestion of using the new method only applies to new implementations.
We just pushed the official Python API Wrapper to Github. Using it you can do cool stuff with just a few lines of code:
import cloudconvert
api = cloudconvert.Api('your_api_key')
process = api.convert({
'inputformat': 'html',
'outputformat': 'pdf',
'input': 'upload',
'file': open('input.html', 'rb')
})
process.wait()
process.download("output.pdf")
As always, you can create ready to use code snippets using the API console.