Skip to content

Latest commit

 

History

History
64 lines (39 loc) · 2.32 KB

README.md

File metadata and controls

64 lines (39 loc) · 2.32 KB

PubNub Chat App

The Simple chat app demonstrates how to build a chat application using PubNub Chat and PubNub Dart SDK. Learn how to add private messaging and group messaging features in general chat application. Learn how to build features like send/receive messages, typing indicators, online members list. You can download the project to run on your local machine, and explore the code to see how we built it.

Home Profile Presence

The application uses PubNub service with Dart SDK.

Prerequisites

PubNub Account

To run this application you must obtain publish and subscribe keys from your PubNub Account. If you don't already have an account, you can create one for free.

  1. Sign in to your PubNub Dashboard.

  2. Click Create New App.

  3. Give your app a name, and select Chat App as the app type.

  4. Select a region to store your user data (e.g. Portland).

  5. Click Create.

  6. Click your new app to open its settings, then click its keyset.

  7. Locate the Publish and Subscribe keys. Include these keys in this project's .env file.

Running the project

  1. Clone the GitHub repository.

    git clone https://github.com/pubnub/flutter-ref-app-simple-chat.git
  2. Add .env file with keyset values as described in .env.sample.

    PUBNUB_SUBSCRIBE_KEY="<Enter Your PubNub Publish Key Here>"
    PUBNUB_PUBLISH_KEY="<Enter Your PubNub Subscribe Key Here>"
  3. Install the dependencies.

    cd flutter-ref-app-simple-chat
    flutter pub get
  4. Start an simulator or connect your device and run application with selected device.

    flutter run

Further Information

Visit the PubNub Dart SDK Docs page for more information about how to use PubNub Dart SDK. Please refer Flutter Install page for flutter framework and simulator setup.