DEVELOPER_TOKEN_NOT_APPROVED Adwords - google-ads-api

Good day guys,
Please, I am working on a project that requires setting up Google Adwords account in order to use the API. I am using the Python Client Library. I am getting a DEVELOPER_TOKEN_NOT_APPROVED error when I run my test application.
After a lot of research on the issue, I figured maybe I didn't set up the production and test accounts properly which I am still struggling with. I really hope you can put me through the process as I am running against time.
Looking forward to your help
Thank you very much.

You need Developer Token from production account, but until approval is pending you need authorize API call only for test AdWords account. You need two different Google accounts. You must get Refresh Token after login to your another Google account for testing purpose.
More info: https://developers.google.com/adwords/api/docs/guides/accounts-overview#test_accounts

Related

How to use Luis.ai Auth Settings

Can anyone provide a URL or tutorial to the help with setting up the Auth Settings tab in Luis.ai?  I am building a tool that allows anyone without coding experience to create a Chat Bot exclusively based on Luis.ai and it's Cognitive Services API.  I could ask users to provide their app id and subscription id; but I would rather have an Oauth login so they wouldn't have to share those keys with my service. 
I asked Microsoft through there support over a week ago, and no response. I am just trying to understand if Oauth configuration is possible and how?   Any insight would be much appreciated.
Spoke with Microsoft and currently the ability to Share the service without divulging the subscription key is not available; however if you visit this Microsoft URL and vote for the feature, they will consider it.
https://cognitive.uservoice.com/forums/551524-luis/suggestions/15365835-sharing-luis-applications
It is currently under review for implementation.

OAuth and google: I must be missing something?

I'm using thephpleague oauth client library and everything works fine except for Google authentication. It seems I have to enable my domain somewhere to be able to use Google apps.
https://support.google.com/a/answer/33419?hl=en
This was not helpful indeed as I don't understand what I have to do. Am I obligated to pay for having a working OAuth connection with Google? I don't have a company, I don't need the apps, cloud or any other thing then a working API.
EDIT: to be clear I already wrote my libraries for OAuth and it's all working, it's Google that needs me to do something on domain level.
You don't have to pay. First of all you need to create a project in the Google Developers Console. Then get your credentials. I don't know which API you are going to access. Have a look at this.
https://developers.google.com/identity/protocols/OAuth2?csw=1
Additional - This site was very helpful for using the Google Calendar API
http://www.daimto.com/accessing-google-calendar-with-php-oauth2/#Conclusion
Hope you find what you are looking for.

How to implement "Use one-click single sign-on" correctly in order to publish to Google Apps Marketplace

We already have a web app that integrate with differente Google services. Right now, you can loguin using a Google account, can import a contact lists from any Google account, and can sync a Google Calendar with our Calendar in the webapp (We implemented all of this using OAuth 2 and invoking the GoogleApi with a REST Client).
We are now trying to publish this app in the GoogleApp Marketplace, but we are failing to comply with the "Use one-click single sign-on" rule (https://developers.google.com/apps-marketplace/practices#5_use_one-click_single_sign-on).
We are believing that the problem is we the way we are solving the fact that we need offline access for all the integrated users in the app. Right now, the only way we found to get the refresh tokens for them, was starting the OAuth2 process with the parameters access_type=offline&approval_prompt=force, but this forces them to enter their credentials.
We aren't using the 'Google+ Domains API', and we are starting to believe that we should. Is the use of this API mandatory for complying with the "Use one-click single sign-on" rule?
Thanks,
Well, we finally figured it out. We had to use the Google Admin SDK in order to implement SSO. We had some troubles with the scopes, but after we polished that, everything seems to be working OK.

can't find where to create adwords developer token

I'm truing to figure out how to create an adwords developer token in new google interface. It was in settings tab formerly (right here at the screenshot http://take.ms/9lBlZ) but now it's gone. I looked through almost all links and didn't find an answer. So I really appreciate your help guys! Thanks!
If you create a campaign in your MCC (manager account), the MCC became normal Account, and you cant find "AdWords API Center" option.
I had to re-create another MCC
This thread is kind of old, but I just went through this so I can highlight the things that were confusing to me.
You need to create a legitimate MCC account, AND a test account. In the real one you need to apply for a developer token. You want to put this token in the properties file here api.adwords.developerToken
From your test MCC you need to create a test client. Use the clientId from the TEST client you just created in api.adwords.clientCustomerId in the properties file.
You need to get an API token for your app (and an OAuth token) through Google's developer console https://console.developers.google.com
Make sure the active google account session for your browser is for the email you registered your TEST Account to. Run the script they give to get the refresh token and put it here api.adwords.refreshToken in the properties file.
Now you're using your test developer token from your real account and given permissions to use the test account.
Google made this way more confusing than it had to be in my opinion...hopefully this helps someone figure it out though!
There are two types of Adwords Manager accounts, normal and testing.
How to get a testing account
With the normal one, I got the developer token but I cannot run nothing throught the API because the account was not approved.
So I created a testing account, which allows to work with the API without the need of being approved.
With the testing account I didn't saw the Adwords API Center link under Account Settings.
Reading documentation I saw the developer token of a normal account can be used with a different Adwords account.
So I'm using the info (client_id, client_secret, oauth_token) of a testing Adwords account and the developer token a normal Adwords account.
To get the Oauth_token you can use the OAuth Playground (remember to set the Playground link for redirection on your Oauth credentials).
Instructions to get a OAuth Playground with Adwords
Please complete the billing details after creating MCC account.
Once that is completed you can see API Center option under Tool Icon.
By filling billing details doesn't charge you but its just for verification purpose.
I just had the same issue.
Go here: https://ads.google.com/home/tools/manager-accounts/
Click "Create a manager account", follow the prompts and voila.

Google Apps Script to Get Users' Tweets on Their Behalves

I was trying out Google Apps Script and Twitter API. It works perfectly for my Twitter account but what I want is users to make my script work on their behalves logging in with their Twitter account.
I was hoping this process is automated by turning on "Allow this application to be used to Sign in with Twitter" in Settings page of my Twitter application (asking twitter user authorization to execute app each time).
It is not. GAS script executes as if my user is already authanticated by twitter.
I understand how it is done in general from Twitter developer documentations (3-legged authorization), but I can't figure out how it is done with given GAS OAuthConfig class and URL Fetch Service. I've played with oAuthUseToken, assigning different values such never or if_available, it didn't work either.
Any help would be appreciated.
So far what I have found, but didn't try out yet (I was searching for completely different subject, yet somehow related to this):
Eric Coleda wrote in this Google Apps Script Issues post that we can now make our own OAuth2 flow by using state tokens and the usercallback endpoint which were added to ScriptApp Class.
They don't have a finished example at the time of this post, neither do I.

Resources