added accesstoken storage and some fixes