Code cleanup, getting ready to setup API auth