Google OAuth 2.0 in AppGyver
Tutorial
Last updated
Was this helpful?
Tutorial
Last updated
Was this helpful?
This tutorial covers the authorization for Firestore
Detailed information can be found in
Obtain OAuth credentials in Google API Console
Obtain the access token from the Google authorization server
Verify the scopes granted
Send the access token to the API
Refresh the access token
Then select Credentials. There you will find the API key (the one you will pass with key=API_KEY parameter) and client ID. The API key can be further configured to restrict access, so it can be only used by specific web sites, IP addresses or apps.
It is strongly recommended to restrict the database access so you prevent unauthorized use. This can be done later, once you have the authorization working for your app.
The access token grants access to the APIs and the scopes of the access
To login, an application variable type object has to be created so contain the email, password an return token flag
The user has to enter the values for email and password, and the value for the return token flag has to be set to "true"
The response from the http request has to be assigned to a applicaton variable type object, with properties to match the Firestore response to the call: localId, email, displayName, idToken, registred, refreshToken, expiresIn. The binding has to be made by formulas, typing the properties names by hand.
Go to the and select your Firestore data base.
A http request has to be set, with a POST call to {your database API key}. The request body is the object that contains the email and password