Chatty is an Android app designed as the final project for CS50x, providing users with a platform to connect through chat rooms. The app encompasses essential features such as authentication, real-time messaging, and seamless room management. Built with Jetpack Compose and following the MVVM architecture, Chatty delivers a modern and intuitive user experience.
Image by roserodionova on Freepik
-
Authentication: Users can securely register and log in, ensuring a personalized and secure chat experience.
-
Room Management: Create new chat rooms, join existing ones using unique IDs, delete rooms, and leave discussions at your convenience.
-
Real-time Messaging: Experience dynamic conversations with real-time messaging capabilities, allowing users to send and receive messages instantly within joined chat rooms.
-
Modern UI: Utilizing Jetpack Compose, Chatty boasts a contemporary user interface that is both visually appealing and user-friendly.
- For a complete experience, ensure you have the chatty-server running. Visit the Chatty-server repository, follow the instructions to start the server.
- Clone this repository.
- Create an
env.properties
file in the project's root folderChatty
. - Populate the file with the server URLs:
SERVER_URL_DEBUG=http://xxx.xxx.xxx.xxx SERVER_URL_RELEASE=http://xxx.xxx.xxx.xxx
- Build and run Chatty on your Android device or emulator.
Important
In Chatty/app/src/main/AndroidManifest.xml
- Set
android:usesCleartextTraffic="true"
to use HTTP in local development. - Set
android:usesCleartextTraffic="false"
to use HTTPS after you've deployed chatty-server to ensure secure communication.
To generate a signed APK for the Chatty app, you'll need to replace the following placeholders:
- The
your-keystore-name.keystore
file will be automatically created in the root of the project by the Codespaces setup. You need to replace it with your keystore file. This keystore file will be used for signing the APK.
The keystore.properties
file will be automatically created in the root of the project by the Codespaces setup. You need to replace the placeholders in the file with your actual keystore information:
STORE_FILE=/workspaces/Chatty/your-keystore-name.keystore
STORE_PASSWORD=your_keystore_password
KEY_ALIAS=your_key_alias
KEY_PASSWORD=your_key_password
Ensure the env.properties
file in the root of the project is populated with the correct server URLs. Replace the placeholders with the actual URLs for your environments:
SERVER_URL_DEBUG=http://xxx.xxx.xxx.xxx
SERVER_URL_RELEASE=https://xxx.xxx.xxx.xxx
To generate the APK, use the following commands from the project root:
./gradlew assembleDebug # For the debug APK
./gradlew assembleRelease # For the release APK
Note
In case of any issues, check out the steps here to debug: Chatty | Wiki