Hi Warren,

The relevant code to capture OAuth callback and exchange it with an access 
token / refresh token looks like this: 
https://github.com/googleads/googleads-dotnet-lib/blob/master/examples/AdWords/CSharp/OAuth/OAuthLogin.aspx.cs#L50.
 
I assume you are (1) using the state parameter to distinguish a redirect to 
google server, and a callback from Google server? and (2) Placed a 
breakpoint on your call to FetchAccessAndRefreshTokens and made sure it 
isn't happening twice?

You can also use Fiddler <http://www.telerik.com/fiddler> to intercept the 
requests to make sure the authorization code in both cases are different 
(i.e. the call is not getting cached somehow)

Cheers,
Anash P. Oommen,
AdWords API Advisor

On Monday, May 15, 2017 at 2:59:12 PM UTC-4, Warren Zhang wrote:
>
> I can change that, but is the outdated parameter the cause of this 
> authorization code issue?
>
> On Monday, May 15, 2017 at 11:24:04 AM UTC-7, Shwetha Vastrad (AdWords API 
> Team) wrote:
>>
>> Hi Warren, 
>>
>> The parameter approval_prompt is now prompt. To get the behavior similar 
>> to approval_prompt=force I would suggest that you change your app to use 
>> prompt=consent. Please see this forum post 
>> <https://groups.google.com/d/msg/adwords-api/iSY2uUBx5JQ/BM3QCbFGAwAJ> for 
>> more details. In your case, you would need to pass the space delimited 
>> values to the prompt 
>> <https://developers.google.com/identity/protocols/OpenIDConnect#prompt>
>>  parameter. 
>>
>> Regards,
>> Shwetha, 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 [email protected]
To unsubscribe from this group, send email to
[email protected]
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 [email protected].
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/20f6c59e-7eb0-441c-a7d9-869b2c7ae590%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
  • Repeated author... Warren Zhang
    • Re: Repeat... James Andrews
    • Re: Repeat... 'Shwetha Vastrad (AdWords API Team)' via AdWords API Forum
      • Re: Re... Warren Zhang
        • Re... 'Shwetha Vastrad (AdWords API Team)' via AdWords API Forum
          • ... Warren Zhang
            • ... 'Shwetha Vastrad (AdWords API Team)' via AdWords API Forum
              • ... Warren Zhang
                • ... 'Shwetha Vastrad (AdWords API Team)' via AdWords API Forum
                • ... Warren Zhang
                • ... 'Anash P. Oommen (AdWords API Team)' via AdWords API Forum
                • ... Warren Zhang
                • ... Warren Zhang

Reply via email to