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.
- Install Rust
- Run the server:
$ cargo run --release
- 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
- As for continuous message updates you can use websocat:
$ cargo install websocat
$ websocat ws://127.0.0.1:9090