zigmund@localhost: ~
 ███████╗██╗ ██████╗ ███╗   ███╗██╗   ██╗███╗   ██╗██████╗
 ╚══███╔╝██║██╔════╝ ████╗ ████║██║   ██║████╗  ██║██╔══██╗
   ███╔╝ ██║██║  ███╗██╔████╔██║██║   ██║██╔██╗ ██║██║  ██║
  ███╔╝  ██║██║   ██║██║╚██╔╝██║██║   ██║██║╚██╗██║██║  ██║
 ███████╗██║╚██████╔╝██║ ╚═╝ ██║╚██████╔╝██║ ╚████║██████╔╝
 ╚══════╝╚═╝ ╚═════╝ ╚═╝     ╚═╝ ╚═════╝ ╚═╝  ╚═══╝╚═════╝

zigmund@dev:~$ A FastAPI-inspired web framework for Zig_

A FastAPI-inspired Web Framework for Zig

Open source · MIT License · Zig 0.15.2

─── [ FEATURES ] ───

FastAPI Patterns

Familiar API design inspired by Python's FastAPI. Typed parameter extraction, dependency injection, and automatic validation.

🔒

Type-Safe Routes

Compile-time route validation with typed query, path, header, and body parameters. Catch errors before they reach production.

📋

OpenAPI 3.1

Automatic OpenAPI spec generation with embedded Swagger UI and ReDoc. Your API documentation stays in sync with your code.

🧩

Middleware Pipeline

Composable middleware for CORS, rate limiting, compression, sessions, and CSRF protection. Build your own with simple hooks.

🔐

Security Built-in

First-class support for OAuth2, HTTP Bearer, API keys, and HTTP Basic auth. Security scheme scaffolding included.

🧪

TestClient

In-process test client for fast, deterministic testing. No network overhead — test your handlers directly.

─── [ QUICK START ] ───

01

Add dependency

build.zig.zon
.dependencies = .{
    .zigmund = .{
        .url = "https://github.com/Softorize/zigmund/archive/main.tar.gz",
    },
},
02

Write your app

src/main.zig
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!",
    });
}
03

Run it

terminal
$ 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

─── [ WHY ZIGMUND ] ───

~$ PERFORMANCE

Zig compiles to native code with no runtime overhead. No garbage collector, no hidden allocations. Your API serves requests at wire speed.

~$ FAMILIAR API

If you know FastAPI, you already know Zigmund. Same patterns, same developer experience — powered by Zig's compile-time safety.

~$ SINGLE BINARY

Deploy a single static binary. No interpreters, no virtual machines, no container runtimes required. Just scp and run.