google-api-java-client

The method setJsonHttpRequestInitializer is undefined for the type Drive.Builder Android

我与影子孤独终老i 提交于 2019-12-22 11:28:14
问题 I am creating an application to working with Google Drive on Android. I've searched in internet for a few examples, but they all are the same. I'm getting the following error: Object Drive.Builder does not have method setJsonHttpRequestInitializer. I have tested with Google drive API V1 and V2 without luck. Where is the problem? Source: private Drive getDriveService(String accountName) { HttpTransport ht = AndroidHttp.newCompatibleTransport(); JacksonFactory jf = new JacksonFactory();

Google API for Google Docs, requesting a list of documents — 400 Bad Request

让人想犯罪 __ 提交于 2019-12-22 06:51:31
问题 After authentication from google servers for google docs, I do a simple getResponse, but I get a 400 Bad Request. I can't understand where am I going wrong. The sample code is, below private void executeRefreshAlbums() { HttpRequest request = transport.buildGetRequest(); request.url = GoogleDocsUrl.forDefaultPrivateFull(); System.out.println("URL = "+request.url); try { HttpResponse response = request.execute(); System.out.println("Response = "+response.getContent()); } catch (IOException e)

How to retrieve youtube thumbnails using Google API Client Library for Java

狂风中的少年 提交于 2019-12-22 06:32:04
问题 I would be obliged, if you could kindly let me know the means by which I can retrieve the youtube thumbnails using Google API Client Library for Java, similar to the way in which we fetched thumbnails using gdata. List<String> thumbnails = new LinkedList<String>(); for (MediaThumbnail mediaThumbnail : mediaGroup.getThumbnails()) { thumbnails.add(mediaThumbnail.getUrl()); } Looking forward, Regards, Rony 回答1: Using the example URL from the reference page: URL: http://gdata.youtube.com/feeds

Integrating Google Sign-In into Android App

一世执手 提交于 2019-12-22 01:19:02
问题 I am following https://developers.google.com/identity/sign-in/android/start-integrating guide to integrate google Sign-in into my android app. I am working on a project where Its not possible for me to put configuration file into app folder of android project. I want to know is there any alternative for that. Can I put API key in the AndroidManifest.xml as a meta-data tag under application tag instead of putting google-services.json in app directory as allowed with Google map API (reference

Google Drive API - too slow.

你离开我真会死。 提交于 2019-12-21 20:04:37
问题 I've just working on Google Drive API. I have one problem, it's too slow. I use methods like in the Documentation. For example: List<File> getFilesByParrentId(String Id, Drive service) throws IOException { Children.List request = service.children().list(Id); ChildList children = request.execute(); List<ChildReference> childList = children.getItems(); File file; List<File> files = new ArrayList<File>(); for (ChildReference child : childList) { file = getFilebyId(child.getId(), service); if

Google Drive API - too slow.

天涯浪子 提交于 2019-12-21 20:04:23
问题 I've just working on Google Drive API. I have one problem, it's too slow. I use methods like in the Documentation. For example: List<File> getFilesByParrentId(String Id, Drive service) throws IOException { Children.List request = service.children().list(Id); ChildList children = request.execute(); List<ChildReference> childList = children.getItems(); File file; List<File> files = new ArrayList<File>(); for (ChildReference child : childList) { file = getFilebyId(child.getId(), service); if

Setting uploadType in Google Drive Java API

℡╲_俬逩灬. 提交于 2019-12-21 18:31:29
问题 I'm having the same problem as this and this but in the Java domain. This question also covers what I want but since no answers have been forthcoming I thought I'd ask it here, with a little more detail. I'm most of the way through writing a Java application to back up files to Google Drive. As others have found, 'internal server error 500' failures are a pretty common problem with uploads, but for small files, implementing the recommended exponential back-off and retry works okay. For large

Google Auth API Javascript idpiframe initialization error on Chrome

ぃ、小莉子 提交于 2019-12-21 06:57:47
问题 I use GSuite and I'm coding a very simple web app to use Google Auth API, and I get an exception "idpiframe_initialization_failed". Now I have the exact HTML as shown in the google Sample: https://developers.google.com/api-client-library/javascript/samples/samples 1) I've created a project on the Google Developer Console 2) I setup the OAUTH authorization screen 3) I've created the client ID, creating restrictions and redirection URL 4) I've also created the API KEY 5) Finally I've enabled

google-api-java-client for Google Calendar on Android Infinite loop

会有一股神秘感。 提交于 2019-12-20 06:25:54
问题 I have been struggling with the sample android application provided by Google for integrating some Google calendar functionality found here at Google code. I've modified the original code just a tad. Specifically, in the CalendarAndroidSample.java class at line 326 I've modified: CalendarUrl url = CalendarUrl.forAllCalendarsFeed(); to now compute: CalendarUrl url = CalendarUrl.forEventFeed(settings.getString("accountName", "NULL"), "private", "full"); This fills the listview with all of the

Using Google Api fetch Documents list and download them?

◇◆丶佛笑我妖孽 提交于 2019-12-20 05:21:39
问题 Hi i am using the picasa example for android and modifying it but i am not getting any list of documents Plz help i am posting my modified class rest are same as in picasa example?Plz help m getting 400 bad request in executeRefreshAlbums() method FetchGooleDocsActivity(This is the main Activity) package com.fetchgoogledocs; import java.io.IOException; import java.util.ArrayList; import java.util.List; import java.util.logging.Level; import java.util.logging.Logger; import android.accounts