Refactored the main.js code for the Votus API to consolidate all the API...

... client code into one, hopefully easier to use file.