loyal812 / rust-chat-app

The essence of the work is that the client sends a message to the backend and these messages are shared with other connected clients via websockets.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Simple chat API backend demo

This is a backend for a chat.

The essence of the work is that the client sends a message to the backend and these messages are shared with other connected clients via websockets.

GIF demo

Try it out!

  1. Install Rust
  2. Run the server:
$ cargo run --release
  1. Use an API client of your choice to send and receive messages:
POST 127.0.0.1:8080/message
GET 127.0.0.1:8080/messages
  1. As for continuous message updates you can use websocat:
$ cargo install websocat

$ websocat ws://127.0.0.1:9090

About

The essence of the work is that the client sends a message to the backend and these messages are shared with other connected clients via websockets.


Languages

Language:Rust 100.0%