Comments (11)
@avermeil hi!
Thanks for creating this library, we found it very useful.
As @npearce and @mateioprea also asked it is very useful to be able to authenticate with a service account.
In an internal corporate software development context, like us at brumbrum.it, it is useful to associate the credentials with a service account rather than with a real user account.
We're starting to work on this pr, we think to propose somenthing functional in the next days.
Our implementation idea start from adding a ServiceAccount type for the ClientOptions and drill down those data till GrpcClient.
Doing that we will able to extend the accessTokenGetter and manage a new getAccessTokenForServiceAccount in token.ts when ServiceAccount data is set.
Make sense for you?
Regards,
from google-ads-api.
Hi @alessandro-aglietti ,
Thanks for taking the time to work on this! Yes, the solution you propose sounds good :)
from google-ads-api.
Hi @wcoots, I have created a library about Google Ads for NodeJS and support Service Account, you can refer to it: https://github.com/htdangkhoa/google-ads
https://github.com/htdangkhoa/google-ads/blob/main/src/lib/utils.ts#L5
Thanks
from google-ads-api.
Hi @mateioprea !
At the moment, we don't support Service Accounts. We've actually never used them, so we're not totally sure how they should work. PRs welcome ;)
That said, is there any reason why you wouldn't want to use a standard OAuth flow (just do it once, manually) to get yourself a permanent refresh token? We've set up a helper to do this: https://refresh-token-helper.opteo.com/
from google-ads-api.
Hi @avermeil!
So it works for generating a permanent refresh token?
from google-ads-api.
I am also looking at the service account option as, from what I can tell (their docs aren't great) Google insists on having a G-Suite domain to create an 'Internal' OAuth consent.
from google-ads-api.
Quick heads up about the new google ads api: it's so slow that the client that I'm working with decided to switch to adwords api.
Just a quick comparison: for pulling 10k keywords from the AdGroups takes about 30s - 1 minute while with the adwords api, it takes 4-5 seconds. :)
from google-ads-api.
Quick heads up about the new google ads api: it's so slow that the client that I'm working with decided to switch to adwords api.
Just a quick comparison: for pulling 10k keywords from the AdGroups takes about 30s - 1 minute while with the adwords api, it takes 4-5 seconds. :)
Yeah.. there is also a back to beta statement on https://developers.google.com/google-ads/api/docs/start.
For the moment we only need the offline conversion, we didn't expect to ran in performance problems.
Anyway, thank you for the hint!
from google-ads-api.
@avermeil here you find our first working version. We've some little fix (naming & docs) to be addressed before opening a PR to this main repo.
In the meantime can you check if our implementation is ok for you?
Btw I've a question about the circle-ci, the project is configured to use dotenv but the yml config didn't create the .env causing failing of the build.
Is ok if we update the circle-ci yml to create a .env from circle-ci envs?
from google-ads-api.
At Opteo we don't use this authentication method so we do not currently support it. However we are aware that this is a desired feature so we will be looking into it in the future.
from google-ads-api.
The work with refreshToken
is hard when you don't need user interactions.
refreshTokens
do expires.
There is an article regarding using service accounts and google ads with code snippets in some languages,
https://developers.google.com/google-ads/api/docs/oauth/service-accounts
Maybe this can help.
from google-ads-api.
Related Issues (20)
- Upgrade Google Ads to v14 HOT 9
- Export the function 'buildQuery'
- Can't create ad_group_ad_critetion with age and gender at the same time
- "The client has already been closed" Error thrown HOT 2
- Wait for response forever in Cloud Functions
- unable to compile with 13.0.1
- No information on documentation HOT 1
- Adding/Removing Criteria, and missing Documentation HOT 1
- OPERATION_NOT_PERMITTED_FOR_REMOVED_RESOURCE
- List customers with their descriptive names
- Why is `toJSON` required for `generateKeywordIdeas`?
- Authentication Error
- Upgrade Google Ads API to v15 HOT 19
- How to create a custom segment via the SDK? HOT 1
- Customer report showing previous day's data when date_constant is 'TODAY'
- Bad resource id in query from conversion_action HOT 1
- TypeError: this.auth.getUniverseDomain is not a function HOT 1
- Query returns campaign data, but report options does not based on TODAY date_constant
- size of module growing, making use with AWS lambda functions difficult HOT 2
- Can't change a Promotion Asset from "Money Amount Off" to "Percent Off".
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from google-ads-api.