Let's integrate UIKit Plugin for Flutter
Mirrorfly Flutter UIKit Plugin is a set of prebuilt UI Widgets that allows you to easily integrate an in-app chat with all the essential messaging features. Our development kit includes light and dark themes, text fonts, colors and more. You can customize these components to create an interactive messaging unique interface.
#
RequirementsThe requirements for Android are:
- Android Lollipop 5.0 (API Level 21) or above
- Java 7 or higher
- Gradle 4.1.0 or higher
The minimum requirements for Chat SDK for iOS
- iOS 12.1 or later
#
Things to be Noted Before Making a Start#
Mirrorfly License KeyNote : Before proceeding with CONTUS MirrorFly Flutter UIKit Plugin integration, there must be an SDK license key that needs to be obtained for your MirrorFly application.
#
To get the License Key,Step 1: Register here to get a MirrorFly User account. Registration is subject to verification and would take up to 24 hours.
Step 2: Login to your Account
Step 3: Get the License key from the application Info
โ section
#
Install UIKit#
Create Android dependency Step 4 : Add the following to your root build.gradle
file in your Android folder.
#
Create iOS dependencyStep 5: Check and Add the following code at end of your ios/Podfile
Step 6: Now, enable all the below mentioned capabilities into your project.
Capabilities |
---|
App Groups |
#
Create Flutter dependencyStep 7: Add the below dependencies in pubspec.yaml
.
STEP 8: Run flutter pub get
command in your project directory. You can use all classes and methods just with the following import statement
#
Initialize MirrorFly UIKit PluginTo initialize the plugin, place the below code in your main.dart
file inside main
function before runApp()
.
#
RegistrationUse the below method to register a user in sandbox Live mode.
Unless you log out the session, make a note that should never call the registration method more than once in an application
#
TerminologySome of the most common terminologies used in Chat SDK with description
keyword | Explanation |
---|---|
userID/userBareID | Unique ID assigned for each user Ex: 12345678 (any alphanumeric). The below characters is not allowed in userId: U+0022 (") U+0026 (&) U+0027 (') U+002F (/) U+003A (:) U+003C (<) U+003E (>) U+0040 (@) userID should follow below specification: https://xmpp.org/extensions/xep-0106.html |
userJid (or) JID | userID+@+domain of the chat server Ex. 12345678@xmpp.chatsystem.dev.contus.us |
groupID/groupBareID | Unique ID assigned for each group Ex: group123456 (any alphanumeric). GroupJID = groupID +@mix.+domain of the chat server Ex: group123456@mix.xmpp.mirrorfly.dev.contus.us` |
#
Display Recent Chat listRecent Chat Widget is the starting point for launching Flutter UIKit in your application. By implementing the code below, you will see a complete list of recent chats that you're made with single and group conversation.
Note : Use
Recent Chat Widget
only when you have done the registration.
Note : You can also navigate to
Recent Chat Page
using below code.
Note : Great!!! We are now end of the Quick Start section. For Advanced with various module navigation. Click Here