Allowing API access to a user account

119 views
Skip to first unread message

Adam Marples

unread,
Sep 27, 2017, 3:02:40 PM9/27/17
to AdWords API Forum
Hi, I am hitting the API to download a SEARCH_QUERY_PERFORMANCE_REPORT for several CIDs. I need to easily allow people to add their CID or MCC CID to my project and have consequently created a us...@gmail.com account which has OAuth privileges to which I am encouraging people to grant access to their CIDs.

Unfortunately, using the invite system, I have hit the limit of 5 invited accounts. Is there a better way to do this? I simply want to be able to either

a) give people my us...@gmail.com address and simple instructions on how to allow access to their CID, or,
b) use the API to send an request for access to the CID i need, which they can grant

Any advice?

Many thanks,

Adam

Peter Oliquino

unread,
Sep 28, 2017, 2:15:26 AM9/28/17
to AdWords API Forum
Hi Adam,

The email invite system is for users to be able to have access and manage other accounts via the AdWords UI. In the AdWords API, in order to access an account, the user will need to have the OAuth2 credentials of the specific account they wish to access or manage.

This means, for your scenario, you will need to acquire or generate the OAuth2 credentials using an email that has access to the client account. In your code, you will then need to implement a feature that will dynamically switch the credentials depending on which clientCustomerId they are associated to. You can do this by using the Credential object in the client library to set the values for each account. Let me know if this helps.

Thanks and regards,
Peter
AdWords API Team

Adam Marples

unread,
Sep 28, 2017, 6:19:24 AM9/28/17
to AdWords API Forum
Hi Peter and thanks for the advice. I have absolutely already implemented all of that! My aim was to simplify the process so that I don't need to ask anybody for their account login information to make a credential object for their account, but transfer authority from their account to a previously authorized account I own.

Does the API have some way of sending a request like this to the account owner?

Thanks,

Adam

Is there any way that some kind of read-only access can be granted to a master account which I have pre-authorized? 

Peter Oliquino

unread,
Sep 28, 2017, 11:37:12 PM9/28/17
to AdWords API Forum
Hi Adam,

What I can recommend is for you to use the ManagedCustomerService and link all the other client accounts to an MCC that you own. Then, you can generate once again the OAuth2 credentials by carefully following this guide. This should allow you to manage information on the clients belonging to your hierarchy. Let me know if this works for you.

Best regards,
Peter
AdWords API Team

Adam Marples

unread,
Sep 29, 2017, 7:24:22 AM9/29/17
to AdWords API Forum
Thanks very much, just what I need
Reply all
Reply to author
Forward
0 new messages