intellicon_chat_sdk 1.0.0+3 intellicon_chat_sdk: ^1.0.0+3 copied to clipboard
A Flutter Intellicon chat sdk
Intellicon Chat SDK Integration #
Getting Started #
To get started with the Intellicon Chat SDK, run the following command in your terminal:
flutter pub add intellicon_chat_sdk
Usage #
Add the following code snippet to any button click event or wherever you want to initiate the chat:
Navigator.push<void>(
context,
MaterialPageRoute(
builder: (context) => Chat(
config: Config(
baseUrl: "YOUR DOMAIN",
appId: "YOUR CHAT BOT APP ID"
),
user: User(
participantId: "ANY UNIQUE IDENTIFIER",
name: "USER NAME WHOM IS USING THE CHAT BOT",
fcmToken: "FOR NOTIFICATION ADD YOUR FIREBASE CLOUD MESSAGING TOKEN HERE" // Optional
),
chatStyle: ChatStyle(
appBarColor: Colors.black,
appBarTextColor: Colors.white,
bubbleStyle: BubbleStyle(visitorBgColor: Colors.blueGrey),
),
),
fullscreenDialog: true,
),
);
Configuration #
- baseUrl: The base URL of your domain where the chat service is hosted.
- appId: The unique identifier for your chat bot application.
- participantId: A unique identifier for the user participating in the chat.
- name: The name of the user using the chat bot.
- fcmToken: (Optional) The Firebase Cloud Messaging token for enabling notifications.
Chat Style Customization #
- appBarColor: The color of the app bar.
- appBarTextColor: The color of the text in the app bar.
- bubbleStyle: Customize the chat bubble style.
- visitorBgColor: The background color of the visitor's chat bubble.