fixed login example and ApiJsonRequest