Skip to content

A messaging social platform based on Discord for Desktop and Android.

License

Notifications You must be signed in to change notification settings

Aghajari/AP-FinalProject

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

34 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

AP-FinalProject

A secure messaging social platform based on Discord for Desktop and Android.
This is my final project for Advanced-Programming (AP) in Amirkabir University of Technology (AUT).

Technologies Used:

  • JavaFX for Desktop GUI
  • Java for Android
  • Java for Socket And ServerSocket
  • Node.js for Rest API
  • PHP for Sample Bots
  • MongoDB And MySQL for Database

Libraries Used:

Video:

video.mp4

This video shows the performance of the application in both Android and desktop versions.
It also displays smooth animations.

Desktop:
The desktop version has been tested on Mac (OS X) and Windows (10)

Android:
The Android version is written in Java,
I tested XmlByPass in this project and it came out proud

Port:

  • Api (Node.js) runs on 3154 by default.
    Change port in .env
    Make sure to change port of API_ADDRESS in ApiService.java too.
  • ServerSocket runs on 2424 by default.
    Change SERVER_PORT in ApiService.java Server, Desktop, Android

Installation:

  • Api (Node.js)

    • Replace YOUR-DOMAIN.com with your domain address in app.js
    • Change jwt_secret in .env (Something random and secure)
    • Install npm packages: npm install
    • Run project: node app.js
  • Server

  • Desktop

  • Android

Chat Page

These are some screen shots of PrivateMessage and Server's GroupChat.
Reactions are lottie animations from telegram emoji set.


Voice Call

Voice call over socket tcp connection (i'll replace it with VoIP soon...)

Friendship

Send friendship request, block your enemies :D, Chat with your online friends.

Servers

Join a server if you have an invite code,
Create a server and design channels & groups then invite your friends to start a party!
Manage permissions of each member in your server.

Login By QRCode

You can login or signup in normal way in both desktop and android
You can also link your authorized android account to the desktop by scanning a QRCode!

Bot

Connect your account to a bot. (Only for developers)
A bot is only an HTTP api link, You can develop the api in all programming languages.

This one is a "Hello World!" bot code written in PHP.

<?php
header("Content-Type: application/json");

$data = json_decode(file_get_contents('php://input'));

echo json_encode([
    "to"=>$data->chatId, 
    "text"=>"Hello World!"
]);

?>

See more...

Bot Api Document

Field Type Description
chatId String Unique identifier for this chat
from User Sender of the message
to User Receiver of the message, if receiver is a user
server Server Server details, if receiver is channel of a server
channel Server.Channel Receiver of the message if is channel of a server
isPrivateMessage Boolean True, if receiver is a user
message Message Information about the message

User

Field Type Description
avatar String User's avatar link
username String User's user name
nickname String User's nick name
email String User's email address
isOnline Boolean True, if user is online

Server

Field Type Description
id String Server's unique id
name String Server's name
avatar String Server's avatar link
channels Array of Server.Channel List of all channel and groups in this server

Server.Channel

Field Type Description
id String Channel's unique id
name String Channel's name
type Integer 0 if is a channel, 1 if is a group

Message

Field Type Description
text String Message's text
time Integer Date the message was sent in Unix time
fromId String Id of sender of this message
toId String Id of receiver of this message

About

A messaging social platform based on Discord for Desktop and Android.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published