I think that the examples and resources of developing async web services in Rust are scarce. So I decided to open-source an API which I developed for an e-commerce site using actix-web framework a couple of months ago. I hope it gives an idea to those who wants to develop async web services using Rust Programming Language.
This API is literally real-wold example, it is live here
Create, Read, Update
users- JWT Authentication middleware
Read
listingsCreate, Read, Update
addressesCreate, Read, Update, Delete
basketCreate, Read
orders
You can either create a docker image, or run it locally.
- create a prod.env file, copy content of .env file to prod.env file, and change them as you wish
docker build -t you-name-it .
docker run --env-file ./prod.env --publish 3003:3003 --name name-your-container you-name-it
container named name-your-container
will start.
cargo run --release
app will start at port 3003.
Stars and PR's are welcome!