Clean up initial implementation

* Add initial command line flags
* Be more golang-like when constructing the API string