Brilliant, I've managed to get all that working so far. The problem I'm having now though comes when the logged-in user is an MCC user. In that instance, the customer I want to add the campaign to is not their MCC customer, it's one of their "account" customers. How do I get a list of all their "account" customers? I can't see any "account" services. Also, how can I tell if the logged in user is an MCC customer or just a standard AdWords customer?
On Friday, 19 December 2014 18:06:38 UTC, Josh Radcliff (AdWords API Team) wrote: > > Hi, > > You may want to go through our entire OAuth guide > <https://developers.google.com/adwords/api/docs/guides/authentication> for > more details, but the OAuth scope for the AdWords API is documented in this > section > <https://developers.google.com/adwords/api/docs/guides/authentication#scope> > . > > Once you have a user's OAuth credentials for that scope, you can use > CustomerService.get > <https://developers.google.com/adwords/api/docs/reference/v201409/CustomerService#get> > > and grab the customerId > <https://developers.google.com/adwords/api/docs/reference/v201409/CustomerService.Customer#customerId> > from > the returned Customer > <https://developers.google.com/adwords/api/docs/reference/v201409/CustomerService.Customer> > object. > You can then use that *customerId* to set the clientCustomerId SOAP header > <https://developers.google.com/adwords/api/docs/guides/soap#clientCustomerId> > in > your API requests. > > Cheers, > Josh, AdWords API Team > > On Friday, December 19, 2014 12:10:44 PM UTC-5, Richard Moran wrote: >> >> I'm trying to follow this example of implementing OAuth ( >> https://developers.google.com/api-client-library/dotnet/guide/aaa_oauth#web_applications) >> >> and I can successfully perform a log in and get access to the various user >> properties using the "https://www.googleapis.com/auth/plus.login" scope. >> What scope do I need to use in order to be able to get a list of the logged >> in user's AdWords client accounts and then post campaigns/AdGroups etc on >> their behalf? I've found some references to " >> https://adwords.google.com/api/adwords/" but that URL returns a 404. >> Similarly, the OAuth playground ( >> https://developers.google.com/oauthplayground/) doesn't have any >> references to AdWords. >> >> Assuming there is a scope, what would it be? If there isn't a scope, how >> do I get all the information and permissions I require? I don't want to use >> an MCC as this adds too many steps and too much admin, I just want to be >> able to get the information from the logged in user and post on their >> behalf. >> > -- -- =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ 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 http://groups.google.com/group/adwords-api. To view this discussion on the web visit https://groups.google.com/d/msgid/adwords-api/a6686f21-5cdf-4516-8e76-f03fb96e4ebb%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
