Authorize user from Lock of SPA with API