A lightweight Python web framework.
Project description
Slush
Slush is a lightweight Python web framework for building fast, clean, and extensible APIs and backend services.
🚀 Overview
Slush is designed to give developers full control without unnecessary complexity. It provides a minimal core with powerful built-in features, allowing you to build APIs and web applications quickly while keeping the codebase clean and understandable.
Whether you're prototyping, building microservices, or creating production-ready backends, Slush offers a solid and flexible foundation.
✨ Features
- ⚡ Built-in development server with auto-reload
- 🧭 Simple and expressive routing system
- 🔌 Route-level middleware support
- 📥 Request parsing (query params, JSON, form data, files)
- 📤 Flexible response handling (JSON, text, HTML, redirects)
- 📦 Pydantic-based request validation
- 📄 Automatic OpenAPI schema generation
- 📊 Interactive API docs (Swagger UI)
- 🌐 CORS support with preflight handling
- 📁 Static file serving
- 🧩 Jinja2 template rendering
- 🚦 Rate limiting (throttling) middleware
- ⚡ Response caching with optional Redis backend
📦 Installation
$ pip install slush
⚡ Quick Start
Create your application
# main.py
from slush.app import Slush
app = Slush()
@app.route("/hello", methods=["GET"])
def hello(request):
return {"message": "Hello from Slush!"}
Run the server
$ python run.py
Or use the built-in CLI:
$ slush runserver main:app
Gunicorn
$ gunicorn main:app
- Minimal core, maximum flexibility
- Explicit behavior over implicit assumptions
- Easy to extend, easy to reason about
📄 License
This project is licensed under the BSD 3-Clause License.
🌐 Links
- 🐙 GitHub: https://github.com/farazkhanfk7/slush
- 📦 PyPI: https://pypi.org/project/slush
- 📘 Documentation: https://slush.gitbook.io/docs
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file slush-1.2.0.tar.gz.
File metadata
- Download URL: slush-1.2.0.tar.gz
- Upload date:
- Size: 21.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.15
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d9f579d7ff3633f59d232afe84edb804fdcc4be0b25d36bcf65280a673c6e0d6
|
|
| MD5 |
80bf7f29496d7ec0f9fdaa43128ef0db
|
|
| BLAKE2b-256 |
fdd84a2366771a1d0bf979d06a208fc61490057a7adcc301155552cf06b28337
|
File details
Details for the file slush-1.2.0-py3-none-any.whl.
File metadata
- Download URL: slush-1.2.0-py3-none-any.whl
- Upload date:
- Size: 22.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.15
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
dfe758337137cc1067075bba2a4ca44f854226477b749f45b0904950e543a5d1
|
|
| MD5 |
e8891004ccae82778b6d8bf40a143c8b
|
|
| BLAKE2b-256 |
21b7b2868ccd1cb8b45ac6cc9fcbacd117c7e44a27a6337dea421ea6c1a1989e
|