Add /api route handler

This commit is contained in:
Paul Makles
2020-02-18 10:04:06 +00:00
parent a763c8cb58
commit 35623452aa
2 changed files with 12 additions and 0 deletions

10
src/routes/root.rs Normal file
View File

@@ -0,0 +1,10 @@
use rocket_contrib::json::{ JsonValue };
use bson::{ bson, doc };
/// root
#[get("/")]
pub fn root() -> JsonValue {
json!({
"revolt": "0.0.1"
})
}