Convert parser to work on both NodeJS and the browser
Add support in the API for logging in and registering