
BurgerAPI
A fast, file-based API framework for Bun, with TypeScript and JavaScript. Pakistan’s first Bun.js framework, created by Isfhan Ahmed.
npm downloads, last 30 days
2,867
| Day | Downloads |
|---|---|
| 3 Nov | 26 |
| 4 Nov | 39 |
| 5 Nov | 56 |
| 6 Nov | 8 |
| 7 Nov | 15 |
| 8 Nov | 26 |
| 9 Nov | 24 |
| 10 Nov | 90 |
| 11 Nov | 17 |
| 12 Nov | 7 |
| 13 Nov | 12 |
| 14 Nov | 50 |
| 15 Nov | 5 |
| 16 Nov | 4 |
| 17 Nov | 6 |
| 18 Nov | 2 |
| 19 Nov | 14 |
| 20 Nov | 2 |
| 21 Nov | 2 |
| 22 Nov | 15 |
| 23 Nov | 550 |
| 24 Nov | 96 |
| 25 Nov | 31 |
| 26 Nov | 701 |
| 27 Nov | 384 |
| 28 Nov | 440 |
| 29 Nov | 92 |
| 30 Nov | 66 |
| 1 Dec | 63 |
| 2 Dec | 24 |
GitHub stars
166
npm packages
3
Latest version
1.0.0-beta.3
Saved numbers, counting @burger-api/cli, burger-api, @burger-api/node-server
Years of Laravel, Express and everything between showed me what felt simple and what felt heavy. When Bun arrived, the question wasn’t whether to build a framework. It was what one would look like if it kept only the good parts.
A folder is a route
// src/api/users/[id]/route.ts → GET /api/users/:id
import type { BurgerContext } from 'burger-api';
export async function GET(ctx: BurgerContext) {
return Response.json({ id: ctx.params.id });
}
What’s in the box
File-based routing
Folders become URLs, with [param] and [...] wildcard routes.
Six lifecycle hooks
onRequest, transform, beforeRoute, afterRoute, mapResponse and onError, global or per route.
Validation you already know
Zod, Valibot or ArkType for body, query, params, headers and cookies, fully typed.
OpenAPI 3.1 out of the box
Docs generated from your routes, with Swagger UI, Scalar or Redoc at /docs.
Plugins and providers
Add features in plugins.ts and share services in providers.ts.
Runs everywhere
Bun, Node, Cloudflare Workers, Deno and Vercel. Every route compiles to a native Bun route.
How it grew
- Feb 2025Launch Bun-native server, file routing, Zod validation and Swagger docs.
- Apr 2025v0.2 Faster core, better middleware handling and OpenAPI output.
- Nov 2025v0.7 A new CLI, a Bun workspace monorepo and major speedups.
- v0.9Ecosystem burger-api add cors logger rate-limiter, plus one-line installers.
- 1.0 betaRewritten from the ground up New core, hook lifecycle, plugins and Standard Schema validation.


