Hi Arjun, In your adwords_api.yml <https://github.com/googleads/google-api-ads-ruby/blob/master/adwords_api/adwords_api.yml> file, if you already have the OAuth tokens (access and refresh), the system will not ask you to reauthorize. Looks like that is happening in your case. To confirm this, you can comment the tokens in the adwords_api.yml <https://github.com/googleads/google-api-ads-ruby/blob/master/adwords_api/adwords_api.yml> file and run the samples. For this, you will need to perform the steps in the order as below:
1. Run $ruby setup_oauth2.rb <https://github.com/googleads/google-api-ads-ruby/blob/master/adwords_api/examples/v201710/misc/setup_oauth2.rb> You will get: "Hit Auth error, please navigate to URL: https://accounts.google.com/o/oauth2/auth?access_type=offline&client_id=****-***.apps.googleusercontent.com&redirect_uri=****&response_type=code&scope=https://www.googleapis.com/auth/adwords <https://accounts.google.com/o/oauth2/auth?access_type=offline&client_id=312235556420-sft57st2ee4dg173ghibg3fidllsr9a0.apps.googleusercontent.com&redirect_uri=urn:ietf:wg:oauth:2.0:oob&response_type=code&scope=https://www.googleapis.com/auth/adwords> " 2. Navigate to the above URL in a private browser session or an incognito window. Log in with the same Google account you use to access AdWords. Click Allow on the OAuth2 consent screen. An authorization code will be shown to you. Copy and paste the verification code into the command line where you're running the setup_oauth2.rb example and press enter. You will get: "Would you like to update your adwords_api.yml to save OAuth2 credentials? (y/N): 3.Type 'y' and press enter. You will get : "OAuth2 token is now saved to ~/adwords_api.yml and will be automatically used by the library." This will take care of updating the adwords_api.yml <https://github.com/googleads/google-api-ads-ruby/blob/master/adwords_api/adwords_api.yml> file. Please let me know if you have further questions. Regards, Dhanya, AdWords API Team -- -- =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ Also find us on our blog and Google+: https://googleadsdeveloper.blogspot.com/ https://plus.google.com/+GoogleAdsDevelopers/posts =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ You received this message because you are subscribed to the Google Groups "AdWords API Forum" group. To post to this group, send email to adwords-api@googlegroups.com To unsubscribe from this group, send email to adwords-api+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/adwords-api?hl=en --- You received this message because you are subscribed to the Google Groups "AdWords API Forum" group. To unsubscribe from this group and stop receiving emails from it, send an email to adwords-api+unsubscr...@googlegroups.com. Visit this group at https://groups.google.com/group/adwords-api. To view this discussion on the web visit https://groups.google.com/d/msgid/adwords-api/e6aee737-1eee-410e-be55-6ecb1696189d%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.