This is a challenge where i create the same api with different languages, so i can rank them (subjectively) in terms of difficulty, usefulness and fun factor. I will try to finish in one sitting as fast as possible. If the language is too exotic i won't time it.
- 🔴 - No previous experience
- ⚪ - Some previous experience, not related to web server/api stuff
- 🔵 - Have previous experience directly related to web server/api stuff
Language | Framework | Experience | Time to beat(h:m) | Done |
---|---|---|---|---|
kotlin | javalin | 🔴 | ~5:00 | ✔️ |
clojure | ring | 🔴 | ❌ | |
haskell | yesod | 🔴 | ❌ | |
f# | dotnet | 🔴 | ❌ | |
ocaml | mirage | 🔴 | ❌ | |
zig | zhp | 🔴 | ❌ | |
vlang | vweb | 🔴 | ❌ | |
c# | dotnet? | 🔴 | ❌ | |
swift | Swifter | 🔴 | ❌ | |
scala | akka-http | 🔴 | ❌ | |
perl | Perldancer | 🔴 | ❌ | |
java | Spring | 🔴 | ❌ | |
crystal | router.cr | 🔴 | ❌ | |
odin | odinhttp | 🔴 | ❌ | |
racket | (builtin) | 🔴 | ❌ | |
dart | aqueduct | 🔴 | ❌ | |
julia | HTTP.jl | 🔴 | ❌ | |
jolie | (builtin) | 🔴 | ❌ | |
imba | express (js interop) | 🔴 | ❌ | |
jython | ? | 🔴 | ❌ | |
vale | ? | 🔴 | ❌ | |
nim | whip? | 🔴 | ❌ | |
php | laravel | 🔴 | ❌ | |
ruby | on rails | 🔴 | ❌ | |
c++ | drogon | ⚪ | ~7:00 | ✔️ |
elixir | phoenix | ⚪ | ❌ | |
python | fastapi | ⚪ | ❌ | |
lua | lapis | ⚪ | ❌ | |
rust | poem | 🔵 | ❌ | |
go | echo | 🔵 | ❌ | |
nodejs | express | 🔵 | 0:33 | ✔️ |
- Have the following routes
- /api/auth/register -> {username: string, password: string} -> 200 (409 if err)
- /api/auth/login -> {username: string, password: string} -> { token: "string" } 200 (401 if err)
- /api/protected -> Authorization header -> authorized ? {message: "you're in"} : {message: "you're in! just kidding, fuck you!"}
- Have cors enabled (all origins)
- Persist user data (using an orm if possible)
- Use environment variables for secrets
- httpit benchmark results (running release builds if compiled)
- Setup instructions and final considerations on readme
- Use youtube (only documentation/articles allowed)
- Ask someone for help