███████╗██╗ ██████╗ ███╗ ███╗██╗ ██╗███╗ ██╗██████╗ ╚══███╔╝██║██╔════╝ ████╗ ████║██║ ██║████╗ ██║██╔══██╗ ███╔╝ ██║██║ ███╗██╔████╔██║██║ ██║██╔██╗ ██║██║ ██║ ███╔╝ ██║██║ ██║██║╚██╔╝██║██║ ██║██║╚██╗██║██║ ██║ ███████╗██║╚██████╔╝██║ ╚═╝ ██║╚██████╔╝██║ ╚████║██████╔╝ ╚══════╝╚═╝ ╚═════╝ ╚═╝ ╚═╝ ╚═════╝ ╚═╝ ╚═══╝╚═════╝
zigmund@dev:~$ A FastAPI-inspired web framework for Zig_
Open source · MIT License · Zig 0.15.2
Familiar API design inspired by Python's FastAPI. Typed parameter extraction, dependency injection, and automatic validation.
Compile-time route validation with typed query, path, header, and body parameters. Catch errors before they reach production.
Automatic OpenAPI spec generation with embedded Swagger UI and ReDoc. Your API documentation stays in sync with your code.
Composable middleware for CORS, rate limiting, compression, sessions, and CSRF protection. Build your own with simple hooks.
First-class support for OAuth2, HTTP Bearer, API keys, and HTTP Basic auth. Security scheme scaffolding included.
In-process test client for fast, deterministic testing. No network overhead — test your handlers directly.
.dependencies = .{ .zigmund = .{ .url = "https://github.com/Softorize/zigmund/archive/main.tar.gz", }, },
const std = @import("std"); const zigmund = @import("zigmund"); pub fn main() !void { var gpa = std.heap.GeneralPurposeAllocator(.{}){}; defer _ = gpa.deinit(); const alloc = gpa.allocator(); var app = try zigmund.App.init(alloc, .{ .title = "My API", .version = "0.1.0", }); defer app.deinit(); try app.get("/", hello, .{}); try app.serve(.{ .port = 8000 }); } fn hello( _: *zigmund.Request, alloc: std.mem.Allocator, ) !zigmund.Response { return zigmund.Response.json(alloc, .{ .message = "Hello, World!", }); }
$ zig build run INFO Zigmund v0.1.0 serving on http://0.0.0.0:8000 INFO OpenAPI docs at http://0.0.0.0:8000/docs
Zig compiles to native code with no runtime overhead. No garbage collector, no hidden allocations. Your API serves requests at wire speed.
If you know FastAPI, you already know Zigmund. Same patterns, same developer experience — powered by Zig's compile-time safety.
Deploy a single static binary. No interpreters, no virtual machines, no container runtimes required. Just scp and run.