how we get to know that from which account(google account) we authorized

21 views
Skip to first unread message

sachin...@gmail.com

unread,
Aug 18, 2017, 6:33:42 AM8/18/17
to AdWords API Forum

Hello,
I am using asp.net web application to record conversions on google adwords account.I am using oauth2.0 flow to authorize the user's accounts (google account). I want to know fee things regarding this flow:

  1. How I can get refresh token every-time I authorize the same google account
  2. Is google authorization API returns any unique parameter or code for authorized account (google account), through which I can identify that this user previously authorized or not

If Point 1 is not possible: So is there any way or unique parameter to find that this account is already authorized for my app. So I can use the previous token that I get the first time for that account

Thanks

Shwetha Vastrad (AdWords API Team)

unread,
Aug 18, 2017, 2:07:56 PM8/18/17
to AdWords API Forum
Hi, 

Please see my response below: 
  1. You can get a refresh token by following the instructions provided in this guide for the application type you have chosen. Please note that there is currently a limit of 50 refresh tokens per user account per client. If the limit is reached, creating a new token automatically invalidates the oldest token without warning.
  2. I'm afraid you'll not be able to identify if a user has been authorized previously. You could consider including the "email" scope when you generate the refresh token, so that you'll be able to get the email address of the user authorized your application and store the refresh token and email address in you database. This way, you'll be able to identify if a user has previously authorized or not.
Regards,
Shwetha, AdWords API Team.
Reply all
Reply to author
Forward
0 new messages