$customer = $customerService->get();Return OAUTH_TOKEN_INVALID, but $OAuth2Handler->IsAccessTokenValid($oauth2Info)return true. Why do i see this error?
$user = new AdWordsUser();
$OAuth2Handler = $user->GetOAuth2Handler();
$user->SetOAuth2Info(
$OAuth2Handler->GetAccessToken(
$user->GetOAuth2Info(), $code, $redirectUri));
$oauth2Info = $user->GetOAuth2Info();
Debugger::dump($oauth2Info);
$customerService = $user->GetService('CustomerService');
$customer = $customerService->get();
It is part of a code. As you see in the beginning information for authorization is requested at the beginning and behind that directly there is a request. Thus correct access_token and refresh_token values return. And when a request of get is sent application returns OAUTH_TOKEN_INVALID error. If there was an error in auth.ini that the method OAuth2Handler->GetAccessToken () would return incorrect information.