5 Things You Can Do With DocumentAlchemy

the DocumentAlchemy blog

 
Last Updated:

Five Things You Can Do With the DocumentAlchemy API

There are a lot of nifty things you can do using the DocumentAlchemy API. In this post we list five of them, and provide full source code examples on how to do each.

1. Upgrade your old *.doc files to *.docx.

Beginning with Office 2007, Microsoft changed the format for Word documents from the proprietary .doc binary format to a standards-based .docx XML format.

Since DocumentAlchemy understands both the .doc and .docx formats, you can use the API to “upgrade” files from the old (binary) format to the new (zipped-XML) format.

See Upgrade your *.doc files to *.docx for more detail and example code.


2. Render Markdown as HTML, PDF or Microsoft Word.

Technically that's three things, but we'll group them as one.

DocumentAlchemy can render Markdown as HTML, PDF and Microsoft Word files.

We'll show you a simple Bash script that can transform a Markdown document into any of those formats.

See Render Markdown as HTML, PDF or Word for more detail and shell-scripts you can use for the task.


3. Resize images to a fixed width.

Suppose you have a collection of images you'd like to display in a gallery. You want an "index" page with a thumbnail for each image.

But the images are of different sizes and aspect ratios.

To keep the index page looking orderly, we will scale each image to a specified width, allowing the height of each image to vary “naturally”, according to the original image's aspect ratio.

See Resize images to a fixed width for more detail and example code.


4. Extract images from a PowerPoint deck.

Let's assume your company is creating a “media asset” library as part of a new content management initiative.

You have a bunch of PowerPoint presentations that employees have created over the past decade, and many of them have interesting charts, photos and diagrams that you'd like to break out as individual “assets” for the library.

How do you get at all of those images without opening each deck and copying each out manually? DocumentAlchemy can help.

See Extract images from a PowerPoint deck for learn how (with sample code).


5. Add a cover page to a PDF document.

Given a collection of PDF files, you'd like to add a one-page “cover” to each document. Your cover page is also a PDF file, so your objective is to insert a single page at the beginning of each of the source documents.

We can use DocumentAlchemy's “join documents” REST endpoint to insert that cover page.

See Add a cover page to a PDF document for details and a working example.


About DocumentAlchemy

DocumentAlchemy is a RESTful web service that developers can use to add document generation, conversion and processing features to their app.

Visit our live demonstrations or interactive API reference to explore Document Alchemy's rapidly growing API for working with MS Office documents, PDFs, images, web pages and more.


Copyright © 2017 DocumentAlchemy.