FirebaseInstallations

class FirebaseInstallations : FirebaseInstallationsApi


Entry point for Firebase installations.

The Firebase installations service:

  • provides a unique identifier for a Firebase installation
  • provides an auth token for a Firebase installation
  • provides a API to perform GDPR-compliant deletion of a Firebase installation.

Summary

Public functions

Task<Void!>

Call to delete this Firebase app installation from the Firebase backend.

Task<String!>

Returns a globally unique identifier of this Firebase app installation.

java-static FirebaseInstallations

Returns the FirebaseInstallations initialized with the default FirebaseApp.

java-static FirebaseInstallations

Returns the FirebaseInstallations initialized with a custom FirebaseApp.

Task<InstallationTokenResult!>
getToken(forceRefresh: Boolean)

Returns a valid authentication token for the Firebase installation.

Public functions

delete

fun delete(): Task<Void!>

Call to delete this Firebase app installation from the Firebase backend. This call may cause Firebase Cloud Messaging, Firebase Remote Config, Firebase A/B Testing, or Firebase In-App Messaging to not function properly.

getId

fun getId(): Task<String!>

Returns a globally unique identifier of this Firebase app installation. This is a url-safe base64 string of a 128-bit integer.

getInstance

java-static fun getInstance(): FirebaseInstallations

Returns the FirebaseInstallations initialized with the default FirebaseApp.

getInstance

java-static fun getInstance(app: FirebaseApp): FirebaseInstallations

Returns the FirebaseInstallations initialized with a custom FirebaseApp.

Parameters
app: FirebaseApp

a custom FirebaseApp

getToken

fun getToken(forceRefresh: Boolean): Task<InstallationTokenResult!>

Returns a valid authentication token for the Firebase installation. Generates a new token if one doesn't exist, is expired, or is about to expire.

Should only be called if the Firebase installation is registered.

Parameters
forceRefresh: Boolean

Options to get an auth token either by force refreshing or not.