Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/sonyarianto/karatan
Template/sample/skeleton/boilerplate web framework implemented in Rust (Actix Web)
https://github.com/sonyarianto/karatan
backend rust web-api
Last synced: 26 days ago
JSON representation
Template/sample/skeleton/boilerplate web framework implemented in Rust (Actix Web)
- Host: GitHub
- URL: https://github.com/sonyarianto/karatan
- Owner: sonyarianto
- License: mit
- Created: 2024-02-29T11:37:05.000Z (11 months ago)
- Default Branch: main
- Last Pushed: 2024-03-03T15:01:11.000Z (11 months ago)
- Last Synced: 2024-11-12T10:41:10.764Z (3 months ago)
- Topics: backend, rust, web-api
- Language: Rust
- Homepage:
- Size: 82 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Funding: .github/FUNDING.yml
- License: LICENSE
Awesome Lists containing this project
README
# Karatan
Karatan is a template/sample/skeleton/boilerplate web framework implemented in Rust using Actix Web. Initially to makes my life easy. It contains simple sample to start your own backend system. Is it performant? I am not sure since I am still learning Rust as well.
## Requirements
- Rust
## How to run?
- Clone the repo and go to the project directory.
- Type `cargo build` and then `cargo run` to run the program.
- It will run the web server on port `8000`, try at http://localhost:8000.
- Then you can try several available sample routes below while reading the source code.## Available sample routes
- (GET) / => Return string "Hello, World!"
- (GET) /about => Return string "This is about page"
- (POST) /upload => Imaginary path for POST end-point, still unimplemented
- (GET) /json => Return JSON data from static string
- (GET) /{name}/age/{age} => Return string with name and age from the URL
- (GET) /external/api/1 => Return JSON data from external API (https://jsonplaceholder.typicode.com/todos)
- (GET) /external/api/2 => Return JSON data from external hidden API with a bearer token## Learn the code
- The entry point file is on `src/main.rs`, for now that's single file and all logic is all there, no include files for easy to learn.
## License
MIT
Copyright © 2024 Sony Arianto Kurniawan <> and contributors.