Giter Club home page Giter Club logo

titanium-freshchat's Introduction

Titanium Freshchat SDK

Use the native Freshchat SDK (iOS / Android) in Titanium. All APIs are 100 % cross-platform! 🤘

Setup

iOS

No setup required

Android

Add the following contents to your [app]/platform/android/build.gradle

allprojects {
  repositories {
    jcenter()
    maven { url "https://jitpack.io" }
  }
}

Example

See the app.js for a full-featured example!

APIs

initialize({ appId, appKey, domain })

Initializes the SDK. The domain is optional.

identifyUser(externalId)

Identifies a user with Freshchat for usage with an external user ID (e.g. of your own database)

signInUser({ firstName, lastName, email })

Signs in a user with Freshchat. All values are optional!

updateUserProperty(key, value)

Updates a given user property (key) by it's value.

signOutUser()

Resets a user in Freshchat

getRestoreID()

Receives the restore ID of the user (may be null if not defined)

trackEvent(eventName, parameters)

Tracks an event by a given eventName. The parameters are optional.

showConversations()

Opens the conversation list.

registerForPushNotifications(fcmToken) (Android only)

Registers the given fcmToken with Freshchat. On iOS, this is handled internally by the corresponding didRegisterForRemoteNotificationsWithDeviceToken: selector of the UIApplicationDelegate.

Events

userRestoreIdReceived

Called when the restore ID has been received by the module. It includes the keys restoreID and externalID which can both be optional.

Author

Hans Knöchel

License

MIT

titanium-freshchat's People

Contributors

hansemannn avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.