API for document format conversion

2.7k Views Asked by At

I am looking for a RESTful web service to which I can send a document (doc, docx, xls, xlsx, ppt, pptx, and tiff at a minimum) for conversion to pdf and swf.

The reason I need swf in addition to pfd is so that I can display the document in the browser using a flash-based document viewer such as FlexPaper.

I basically want transloadit.com for documents.

One option is to use the Scribd API, download the pdf, and use swftools to convert the pdf to swf. However I am interested in alternatives.

4

There are 4 best solutions below

1
On

doxument.com might be what you looking for. They do offer some kind of REST API. I'm not sure about the formats though.

1
On

I am developing on http://webservices.io which is in beta and offers document conversion via a REST API.

While it also doesn't do all the conversions you are asking for, it does have docx and xlsx support. See matrix with supported conversions

0
On

Aspose library is best of the best http://www.aspose.com/ Use it for create your own service

0
On

Although it's an old question, however just want to share another solution for future reference. GroupDocs.Conversion Cloud REST API is another option to convert back and forth between over 65+ types of documents and images, including all Microsoft Office and OpenDocument file formats, PDF documents, HTML, CAD, raster images and much more.

cURL sample Code:

### Retrieve access token
### TODO: Get your AppSID and AppKey at https://dashboard.groupdocs.cloud (free registration is required).
curl --request POST https://api.groupdocs.cloud/connect/token 
--header "Content-Type: application/x-www-form-urlencoded" 
--data "grant_type=client_credentials&client_id=[APP_SID]&client_secret=[APP_KEY]"

### Convert and Add Watermark
curl --request POST "https://api.groupdocs.cloud/v2.0/conversion" 
--header "authorization: Bearer [ACCESS_TOKEN]" 
--header "accept: application/json" 
--header "Content-Type: application/json" --data "{ "FilePath": "test_doc.docx", "Format": "pdf", "ConvertOptions": { "FromPage": 1, "PagesCount": 1, "WatermarkOptions": { "text": "Watermark" } }, "OutputPath": "Output"}"

I work with Aspose as developer evangelist.