google-api-dotnet-client

.NET client for the Google People API

喜你入骨 提交于 2019-12-20 07:18:58
问题 I do not see a .NET client for the Google People API here. https://code.google.com/p/google-api-dotnet-client/wiki/APIs Do you know of any? I need to get the user's full name, email address, gender and date of birth from Google using OAuth2. I could use it the raw HTTP way, but just to be safe, I want to use a Google provided client API. Update Hurray to hand-plumbing 回答1: The Google .net client Library can be found on NuGet, the plus package is here Google.Apis.Plus.v1 Client Library PM>

Google.Apis.Email_Migration_v2

耗尽温柔 提交于 2019-12-20 06:32:05
问题 I am attempting to retrieve the HttpStatusCode from every UploadAsync method call. I need the status code as to properly perform an exponential back-off algorithm to retry a failed upload, display an error message to the user when not retrying the upload and to report success of the upload. I do not care how it is received, so long as it is clean and not being parsed from the Exception.Message (string) property like Tor Jonsson suggested in the link provided below. To force the "Bad Request

Oauth2 login to Google api with ASP .net core MVC

谁都会走 提交于 2019-12-19 09:51:05
问题 I have been following Web applications (ASP.NET MVC) Attempting to connect to one of the Google APIs. using System; using System.Web.Mvc; using Google.Apis.Auth.OAuth2; using Google.Apis.Auth.OAuth2.Flows; using Google.Apis.Auth.OAuth2.Mvc; using Google.Apis.Drive.v2; using Google.Apis.Util.Store; namespace Google.Apis.Sample.MVC4 { public class AppFlowMetadata : FlowMetadata { private static readonly IAuthorizationCodeFlow flow = new GoogleAuthorizationCodeFlow(new

How to upload Video to youtube using Google.Apis.YouTube.v3 and C#?

落爺英雄遲暮 提交于 2019-12-18 14:48:28
问题 I have created console application using C# . Which will upload Video from local drive to youtube . I have created new app in google api using this link. I have also installed all required packages using nuget . When I run my application I am getting error as " Access Denied " I am not able to find the issue. I am getting error in Task Run() method. using System; using System.IO; using System.Reflection; using System.Threading; using System.Threading.Tasks; using Google.Apis.Auth.OAuth2;

Analytics Reporting API V4 Client Library for .NET

霸气de小男生 提交于 2019-12-18 10:11:57
问题 I'm trying to get some data from our google analytics instance and I'd like to use the Analytics Reporting API V4 Client Library for .NET (https://developers.google.com/api-client-library/dotnet/apis/analyticsreporting/v4) so that I can bake some of this data into an administration site we have built. I'm having trouble finding any examples of using this code and the documentation seems to be incredibly sparse. I would like to use a service account to authorize as we only need to view data

GoogleWebAuthorizationBroker in MVC For Google Drive Access

老子叫甜甜 提交于 2019-12-18 08:27:48
问题 I'm stuck trying to access a specific Google drive account from a MVC app. All I need is for the MVC web app to access my google drive scan for a few files and alter the database based on the contents of the google drive. The problem is when running in IIS the drive cannot be authenticated as GoogleWebAuthorizationBroker tries to open browser if its a windows app but doesn't seem to be able to do that through IIS and even if it did it would be server side. Ideally I would not have to

Google Calendar Api working fine Locally but not raising its Authentication on Server

拥有回忆 提交于 2019-12-18 07:43:17
问题 I have created a project in console.developers.google.com to use Google Calendar API . there we need to generate credential and select application type For Localhost and application type other following is the Json which works fine. { "installed": { "client_id": "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx.apps.googleusercontent.com", "project_id": "xxxxxx-00000", "auth_uri": "https://accounts.google.com/o/oauth2/auth", "token_uri": "https://accounts.google.com/o/oauth2/token", "auth_provider_x509_cert

Update a Cell with C# and Sheets API v4

瘦欲@ 提交于 2019-12-18 03:59:05
问题 Does anyone have a good C# example for updating a cell with the v4 API? I have the get cell values c# example from the developer website working with Google Sheets API v4. I am trying to modify the example to update a cell with a value of "Tom". I'm stuck on the settings for SpreadSheets.Values.Update . using Google.Apis.Auth.OAuth2; using Google.Apis.Sheets.v4; using Google.Apis.Sheets.v4.Data; using Google.Apis.Services; using Google.Apis.Util.Store; using System; using System.Collections

Google .NET APIs - any other DataStore other than the FileDataStore?

自闭症网瘾萝莉.ら 提交于 2019-12-17 22:58:27
问题 I'm using the Google .NET API to get analytics data from google analytics. this is me code to start the authentication: IAuthorizationCodeFlow flow = new GoogleAuthorizationCodeFlow(new GoogleAuthorizationCodeFlow.Initializer { ClientSecrets = new ClientSecrets { ClientId = googleApiClientId, ClientSecret = googleApiClientSecret }, Scopes = new[] { Google.Apis.Analytics.v3.AnalyticsService.Scope.AnalyticsReadonly }, DataStore = new Google.Apis.Util.Store.FileDataStore("Test_GoogleApi") }); it

How to programmticly remove a file from “share wtih me” in Google drive

≯℡__Kan透↙ 提交于 2019-12-17 21:12:41
问题 Doing the following command with the full drive scope var request = service.Files.Delete(fileId); results in insufficient permission error. When trying to delete a file from google drive "Shared with me" folder. How do you delete a file from shared with me when the user that is logged in does not actually have access to delete a file they dont own. 回答1: The problem is that the user in question doesnt own the file. After a lot of digging a relised what you want to do is remove the permissions