I am having the same issue. Were you able to figure this out?
On Thursday, April 3, 2014 11:13:19 AM UTC-4, Richard wrote: > > > Hi, > We have an internal c# Adwords application which I trying to upgrade from > client login(v201309) to OAuth2(v201402) > The application is running by scheduled job to update our Adwords data as > well as pulling reports so there is no user interaction involved. > I have followed below example and was able to get as far as initialize the > ServiceAccountCredential, In the example it's using PlusService but I was > not able to find any example on Adwords API with ServiceAccountCredential, > please advice how to obtain an Access Token from this point. > > > https://developers.google.com/api-client-library/dotnet/guide/aaa_oauth#service_account > > X509Certificate2 certificate = new > X509Certificate2(SERVICE_ACCOUNT_PKCS12_FILE_PATH, "notasecret", > X509KeyStorageFlags.Exportable); > > ServiceAccountCredential credential = new > ServiceAccountCredential( > new > ServiceAccountCredential.Initializer(SERVICE_ACCOUNT_EMAIL) > { > Scopes = new[] { " > https://adwords.google.com/api/adwords/" } > }.FromCertificate(certificate)); > > // Create the service ==> where I am stuck > //var service = new PlusService(new > BaseClientService.Initializer() > //{ > // HttpClientInitializer = credential, > // ApplicationName = "Plus API Sample", > //}); > > //Activity activity = > service.Activities.Get(ACTIVITY_ID).Execute(); > //Console.WriteLine(" Activity: " + activity.Object.Content); > //Console.WriteLine(" Video: " + > activity.Object.Attachments[0].Url); > > //Console.WriteLine("Press any key to continue..."); > //Console.ReadKey(); > -- -- =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ 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 adwords-api@googlegroups.com To unsubscribe from this group, send email to adwords-api+unsubscr...@googlegroups.com 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 adwords-api+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.