https://forem.julialang.org/ndortega/oxygenjl-a-breath-of-fresh-air-for-programming-web-apps-in-julia-454d Skip to content Julia Community [ ] Log in Create account Julia Community Julia Community is a community of amazing users A fresh approach to technical computing. Create account Log in * Home * Discourse * Docs * YouTube * Slack * Zulip * Discord * Learn * Podcasts * Sponsors Other * Code of Conduct * Privacy Policy * Terms of Use Copy link Copied to Clipboard Share to Twitter Share to LinkedIn Share to Reddit Share to Hacker News Share to Facebook Share Post via... Report Abuse Cover image for Oxygen.jl: A breath of fresh air for programming web apps in Julia Nathan Ortega Nathan Ortega Posted on Jun 6 Oxygen.jl: A breath of fresh air for programming web apps in Julia #package #web #framework #http I'm excited to announce Oxygen.jl, a micro-framework built on top of the HTTP.jl library that's designed to simplify building web applications in Julia. using Oxygen using HTTP @get "/greet" function(req::HTTP.Request) return "hello world!" end # both path parameters are automatically converted to Float64's @get "/multiply/{a}/{b}" function(req, a::Float64, b::Float64) return a * b end # all objects are automatically deserialized into JSON @get "/getdata" function() return Dict("message" => "hello!") end # mount all nested files inside the "content" folder under "/static" @staticfiles "content" "static" # start the web server serve() Features * Straightforward routing (@get, @post, @put, @patch, @delete and @route macros) * Out-of-the-box JSON serialization & deserialization * Optional type definition support for Path parameters * Helper functions to parse & transform the body of requests & responses * Hosting static files * Built-in multithreading support Why build another web framework? That's a great question, why create another package if Julia already has full stack frameworks like Genie.jl that can do just about anything? My quick answer: most people don't need all features that come with these heavyweight packages. About a month ago, I was one of those people looking to quickly spin up a web server to prototype some ideas. I wanted something lightweight and straightforward, and I didn't want to spend a lot of time learning a new syntax. Ideally, I wanted something similar to Flask or FastApi but in Julia. So, I set out to create this package and design a no-nonsense api that would hopefully feel familiar to JS and Python programmers and drive greater adoption in these communities. Feature Requests If you have any ideas or feature requests, please feel free to open an issue on the github page! Discussion (6) Subscribe pic [ ] [ ] Upload image [Upload] [ ] Templates Personal Moderator loading Create template Templates let you quickly answer FAQs or store snippets for re-use. Submit Preview Dismiss ifihan profile image Ifihan Olusheye Ifihan Olusheye [anBn] Ifihan Olusheye Follow Software Developer & Technical Writer. * Joined May 16, 2022 * Jun 6 * Edited on Jun 6 * Copy link * * Hide * * * This is nice. The first thing that came to mind was this is Flask but for Julia and I'm happy I saw it in the post. Great work I'll try it out and if I find have any questions, I will ask 6 likes Reply cjdoris profile image Christopher Rowley Christopher Rowley [LnBuZw] Christopher Rowley Follow * Joined Jun 1, 2022 * Jun 6 * Copy link * * Hide * * * Looks cool, I too have wanted "FastAPI for Julia". 5 likes Reply logankilpatrick profile image Logan Kilpatrick Logan Kilpatrick [cGc] Logan Kilpatrick Follow Julia Developer Community Advocate | JuliaCon Organizer | NumFOCUS Board of Directors | Ping me if I can be of any help! * Email logan@julialang.org * Location California * Joined Nov 8, 2021 * Jun 6 * Copy link * * Hide * * * Same here, Jeremey Howard (creator of FastAI) has said many times that having things like FastAPI is critical for Julia's long term success so I am excited to see this! 4 likes Reply imresamu profile image ImreSamu ImreSamu [LnBuZw] ImreSamu Follow interested in Postgres, PostGIS, Routing, Geo, Openstreetmap, Wikidata, ... Data ... * Joined Jun 1, 2022 * Jun 6 * Copy link * * Hide * * * Please add a benchmark :-) to -> github.com/TechEmpower/FrameworkBe... 1 like Reply edwinlock profile image Edwin Lock Edwin Lock [LmpwZWc] Edwin Lock Follow * Joined Jun 1, 2022 * Jun 6 * Copy link * * Hide * * * Very nice. Do you happen to know whether there's a templating engine (like Jinja for flask) that can be used in combination with Oxygen? 2 likes Reply ndortega profile image Nathan Ortega Nathan Ortega [LnBuZw] Nathan Ortega Follow * Joined Jun 5, 2022 * Jun 6 * Copy link * * Hide * * * There's a package called Mustache.jl which is a generic templating engine. They should be compatible, but I haven't tested this yet. Let me know if you run into any issues. github.com/jverzani/Mustache.jl 2 likes Reply Code of Conduct * Report abuse Are you sure you want to hide this comment? It will become hidden in your post, but will still be visible via the comment's permalink. [ ] Hide child comments as well Confirm For further actions, you may consider blocking this person and/or reporting abuse Read next inphyt profile image [ANN] ICD_GEMs.jl: A Package to Translate Between ICD-9 and ICD-10 Codes Interdisciplinary Physics Team - May 25 inphyt profile image [ANN] UnrollingAverages.jl: A Package to Deconvolve Time Series Data Interdisciplinary Physics Team - May 25 melonedo profile image Julia Interpolation Cookbook melonedo - Jun 5 ben profile image What makes Julia special? Ben Halpern - Jun 2 [LnBuZw] Nathan Ortega Follow * Joined Jun 5, 2022 Julia Community -- Discuss, write about, and share Julia programming language content. Built on Forem -- the open source software that powers DEV and other inclusive communities. Made with love and Ruby on Rails. Julia Community (c) 2021 - 2022. Julia Community A fresh approach to technical computing. Log in Create account