Can google sign be used just to log in? - android

I'm going to implement Google Sign in my app to let the users log in with their google account. This app doesn't allow registration, as the users are created in a web portal.
The web also have google sign, except that it does uses it for registration.
So, what I want is to only use this in the android app to log users who has already registered at the portal. Is that possible?
I'm following the android docs, which says I need to configure a Google Api console project, do I need two (one for the android app and the other for the web), or it can be managed with just one? Also, I'm wondering the same question having two apps (android and iOS).
I'm trying to understand the logic of the process. Google docs explain how to do it, but I wanted to know a little more about what's happening.

If I understand your question correctly then you need to implement the google authentication process in your application that can be used in all the platforms (Web, iOS, Android).
Google has a platform Firebase Authentication solely for this purpose.
https://firebase.google.com/products/auth/
Here you create a project in the firebase console and then use it for all the 3 platforms.
You can go through the google documentation, it is easy to understand and use.
Or you can go through this link to understand how to implement it on Android.
https://medium.com/#valokafor/working-with-firebase-authentication-8f7dcb016e84

Related

Can I still use firebase's features & firestore database, if my app has been suspended from Google Play?

So, what actually happened is that, I had an app named X on Google play. It was getting around 400 downloads everyday and it was just 3.5 months from its launch when Google suspended it due to some policy violation.
The app X was getting very popular among the users. So the users started to demand the app again. Therefore what I thought is I should distribute it using some other medium or maybe create own website for the app.
And here is the main question. My app was using in-app purchases and also some firebase features. Now I would have to implement some other type of payment gateway and will also need a server. And my app is already on Firebase. So, its the best option for me to use it. But, I am little afraid, that if I keep using firebase, will it be safe ? Are there any chances that Google will close my firebase project as well ?
It is safe to keep using firebase as your app violated the policy of Google Play not your firebase project and as you told you are thinking to distribute your app through website so it's totally safe. Also if it makes you feel any better my app was also suspended from Google Play but i can still use my firebase project & it's related services.

Access third-party app functions with Google Assistant

I've created an app that counts the time you've spent on customers projects. I would now like to integrate this in Google Assistant, so when you say "Talk to MyTimeApp" and then say "Start counting time on Project A", the app should start the stopwatch.
So far this should be possible with Intents for Google Assistant and API.ai. But how can I manage to check which user is using my app (so who is logged in), in order to only access his account and his connected projects? In all the tutorial videos from Google, they provide only non-user-specific examples.
I've read about the possibility to provide also a login function. Can I therefore use my own registration-service or do I need to use the Google-Account? Or is there a way to access the installed TimeApp, where the user is already signed in?
The Actions on Google system, which is how you build Actions for the Assistant, gives you a few options for authentication depending on exactly what your needs are.
First, if you're assuming they will be doing this on their phones that already has the app installed, then you can see if App Actions will meet your need when they are available.
If you are looking to do this as a conversational Action that does not require the mobile app, and you already have an existing authentication system, then you would use Account Linking to link their Assistant account to the account that you have for them. This typically requires an OAuth2 server.
You can, if you wish, simplify this if your account is linked to their Google Account, in which case you'll be able to use Google Sign-In for the Assistant to handle the sign-in on all Assistant platforms.

Google Play Store Developer Console: Is it possible to get installs variable via API for my hosted app?

I have an Android application deployed on Google Play Store.
I am currently getting data like app installs from Google Play Store Developer Console (Statistics -> and just view the graph).
I want to be able to automatically get installs data for my App every day by running an API call and storing into my Database.
Is this possible using ONE OF googles APIs?
This is very complex to understand how to get simple specific stuff from google because the explain everything in a general way.
What API do I need to register?
Can someone give me the steps?
P.S: I use PHP or Javascript to sort out JSONs.
You can using gsutil - follow this link https://cloud.google.com/storage/docs/gsutil
https://support.google.com/googleplay/android-developer/answer/6135870?hl=en

Register/Login user using their Google Account?

I want my users to login with their Google accounts.
SwiftKey and Catch Notes do it by opening a WebView in their apps. I don't want to do that. I want to use AccountManager.
Tasks Free from Team Tasks uses it and loads your Google tasks easily. The official Google Reader app also uses it and loads your Google Reader feeds.
But I don't want to get any data of the user from Google except their name, email, etc. I only want to register the user and log them back in easily.
How do I register them with OAuth tokens etc?
All the examples I have found either use WebView or only load data from Google (not register).
When I first asked this question, it was really really hard to do. You had to use the Google Java API definitely not built for Android.
But there is now Google Play Services and this task is very easy to do.
Anyone can follow the below links:
https://developers.google.com/+/mobile/android/sign-in
https://developer.android.com/google/play-services/index.html
Google I/O 2011 covered Android + App Engine, which uses Google accounts for authentication. The Android client uses AccountManager. Here's the screenshot.
You may want to look at AccountsActivity in the source code.

Can I use AccountManager to let users sign in with their Google account?

I'm creating an app that will need users to create an account. (Like Facebook or Twitter would require you to.)
BUT, since it's an Android app, should/can I let them sign in with their Google Account using AccountManager or some other service? It'd be very helpful if they could just sign in to their Google account and their settings and other options would be saved to that account.
Main questions summed up:
Is it possible to let a user just use their Google account in my app?
If so, do I use AccountManager to have them sign in and save account information/settings?
What are other options?
Yes, you can get users to log into their Google Services using their Google credentials, for example, I have an app on Google Tasks and I use the Android AccountManager to let users authenticate themselves using their Google account on the android device (No need for users to enter their password!)
There are some really good examples to get you started:
This is an in-depth look into how you can authenticate based on the users Android credentials, has an example of how things work and how the UI should be: http://www.finalconcept.com.au/article/view/android-account-manager-step-by-step-2
This is an example of getting AccountManager to work with a Google service like Google Tasks: https://developers.google.com/google-apps/tasks/oauth-and-tasks-on-android
The last example is using the same concept for accessing the Google Picasa service: http://code.google.com/p/google-api-java-client/wiki/AndroidAccountManager
The other options you have is to have users manually enter their username/password. For that you have to use a third party authentication API (like signpost for OAuth) for them to log in.
In my tasks/todo application I provide users both options to sign in, using their android credentials or using third party authentication for users that want to log in using some other account (an account which is not enabled on that device)
Let me know if you have more questions
Although it is a new development, Google Plus Sign-in introduced as part of Google Play Services can also be used. More info can be found at Android developers blog. See example implementation from Banjo app
There seems to be a big limitation - The user need to have Google+ app installed on the device to use this.
Also this is a pretty good blog if someone is interested in implementing the solution.
#Soham gave you some very useful links but he didn't correct one major error: AccountManager is the entity that manages the accounts on your Android device - it has nothing to do with your google account! you can use google account and create a NEW account on your device using the AccountManager.
The rest you can learn from the links Soham gave you.

Categories

Resources