Saved searches

Use saved searches to filter your results more quickly

Cancel Create saved search Sign up Reseting focus

You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session.

Sample Android App demonstrating how to fetching data from user's Google Sheet using Java API

License

Notifications You must be signed in to change notification settings

sdivakarrajesh/Google-Sheet-Java-API

This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Go to file

Folders and files

Last commit message Last commit date

Latest commit

History

View all files

Repository files navigation

Using GSheet Java Api in Android Sample

WHAT THIS APP DOES?

This app contains sample code on how to implement the Google SpreadSheet API and Google Sign-In(Android Client API). For the time being I have just implemented the methods to read and write(Append to be more specific) using the java client library. More code for achieving different features can be found in the official documentation To use this code

Get the credentials

First go to console.developers.google.com and enable G+ api and Google SpreadSheet Api Then get the google services JSON from here and add it to the app folder of your android project

Adding the permissions

Be sure that you have added the following permissions in the android Manifest

Adding the dependencies

Be sure that you have added the following dependencies in the Project level gradle build file
classpath 'com.google.gms:google-services:3.1.0' 
Add the following dependencies in the App level gradle build file
Android < . configurations.all < resolutionStrategy.force 'com.google.code.findbugs:jsr305:1.3.9' >. > 
compile 'com.google.android.gms:play-services-auth:11.6.2' compile('com.google.apis:google-api-services-sheets:v4-rev493-1.23.0') < exclude group: 'org.apache.httpcomponents' >compile 'com.google.android.gms:play-services-auth:11.6.2' compile 'pub.devrel:easypermissions:0.3.0' compile 'com.google.oauth-client:google-oauth-client-jetty:1.23.0' compile('com.google.api-client:google-api-client-android:1.23.0')
Below everything else add
apply plugin: 'com.google.gms.google-services'