Added bunch of auth stuff and setRoles endpoint for semi-atomic account management.