Minor fixes in auth services and invitations API