Installation#
Supported Python Versions#
ASGI-Tools requires Python 3.10 or newer. We recommend using the latest stable release for best performance and compatibility.
Note
PyPy3 is also supported and can provide performance benefits for some workloads.
Core Dependencies#
ASGI-Tools automatically installs its minimal dependencies:
Http-Router – Fast and flexible HTTP routing
Yarl – URL parsing and manipulation
Multidict – Multi-value dictionary structures
Installation Methods#
Using pip#
Install the latest release from PyPI:
pip install asgi-tools
For the latest development version directly from GitHub:
pip install git+https://github.com/klen/asgi-tools.git
Using Poetry#
If you manage dependencies with Poetry:
poetry add asgi-tools
ASGI Server Requirement#
ASGI-Tools is a toolkit/framework and requires an ASGI server to run your application. We recommend one of the following:
Uvicorn – Lightning-fast ASGI server
Daphne – HTTP, HTTP2, and WebSocket server
Hypercorn – ASGI server with HTTP/2 support
Install your preferred server:
pip install uvicorn # or daphne, or hypercorn
Verify Installation#
To verify that ASGI-Tools is installed correctly, create a simple test application:
from asgi_tools import App
app = App()
@app.route("/")
async def hello(request):
return "Hello, ASGI-Tools!"
Save this as test_app.py and run it with your chosen ASGI server:
uvicorn test_app:app
Visit http://127.0.0.1:8000/ in your browser. You should see: Hello, ASGI-Tools!
Next Steps#
✅ Continue learning:
Read the Usage guide for detailed usage examples
Explore the API Reference reference for all available components
Check out the examples for real-world patterns and best practices