Quickstart
Get your first BustAPI app running in under 5 minutes.
Installation
Requirements
- Python 3.10 - 3.14
- Pre-built wheels for Linux, macOS, and Windows
Hello World
Create a file called app.py:
| app.py | |
|---|---|
Run it:
Open http://127.0.0.1:5000 in your browser.
Level Up: Turbo Routes
For maximum performance, use @app.turbo_route():
Benchmark Results (v0.8.0)
Tested with oha -z 10s -c 50 on Python 3.13:
| Route Type | Linux (4w) | macOS | Windows |
|---|---|---|---|
| Static turbo | 105,012 | 35,560 | 17,772 |
| Dynamic turbo | 99,142 | 27,532 | 17,844 |
| Cached turbo | ~160,000 | - | - |
Note
Turbo routes skip middleware and sessions for speed. Use @app.route() if you need those features.
Production Mode
For maximum performance, use multiprocessing:
| app.py | |
|---|---|
- Spawns 4 worker processes for parallel request handling
- Always disable debug in production!
Platform Performance (v0.8.0)
| Platform | Workers | RPS | Note |
|---|---|---|---|
| Linux | 4 | 105,012 | SO_REUSEPORT load balancing |
| macOS | 1 | 35,560 | Single-process mode |
| Windows | 1 | 17,772 | Single-process mode |
Production Recommendation
Deploy on Linux for maximum performance with kernel-level load balancing.
Next Steps
-
Learn about dynamic paths and blueprints.
-
Deep dive into high-performance routes.
-
Scale to 100k+ RPS on Linux.
-
Secure your API with tokens.