Added type check for the access_token option.