api: better domain lookup
api: logout