Use the Firebase Core SDK in Axway Titanium 🚀
Clone or download
hansemannn Merge pull request #24 from luigivitelli23/master
Enabling the instance id and token delete
Latest commit 24450fe Oct 7, 2018
Permalink
Failed to load latest commit information.
android new version codes Oct 7, 2018
apidoc Initial commit Oct 18, 2017
example Initial commit Oct 18, 2017
ios new version codes Oct 7, 2018
.gitignore Update core to latest Apr 21, 2018
LICENSE Initial commit Oct 18, 2017
README.md Update README.md Oct 6, 2018

README.md

Firebase Core - Titanium Module

Use the native Firebase SDK in Axway Titanium. This repository is part of the Titanium Firebase project.

Requirements

  • Titanium SDK 6.3.0+

Download

API's

FirebaseCore

Methods

configure()

Configure Firebase without additional parameters.

configure(parameters)

Configure Firebase without configuration parameters.

Name Type Component Platform
file* String *
googleAppID String *
GCMSenderID String Cloud Messaging *
APIKey String Auth *
projectID String *
databaseURL String Real Time Database *
storageBucket String Storage Bucket *
bundleID String iOS
clientID String iOS
trackingID String iOS
androidClientID String iOS
deepLinkURLScheme String iOS
applicationID String Analytics Android

* By passing the file property, you can give a location to the Firebase plist file (usually named "GoogleService-Info.plist"), which contains all necessary properties for your Firebase project. This makes all other properties unnecessary. For Android: place the file in /app/assets/android/ and pass just the filename.

deleteInstanceId(callback)

Delete the current instanceId (invalidating all tokens). See the Firebase docs for details.

The callback receives an object containing this fields:

Key Type Description
success Boolean true if the deletion succeeded
error String The localized error message
deleteToken(authorizedEntity, scope, callback)

Delete the token of the provided authorizedEntity and scope. See the Firebase docs for details.

The callback receives an object containing this fields:

Key Type Description
success Boolean true if the deletion succeeded
error String The localized error message

Examples

// Require the Firebase Core module
var FirebaseCore = require('firebase.core');

// Configure your Firebase API's (only required once for all)
FirebaseCore.configure({
  APIKey: "AIYasZBtfJh..........",
  projectID: "test-12345",
  storageBucket: "test-12345.appspot.com",
  applicationID: "1:12345678890:android:abc123efg456"
});

// alternative way:
FirebaseCore.configure({
  file: "filename.json"
});

Build

cd [ios|android]
appc run -p [ios|android] --build-only

Legal

This module is Copyright (c) 2017-Present by Hans Knöchel. All Rights Reserved.