Cleaned up API docs generation

* API docs generation is now not so hacky.
* Deploy script for deploying API docs to new repository
Merge pull request #1292 from jroper/api-docs

Cleaned up API docs generation