This is a reference application showcasing the integration of CometChat's Android UI Kit in a native Android application using Kotlin. It demonstrates how to implement real-time messaging and voice/video calling features with ease.
-
Ensure you have the following installed:
- Android Studio (latest stable version)
- Java Development Kit (JDK 8 or later)
-
Sign up for a CometChat account to obtain your app credentials:
App ID
,Region
, andAuth Key
-
Clone the repository:
git clone https://github.com/cometchat/cometchat-uikit-android.git
-
Checkout v5 branch:
git checkout v5
-
Sync Gradle to ensure all dependencies are downloaded.
-
[Optional]
Enter your CometChatApp ID
,Region
, andAuth Key
in the AppCredentials.java file: file: -
Set up Firebase Cloud Messaging (FCM):
- Go to the Firebase Console and create a project.
- Add your Android app to the Firebase project and download the
google-services.json
file. - Place the
google-services.json
file in thesample-app-kotlin+push-notification/
directory of your project.
-
Set up CometChat Push Notification:
- Go to the Notification Documentation and follow integration steps.
- Note the provider id entered while configuring the Push Notifications in CometChat Dashboard.
-
Update the provider id from the step 7 in AppConstants.kt file:
-
In the Android Studio toolbar, select the
sample-app-kotlin+push-notification
module from the module dropdown and run the project using an emulator or a physical device
For issues running the project or integrating with our UI Kits, consult our documentation or create a support ticket. You can also access real-time support via the CometChat Dashboard.