A lot of communities rely on using Discord for communication, discussion and support.
Discord however has multiple disadvantages:
it is centralized and proprietary, so Discord has the full power over everything happening there
it has some privacy issues
it’s pretty complicated to export or publish message history
So why do so many communities use Discord?
It’s free, server owners can just create a new Discord server easily and without any technical knowledge
It’s very convenient, because users can just use one global account for every community and have everything in one place
So let’s introduce SkyChat, a decentralized alternative to Discord that aims to fix these issues, powered by Skynet and Akash!
SkyChat uses MySky to let users login in a decentralized way. With MySky, every user fully owns their key pair, which is the root of their decentralized identity. MySky also enables sharing data between different Skynet apps, so for example the profile picture and username you set using MySky is visible in SkyChat, SkyChess or SkyTransfer! You can read more about how MySky works and what it does here: MySky: Your Home on the Global Operating System of the Future | by David Vorick | Sia and Skynet Blog
MySky makes it possible to join multiple SkyChat Servers in a completely decentralized way using the same identity.
SkyChat never contacts another user or SkyChat server directly, it always writes and reads the current state from and to their preferred Skynet portal only. This also has the advantage, that all messages and users state is kept online, even if all moderators and admins of a SkyChat server quit and/or stop the Akash node running it. The Akash node is only used to mutate the state of a SkyChat channel, so without it being active, everything basically stays the same. This also makes it pretty reliable, because even in case of an outage, all existing messages are still available.
And because all state is saved on Skynet, the container running on Akash does not need to save any state! It just needs some environment variables with user-generated secret keys and some basic configuration, so it can be started at a new provider or location very fast in case something happens.
Direct messages are not yet implemented, but they will use end-to-end-encryption to make sure that nobody can read them.
One difference to other self-hosted chat tools like Matrix or Zulip I already mentioned earlier, is that clients never directly connect to a SkyChat server running on Akash or somewhere else. This makes things like DDoS attacks impossible and allows someone who wants to create a SkyChat server to just run the server software on their own device or hardware without having to expose it to the internet.
And when wanting 24/7 uptime for a SkyChat server, Akash is the easiest choice! Just deploy the SkyChat server container using Akash and the SkyChat server will run as expected - for very cheap. Even for 1000+ users, the Akash node needs next to no bandwidth or power, because all the media content is directly handled by Skynet and there are no direct client connections made to it.
Usually when creating a chat server, the work needed to keep it running does get a lot bigger with every user and channel added. Because all the client-server interaction happens using Skynet, the SkyChat server only needs to listen to (n + 1) SkyDB entries (n being the joined user count) and only write to SkyDB when a new user joins the server or a message is sent. “Approving and sending” a message is always the same work for the server, it doesn’t matter if there are 10 or 10000 users who are part of the SkyChat server.
The SkyChat protocol uses the Feed DAC data structures from SkyStandards: skystandards/draft-01 at main · SkynetLabs/skystandards · GitHub
This means, that all Skynet apps supporting the Feed DAC can display content from SkyChat! So you can for example use a SkyChat channel to publish your blog posts and then someone can follow the channel on Rift and see all the messages in their feed!
It should also be pretty easy to create a Matrix bridge in the future.
Skynet and MySky to store all of the state
Akash and Docker to run the always-online moderation SkyChat server
The Dart programming language and the Skynet Dart SDK for all of the server-side and client-side logic, all created by me (GitHub - redsolver/skynet: Use Sia Skynet and SkyDB in your Dart and Flutter projects (Decentralized CDN and database))
HTML and CSS for the frontend UI and layout, most of it created by other developers, see the contributors here: GitHub - adnssc/SkyChat: SkyChat is a decentralized chat platform inspired by discord.
A working version with all basic features is deployed and can be tried here: https://chatbubble.hns.siasky.net/
Or you can use it integrated in the experimental new “SkynetOS” interface: http://skappy.hns.siasky.net/
The server for the SkyChat test server is currently running on Akash 24/7.
Implement more features, for example contacts, direct messages, dark mode, reactions or file transfer.
Thanks for reading, feel free to ask if you have any questions or feedback.