changed accesstoken from static to class